aboutsummaryrefslogtreecommitdiff
path: root/target/microblaze
diff options
context:
space:
mode:
authorEdgar E. Iglesias <edgar.iglesias@xilinx.com>2016-08-09 14:59:35 +0200
committerEdgar E. Iglesias <edgar.iglesias@xilinx.com>2017-07-04 09:22:20 +0200
commite3e84983fb4d1006438335d869855340aacdeb59 (patch)
tree0f618e9e1e779e4636d7b0d60df8a8e25ac4d043 /target/microblaze
parentbc54e71e0c55db3ae4599b4333f349e5771cb5ef (diff)
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/microblaze')
-rw-r--r--target/microblaze/translate.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/target/microblaze/translate.c b/target/microblaze/translate.c
index 4136a8e0ac..e959de72f2 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);