This is an archive of the discontinued LLVM Phabricator instance.

[X86][AVX512] add comi with Sae
ClosedPublic

Authored by AsafBadouh on Nov 4 2015, 5:05 AM.

Details

Summary

add builtin_ia32_vcomisd and builtin_ia32_vcomisd.
both have comparison modifier to handle.
isX86CondUnordered - check if the modifier is for ordered (comi) or unordered (ucomi).
TranslateX86ConstCondToX86CC - translate from intel const to X86 condcode.

Diff Detail

Event Timeline

AsafBadouh updated this revision to Diff 39190.Nov 4 2015, 5:05 AM
AsafBadouh retitled this revision from to [X86][AVX512] add comi with Sae.
AsafBadouh updated this object.
AsafBadouh added reviewers: igorb, delena.
AsafBadouh added a subscriber: llvm-commits.
delena added inline comments.Nov 4 2015, 6:10 AM
../llvm/lib/Target/X86/X86ISelLowering.cpp
4002 ↗(On Diff #39190)

(imm & 0x8) >> 3

4129 ↗(On Diff #39190)

I think the whole function should be something like this:

{ return imm & 0x7; }

AsafBadouh updated this revision to Diff 39212.Nov 4 2015, 8:54 AM

refactor and combine the two functions into one that returns tuple<isOrdered, x86::codeCond>

delena accepted this revision.Nov 4 2015, 11:12 PM
delena edited edge metadata.

LGTM

This revision is now accepted and ready to land.Nov 4 2015, 11:12 PM
This revision was automatically updated to reflect the committed changes.
AsafBadouh updated this revision to Diff 39649.Nov 8 2015, 1:37 AM
AsafBadouh edited edge metadata.
AsafBadouh removed rL LLVM as the repository for this revision.

fix failure in Ubuntu.
add compare constants to the header.

delena added inline comments.Nov 14 2015, 11:21 PM
../commit/llvm_clean/lib/Target/X86/X86ISelLowering.cpp
16434

X86CC - unsigned
X86CC - a tuple, please use another name in the next case

16447

Please add comments here.

16450

Align the line

../commit/llvm_clean/lib/Target/X86/X86IntrinsicsInfo.h
1811

It may fail on platforms, where these constants are defined.

AsafBadouh added inline comments.Nov 16 2015, 4:59 AM
../commit/llvm_clean/lib/Target/X86/X86IntrinsicsInfo.h
1811

I've tested it on Ubuntu OS and Win

AsafBadouh added inline comments.Nov 16 2015, 5:16 AM
../commit/llvm_clean/lib/Target/X86/X86IntrinsicsInfo.h
1811

sorry, It is raise warning on Win.
I'll think on different solution.

AsafBadouh updated this revision to Diff 40383.Nov 17 2015, 3:53 AM