[PATCH] D53285: [MergeFuncs] Generate alias instead of thunk if possible (default disabled)

whitequark via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Oct 28 23:55:35 PDT 2018


whitequark added inline comments.


================
Comment at: lib/Transforms/IPO/MergeFunctions.cpp:803
 
-    if (!isThunkProfitable(F)) {
+    if (!isThunkProfitable(F) && (!canCreateAliasFor(F) || !canCreateAliasFor(G))) {
       return;
----------------
Can you explain this logic a bit? It's not clear to me why the condition should be written like that (two canCreateAliasFor` calls).


Repository:
  rL LLVM

https://reviews.llvm.org/D53285





More information about the llvm-commits mailing list