diff options
author | Edgar E. Iglesias <edgar.iglesias@xilinx.com> | 2016-08-09 14:59:35 +0200 |
---|---|---|
committer | Edgar E. Iglesias <edgar.iglesias@xilinx.com> | 2017-07-04 09:22:20 +0200 |
commit | e3e84983fb4d1006438335d869855340aacdeb59 (patch) | |
tree | 0f618e9e1e779e4636d7b0d60df8a8e25ac4d043 /target | |
parent | bc54e71e0c55db3ae4599b4333f349e5771cb5ef (diff) | |
download | qemu-e3e84983fb4d1006438335d869855340aacdeb59.zip qemu-e3e84983fb4d1006438335d869855340aacdeb59.tar.gz qemu-e3e84983fb4d1006438335d869855340aacdeb59.tar.bz2 |
target-microblaze: dec_barrel: Use extract32
Use extract32 instead of opencoding the shifting and masking.
No functional change.
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com>
Diffstat (limited to 'target')
-rw-r--r-- | target/microblaze/translate.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/target/microblaze/translate.c b/target/microblaze/translate.c index 4136a8e..e959de7 100644 --- a/target/microblaze/translate.c +++ b/target/microblaze/translate.c @@ -670,8 +670,8 @@ static void dec_barrel(DisasContext *dc) return; } - s = dc->imm & (1 << 10); - t = dc->imm & (1 << 9); + s = extract32(dc->imm, 10, 1); + t = extract32(dc->imm, 9, 1); LOG_DIS("bs%s%s r%d r%d r%d\n", s ? "l" : "r", t ? "a" : "l", dc->rd, dc->ra, dc->rb); |