diff options
author | Chris Lattner <sabre@nondot.org> | 2009-07-15 02:36:21 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-07-15 02:36:21 +0000 |
commit | 1a87c05ec011eaccb950e5f0160e2162e5747553 (patch) | |
tree | 491e0f171f64c8dc7701520b63fa5174a1fd5ba5 | |
parent | defd3000dc34cc237dc44530f930ebf184d5e890 (diff) | |
download | external_llvm-1a87c05ec011eaccb950e5f0160e2162e5747553.zip external_llvm-1a87c05ec011eaccb950e5f0160e2162e5747553.tar.gz external_llvm-1a87c05ec011eaccb950e5f0160e2162e5747553.tar.bz2 |
turn some if/then's into ?:
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75732 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp b/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp index f57945d..09c58a2 100644 --- a/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp +++ b/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp @@ -1029,10 +1029,7 @@ bool PPCDarwinAsmPrinter::doFinalization(Module &M) { SwitchToDataSection(".lazy_symbol_pointer"); O << Info.LazyPtr << ":\n"; O << "\t.indirect_symbol " << I->getKeyData() << '\n'; - if (isPPC64) - O << "\t.quad dyld_stub_binding_helper\n"; - else - O << "\t.long dyld_stub_binding_helper\n"; + O << (isPPC64 ? "\t.quad" : "\t.long") << " dyld_stub_binding_helper\n"; } } else if (!FnStubs.empty()) { SwitchToTextSection("\t.section __TEXT,__symbol_stub1,symbol_stubs," @@ -1044,20 +1041,14 @@ bool PPCDarwinAsmPrinter::doFinalization(Module &M) { O << Info.Stub << ":\n"; O << "\t.indirect_symbol " << I->getKeyData() << '\n'; O << "\tlis r11,ha16(" << Info.LazyPtr << ")\n"; - if (isPPC64) - O << "\tldu r12,lo16("; - else - O << "\tlwzu r12,lo16("; + O << (isPPC64 ? "\tldu" : "\tlwzu") << " r12,lo16("; O << Info.LazyPtr << ")(r11)\n"; O << "\tmtctr r12\n"; O << "\tbctr\n"; SwitchToDataSection(".lazy_symbol_pointer"); O << Info.LazyPtr << ":\n"; O << "\t.indirect_symbol " << I->getKeyData() << '\n'; - if (isPPC64) - O << "\t.quad dyld_stub_binding_helper\n"; - else - O << "\t.long dyld_stub_binding_helper\n"; + O << (isPPC64 ? "\t.quad" : "\t.long") << " dyld_stub_binding_helper\n"; } } |