[PATCH] D70066: [MacroFusion] Limit the max fused number as 2 to reduce the dependency

qshanz via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 26 21:28:13 PST 2019


steven.zhang added a comment.

I have updated the patch for easy to review. Personally, passing the SUnit and add one helper function for target to check the fused SU number is also ok for me. The only concern is that, other target might not know that, they need to check it manually if they happens to add some fusion pattern that could be fused more than once. As the hardware only supports the back-2-back macro-fusion as far as I see now,  it makes sense to assume it in MacroFusion. And we can change it in the future if some target want it.

The penalty for this patch is to check the SU's number for all targets. However, as the limit is 2 and we need to walk the list once at most. It is cheap I think.


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

https://reviews.llvm.org/D70066





More information about the llvm-commits mailing list