summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExpr.cpp
diff options
context:
space:
mode:
authorRenato Golin <renato.golin@linaro.org>2014-05-19 22:36:19 +0000
committerRenato Golin <renato.golin@linaro.org>2014-05-19 22:36:19 +0000
commit156a853ccb1030220fc6b407e2a9517dff380bb5 (patch)
treef601612f4bc30948e4021321b09f8aac3e53d078 /clang/lib/CodeGen/CGExpr.cpp
parent62b2317fd878cf321ccf7e24bca840abf0c81358 (diff)
downloadbcm5719-llvm-156a853ccb1030220fc6b407e2a9517dff380bb5.tar.gz
bcm5719-llvm-156a853ccb1030220fc6b407e2a9517dff380bb5.zip
Fix usage of string when StringRef was needed
Also adding a variable to the test, so release bots match %1. This should also calm the gdb buildbot. . llvm-svn: 209171
Diffstat (limited to 'clang/lib/CodeGen/CGExpr.cpp')
-rw-r--r--clang/lib/CodeGen/CGExpr.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExpr.cpp b/clang/lib/CodeGen/CGExpr.cpp
index 4822769f392..2025f39355e 100644
--- a/clang/lib/CodeGen/CGExpr.cpp
+++ b/clang/lib/CodeGen/CGExpr.cpp
@@ -1780,7 +1780,9 @@ static LValue EmitGlobalNamedRegister(const VarDecl *VD,
CharUnits Alignment) {
AsmLabelAttr *Asm = VD->getAttr<AsmLabelAttr>();
llvm::Twine Name("llvm.named.register."+Asm->getLabel());
- llvm::NamedMDNode *M = CGM.getModule().getOrInsertNamedMetadata(Name.str());
+ SmallString<256> DummyVec;
+ llvm::NamedMDNode *M =
+ CGM.getModule().getOrInsertNamedMetadata(Name.toStringRef(DummyVec));
if (M->getNumOperands() == 0) {
llvm::MDString *Str = llvm::MDString::get(CGM.getLLVMContext(),
Asm->getLabel());
OpenPOWER on IntegriCloud