[PATCH] D142046: [BPF][clang] Ignore stack protector options for BPF target
Eduard Zingerman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 18 11:37:55 PST 2023
eddyz87 added a comment.
Slightly above my edit there is a similar logic for NVPTX target:
static void RenderSSPOptions(const Driver &D, const ToolChain &TC,
const ArgList &Args, ArgStringList &CmdArgs,
bool KernelOrKext) {
const llvm::Triple &EffectiveTriple = TC.getEffectiveTriple();
// NVPTX doesn't support stack protectors; from the compiler's perspective, it
// doesn't even have a stack!
if (EffectiveTriple.isNVPTX())
return;
...
I don't like it because it produces rather vague error message:
warning: argument unused during compilation: '-fstack-protector' [-Wunused-command-line-argument]
However I'm hesitant to merge the NVPTX check with BPF check to avoid any potential changes in the NVPTX target behavior (e.g. different warning).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D142046/new/
https://reviews.llvm.org/D142046
More information about the cfe-commits
mailing list