[PATCH] [OPENMP] llvm.loop.vectorize.enable metadata are lost after critical edge splitting
atrick at apple.com
Tue Sep 30 09:25:57 PDT 2014
If the problem here is that GVN is dropping the loop.vectortize metadata, adding LoopInfo as a required pass seems fundamentally wrong. Critical edge splitting is supposed to be something any pass can do on-the-fly without extra analysis. Of course, the whole problem would have been simpler if we just required annotated loops to have split edges to begin with, but that issue is out-of-scope for this bug.
I have some basic questions:
- I haven't been paying close attention to the loop.vectorize metadata design. Why does it need to be on the loop backedge branch? It doesn't seem hard to discover the metadata on the last conditional branch leading to the backedge.
- Even if you do need to move the metadata to a different branch, why is LoopInfo required? Is it because we can't tell if we're splitting the backedge or the loop exit? DomTree would often be sufficient to tell them apart.
More information about the llvm-commits