gold/
authorCary Coutant <ccoutant@google.com>
Mon, 22 Dec 2014 18:13:37 +0000 (10:13 -0800)
committerCary Coutant <ccoutant@google.com>
Mon, 22 Dec 2014 18:13:37 +0000 (10:13 -0800)
* powerpc.cc (Target_powerpc::relocate): Fix overflow check.

gold/ChangeLog
gold/powerpc.cc

index f67df17b5b47db45ed98907e0f7ce69ba29aec38..457fa6b87b9b86e591e69b84609daa1845ecdcf5 100644 (file)
@@ -1,3 +1,7 @@
+2014-12-22  Cary Coutant  <ccoutant@google.com>
+
+       * powerpc.cc (Target_powerpc::relocate): Fix overflow check.
+
 2014-12-20  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR gold/14608
index 1407a0e873ec5c1e425c4595c3c9d85590d42e2d..e456c8522896c4507a6d3d81f590ff209363b554 100644 (file)
@@ -7531,7 +7531,6 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
       Insn* iview = reinterpret_cast<Insn*>(view - 2 * big_endian);
       Insn insn = elfcpp::Swap<32, big_endian>::readval(iview);
 
-      overflow = Reloc::CHECK_SIGNED;
       if ((insn & (0x3f << 26)) == 10u << 26 /* cmpli */)
        overflow = Reloc::CHECK_BITFIELD;
       else if (overflow == Reloc::CHECK_LOW_INSN
@@ -7542,6 +7541,8 @@ Target_powerpc<size, big_endian>::Relocate::relocate(
                  || (insn & (0x3f << 26)) == 25u << 26 /* oris */
                  || (insn & (0x3f << 26)) == 27u << 26 /* xoris */))
        overflow = Reloc::CHECK_UNSIGNED;
+      else
+       overflow = Reloc::CHECK_SIGNED;
     }
 
   typename Powerpc_relocate_functions<size, big_endian>::Status status
This page took 0.039825 seconds and 4 git commands to generate.