[PATCH] D56474: [ARM] [NEON] Add ROTR/ROTL lowering

easyaspi314 (Devin) via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 8 21:16:09 PST 2019


easyaspi314 created this revision.
easyaspi314 added reviewers: RKSimon, efriedma, craig.topper, t.p.northover, spatel.
Herald added subscribers: llvm-commits, kristof.beyls, javed.absar.

This patch adds support for converting `ISD::ROTR` and `ISD::ROTL` into either a `vshl/vsri` or a `vrevN` for ARM32 NEON.

This patch would also work for aarch64, and I will probably add it in later when I get a chance.

`vshl`/`vsri` vs `vshl`/`vshr`/`vorr` saves one instruction, and vrevN is a single cycle rotl for an `N/2` rotation (eg a 32-bit rotation on a 64-bit lane).


Repository:
  rL LLVM

https://reviews.llvm.org/D56474

Files:
  lib/Target/ARM/ARMISelLowering.cpp
  test/CodeGen/ARM/rotate.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56474.180788.patch
Type: text/x-patch
Size: 7248 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190109/43602933/attachment-0001.bin>


More information about the llvm-commits mailing list