mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
tcg/optimize: Use fold_masks_z in fold_neg_no_const
Avoid the use of the OptContext slots. Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
fa3168ee93
commit
d151fd34b0
1 changed files with 2 additions and 7 deletions
|
@ -2044,14 +2044,9 @@ static bool fold_neg_no_const(OptContext *ctx, TCGOp *op)
|
|||
{
|
||||
/* Set to 1 all bits to the left of the rightmost. */
|
||||
uint64_t z_mask = arg_info(op->args[1])->z_mask;
|
||||
ctx->z_mask = -(z_mask & -z_mask);
|
||||
z_mask = -(z_mask & -z_mask);
|
||||
|
||||
/*
|
||||
* Because of fold_sub_to_neg, we want to always return true,
|
||||
* via finish_folding.
|
||||
*/
|
||||
finish_folding(ctx, op);
|
||||
return true;
|
||||
return fold_masks_z(ctx, op, z_mask);
|
||||
}
|
||||
|
||||
static bool fold_neg(OptContext *ctx, TCGOp *op)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue