[PATCH] D87956: [WIP][IR] add fn attr for no_stack_protector; prevent inlining ssp into no-ssp

Bill Wendling via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 30 03:17:32 PDT 2020


void added inline comments.


================
Comment at: llvm/lib/Transforms/Utils/InlineFunction.cpp:1679
 
+  // Inlining a function the explicitly should not have a stack protector may
+  // break the code if inlined into a function that does have a stack
----------------
s/the/that/


================
Comment at: llvm/lib/Transforms/Utils/InlineFunction.cpp:1682
+  // protector.
+  if (Caller->hasFnAttribute(Attribute::NoStackProtect))
+    if (CalledFunc->hasFnAttribute(Attribute::StackProtect) ||
----------------
Should we check whether the function with nossp needs an ssp before issuing the error?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D87956/new/

https://reviews.llvm.org/D87956



More information about the llvm-commits mailing list