[PATCH] D12887: [Machine Combiner] Refactor machine reassociation into a target-independent pass
Haicheng Wu via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 16 07:45:02 PDT 2015
haicheng added a comment.
Thank you for your quick response, Sanjay.
This patch is trivial. As the next step, we will add the reassociation pass to other targets such as aarch64. In that case, aarch64 needs to run both reassociation and machine-combiner pass. We separate these two passes because of two reasons.
1. The machine-combiner pass searches and combines a pair of instructions (mul & add/sub), but the reassociation pass may optimize on a long chain of instructions. They may need different optimizations in the future (e.g. compilation time optimization).
2. If a target needs to run both passes, it may need different pattern enums. It might be ugly to put them in the same pass.
Please let us know your opinion.
Repository:
rL LLVM
http://reviews.llvm.org/D12887
More information about the llvm-commits
mailing list