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

Hideto Ueno via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 7 23:13:22 PST 2019


uenoku added a comment.

Sorry for the delay. Basically it looks good to me regarding the logic. 
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>.



================
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);
----------------
Replaced/Replacement is a bit confusing. Could you change to Old/New or more appropriate words?


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