This is an archive of the discontinued LLVM Phabricator instance.

DAG: Add new control for ISD::FMAD formation
ClosedPublic

Authored by arsenm on Oct 28 2019, 11:17 AM.

Details

Summary

For AMDGPU this depends on whether denormals are enabled in the
default FP mode for the function. Currently this is treated as a
subtarget feature, so FMAD is selectively legal based on that. I want
to move this out of the subtarget features so this can be controlled
with a denormal mode attribute. Additionally, this will allow folding
based on a future ftz fast math flag.

Diff Detail

Event Timeline

arsenm created this revision.Oct 28 2019, 11:17 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 28 2019, 11:17 AM
simoll added a subscriber: simoll.Oct 28 2019, 11:21 AM

This looks good. Is it possible to write tests for the AMDGPU specific change?

Side note: I've been meaning to get around to pushing the FTZ conversation on llvm-dev, but haven't found time yet. I'll try to coordinate with @andrew.w.kaylor towards the end of this week...

This looks good. Is it possible to write tests for the AMDGPU specific change?

Side note: I've been meaning to get around to pushing the FTZ conversation on llvm-dev, but haven't found time yet. I'll try to coordinate with @andrew.w.kaylor towards the end of this week...

This patch is NFC. Switching the denormal handling is in a future patch

This revision is now accepted and ready to land.Oct 29 2019, 12:07 PM