This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Add patterns for bitreverse intrinsic on MVE
ClosedPublic

Authored by oliverlars on Sep 3 2019, 9:44 AM.

Details

Summary

BITREVERSE can use the VBRSR which will reverse and right shift. Shifting right by 0 will just reverse the bits.

Diff Detail

Repository
rL LLVM

Event Timeline

oliverlars created this revision.Sep 3 2019, 9:44 AM
oliverlars updated this revision to Diff 218704.Sep 4 2019, 7:54 AM

Added -verify-machineinstrs and a test for 2i64

oliverlars updated this revision to Diff 219349.Sep 9 2019, 7:29 AM

added test for 2i64 and fixed vbrsr not taking a register operand

dmgreen accepted this revision.Sep 13 2019, 2:21 AM

LGTM. Thanks

llvm/test/CodeGen/Thumb2/mve-bitreverse.ll
10

This one is nice too, that it works this out.

This revision is now accepted and ready to land.Sep 13 2019, 2:21 AM