[PATCH] D63405: GlobalISel: Don't lose fneg flags when lowering to fsub

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 17 09:18:50 PDT 2019


arsenm added a comment.

In D63405#1546342 <https://reviews.llvm.org/D63405#1546342>, @spatel wrote:

> I'm not familiar with how flags are being used in this layer, but union of flags doesn't match the way we deal with FMF in IR. If the fneg is strict (disregard the irrelevant 'arcp' in that last test), then it's invalid to assume that it inherits the 'nsz' property from its operand.


I would expect the lowering here to just preserve the flag on the original instruction, and not propagate the source (as was done here previously). The corresponding expansion in the DAG has a TODO to preserve the flags, so there isn't precedent for this


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

https://reviews.llvm.org/D63405





More information about the llvm-commits mailing list