diff options
author | Craig Topper <craig.topper@gmail.com> | 2016-04-16 19:09:32 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2016-04-16 19:09:32 +0000 |
commit | 1663e7a472a48a69cedb3ca26f4885425f2648bb (patch) | |
tree | 2664c8fedbf2af995ef95dfd41c55c0b68e9e6c6 | |
parent | fd4b9b02a31febf107560a4196e30c0aede2bc5d (diff) | |
download | bcm5719-llvm-1663e7a472a48a69cedb3ca26f4885425f2648bb.tar.gz bcm5719-llvm-1663e7a472a48a69cedb3ca26f4885425f2648bb.zip |
[X86] Use ternary operator to reduce code slightly. NFC
llvm-svn: 266534
-rw-r--r-- | llvm/lib/Target/X86/X86ISelLowering.cpp | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/llvm/lib/Target/X86/X86ISelLowering.cpp b/llvm/lib/Target/X86/X86ISelLowering.cpp index 284925c9030..263fc133a08 100644 --- a/llvm/lib/Target/X86/X86ISelLowering.cpp +++ b/llvm/lib/Target/X86/X86ISelLowering.cpp @@ -478,14 +478,9 @@ X86TargetLowering::X86TargetLowering(const X86TargetMachine &TM, // VASTART needs to be custom lowered to use the VarArgsFrameIndex setOperationAction(ISD::VASTART , MVT::Other, Custom); setOperationAction(ISD::VAEND , MVT::Other, Expand); - if (Subtarget.is64Bit()) { - setOperationAction(ISD::VAARG , MVT::Other, Custom); - setOperationAction(ISD::VACOPY , MVT::Other, Custom); - } else { - // TargetInfo::CharPtrBuiltinVaList - setOperationAction(ISD::VAARG , MVT::Other, Expand); - setOperationAction(ISD::VACOPY , MVT::Other, Expand); - } + bool Is64Bit = Subtarget.is64Bit(); + setOperationAction(ISD::VAARG, MVT::Other, Is64Bit ? Custom : Expand); + setOperationAction(ISD::VACOPY, MVT::Other, Is64Bit ? Custom : Expand); setOperationAction(ISD::STACKSAVE, MVT::Other, Expand); setOperationAction(ISD::STACKRESTORE, MVT::Other, Expand); |