mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
tcg: Merge INDEX_op_shl_{i32,i64}
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
27d21ee7c7
commit
6ca594517a
7 changed files with 17 additions and 25 deletions
|
@ -446,10 +446,10 @@ static uint64_t do_constant_folding_2(TCGOpcode op, TCGType type,
|
|||
case INDEX_op_xor_vec:
|
||||
return x ^ y;
|
||||
|
||||
case INDEX_op_shl_i32:
|
||||
return (uint32_t)x << (y & 31);
|
||||
|
||||
case INDEX_op_shl_i64:
|
||||
case INDEX_op_shl:
|
||||
if (type == TCG_TYPE_I32) {
|
||||
return (uint32_t)x << (y & 31);
|
||||
}
|
||||
return (uint64_t)x << (y & 63);
|
||||
|
||||
case INDEX_op_shr_i32:
|
||||
|
@ -3031,7 +3031,7 @@ void tcg_optimize(TCGContext *s)
|
|||
CASE_OP_32_64(rotl):
|
||||
CASE_OP_32_64(rotr):
|
||||
CASE_OP_32_64(sar):
|
||||
CASE_OP_32_64(shl):
|
||||
case INDEX_op_shl:
|
||||
CASE_OP_32_64(shr):
|
||||
done = fold_shift(&ctx, op);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue