diff options
| author | Nirav Dave <niravd@google.com> | 2016-03-30 15:41:12 +0000 |
|---|---|---|
| committer | Nirav Dave <niravd@google.com> | 2016-03-30 15:41:12 +0000 |
| commit | 8dd66e5753bcff1a7ea6bd217db0a94c6cb98585 (patch) | |
| tree | cdbf1733fa153f3d2ee5afbec8bb050d3ff6b3d7 /llvm/lib/Target | |
| parent | 20beeea24a6a11cac6e59dee8250b72fe24b6871 (diff) | |
| download | bcm5719-llvm-8dd66e5753bcff1a7ea6bd217db0a94c6cb98585.tar.gz bcm5719-llvm-8dd66e5753bcff1a7ea6bd217db0a94c6cb98585.zip | |
Remove HasFnAttribute guards to getFnAttribute calls
These checks are redundant and can be removed
Reviewers: hans
Subscribers: llvm-commits, mzolotukhin
Differential Revision: http://reviews.llvm.org/D18564
llvm-svn: 264872
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMTargetMachine.cpp | 1 | ||||
| -rw-r--r-- | llvm/lib/Target/PowerPC/PPCTargetMachine.cpp | 3 | ||||
| -rw-r--r-- | llvm/lib/Target/X86/X86TargetMachine.cpp | 1 |
3 files changed, 1 insertions, 4 deletions
diff --git a/llvm/lib/Target/ARM/ARMTargetMachine.cpp b/llvm/lib/Target/ARM/ARMTargetMachine.cpp index 4c58f8b59e1..390b39c4ece 100644 --- a/llvm/lib/Target/ARM/ARMTargetMachine.cpp +++ b/llvm/lib/Target/ARM/ARMTargetMachine.cpp @@ -219,7 +219,6 @@ ARMBaseTargetMachine::getSubtargetImpl(const Function &F) const { // it as a key for the subtarget since that can be the only difference // between two functions. bool SoftFloat = - F.hasFnAttribute("use-soft-float") && F.getFnAttribute("use-soft-float").getValueAsString() == "true"; // If the soft float attribute is set on the function turn on the soft float // subtarget feature. diff --git a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp index 230f2f9c5f2..8d5af9458be 100644 --- a/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp +++ b/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp @@ -245,8 +245,7 @@ PPCTargetMachine::getSubtargetImpl(const Function &F) const { // it as a key for the subtarget since that can be the only difference // between two functions. bool SoftFloat = - F.hasFnAttribute("use-soft-float") && - F.getFnAttribute("use-soft-float").getValueAsString() == "true"; + F.getFnAttribute("use-soft-float").getValueAsString() == "true"; // If the soft float attribute is set on the function turn on the soft float // subtarget feature. if (SoftFloat) diff --git a/llvm/lib/Target/X86/X86TargetMachine.cpp b/llvm/lib/Target/X86/X86TargetMachine.cpp index 382de993459..397303003a9 100644 --- a/llvm/lib/Target/X86/X86TargetMachine.cpp +++ b/llvm/lib/Target/X86/X86TargetMachine.cpp @@ -157,7 +157,6 @@ X86TargetMachine::getSubtargetImpl(const Function &F) const { // it as a key for the subtarget since that can be the only difference // between two functions. bool SoftFloat = - F.hasFnAttribute("use-soft-float") && F.getFnAttribute("use-soft-float").getValueAsString() == "true"; // If the soft float attribute is set on the function turn on the soft float // subtarget feature. |

