Page MenuHomePhabricator

[X86][FPEnv] Teach X86 mask compare intrinsics to respect strict FP semantics.
ClosedPublic

Authored by pengfei on Aug 5 2020, 5:50 PM.

Details

Summary

When we use mask compare intrinsics under strict FP option, the masked
elements shouldn't raise any exception. So, we cann't replace the
intrinsic with a full compare + "and" operation.

Diff Detail

Event Timeline

pengfei created this revision.Aug 5 2020, 5:50 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptAug 5 2020, 5:50 PM
pengfei requested review of this revision.Aug 5 2020, 5:50 PM
craig.topper added inline comments.Aug 10 2020, 5:43 PM
clang/test/CodeGen/avx512f-builtins-constrained-cmp.c
793

I missed this in our internal review. All of these check lines check "#2" at the end, do we need that?

llvm/lib/IR/AutoUpgrade.cpp
3764

Can we use getX86MaskVec here?

pengfei updated this revision to Diff 284547.Aug 10 2020, 6:41 PM
pengfei marked 2 inline comments as done.

Address review comments.

pengfei added inline comments.Aug 10 2020, 6:42 PM
clang/test/CodeGen/avx512f-builtins-constrained-cmp.c
793

No. I forgot to remove them. Thank you.

llvm/lib/IR/AutoUpgrade.cpp
3764

Sure. It's more clean now. Thanks.

This revision is now accepted and ready to land.Aug 10 2020, 6:58 PM
This revision was landed with ongoing or failed builds.Aug 10 2020, 7:28 PM
This revision was automatically updated to reflect the committed changes.