You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Configuring done
-- Generating done
-- Build files have been written to: /home/e0004850/project_code/llvm_for_hlo/llvm-build
The issue seems like mixing gcc with the lld linker. Which version of gcc are you using? (/usr/bin/cc --version)
Disabling -DLLVM_ENABLE_LLD=ON or building with clang (or a more recent gcc) should work I think?
gcc version (Ubuntu 8.4.0-1ubuntu1~18.04) 8.4.0 ,
Disabling -DLLVM_ENABLE_LLD=ON build is ok when use "build_tools/build_mlir.sh ${PWD}/llvm-project/ ${PWD}/llvm-build" this command
$ mkdir build && cd build
$ cmake .. -GNinja
-DLLVM_ENABLE_LLD=ON
-DCMAKE_BUILD_TYPE=Release
-DLLVM_ENABLE_ASSERTIONS=On
-DMLIR_DIR=${PWD}/../llvm-build/lib/cmake/mlir
$ ninja check-mlir-hlo
use the above command, set -DLLVM_ENABLE_LLD=OFF \ cause a link problem , so set -DLLVM_ENABLE_LLD=ON build is ok, is there any problem build like this?
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Configuring done
-- Generating done
-- Build files have been written to: /home/e0004850/project_code/llvm_for_hlo/llvm-build
[383/2912] Linking C executable bin/count
FAILED: bin/count
: && /usr/bin/cc -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-comment -fdiagnostics-color -O2 -g -DNDEBUG -fuse-ld=lld -W
l,--color-diagnostics -Wl,-O3 -Wl,--gc-sections utils/count/CMakeFiles/count.dir/count.c.o -o bin/count -Wl,-rpath,"$ORIGIN/../lib" -lpthread && :
/usr/bin/ld.lld: error: unknown argument: --push-state
/usr/bin/ld.lld: error: unknown argument: --pop-state
/usr/bin/ld.lld: error: unknown argument: --push-state
/usr/bin/ld.lld: error: unknown argument: --pop-state
collect2: error: ld returned 1 exit status
[416/2912] Building CXX object lib/DebugInfo/CodeView/CMakeFiles/LLVMDebugInfoCodeView.dir/EnumTables.cpp.o
ninja: build stopped: subcommand failed.
how to solve this problem
The text was updated successfully, but these errors were encountered: