]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
Sparc64: remove useless variable
authorBlue Swirl <blauwirbel@gmail.com>
Sun, 4 Sep 2011 11:32:23 +0000 (11:32 +0000)
committerBlue Swirl <blauwirbel@gmail.com>
Sat, 10 Sep 2011 14:56:01 +0000 (14:56 +0000)
Remove a useless variable, spotted by clang analyzer:
/src/qemu/target-sparc/op_helper.c:3904:18: warning: unused variable 'tmp' [-Wunused-variable]
    target_ulong tmp = val;
The error message is actually incorrect since the variable is used.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
target-sparc/op_helper.c

index d1a8dd9939aed73b29c7f9db2d71ccced107f431..48e1db8227f753467b8d13b64b458db887012ccf 100644 (file)
@@ -3901,10 +3901,8 @@ target_ulong cpu_get_ccr(CPUState *env1)
 
 static void put_ccr(target_ulong val)
 {
-    target_ulong tmp = val;
-
-    env->xcc = (tmp >> 4) << 20;
-    env->psr = (tmp & 0xf) << 20;
+    env->xcc = (val >> 4) << 20;
+    env->psr = (val & 0xf) << 20;
     CC_OP = CC_OP_FLAGS;
 }