Page MenuHomePhabricator

[X86][AVX][AVX2]: Adding full coverage of MC encoding for the AVX, AVX2 isa set.<NFC>
ClosedPublic

Authored by gadi.haber on Nov 21 2017, 1:31 AM.

Details

Summary

NFC.
Adding MC regressions tests to cover the AVX and AVX2 ISA sets.
This patch is part of a larger task to cover MC encoding of all X86 ISA Sets.
See revision: https://reviews.llvm.org/D39952

Diff Detail

Repository
rL LLVM

Event Timeline

gadi.haber created this revision.Nov 21 2017, 1:31 AM
RKSimon edited edge metadata.Nov 22 2017, 7:44 AM

Should 64-bit tests be testing both 0-7 reg and 8-15?

You mean that each instruction should cover all registers?
I did a quick check and it produces a huge number of tests that exceed 200k including AVX512.
I, therefore, chose to use only representatives.

You mean that each instruction should cover all registers?
I did a quick check and it produces a huge number of tests that exceed 200k including AVX512.
I, therefore, chose to use only representatives.

Not all registers, just the cases where the xmm8-15 (x86-64) variants have different encodings.

Ah, You mean the XMM registers.

I think he wants you to make sure you test both values of the VEX.R, VEX.X and VEX.B bits.

I think he wants you to make sure you test both values of the VEX.R, VEX.X and VEX.B bits.

Yes, that will require testing on the AVX1/AVX2/FMA tests at least, maybe others as well.

AVX2-32.s : Removed redundant # signs from AVX2-32.s
AVX2-64.s: Duplicated the tests to use XMM8 and YMM9

  1. Added AVX tests for 32 and 64 bits.
  2. Updated AVX2 64 bit tests to include xmm15 test in addition to xmm6 tests
gadi.haber retitled this revision from [X86][AVX2]: Adding full coverage of MC encoding for the AVX2 isa set.<NFC> to [X86][AVX][AVX2]: Adding full coverage of MC encoding for the AVX2 isa set.<NFC>.Dec 1 2017, 11:05 AM
gadi.haber edited the summary of this revision. (Show Details)
gadi.haber retitled this revision from [X86][AVX][AVX2]: Adding full coverage of MC encoding for the AVX2 isa set.<NFC> to [X86][AVX][AVX2]: Adding full coverage of MC encoding for the AVX, AVX2 isa set.<NFC>.Dec 10 2017, 1:12 PM

LGTM, if no one has something to add

m_zuckerman accepted this revision.Dec 14 2017, 4:35 AM
This revision is now accepted and ready to land.Dec 14 2017, 4:35 AM

X87 diff replaced by AVX1 diff

gadi.haber closed this revision.Dec 14 2017, 9:25 AM

Are gather instructions in a different ISA set? Architecturally they are part of AVX2, but i don't see them here.

This also doesn't appear to test the VEX.X bit since your addresses never use r8-r15 for an index.

Yes Gather instructions are part of AVX2GATHER.
I will add the VEX.X testing to all AVX tests.