[PATCH] D76707: [DAGCombine] Add basic optimizations for FREEZE in SelDag

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 24 11:17:00 PDT 2020


spatel added a comment.

In D76707#1939525 <https://reviews.llvm.org/D76707#1939525>, @aqjune wrote:

> BTW, I tried to write a unit test that checks the freeze(freeze) -> freeze folding, but simply making llc print assembly wasn't enough to distinguish its effect. Is there a commandline option that prints SelDag just after dagcombiner?


You could try something like "-stop-before=finalize-isel" and then check the MIR for an extra COPY instruction.
See llvm/test/CodeGen/X86/sqrt-fastmath-mir.ll for an example of that type of regression test.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D76707





More information about the llvm-commits mailing list