This is an archive of the discontinued LLVM Phabricator instance.

DAG: Fix getNode dropping flags if there's a glue output
ClosedPublic

Authored by arsenm on May 28 2020, 6:02 AM.

Details

Summary

The AMDGPU non-strict fdiv lowering needs to introduce an FP mode
switch in some cases, and has custom nodes to provide chain/glue for
the intermediate FP operations. We need to propagate nofpexcept here,
but getNode was dropping the flags.

Adding nofpexcept in the AMDGPU custom lowering is left to a future
patch.

Also fix a second case where flags were dropped, but in this case it
seems it just didn't handle this number of operands.

Test will be included in future AMDGPU patch.

Diff Detail