[llvm] 1fe64fe - [ORC] Add visibility macros to functions needed by lli and jitlink (#113271)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 24 10:41:37 PDT 2024
Author: Thomas Fransham
Date: 2024-10-24T10:41:34-07:00
New Revision: 1fe64fe04687e5c95c33be9abac921cdd2a8e2ff
URL: https://github.com/llvm/llvm-project/commit/1fe64fe04687e5c95c33be9abac921cdd2a8e2ff
DIFF: https://github.com/llvm/llvm-project/commit/1fe64fe04687e5c95c33be9abac921cdd2a8e2ff.diff
LOG: [ORC] Add visibility macros to functions needed by lli and jitlink (#113271)
Annotating these symbols will fix missing symbols errors for lli and
llvm-jitlink when when the LLVM is built as shared library on windows
with explicit symbol visibility macros enabled.
This is part of the work to enable LLVM_BUILD_LLVM_DYLIB and plugins on
window.
Added:
Modified:
llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderGDB.h
llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderPerf.h
llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderVTune.h
llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/RegisterEHFrames.h
Removed:
################################################################################
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderGDB.h b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderGDB.h
index 9f91a64e95ce99..1563d13468988f 100644
--- a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderGDB.h
+++ b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderGDB.h
@@ -14,6 +14,7 @@
#define LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERGDB_H
#include "llvm/ExecutionEngine/Orc/Shared/WrapperFunctionUtils.h"
+#include "llvm/Support/Compiler.h"
#include <cstdint>
// Keep in sync with gdb/gdb/jit.h
@@ -42,10 +43,10 @@ struct jit_descriptor {
};
}
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerJITLoaderGDBWrapper(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerJITLoaderGDBAllocAction(const char *Data, size_t Size);
#endif // LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERGDB_H
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderPerf.h b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderPerf.h
index 1d8e33f8013b9f..aa9951a23b99e6 100644
--- a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderPerf.h
+++ b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderPerf.h
@@ -14,15 +14,16 @@
#define LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERPERF_H
#include "llvm/ExecutionEngine/Orc/Shared/WrapperFunctionUtils.h"
+#include "llvm/Support/Compiler.h"
#include <cstdint>
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerJITLoaderPerfImpl(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerJITLoaderPerfStart(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerJITLoaderPerfEnd(const char *Data, uint64_t Size);
#endif // LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERPERF_H
\ No newline at end of file
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderVTune.h b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderVTune.h
index afb7df592faf27..63a0d7325d5ad6 100644
--- a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderVTune.h
+++ b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/JITLoaderVTune.h
@@ -15,15 +15,16 @@
#define LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERVTUNE_H
#include "llvm/ExecutionEngine/Orc/Shared/WrapperFunctionUtils.h"
+#include "llvm/Support/Compiler.h"
#include <cstdint>
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerVTuneImpl(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_unregisterVTuneImpl(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_test_registerVTuneImpl(const char *Data, uint64_t Size);
#endif // LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_JITLOADERVTUNE_H
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/RegisterEHFrames.h b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/RegisterEHFrames.h
index 04790afa6e3163..d375f6034616a5 100644
--- a/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/RegisterEHFrames.h
+++ b/llvm/include/llvm/ExecutionEngine/Orc/TargetProcess/RegisterEHFrames.h
@@ -17,6 +17,7 @@
#define LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_REGISTEREHFRAMES_H
#include "llvm/ExecutionEngine/Orc/Shared/WrapperFunctionUtils.h"
+#include "llvm/Support/Compiler.h"
#include "llvm/Support/Error.h"
namespace llvm {
@@ -33,10 +34,10 @@ Error deregisterEHFrameSection(const void *EHFrameSectionAddr,
} // end namespace orc
} // end namespace llvm
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_registerEHFrameSectionWrapper(const char *Data, uint64_t Size);
-extern "C" llvm::orc::shared::CWrapperFunctionResult
+extern "C" LLVM_ABI llvm::orc::shared::CWrapperFunctionResult
llvm_orc_deregisterEHFrameSectionWrapper(const char *Data, uint64_t Size);
#endif // LLVM_EXECUTIONENGINE_ORC_TARGETPROCESS_REGISTEREHFRAMES_H
More information about the llvm-commits
mailing list