summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRui Ueyama <ruiu@google.com>2016-02-04 23:18:22 +0000
committerRui Ueyama <ruiu@google.com>2016-02-04 23:18:22 +0000
commitf9cec37880805bad4d54571f90688d1ab11688b2 (patch)
tree1cba5fd66167df2c763e554ffc5861e569dedbf0
parentff56c1c6a04e4148ac89c6afd1c4060340586e7d (diff)
downloadbcm5719-llvm-f9cec37880805bad4d54571f90688d1ab11688b2.tar.gz
bcm5719-llvm-f9cec37880805bad4d54571f90688d1ab11688b2.zip
Merge conditions of two nested `if`s.
llvm-svn: 259843
-rw-r--r--lld/ELF/Writer.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp
index 1ce64d6a5b8..1a2fde9cbaf 100644
--- a/lld/ELF/Writer.cpp
+++ b/lld/ELF/Writer.cpp
@@ -292,12 +292,11 @@ void Writer<ELFT>::scanRelocs(
Body, getAddend<ELFT>(RI)});
// MIPS has a special rule to create GOTs for local symbols.
- if (Config->EMachine == EM_MIPS && !canBePreempted(Body, true)) {
- if (Type == R_MIPS_GOT16 || Type == R_MIPS_CALL16) {
- // FIXME (simon): Do not add so many redundant entries.
- Out<ELFT>::Got->addMipsLocalEntry();
- continue;
- }
+ if (Config->EMachine == EM_MIPS && !canBePreempted(Body, true) &&
+ (Type == R_MIPS_GOT16 || Type == R_MIPS_CALL16)) {
+ // FIXME (simon): Do not add so many redundant entries.
+ Out<ELFT>::Got->addMipsLocalEntry();
+ continue;
}
// If a symbol in a DSO is referenced directly instead of through GOT,
OpenPOWER on IntegriCloud