Go to file
Sanjay Patel e98ec77a95 [InstSimplify] delete shift-of-zero guard ops around funnel shifts
This is a problem seen in common rotate idioms as noted in:
https://bugs.llvm.org/show_bug.cgi?id=34924

Note that we are not canonicalizing standard IR (shifts and logic) to the intrinsics yet. 
(Although I've written this before...) I think this is the last step before we enable 
that transform. Ie, we could regress code by doing that transform without this 
simplification in place.

In PR34924, I questioned whether this is a valid transform for target-independent IR, 
but I convinced myself this is ok. If we're speculating a funnel shift by turning cmp+br 
into select, then SimplifyCFG has already determined that the transform is justified. 
It's possible that SimplifyCFG is not taking into account profile or other metadata, 
but if that's true, then it's a bug independent of funnel shifts.

Also, we do have CGP code to restore a guard like this around an intrinsic if it can't 
be lowered cheaply. But that isn't necessary for funnel shift because the default 
expansion in SelectionDAGBuilder includes this same cmp+select.

Differential Revision: https://reviews.llvm.org/D54552

llvm-svn: 346960
2018-11-15 14:53:37 +00:00
clang [AST][NFC] Re-add comment in BinaryOperator which was removed by r346954 2018-11-15 14:30:18 +00:00
clang-tools-extra [clangd] global-symbol-builder => clangd-indexer 2018-11-15 14:15:19 +00:00
compiler-rt Start adding the supporting code to perform out-of-process allocator 2018-11-15 14:20:28 +00:00
debuginfo-tests Set config.lit_tools_dir, which is needed by lit.llvm.initialize. 2018-11-06 21:54:27 +00:00
libclc r600: Add datalayout to image builtin implementation 2018-11-10 21:43:40 +00:00
libcxx propagate __config_site includes when building benchmarks 2018-11-15 07:29:56 +00:00
libcxxabi [CMake] Passthrough CFLAGS when checking the compiler-rt path 2018-11-14 00:09:26 +00:00
libunwind [CMake] Passthrough CFLAGS when checking the compiler-rt path 2018-11-14 00:09:26 +00:00
lld [ELF] Fix compilation with GCC 5 2018-11-15 08:20:18 +00:00
lldb Fix a use-after-free of the ABI plugin. 2018-11-15 05:06:59 +00:00
llgo
llvm [InstSimplify] delete shift-of-zero guard ops around funnel shifts 2018-11-15 14:53:37 +00:00
openmp Fix for bugzilla https://bugs.llvm.org/show_bug.cgi?id=39137. 2018-11-14 13:49:41 +00:00
parallel-libs
polly [CMake] Fix generation of exported targets in build directory 2018-11-06 15:18:17 +00:00
README.md

README.md

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.