[MCJIT] Add a 'section_addr' builtin function to RuntimeDyldChecker.
[oota-llvm.git] / lib / ExecutionEngine / RuntimeDyld / RuntimeDyld.cpp
index 537a683cd5fdff01cc5c7af537e236ef140ad7ea..d1b17ce94d8a10a6ee8ee111fe1734d05a738993 100644 (file)
@@ -550,6 +550,10 @@ unsigned RuntimeDyldImpl::emitSection(ObjectImage &Obj,
   }
 
   Sections.push_back(SectionEntry(Name, Addr, DataSize, (uintptr_t)pData));
+
+  if (Checker)
+    Checker->registerSection(Obj.getImageName(), SectionID);
+
   return SectionID;
 }