[PATCH] D22713: Fix - CodeExtractor : Inherit Target Dependent Attributes from the parent function.
David Majnemer via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 22 21:26:24 PDT 2016
majnemer added a subscriber: majnemer.
================
Comment at: /Users/rriddle/Desktop/llvm/llvm/lib/Transforms/Utils/CodeExtractor.cpp:344
@@ +343,3 @@
+ // Inherit the uwtable attribute if we need to.
+ if(oldFunction->hasUWTable())
+ newFunction->setHasUWTable();
----------------
space after `if`
================
Comment at: /Users/rriddle/Desktop/llvm/llvm/lib/Transforms/Utils/CodeExtractor.cpp:353
@@ +352,3 @@
+ AttrBuilder AB(OldAttrs, AttributeSet::FunctionIndex);
+ for(auto Attr : AB.td_attrs())
+ newFunction->addFnAttr(Attr.first, Attr.second);
----------------
space after `for`
================
Comment at: /Users/rriddle/Desktop/llvm/llvm/lib/Transforms/Utils/CodeExtractor.cpp:388
@@ -374,3 +387,3 @@
AI->setName(inputs[i]->getName());
- for (unsigned i = 0, e = outputs.size(); i != e; ++i, ++AI)
+ for (unsigned i = 0, e = outputs.size(); i != e; ++i, ++AI){
AI->setName(outputs[i]->getName()+".out");
----------------
space before {
================
Comment at: /Users/rriddle/Desktop/llvm/llvm/test/Transforms/CodeExtractor/2016-07-20-InheritAttributes.ll:33-34
@@ +32,3 @@
+
+; CHECK-LABEL: @inlinedFunc.1_if.then
+; CHECK: #1
----------------
This doesn't do anything because you never pipe into FileCheck.
https://reviews.llvm.org/D22713
More information about the llvm-commits
mailing list