[clang] [llvm] [ORC] Move JITLinkMemoryManager ownership out of ExecutorProcessControl. (PR #192665)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Apr 22 03:28:23 PDT 2026
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions h,cpp -- clang/lib/Interpreter/IncrementalExecutor.cpp llvm/examples/Kaleidoscope/BuildingAJIT/Chapter3/KaleidoscopeJIT.h llvm/examples/Kaleidoscope/BuildingAJIT/Chapter4/KaleidoscopeJIT.h llvm/examples/OrcV2Examples/LLJITWithExecutorProcessControl/LLJITWithExecutorProcessControl.cpp llvm/examples/OrcV2Examples/LLJITWithRemoteDebugging/RemoteJITUtils.cpp llvm/include/llvm/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.h llvm/include/llvm/ExecutionEngine/Orc/EPCIndirectionUtils.h llvm/include/llvm/ExecutionEngine/Orc/ExecutorProcessControl.h llvm/include/llvm/ExecutionEngine/Orc/LLJIT.h llvm/include/llvm/ExecutionEngine/Orc/LinkGraphLinkingLayer.h llvm/include/llvm/ExecutionEngine/Orc/MemoryMapper.h llvm/include/llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h llvm/include/llvm/ExecutionEngine/Orc/SelfExecutorProcessControl.h llvm/include/llvm/ExecutionEngine/Orc/Shared/OrcRTBridge.h llvm/include/llvm/ExecutionEngine/Orc/SimpleRemoteEPC.h llvm/lib/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.cpp llvm/lib/ExecutionEngine/Orc/EPCIndirectionUtils.cpp llvm/lib/ExecutionEngine/Orc/LLJIT.cpp llvm/lib/ExecutionEngine/Orc/LinkGraphLinkingLayer.cpp llvm/lib/ExecutionEngine/Orc/MemoryMapper.cpp llvm/lib/ExecutionEngine/Orc/SelfExecutorProcessControl.cpp llvm/lib/ExecutionEngine/Orc/Shared/OrcRTBridge.cpp llvm/lib/ExecutionEngine/Orc/SimpleRemoteEPC.cpp llvm/lib/ExecutionEngine/Orc/TargetProcess/SimpleExecutorMemoryManager.cpp llvm/tools/lli/lli.cpp llvm/tools/llvm-jitlink/llvm-jitlink.cpp llvm/tools/llvm-jitlink/llvm-jitlink.h llvm/unittests/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManagerTest.cpp llvm/unittests/ExecutionEngine/Orc/OrcTestCommon.h --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.h b/llvm/include/llvm/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.h
index 68975e950..111a2b6c1 100644
--- a/llvm/include/llvm/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.h
+++ b/llvm/include/llvm/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManager.h
@@ -46,17 +46,15 @@ public:
/// Create an EPCGenericJITLinkMemoryManager using the given implementation
/// symbol names. These will be looked up in the given JITDylib.
static Expected<std::unique_ptr<EPCGenericJITLinkMemoryManager>>
- Create(JITDylib &JD,
- rt::SimpleExecutorMemoryManagerSymbolNames SNs =
- rt::orc_rt_SimpleNativeMemoryMapSPSSymbols);
+ Create(JITDylib &JD, rt::SimpleExecutorMemoryManagerSymbolNames SNs =
+ rt::orc_rt_SimpleNativeMemoryMapSPSSymbols);
/// Create an EPCGenericJITLinkMemoryManager using the given implementation
/// symbol names. These will be looked up in the given ExecutionSession's
/// Bootstrap JITDylib.
static Expected<std::unique_ptr<EPCGenericJITLinkMemoryManager>>
- Create(ExecutionSession &ES,
- rt::SimpleExecutorMemoryManagerSymbolNames SNs =
- rt::orc_rt_SimpleNativeMemoryMapSPSSymbols);
+ Create(ExecutionSession &ES, rt::SimpleExecutorMemoryManagerSymbolNames SNs =
+ rt::orc_rt_SimpleNativeMemoryMapSPSSymbols);
void allocate(const jitlink::JITLinkDylib *JD, jitlink::LinkGraph &G,
OnAllocatedFunction OnAllocated) override;
diff --git a/llvm/lib/ExecutionEngine/Orc/Shared/OrcRTBridge.cpp b/llvm/lib/ExecutionEngine/Orc/Shared/OrcRTBridge.cpp
index c5654f77a..f477cd096 100644
--- a/llvm/lib/ExecutionEngine/Orc/Shared/OrcRTBridge.cpp
+++ b/llvm/lib/ExecutionEngine/Orc/Shared/OrcRTBridge.cpp
@@ -83,8 +83,6 @@ const char *RunAsVoidFunctionWrapperName =
const char *RunAsIntFunctionWrapperName =
"__llvm_orc_bootstrap_run_as_int_function_wrapper";
-
-
const SimpleExecutorMemoryManagerSymbolNames
orc_rt_SimpleNativeMemoryMapSPSSymbols = {
"orc_rt_SimpleNativeMemoryMap_Instance",
diff --git a/llvm/lib/ExecutionEngine/Orc/TargetProcess/SimpleExecutorMemoryManager.cpp b/llvm/lib/ExecutionEngine/Orc/TargetProcess/SimpleExecutorMemoryManager.cpp
index fdff9ee4e..ab3ff57f9 100644
--- a/llvm/lib/ExecutionEngine/Orc/TargetProcess/SimpleExecutorMemoryManager.cpp
+++ b/llvm/lib/ExecutionEngine/Orc/TargetProcess/SimpleExecutorMemoryManager.cpp
@@ -220,7 +220,6 @@ void SimpleExecutorMemoryManager::addBootstrapSymbols(
M[SNs.DeinitializeName] = ExecutorAddr::fromPtr(deinitializeWrapper);
M[SNs.ReleaseName] = ExecutorAddr::fromPtr(releaseWrapper);
}
-
}
Expected<SimpleExecutorMemoryManager::SlabInfo &>
diff --git a/llvm/unittests/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManagerTest.cpp b/llvm/unittests/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManagerTest.cpp
index eee257551..fb1354f6e 100644
--- a/llvm/unittests/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManagerTest.cpp
+++ b/llvm/unittests/ExecutionEngine/Orc/EPCGenericJITLinkMemoryManagerTest.cpp
@@ -214,8 +214,7 @@ TEST(EPCGenericJITLinkMemoryManagerTest, CreateFromExecutionSession) {
}
};
- auto &SNs =
- rt::orc_rt_SimpleNativeMemoryMapSPSSymbols;
+ auto &SNs = rt::orc_rt_SimpleNativeMemoryMapSPSSymbols;
ExecutorAddr AllocatorAddr(1), ReserveAddr(2), InitAddr(3), DeinitAddr(4),
ReleaseAddr(5);
``````````
</details>
https://github.com/llvm/llvm-project/pull/192665
More information about the cfe-commits
mailing list