Closed nickdesaulniers closed 1 year ago
What version of LLVM/clang? Mine works:
$ clang --version | head -1
ClangBuiltLinux clang version 17.0.0 (https://github.com/llvm/llvm-project 31d8bdbcad91c0b2547f0836406ce119fe0e11ea)
$ make -skj"$(nproc)" ARCH=riscv LLVM=1 defconfig
$ rg "(AS|CC|TOOLCHAIN)_HAS_" .config
14:CONFIG_CC_HAS_ASM_GOTO_OUTPUT=y
15:CONFIG_CC_HAS_ASM_GOTO_TIED_OUTPUT=y
17:CONFIG_CC_HAS_ASM_INLINE=y
18:CONFIG_CC_HAS_NO_PROFILE_FN_ATTR=y
144:CONFIG_CC_HAS_INT128=y
274:CONFIG_AS_HAS_INSN=y
275:CONFIG_AS_HAS_OPTION_ARCH=y
324:CONFIG_TOOLCHAIN_HAS_V=y
327:CONFIG_TOOLCHAIN_HAS_ZBB=y
331:CONFIG_TOOLCHAIN_HAS_ZIHINTPAUSE=y
4430:CONFIG_CC_HAS_AUTO_VAR_INIT_PATTERN=y
4431:CONFIG_CC_HAS_AUTO_VAR_INIT_ZERO_BARE=y
4432:CONFIG_CC_HAS_AUTO_VAR_INIT_ZERO=y
4440:CONFIG_CC_HAS_RANDSTRUCT=y
4799:CONFIG_AS_HAS_NON_CONST_LEB128=y
4872:CONFIG_CC_HAS_KASAN_GENERIC=y
4873:CONFIG_CC_HAS_WORKING_NOSANITIZE_ADDRESS=y
4988:CONFIG_CC_HAS_SANCOV_TRACE_PC=y
clang version 17.0.0 (git@github.com:llvm/llvm-project.git ac524886094db58112ca176e1d727330a94634a8)
d'oh, I don't have my riscv backend enabled...
arch/riscv/Kconfig:L479 is the test. Is something wrong there? Was something unsupported added to KBUILD_CFLAGS that clang does not support, causing cc-option to fail mistakenly?