[PATCH] D68765: [Attributor] Function signature rewrite infrastructure

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 8 12:16:01 PST 2019


jdoerfert marked an inline comment as done.
jdoerfert added a comment.

In D68765#1738212 <https://reviews.llvm.org/D68765#1738212>, @uenoku wrote:

> Sorry for the delay. Basically it looks good to me regarding the logic.


Let me know if there is anything else. I would update this for the final version based on the smaller changes you requested.

> I think you need to separate diff for argument promotion test changes or wait for reaching on an agreement in D69748 <https://reviews.llvm.org/D69748>.

I'll copy the tests over into a new Attributor test folder.



================
Comment at: llvm/lib/Transforms/IPO/Attributor.cpp:5173-5192
+    Function *ReplacementFn =
+        Function::Create(ReplacementFnTy, ReplacedFn->getLinkage(),
+                         ReplacedFn->getAddressSpace(), "");
+    ReplacedFn->getParent()->getFunctionList().insert(ReplacedFn->getIterator(),
+                                                      ReplacementFn);
+    ReplacementFn->takeName(ReplacedFn);
+    ReplacementFn->copyAttributesFrom(ReplacedFn);
----------------
uenoku wrote:
> Replaced/Replacement is a bit confusing. Could you change to Old/New or more appropriate words?
Will do.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D68765





More information about the llvm-commits mailing list