[PATCH] D31085: [InlineCost] Increase the cost of Switch

Jun Bum Lim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 17 08:04:03 PDT 2017


junbuml added a comment.



> I was hoping we wouldn't need the refactoring to SwitchCaseCluster.cpp, and that InlineCost.cpp could just work with TLI to check whether jump tables are allowed, density requirements etc.

Sure, I can make InlineCost work with just TLI, but I don't want to duplicate the same code for InlineCost from lowering.  So I will refactor just a little bit on SelectionDAGBuilder to expose some util functions.

> My concern is that separating the case cluster code from SelectionDAGBuilder might be more trouble than it's worth.

Can you give me little bit more details about your concern  ?


https://reviews.llvm.org/D31085





More information about the llvm-commits mailing list