llvm-project/llvm
Simon Pilgrim 96238486ed [DAGCombine] Move the remaining X86 funnel shift patterns to DAGCombine
X86 matches several 'shift+xor' funnel shift patterns:

  fold (or (srl (srl x1, 1), (xor y, 31)), (shl x0, y))  -> (fshl x0, x1, y)
  fold (or (shl (shl x0, 1), (xor y, 31)), (srl x1, y))  -> (fshr x0, x1, y)
  fold (or (shl (add x0, x0), (xor y, 31)), (srl x1, y)) -> (fshr x0, x1, y)

These patterns are also what we end up with the proposed expansion changes in D77301.

This patch moves these to DAGCombine's generic MatchFunnelPosNeg.

All existing X86 test cases still pass, and we just have a small codegen change in pr32282.ll.

Reviewed By: @spatel

Differential Revision: https://reviews.llvm.org/D78935
2020-04-30 12:57:17 +01:00
..
benchmarks
bindings Update go bindings for 2dea3f1298 2020-04-22 19:02:59 +02:00
cmake Fix spurious warning in ExtensionDependencies.inc [nfc] 2020-04-30 11:16:37 +02:00
docs [docs][llvm-cxxfilt] Fix indentation in rst file 2020-04-30 10:41:45 +01:00
examples [ORC] Add example showing how to initialize/deinitialize a JITDylib with LLJIT. 2020-04-18 14:16:54 -07:00
include [AArch64][SVE] Remove unused FP reduction intrinsic definitions 2020-04-30 10:18:40 +00:00
lib [DAGCombine] Move the remaining X86 funnel shift patterns to DAGCombine 2020-04-30 12:57:17 +01:00
projects
resources
runtimes
test [DAGCombine] Move the remaining X86 funnel shift patterns to DAGCombine 2020-04-30 12:57:17 +01:00
tools [llvm-objcopy] [COFF] Fix a misconception about debug directory payloads 2020-04-29 20:35:36 +03:00
unittests [SVE][NFC] Remove unused variable 2020-04-29 14:30:32 -07:00
utils [lit] Provide extension API for custom result categories 2020-04-29 19:45:55 -07:00
.clang-format
.clang-tidy
.gitattributes
.gitignore
CMakeLists.txt Revert "Temporarily revert "build: use `find_package(Python3)` if available"" 2020-04-29 01:38:08 +00:00
CODE_OWNERS.TXT
CREDITS.TXT
LICENSE.TXT
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT
configure
llvm.spec.in

README.txt

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.