[examples] Adjust ThinLtoInstrumentationLayer for emit signature change
authorJonas Devlieghere <jonas@devlieghere.com>
Fri, 11 Sep 2020 15:32:55 +0000 (08:32 -0700)
committerJonas Devlieghere <jonas@devlieghere.com>
Fri, 11 Sep 2020 15:33:37 +0000 (08:33 -0700)
Emit now takes a std::unique_ptr<MaterializationResponsibility> instead
of a MaterializationResponsibility directly.

This should fix:
http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake-standalone/

llvm/examples/ThinLtoJIT/ThinLtoInstrumentationLayer.cpp
llvm/examples/ThinLtoJIT/ThinLtoInstrumentationLayer.h

index 345bfd8..df844bf 100644 (file)
@@ -120,8 +120,8 @@ void ThinLtoInstrumentationLayer::nudgeIntoDiscovery(
   LLVM_DEBUG(dbgs() << "Nudged " << Count << " new functions into discovery\n");
 }
 
-void ThinLtoInstrumentationLayer::emit(MaterializationResponsibility R,
-                                       ThreadSafeModule TSM) {
+void ThinLtoInstrumentationLayer::emit(
+    std::unique_ptr<MaterializationResponsibility> R, ThreadSafeModule TSM) {
   TSM.withModuleDo([this](Module &M) {
     std::vector<Function *> FunctionsToInstrument;
 
index cd87207..25006b4 100644 (file)
@@ -34,7 +34,8 @@ public:
 
   ~ThinLtoInstrumentationLayer() override;
 
-  void emit(MaterializationResponsibility R, ThreadSafeModule TSM) override;
+  void emit(std::unique_ptr<MaterializationResponsibility> R,
+            ThreadSafeModule TSM) override;
 
   unsigned reserveDiscoveryFlags(unsigned Count);
   void registerDiscoveryFlagOwners(std::vector<GlobalValue::GUID> Guids,