forked from OSchip/llvm-project
[X86] Avoid a std::string copy by replacing auto with const auto&. NFC.
Fixes msvc analyzer warning.
This commit is contained in:
parent
64132f541e
commit
86021d98d3
|
@ -2516,7 +2516,7 @@ Value *X86TargetLowering::getIRStackGuard(IRBuilder<> &IRB) const {
|
|||
if (Offset == (unsigned)-1)
|
||||
Offset = (Subtarget.is64Bit()) ? 0x28 : 0x14;
|
||||
|
||||
auto GuardReg = getTargetMachine().Options.StackProtectorGuardReg;
|
||||
const auto &GuardReg = getTargetMachine().Options.StackProtectorGuardReg;
|
||||
if (GuardReg == "fs")
|
||||
AddressSpace = X86AS::FS;
|
||||
else if (GuardReg == "gs")
|
||||
|
|
Loading…
Reference in New Issue