ObjectLinkingLayer Plugin on windows

Hello,

Is it possible to use the ObjectLinkingLayer Plugin on windows?
I compiled and ran “OrcV2Examples\LLJITWithObjectLinkingLayerPlugin”, but I got the following error.

JIT session error: Symbols not found: [ __ImageBase ]
LLJITWithObjectLinkingLayerPlugin.exe: Failed to materialize symbols: { (main, { entry, callee }) }

Is this feature not available on winodws?
Do I need to modify the example code?

Environment:

  • llvm version: 16.0.4
  • OS: windows 11 64bit
  • Compiler: MSVC 14.3 (MSBuild 17)

Thank you.

AFAIK plugins are not supported on Windows.

I solved it myself.
Using orc-runtime, I can apply ObjectLinkingLayer Plugin to JIT on windows.

I modified the example code for LLJITBuilder configuration as follows:

auto J = ExitOnErr(
      LLJITBuilder()
          .setJITTargetMachineBuilder(std::move(JTMB))
          .setPlatformSetUp(orc::ExecutorNativePlatform( [path to "orc_rt-x86_64.lib"] ))   // Added this line.
          .setObjectLinkingLayerCreator(
           ...
           )

I created “orc_rt-x86_64.lib” by building “compiler-rt” included in the LLVM project.

  • llvm version: 17.0.0-rc1
  • OS: windows 11 64bit