On Tue, Feb 21, 2023 at 02:30:17PM +0530, Naresh Kamboju wrote: > The riscv defconfig and tinyconfig builds failed with clang-nightly > due to below build warnings / errors on latest stable-rc 5.10. > > Regression on riscv: > - build/clang-nightly-tinyconfig - FAILED > - build/clang-nightly-defconfig - FAILED > Build log: > ---- > make --silent --keep-going --jobs=8 > O=/home/tuxbuild/.cache/tuxmake/builds/1/build ARCH=riscv > CROSS_COMPILE=riscv64-linux-gnu- HOSTCC=clang CC=clang LLVM=1 > LLVM_IAS=1 LD=riscv64-linux-gnu-ld > riscv64-linux-gnu-ld: -march=rv64i2p0_m2p0_a2p0_zicsr2p0_zifencei2p0: > Invalid or unknown z ISA extension: 'zifencei' > riscv64-linux-gnu-ld: failed to merge target specific data of file > init/version.o > riscv64-linux-gnu-ld: -march=rv64i2p0_m2p0_a2p0_zicsr2p0_zifencei2p0: > Invalid or unknown z ISA extension: 'zifencei' > riscv64-linux-gnu-ld: failed to merge target specific data of file > init/do_mounts.o > riscv64-linux-gnu-ld: -march=rv64i2p0_m2p0_a2p0_zicsr2p0_zifencei2p0: > Invalid or unknown z ISA extension: 'zifencei' > riscv64-linux-gnu-ld: failed to merge target specific data of file > init/noinitramfs.o > riscv64-linux-gnu-ld: -march=rv64i2p0_m2p0_a2p0_zicsr2p0_zifencei2p0: > Invalid or unknown z ISA extension: 'zifencei' > riscv64-linux-gnu-ld: failed to merge target specific data of file > init/calibrate.o > riscv64-linux-gnu-ld: -march=rv64i2p0_m2p0_a2p0_zicsr2p0_zifencei2p0: > Invalid or unknown z ISA extension: 'zifencei' > Build details, > https://qa-reports.linaro.org/lkft/linux-stable-rc-linux-5.10.y/build/v5.10.168-58-g7d11e4c4fc56/testrun/14869376/suite/build/test/clang-nightly-tinyconfig/details/ binutils 2.35 by the looks of things, I **think** that zifencei didn't land until 2.36. zicsr and zifence get added via cc-option-yn, which, IIRC, doesn't do anything with the linker. I dunno if anyone in RISC-V land cares this much about "odd" configurations back in 5.10, but while a fix is outstanding, you could use a newer binutils?
Attachment:
signature.asc
Description: PGP signature