From ea709c7dcdcfc93b0fe58dbe97c62ebcb93cd244 Mon Sep 17 00:00:00 2001 From: Lang Hames Date: Fri, 6 Jun 2025 13:33:47 +1000 Subject: [PATCH] [ORC] Fix examples after cd585864c0b. cd585864c0b added a MemoryBuffer argument to the memory manager factory. This patch updates the examples to reflect that change. --- .../LLJITWithGDBRegistrationListener.cpp | 2 +- llvm/examples/SpeculativeJIT/SpeculativeJIT.cpp | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/llvm/examples/OrcV2Examples/LLJITWithGDBRegistrationListener/LLJITWithGDBRegistrationListener.cpp b/llvm/examples/OrcV2Examples/LLJITWithGDBRegistrationListener/LLJITWithGDBRegistrationListener.cpp index df2f48cef14c..8623834dcf42 100644 --- a/llvm/examples/OrcV2Examples/LLJITWithGDBRegistrationListener/LLJITWithGDBRegistrationListener.cpp +++ b/llvm/examples/OrcV2Examples/LLJITWithGDBRegistrationListener/LLJITWithGDBRegistrationListener.cpp @@ -63,7 +63,7 @@ int main(int argc, char *argv[]) { ExitOnErr(LLJITBuilder() .setJITTargetMachineBuilder(std::move(JTMB)) .setObjectLinkingLayerCreator([&](ExecutionSession &ES) { - auto GetMemMgr = []() { + auto GetMemMgr = [](const MemoryBuffer &) { return std::make_unique(); }; auto ObjLinkingLayer = diff --git a/llvm/examples/SpeculativeJIT/SpeculativeJIT.cpp b/llvm/examples/SpeculativeJIT/SpeculativeJIT.cpp index 24ae953eca7a..acdbce4f6e3e 100644 --- a/llvm/examples/SpeculativeJIT/SpeculativeJIT.cpp +++ b/llvm/examples/SpeculativeJIT/SpeculativeJIT.cpp @@ -125,7 +125,8 @@ private: ExitOnErr(CXXRuntimeoverrides.enable(MainJD, Mangle)); } - static std::unique_ptr createMemMgr() { + static std::unique_ptr + createMemMgr(const MemoryBuffer &) { return std::make_unique(); }