[llvm] r241301 - Try to fix the build of IntelJITEventListener.
Rafael Espindola
rafael.espindola at gmail.com
Thu Jul 2 14:24:12 PDT 2015
Author: rafael
Date: Thu Jul 2 16:24:12 2015
New Revision: 241301
URL: http://llvm.org/viewvc/llvm-project?rev=241301&view=rev
Log:
Try to fix the build of IntelJITEventListener.
Modified:
llvm/trunk/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp
Modified: llvm/trunk/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp?rev=241301&r1=241300&r2=241301&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp (original)
+++ llvm/trunk/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp Thu Jul 2 16:24:12 2015
@@ -114,10 +114,11 @@ void IntelJITEventListener::NotifyObject
std::string SourceFileName;
if (Sym.getType() == SymbolRef::ST_Function) {
- StringRef Name;
- uint64_t Addr;
- if (Sym.getName(Name))
+ ErrorOr<StringRef> Name = Sym.getName();
+ if (!Name)
continue;
+
+ uint64_t Addr;
if (Sym.getAddress(Addr))
continue;
uint64_t Size = P.second;
@@ -126,10 +127,8 @@ void IntelJITEventListener::NotifyObject
Functions.push_back((void*)Addr);
// Build the function loaded notification message
- iJIT_Method_Load FunctionMessage = FunctionDescToIntelJITFormat(*Wrapper,
- Name.data(),
- Addr,
- Size);
+ iJIT_Method_Load FunctionMessage =
+ FunctionDescToIntelJITFormat(*Wrapper, Name->data(), Addr, Size);
if (Context) {
DILineInfoTable Lines = Context->getLineInfoForAddressRange(Addr, Size);
DILineInfoTable::iterator Begin = Lines.begin();
More information about the llvm-commits
mailing list