[clang] [AMDGPU][clang] Fix clang driver check for multiple sanitizer arguments (PR #166851)
Thorsten Blaß via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 10 01:37:34 PST 2025
ThorBl wrote:
> Is this supposed to be a warning or an error. Personally I think the user should be able to do stuff like `-Xarch_host -fsanitize=a,b,c -Xarch_device -fsanitize=address` since we only support one. Seems a little unintuitive to just ignore things requested by the user just because we can't handle them.
That's a good point. I think if the user applies -fsanitize options generically, a warning is appropriate. This informs them that some sanitizers aren’t supported on the device, but the build can still proceed for the host. However, if the user explicitly targets the device with unsupported sanitizers (e.g., using -Xarch_device), an error would be more appropriate to avoid confusion.
A balanced approach would be to warn for implicitly routed unsupported sanitizers, but error out when the user explicitly requests them for the device.
https://github.com/llvm/llvm-project/pull/166851
More information about the cfe-commits
mailing list