[PATCH] D72906: [X86] Improve X86 cmpps/cmppd/cmpss/cmpsd intrinsics with strictfp

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 17 01:37:33 PST 2020


craig.topper created this revision.
craig.topper added reviewers: RKSimon, spatel, uweigand.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
craig.topper added reviewers: pengfei, LiuChen3, andrew.w.kaylor.

The constrained fcmp intrinsics don't allow the TRUE/FALSE predicates.
Using them will assert. To workaround this I'm just emitting
all ones or all zeros. But I'm losing the exception behavior as
noted in the FIXME. But missing an exception is better than not
compiling at all.

I've also added support for selecting between signaling and quiet.

Still need to support SAE which will require using a target specific
intrinsic. Also need to fix masking to not use an AND instruction
after the compare.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D72906

Files:
  clang/lib/CodeGen/CGBuiltin.cpp
  clang/test/CodeGen/avx-builtins-constrained.c
  clang/test/CodeGen/avx512f-builtins-constrained.c
  clang/test/CodeGen/avx512vl-builtins-constrained.c
  clang/test/CodeGen/sse-builtins-constrained.c
  clang/test/CodeGen/sse2-builtins-constrained.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72906.238715.patch
Type: text/x-patch
Size: 196417 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200117/b4ac567b/attachment-0001.bin>


More information about the llvm-commits mailing list