diff options
author | Eric Christopher <echristo@gmail.com> | 2014-09-03 20:36:31 +0000 |
---|---|---|
committer | Eric Christopher <echristo@gmail.com> | 2014-09-03 20:36:31 +0000 |
commit | b68e25330b102ea662891aca1d129485c37a0268 (patch) | |
tree | 45fbcd52189d008ae270fbdb08215a9c3f47e3f5 /llvm/lib/Target/PowerPC/PPCSubtarget.cpp | |
parent | e08189195bb71dccba2f80b908043cc082dea1eb (diff) | |
download | bcm5719-llvm-b68e25330b102ea662891aca1d129485c37a0268.tar.gz bcm5719-llvm-b68e25330b102ea662891aca1d129485c37a0268.zip |
Remove resetSubtargetFeatures as it is unused.
llvm-svn: 217071
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCSubtarget.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCSubtarget.cpp | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp index 1758bf19bc0..64c798c2271 100644 --- a/llvm/lib/Target/PowerPC/PPCSubtarget.cpp +++ b/llvm/lib/Target/PowerPC/PPCSubtarget.cpp @@ -69,7 +69,7 @@ static std::string getDataLayoutString(const Triple &T) { PPCSubtarget &PPCSubtarget::initializeSubtargetDependencies(StringRef CPU, StringRef FS) { initializeEnvironment(); - resetSubtargetFeatures(CPU, FS); + initSubtargetFeatures(CPU, FS); return *this; } @@ -84,22 +84,6 @@ PPCSubtarget::PPCSubtarget(const std::string &TT, const std::string &CPU, FrameLowering(initializeSubtargetDependencies(CPU, FS)), InstrInfo(*this), TLInfo(TM), TSInfo(&DL) {} -void PPCSubtarget::resetSubtargetFeatures(const MachineFunction *MF) { - AttributeSet FnAttrs = MF->getFunction()->getAttributes(); - Attribute CPUAttr = FnAttrs.getAttribute(AttributeSet::FunctionIndex, - "target-cpu"); - Attribute FSAttr = FnAttrs.getAttribute(AttributeSet::FunctionIndex, - "target-features"); - std::string CPU = - !CPUAttr.hasAttribute(Attribute::None) ? CPUAttr.getValueAsString() : ""; - std::string FS = - !FSAttr.hasAttribute(Attribute::None) ? FSAttr.getValueAsString() : ""; - if (!FS.empty()) { - initializeEnvironment(); - resetSubtargetFeatures(CPU, FS); - } -} - void PPCSubtarget::initializeEnvironment() { StackAlignment = 16; DarwinDirective = PPC::DIR_NONE; @@ -134,7 +118,7 @@ void PPCSubtarget::initializeEnvironment() { HasLazyResolverStubs = false; } -void PPCSubtarget::resetSubtargetFeatures(StringRef CPU, StringRef FS) { +void PPCSubtarget::initSubtargetFeatures(StringRef CPU, StringRef FS) { // Determine default and user specified characteristics std::string CPUName = CPU; if (CPUName.empty()) |