This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Add isel support for scalar STRICT_FADD/FSUB/FMUL/FDIV/FSQRT.
ClosedPublic

Authored by craig.topper on Dec 13 2021, 2:54 PM.

Details

Summary

Test that STRICT_FMINNUM/FMAXNUM are lowered to libcalls for f32/f64.
The RISC-V instructions don't match the behavior of fmin/fmax libcalls
with respect to SNaN.

Promoting FMINNUM/FMAXNUM for f16 needs more work outside of the
RISC-V backend.

Diff Detail

Event Timeline

craig.topper created this revision.Dec 13 2021, 2:54 PM
craig.topper requested review of this revision.Dec 13 2021, 2:54 PM
Herald added a project: Restricted Project. · View Herald TranscriptDec 13 2021, 2:54 PM
Herald added a subscriber: MaskRay. · View Herald Transcript
arcbbb accepted this revision.Dec 14 2021, 1:11 AM

LGTM

This revision is now accepted and ready to land.Dec 14 2021, 1:11 AM
asb accepted this revision.Dec 14 2021, 5:27 AM

My familiarity with the constrained FP intrinsics isn't high, so please speak up if there are any parts of this patch that you think need closer review. Though I've checked through and read Ulrich's patch adding the relevant STRICT_* SDag nodes, and it all seems fine to me.

This revision was landed with ongoing or failed builds.Dec 14 2021, 10:51 AM
This revision was automatically updated to reflect the committed changes.