summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--target-ppc/op.c2
-rw-r--r--target-ppc/op_helper.h5
2 files changed, 3 insertions, 4 deletions
diff --git a/target-ppc/op.c b/target-ppc/op.c
index 0b972c8e69..f13f6f5676 100644
--- a/target-ppc/op.c
+++ b/target-ppc/op.c
@@ -720,7 +720,7 @@ void OPPROTO op_check_addo (void)
 void OPPROTO op_check_addo_64 (void)
 {
     if (likely(!(((uint64_t)T2 ^ (uint64_t)T1 ^ UINT64_MAX) &
-                 ((uint64_t)T2 ^ (uint64_t)T0) & (1UL << 63)))) {
+                 ((uint64_t)T2 ^ (uint64_t)T0) & (1ULL << 63)))) {
         xer_ov = 0;
     } else {
         xer_so = 1;
diff --git a/target-ppc/op_helper.h b/target-ppc/op_helper.h
index 8a735c1fd2..3aa6045838 100644
--- a/target-ppc/op_helper.h
+++ b/target-ppc/op_helper.h
@@ -313,12 +313,11 @@ static inline int _do_cntlzd (uint64_t val)
         cnt++;
     }
 #else
-    uint32_t tmp;
     /* Make it easier on 32 bits host machines */
     if (!(val >> 32))
-        cnt = cntlzw(val) + 32;
+        cnt = _do_cntlzw(val) + 32;
     else
-        cnt = cntlzw(val >> 32);
+        cnt = _do_cntlzw(val >> 32);
 #endif
     return cnt;
 }