Skip to content

Why can't the clang in riscv32-elf-ubunt-24.04-llvm-nightly enable KASAN #1766

@dong-miao

Description

@dong-miao

Why can't the clang in riscv32-elf-ubunt-24.04-llvm-nightly enable KASAN and report an error: unsupported option '-fsanitize=kernel-address' for target 'riscv32-unknown-unknown-elf'.
However, the llvm-project/clang/lib/Driver/ToolChains/BareMetal.cpp file clearly defines that RISC-V32 can also enable KASAN.
The clang in the build-llvm-newlib/bin directory can enable KASAN without any errors.
I would like to know how to modify it so that clang in the insatll directory can also be enabled.
Thanks all for your help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions