This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC][Power10] Implement Test LSB by Byte Builtins in LLVM/Clang
ClosedPublic

Authored by amyk on Jun 23 2020, 8:25 PM.

Details

Summary

This patch implements builtins for the following prototypes:

int vec_test_lsbb_all_ones (vector unsigned char a);  
int vec_test_lsbb_all_zeros (vector unsigned char a);

Diff Detail

Event Timeline

amyk created this revision.Jun 23 2020, 8:25 PM
amyk updated this revision to Diff 273745.Jun 26 2020, 8:27 AM

Updated to the correct indentation for the functions in altivec.h.

lei accepted this revision as: lei.Jun 26 2020, 12:40 PM

LGTM

This revision is now accepted and ready to land.Jun 26 2020, 12:40 PM
amyk updated this revision to Diff 274239.Jun 29 2020, 2:35 PM

Updated revision to:

  • add the MC test cases into vsx.s and vsx.txt.
  • create a test file called builtins-ppc-p10vsx.ll to place all Power10 VSX builtins tests.
amyk added a comment.Jun 29 2020, 2:35 PM

@lei Could you please take another look at this to see if this change is OK?

steven.zhang added inline comments.
llvm/test/MC/Disassembler/PowerPC/vsx.txt
2 ↗(On Diff #274239)

So, this is for bigendian, where is the little endian disassemble tests ...

lei added a comment.Jun 30 2020, 11:56 AM

encoding tests need to be placed in corresponding ppc64-encoding-ISA31* files

amyk updated this revision to Diff 274667.Jun 30 2020, 7:08 PM

Update patch to:

  • place MC tests in correct files
lei accepted this revision.Jun 30 2020, 8:26 PM

LGTM thx!

This revision was automatically updated to reflect the committed changes.