target-sh4: optimize xtrct
authorAurelien Jarno <aurelien@aurel32.net>
Sun, 16 Sep 2012 11:12:20 +0000 (13:12 +0200)
committerAurelien Jarno <aurelien@aurel32.net>
Fri, 21 Sep 2012 17:53:16 +0000 (19:53 +0200)
The register being 32 bit long, after a shift to the right by 16 bits,
the upper 16 bit are already cleared. There is no need to call ext16u
to clear them.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
target-sh4/translate.c

index 41a1f228c73c0187d62ad7d7d304d97c6c515849..92c5a1fb6dc6ec5fb9977ff001b3d6ebfa1d8afd 100644 (file)
@@ -751,7 +751,6 @@ static void _decode_opc(DisasContext * ctx)
            tcg_gen_shli_i32(high, REG(B7_4), 16);
            low = tcg_temp_new();
            tcg_gen_shri_i32(low, REG(B11_8), 16);
-           tcg_gen_ext16u_i32(low, low);
            tcg_gen_or_i32(REG(B11_8), high, low);
            tcg_temp_free(low);
            tcg_temp_free(high);