[PATCH] expose ILP for associative operations in the DAG

Sanjay Patel spatel at rotateright.com
Thu May 14 13:24:09 PDT 2015


In http://reviews.llvm.org/D9780#173061, @escha wrote:

> Could you help me try to understand what purpose this serves in terms of complementing the already-existing reassociate pass? That is, what benefit comes from doing it in the DAG in addition to the existing reassociate IR pass?


Sure - this came up in the earlier review thread:

1. http://reviews.llvm.org/D8941 provides a simple motivating example for doing this in the DAG; the multiplies that we want to reassociate don't exist before the DAGCombine that transforms the divisions.
2. More important: this is not a canonical-type of transform that is suitable for IR; this transform increases register pressure and some targets (like some GPUs, as I learned from the previous reversion) simply won't benefit from this optimization because there is no ILP exposed to the programmer.


http://reviews.llvm.org/D9780

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list