[llvm] [ORC] Add LoadRelocatableObject: universal binary support, clearer er… (PR #104406)

LLVM Continuous Integration via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 15 17:01:21 PDT 2024


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `mlir-nvidia` running on `mlir-nvidia` while building `llvm` at step 5 "build-check-mlir-build-only".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/138/builds/2481

Here is the relevant piece of the build log for the reference:
```
Step 5 (build-check-mlir-build-only) failure: build (failure)
...
32.840 [646/16/4270] Creating library symlink lib/libMLIRVectorToLLVMPass.so
32.854 [645/16/4271] Linking CXX shared library lib/libMLIRControlFlowTestPasses.so.20.0git
32.862 [644/16/4272] Creating library symlink lib/libMLIRControlFlowTestPasses.so
32.866 [643/16/4273] Building CXX object tools/mlir/test/lib/Dialect/GPU/CMakeFiles/MLIRGPUTestPasses.dir/TestGpuRewrite.cpp.o
32.868 [642/16/4274] Linking CXX shared library lib/libMLIRArithTestPasses.so.20.0git
32.884 [641/16/4275] Building CXX object tools/mlir/test/lib/Dialect/LLVM/CMakeFiles/MLIRLLVMTestPasses.dir/TestLowerToLLVM.cpp.o
32.891 [640/16/4276] Creating library symlink lib/libMLIRArithTestPasses.so
32.894 [639/16/4277] Building CXX object tools/mlir/test/lib/Dialect/Math/CMakeFiles/MLIRMathTestPasses.dir/TestExpandMath.cpp.o
32.904 [638/16/4278] Building CXX object tools/mlir/test/lib/Dialect/Linalg/CMakeFiles/MLIRLinalgTestPasses.dir/TestPadFusion.cpp.o
32.913 [637/16/4279] Linking CXX shared library lib/libLLVMOrcJIT.so.20.0git
FAILED: lib/libLLVMOrcJIT.so.20.0git 
: && /usr/bin/clang++ -fPIC -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -DNDEBUG  -Wl,-z,defs -Wl,-z,nodelete -fuse-ld=lld -Wl,--color-diagnostics   -Wl,--gc-sections -shared -Wl,-soname,libLLVMOrcJIT.so.20.0git -o lib/libLLVMOrcJIT.so.20.0git lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/COFFVCRuntimeSupport.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/COFFPlatform.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/CompileOnDemandLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/CompileUtils.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/Core.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/DebugObjectManagerPlugin.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/DebugUtils.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCDynamicLibrarySearchGenerator.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCDebugObjectRegistrar.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCEHFrameRegistrar.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCGenericDylibManager.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCGenericJITLinkMemoryManager.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCGenericRTDyldMemoryManager.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/EPCIndirectionUtils.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ExecutionUtils.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ObjectFileInterface.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/IndirectionUtils.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/IRCompileLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/IRTransformLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/JITTargetMachineBuilder.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/LazyReexports.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/Layer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/LoadRelocatableObject.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/LookupAndRecordAddrs.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/LLJIT.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/MachO.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/MachOPlatform.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/MapperJITLinkMemoryManager.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/MemoryMapper.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ELFNixPlatform.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/Mangling.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ObjectLinkingLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ObjectTransformLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/OrcABISupport.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/OrcV2CBindings.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/RTDyldObjectLinkingLayer.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/SectCreate.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/SimpleRemoteEPC.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/Speculation.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/SpeculateAnalyses.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ExecutorProcessControl.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/TaskDispatch.cpp.o lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/ThreadSafeModule.cpp.o  -Wl,-rpath,"\$ORIGIN/../lib:/vol/worker/mlir-nvidia/mlir-nvidia/llvm.obj/lib:"  -lrt  lib/libLLVMExecutionEngine.so.20.0git  lib/libLLVMJITLink.so.20.0git  lib/libLLVMOrcTargetProcess.so.20.0git  lib/libLLVMWindowsDriver.so.20.0git  lib/libLLVMPasses.so.20.0git  lib/libLLVMRuntimeDyld.so.20.0git  lib/libLLVMBitWriter.so.20.0git  lib/libLLVMTransformUtils.so.20.0git  lib/libLLVMTarget.so.20.0git  lib/libLLVMAnalysis.so.20.0git  lib/libLLVMObject.so.20.0git  lib/libLLVMBitReader.so.20.0git  lib/libLLVMCore.so.20.0git  lib/libLLVMMC.so.20.0git  lib/libLLVMOrcShared.so.20.0git  lib/libLLVMTargetParser.so.20.0git  lib/libLLVMSupport.so.20.0git  -Wl,-rpath-link,/vol/worker/mlir-nvidia/mlir-nvidia/llvm.obj/lib && :
ld.lld: error: undefined symbol: llvm::identify_magic(llvm::StringRef)
>>> referenced by LoadRelocatableObject.cpp
>>>               lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/LoadRelocatableObject.cpp.o:(llvm::orc::loadRelocatableObject(llvm::StringRef, llvm::Triple const&))
>>> referenced by MachO.cpp
>>>               lib/ExecutionEngine/Orc/CMakeFiles/LLVMOrcJIT.dir/MachO.cpp.o:(llvm::orc::loadMachORelocatableObject(llvm::StringRef, llvm::Triple const&))
clang: error: linker command failed with exit code 1 (use -v to see invocation)
32.923 [637/15/4280] Building CXX object tools/mlir/test/lib/Dialect/Linalg/CMakeFiles/MLIRLinalgTestPasses.dir/TestLinalgFusionTransforms.cpp.o
32.926 [637/14/4281] Building CXX object tools/mlir/test/lib/Dialect/Linalg/CMakeFiles/MLIRLinalgTestPasses.dir/TestLinalgDecomposeOps.cpp.o
32.927 [637/13/4282] Linking CXX shared library lib/libMLIRLinalgToStandard.so.20.0git
32.936 [637/12/4283] Building CXX object tools/mlir/test/lib/Dialect/Linalg/CMakeFiles/MLIRLinalgTestPasses.dir/TestLinalgElementwiseFusion.cpp.o
32.942 [637/11/4284] Building CXX object tools/mlir/test/lib/Dialect/Linalg/CMakeFiles/MLIRLinalgTestPasses.dir/TestDataLayoutPropagation.cpp.o
32.942 [637/10/4285] Linking CXX shared library lib/libMLIRTensorToLinalg.so.20.0git
32.977 [637/9/4286] Linking CXX shared library lib/libMLIRArmSMETestPasses.so.20.0git
32.978 [637/8/4287] Linking CXX executable tools/mlir/unittests/Dialect/ArmSME/MLIRArmSMETests
33.007 [637/7/4288] Linking CXX shared library lib/libMLIRSparseTensorTransforms.so.20.0git
33.016 [637/6/4289] Linking CXX shared library lib/libMLIRLinalgTransformOps.so.20.0git
33.824 [637/5/4290] Building CXX object lib/CodeGen/AsmPrinter/CMakeFiles/LLVMAsmPrinter.dir/AsmPrinter.cpp.o
38.542 [637/4/4291] Building CXX object tools/mlir/lib/CAPI/ExecutionEngine/CMakeFiles/obj.MLIRCAPIExecutionEngine.dir/ExecutionEngine.cpp.o
43.391 [637/3/4292] Building CXX object tools/mlir/lib/ExecutionEngine/CMakeFiles/MLIRJitRunner.dir/JitRunner.cpp.o
43.810 [637/2/4293] Building CXX object tools/mlir/lib/ExecutionEngine/CMakeFiles/MLIRExecutionEngine.dir/ExecutionEngine.cpp.o
62.789 [637/1/4294] Building CXX object tools/mlir/unittests/ExecutionEngine/CMakeFiles/MLIRExecutionEngineTests.dir/Invoke.cpp.o
ninja: build stopped: subcommand failed.

```

https://github.com/llvm/llvm-project/pull/104406


More information about the llvm-commits mailing list