This revision split out a new CRunnerUtils library that supports
MLIR execution on targets without a C++ runtime.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/include/mlir/ExecutionEngine/CRunnerUtils.h | ||
---|---|---|
42 | I'm not sure templates align with the comment above saying "entities must be kept C compatible". |
mlir/include/mlir/ExecutionEngine/CRunnerUtils.h | ||
---|---|---|
3 | Please fix this. |
mlir/include/mlir/ExecutionEngine/CRunnerUtils.h | ||
---|---|---|
42 | True, thanks, rephrased. |
This change broke the MLIR build on Windows.
As far as I can tell, the intention here is to produce two separate shared libraries: mlir_c_runner_utils and mlir_runner_utils with the second one (mlir_runner_utils) including the first one (mlir_c_runner_utils). Since:
add_llvm_library(mlir_c_runner_utils SHARED CRunnerUtils.cpp)
produces *only* a dll on windows, the linking of mlir_runner_utils fails because target_link_libraries is looking for a .lib file as opposed to a .dll file. I think this may be a case where either we need to use LINK_LIBS or explicitly build a static lib as well, but I haven't tried either yet.
@stella.stamenova @NathanielMcVicar bcee8982a2931960ca29a9e95e3d10355e7393ab adds an extra static library for linking for Windows.
As I do not have a Windows configuration handy, would you please confirm it fixes the issue you see?
Thanks!
Please fix this.