diff options
author | Cary Coutant <ccoutant@google.com> | 2014-12-22 10:13:37 -0800 |
---|---|---|
committer | Cary Coutant <ccoutant@google.com> | 2014-12-22 10:13:37 -0800 |
commit | e30880c2eeee3b43897161344bbbffd03f3a1c91 (patch) | |
tree | 97e0d58374f6fa51d4e09826edd43d1bb5c13ee0 /gold/powerpc.cc | |
parent | f953163fe9bb5b87edb168a6ea25e2baa966750f (diff) | |
download | gdb-e30880c2eeee3b43897161344bbbffd03f3a1c91.zip gdb-e30880c2eeee3b43897161344bbbffd03f3a1c91.tar.gz gdb-e30880c2eeee3b43897161344bbbffd03f3a1c91.tar.bz2 |
gold/
* powerpc.cc (Target_powerpc::relocate): Fix overflow check.
Diffstat (limited to 'gold/powerpc.cc')
-rw-r--r-- | gold/powerpc.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gold/powerpc.cc b/gold/powerpc.cc index 1407a0e..e456c85 100644 --- a/gold/powerpc.cc +++ b/gold/powerpc.cc @@ -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 |