================
@@ -5736,6 +5736,17 @@ option.
}];
}
+def StackProtectorIgnoreDocs : Documentation {
+ let Category = DocCatFunction;
+ let Content = [{
+The ``stack_protector_ignore`` attribute skips analysis of the given local
+variable when determining if a function should use a stack protector.
+
+If ``-fstack-protector-all`` is specified then the given function will still
+use a stack protector, even if some/all variables have this attribute.
----------------
cooperp wrote:
I've added `CodeGenModule::StackProtectorAttribute(const Decl *D)` so that i
could get the attribute kind (if any) for a given decl. That is then used from
`SetLLVMFunctionAttributesForDefinition()` as it is today.
I also use it from `EmitAutoVarAlloca()` such that when the
`stack_protector_ignore` attribute is on a variable, you can get a warning such
as:
'stack_protector_ignore' attribute ignored due to '-fstack-protector-all'
option
https://github.com/llvm/llvm-project/pull/173311
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits