[llvm] [llvm-(min-)tblgen] Avoid redundant source compilation (PR #114494)

LLVM Continuous Integration via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 2 14:27:57 PST 2025


llvm-ci wrote:

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

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

<details>
<summary>Here is the relevant piece of the build log for the reference</summary>

```
Step 6 (build-check-mlir-build-only) failure: build (failure)
...
0.829 [4617/9/428] Copying python source /vol/worker/mlir-nvidia/mlir-nvidia/llvm.src/mlir/python/mlir/dialects/python_test.py -> /vol/worker/mlir-nvidia/mlir-nvidia/llvm.obj/tools/mlir/python_packages/mlir_core/mlir/dialects/python_test.py
0.839 [4617/8/429] Linking CXX static library lib/libMLIRTblgenLib.a
2.088 [4617/7/430] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/Attributes.cpp.o
2.113 [4617/6/431] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/VTEmitter.cpp.o
2.119 [4617/5/432] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/TableGen.cpp.o
2.572 [4617/4/433] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/RISCVTargetDefEmitter.cpp.o
2.937 [4617/3/434] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o
4.707 [4617/2/435] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/IntrinsicEmitter.cpp.o
5.054 [4617/1/436] Building CXX object utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/DirectiveEmitter.cpp.o
5.126 [4616/1/437] Linking CXX executable bin/llvm-min-tblgen
FAILED: bin/llvm-min-tblgen 
: && /usr/bin/clang++ -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 -fuse-ld=lld -Wl,--color-diagnostics     -Wl,--gc-sections utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/Attributes.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/CodeGenIntrinsics.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/DirectiveEmitter.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/IntrinsicEmitter.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/RISCVTargetDefEmitter.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/SDNodeProperties.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/TableGen.cpp.o utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/VTEmitter.cpp.o utils/TableGen/CMakeFiles/llvm-min-tblgen.dir/llvm-min-tblgen.cpp.o -o bin/llvm-min-tblgen  -Wl,-rpath,"\$ORIGIN/../lib:/vol/worker/mlir-nvidia/mlir-nvidia/llvm.obj/lib"  lib/libLLVMTableGen.so.20.0git  -Wl,-rpath-link,/vol/worker/mlir-nvidia/mlir-nvidia/llvm.obj/lib && :
ld.lld: error: undefined symbol: llvm::raw_ostream::write(char const*, unsigned long)
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced 1019 more times

ld.lld: error: undefined symbol: llvm::StringMapImpl::hash(llvm::StringRef)
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced 11 more times

ld.lld: error: undefined symbol: llvm::StringRef::upper[abi:cxx11]() const
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced 12 more times

ld.lld: error: undefined symbol: llvm::raw_ostream::operator<<(unsigned long)
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced by ARMTargetDefEmitter.cpp
>>>               utils/TableGen/Basic/CMakeFiles/obj.LLVMTableGenBasic.dir/ARMTargetDefEmitter.cpp.o:(emitARMTargetDef(llvm::RecordKeeper const&, llvm::raw_ostream&))
>>> referenced 22 more times

ld.lld: error: undefined symbol: llvm::raw_ostream::operator<<(llvm::format_object_base const&)

```

</details>

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


More information about the llvm-commits mailing list