[PATCH] [PATCH 1/2] Add a "probe-stack" attribute

John Kåre Alsaker john.mailinglists at gmail.com
Sun May 10 23:30:25 PDT 2015


http://reviews.llvm.org/D9653

Files:
  lib/Transforms/IPO/Inliner.cpp

Index: lib/Transforms/IPO/Inliner.cpp
===================================================================
--- lib/Transforms/IPO/Inliner.cpp
+++ lib/Transforms/IPO/Inliner.cpp
@@ -132,6 +132,12 @@
 
   AdjustCallerSSPLevel(Caller, Callee);
 
+  // If the callee requires stack probes, we ensure that the caller will
+  // require those too
+  if (Callee->hasFnAttribute("probe-stack")) {
+    Caller->addFnAttr("probe-stack", "");
+  }
+
   // Look at all of the allocas that we inlined through this call site.  If we
   // have already inlined other allocas through other calls into this function,
   // then we know that they have disjoint lifetimes and that we can merge them.

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D9653.25445.patch
Type: text/x-patch
Size: 680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150511/eb096bfe/attachment.bin>


More information about the llvm-commits mailing list