[PATCH] D133417: [RISCV] Added optimization patterns with Zbb extension

Ilya Andreev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 8 02:52:59 PDT 2022


iabg-sc added a comment.

This patch specific for RISCV. There is no guarantee that min/max will work faster than two comparisons on other archs. 
I am not sure how count of the instructions can be increased as pattern explicitly specifies changes from three instructions to two (or three) instructions. Could you please give an example?
xori can be optimized later, but it requires more complex analysis than I suggest in this patch.
Right now I am trying to write self-expanding patterns in TableGen to support most cases.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D133417



More information about the llvm-commits mailing list