[clang] [X86] Relax AVX ABI warning on internal functions (PR #157570)
Joseph Huber via cfe-commits
cfe-commits at lists.llvm.org
Wed Sep 10 15:49:19 PDT 2025
================
@@ -1513,12 +1513,17 @@ static void initFeatureMaps(const ASTContext &Ctx,
static bool checkAVXParamFeature(DiagnosticsEngine &Diag,
SourceLocation CallLoc,
+ const FunctionDecl &Callee,
const llvm::StringMap<bool> &CallerMap,
const llvm::StringMap<bool> &CalleeMap,
QualType Ty, StringRef Feature,
bool IsArgument) {
bool CallerHasFeat = CallerMap.lookup(Feature);
bool CalleeHasFeat = CalleeMap.lookup(Feature);
+ // No explicit features and the function is internal, be permissive.
+ if (!CallerHasFeat && !CalleeHasFeat && !Callee.isExternallyVisible())
+ return false;
----------------
jhuber6 wrote:
Not that I'm aware of, this is the only member of the `psabi` warning group and the whole of `"Codegen ABI Check"` diagnostics only contains this, unsupported types for an ABI, and mismatching inlining attributes. So, I don't think there's any other checks, at least not ones that are easily found.
https://github.com/llvm/llvm-project/pull/157570
More information about the cfe-commits
mailing list