Incorrect builtins are exposed for offload targets #64436
Open
Description
When using -aux-triple for an offload target, the incorrect builtins are being exposed. The builtins exposed are not based on the target specified. e.g,
static_assert(__has_builtin(__cpuidex), "uh oh");
will not fail when given: -c -fopenmp -Xclang -fopenmp-is-target-device -Xclang -aux-triple -Xclang x86_64-unknown-linux-gnu, but it should fail because that's a Windows-specific builtin. Removing the -aux-triple will cause the assertion to trigger as expected.
Activity