[PATCH] D93838: [LLVM] [SCCP] [WIP] : Add Function Specialization pass

Vinay Madhusudan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 5 22:04:16 PST 2021


mivnay added inline comments.


================
Comment at: lib/Transforms/IPO/FunctionSpecialization.cpp:247
+  unsigned getSpecializationBonus(Argument *A, Constant *C) {
+    // TODO: Yet to implement
+    return 2;
----------------
dongAxis1944 wrote:
> by the way,  could we use the inline cost model to get this bonus?
> 
> The inline cost might calculate the cost that considering sora,const-prop,dce, etc. I think it might be great for this function.  
> 
> Any thoughts?
 Inline cost model works for the function pointer like arguments. We are specializing other type arguments as well. I have a patch ready for proposal but waiting for D93762 to be checked-in first..


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D93838



More information about the llvm-commits mailing list