[all-commits] [llvm/llvm-project] 8779b1: [DAGCombiner] rot i16 X, 8 --> bswap X
RotateRight via All-commits
all-commits at lists.llvm.org
Mon Jul 13 09:02:52 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 8779b114109dd1461a410e2357f2505665e6efec
https://github.com/llvm/llvm-project/commit/8779b114109dd1461a410e2357f2505665e6efec
Author: Sanjay Patel <spatel at rotateright.com>
Date: 2020-07-13 (Mon, 13 Jul 2020)
Changed paths:
M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
M llvm/test/CodeGen/X86/rot16.ll
Log Message:
-----------
[DAGCombiner] rot i16 X, 8 --> bswap X
We have this generic transform in IR (instcombine),
but as shown in PR41098:
http://bugs.llvm.org/PR41098
...the pattern may emerge in codegen too.
x86 has a potential refinement/reversal opportunity here,
but that should come later or needs a target hook to
avoid the transform. Converting to bswap is the more
specific form, so we should use it if it is available.
More information about the All-commits
mailing list