This is an archive of the discontinued LLVM Phabricator instance.

[clang][SveEmitter] SVE builtins for `svusdot` and `svsudot` ACLE.
ClosedPublic

Authored by fpetrogalli on May 13 2020, 9:20 AM.

Details

Summary

Intrinsics, guarded by __ARM_FEATURE_SVE_MATMUL_INT8:

  • svusdot[_s32]
  • svusdot[_n_s32]
  • svusdot_lane[_s32]
  • svsudot[_s32]
  • svsudot[_n_s32]
  • svsudot_lane[_s32]

Diff Detail

Event Timeline

fpetrogalli created this revision.May 13 2020, 9:20 AM
efriedma accepted this revision.May 13 2020, 11:21 AM

LGTM with one small comment.

clang/include/clang/Basic/arm_sve.td
1249

These intrinsics aren't overloaded; maybe consider writing the actual type int8_t/uint8_t, instead of introducing "unsigned scalar of 1/4 width element type"? If there's some reason the current form is better, that's fine, though.

This revision is now accepted and ready to land.May 13 2020, 11:21 AM
fpetrogalli marked 2 inline comments as done.May 14 2020, 3:39 PM
fpetrogalli added inline comments.
clang/include/clang/Basic/arm_sve.td
1249

I am probably missing something, but I can't see a type specifier that is not overloaded and that renders to 8-bit elements?

I have opted for adding "unsigned scalar of 1/4 width element type" because it keeps things symmetric with the vector equivalent, signed and unsigned.

// r: scalar of 1/4 width element type (splat to vector type)
// @: unsigned scalar of 1/4 width element type (splat to vector type)
[..]
// b: 1/4 width unsigned elements, 4x element count
// q: 1/4 width elements, 4x element count
fpetrogalli marked an inline comment as done.

Fix formatting of code in test. NFC

fpetrogalli marked an inline comment as done.May 18 2020, 3:35 PM
fpetrogalli added inline comments.
clang/include/clang/Basic/arm_sve.td
1249

@efriedma , are you satisfied with this answer? are you happy for me to submit this as it is?

efriedma accepted this revision.May 18 2020, 3:52 PM
efriedma added inline comments.
clang/include/clang/Basic/arm_sve.td
1249

Yes, it's fine.

This revision was automatically updated to reflect the committed changes.