summaryrefslogtreecommitdiff
path: root/lib/ExecutionEngine/MCJIT
diff options
context:
space:
mode:
authorJim Grosbach <grosbach@apple.com>2011-05-18 23:56:43 +0000
committerJim Grosbach <grosbach@apple.com>2011-05-18 23:56:43 +0000
commite0b58634a1953ed9138882da8b251b3e2aab9220 (patch)
tree91efd03201ea8a8c731e4a7230ce09676560249d /lib/ExecutionEngine/MCJIT
parente37234739e6a3bb67e0d2fe5e4ee5cd03257514e (diff)
downloadllvm-e0b58634a1953ed9138882da8b251b3e2aab9220.tar.gz
llvm-e0b58634a1953ed9138882da8b251b3e2aab9220.tar.bz2
llvm-e0b58634a1953ed9138882da8b251b3e2aab9220.tar.xz
Restore sanity to 131601.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131603 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/ExecutionEngine/MCJIT')
-rw-r--r--lib/ExecutionEngine/MCJIT/MCJIT.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/ExecutionEngine/MCJIT/MCJIT.cpp b/lib/ExecutionEngine/MCJIT/MCJIT.cpp
index 96e5c6803a..09a79f64d4 100644
--- a/lib/ExecutionEngine/MCJIT/MCJIT.cpp
+++ b/lib/ExecutionEngine/MCJIT/MCJIT.cpp
@@ -104,10 +104,11 @@ void *MCJIT::getPointerToFunction(Function *F) {
// FIXME: Should we be using the mangler for this? Probably.
StringRef BaseName = F->getName();
+ Twine Name;
if (BaseName[0] == '\1')
- BaseName = BaseName.substr(1);
+ Name = BaseName.substr(1);
else
- Twine Name = TM->getMCAsmInfo()->getGlobalPrefix() + BaseName;
+ Name = TM->getMCAsmInfo()->getGlobalPrefix() + BaseName;
return (void*)Dyld.getSymbolAddress(Name.str());
}