]> Git Repo - qemu.git/commitdiff
target-microblaze: dec_barrel: Use extract32
authorEdgar E. Iglesias <[email protected]>
Tue, 9 Aug 2016 12:59:35 +0000 (14:59 +0200)
committerEdgar E. Iglesias <[email protected]>
Tue, 4 Jul 2017 07:22:20 +0000 (09:22 +0200)
Use extract32 instead of opencoding the shifting and masking.
No functional change.

Reviewed-by: Richard Henderson <[email protected]>
Signed-off-by: Edgar E. Iglesias <[email protected]>
target/microblaze/translate.c

index 4136a8e0acadf5b0f203e46dfe692b34ac42ee6e..e959de72f2ba713c6ebef30e4a5eefb8f9151917 100644 (file)
@@ -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);
This page took 0.040174 seconds and 4 git commands to generate.