mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01:00
std::string to StringRef.
llvm-svn: 176166
This commit is contained in:
parent
fc840cf992
commit
c64a5a0435
@ -332,9 +332,9 @@ void X86Subtarget::resetSubtargetFeatures(const MachineFunction *MF) {
|
|||||||
"target-cpu");
|
"target-cpu");
|
||||||
Attribute FSAttr = FnAttrs.getAttribute(AttributeSet::FunctionIndex,
|
Attribute FSAttr = FnAttrs.getAttribute(AttributeSet::FunctionIndex,
|
||||||
"target-features");
|
"target-features");
|
||||||
std::string CPU =
|
StringRef CPU =
|
||||||
!CPUAttr.hasAttribute(Attribute::None) ?CPUAttr.getValueAsString() : "";
|
!CPUAttr.hasAttribute(Attribute::None) ? CPUAttr.getValueAsString() : "";
|
||||||
std::string FS =
|
StringRef FS =
|
||||||
!FSAttr.hasAttribute(Attribute::None) ? FSAttr.getValueAsString() : "";
|
!FSAttr.hasAttribute(Attribute::None) ? FSAttr.getValueAsString() : "";
|
||||||
if (!FS.empty()) {
|
if (!FS.empty()) {
|
||||||
initializeEnvironment();
|
initializeEnvironment();
|
||||||
@ -343,7 +343,7 @@ void X86Subtarget::resetSubtargetFeatures(const MachineFunction *MF) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void X86Subtarget::resetSubtargetFeatures(StringRef CPU, StringRef FS) {
|
void X86Subtarget::resetSubtargetFeatures(StringRef CPU, StringRef FS) {
|
||||||
std::string CPUName = CPU;
|
StringRef CPUName = CPU;
|
||||||
if (!FS.empty() || !CPU.empty()) {
|
if (!FS.empty() || !CPU.empty()) {
|
||||||
if (CPUName.empty()) {
|
if (CPUName.empty()) {
|
||||||
#if defined(i386) || defined(__i386__) || defined(__x86__) || defined(_M_IX86)\
|
#if defined(i386) || defined(__i386__) || defined(__x86__) || defined(_M_IX86)\
|
||||||
|
Loading…
Reference in New Issue
Block a user