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

easyaspi314 (Devin) via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 22 16:49:12 PST 2019


easyaspi314 added a comment.

Huh. Sorry about the idle time.

I noticed that there is an even faster way of doing a rotate, which is replacing `vshr`/`vsli` with `vshl`/`vsra`.

It appears to save at least one cycle, and in the xxhash benchmark, I go from 5.7 GB/s to almost 6.2 GB/s.

Doing this also fixes this bug:

  vsraq_n_u32(vshlq_n_u32(val, 13), val, 19);

should not generate

  vshl.i32 tmp, val, #13 
  vshr.u32 val, val, #19 
  vorr val, val, tmp


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56474/new/

https://reviews.llvm.org/D56474





More information about the llvm-commits mailing list