hanchenye-llvm-project/llvm/test
Sanjay Patel e12d734be3 [InstCombine] narrow truncated add/sub/mul with constant
Name: narrow_sub
  %sub = sub i32 C1, %x
  %r = trunc i32 %sub to i8
  =>  
  %xn = trunc i32 %x to i8
  %narrowC = trunc i32 C1 to i8
  %r = sub i8 %narrowC, %xn
 
Name: narrow_add
  %add = add i32 %x, C1
  %r = trunc i32 %add to i8
  =>  
  %xn = trunc i32 %x to i8
  %narrowC = trunc i32 C1 to i8
  %r = add i8 %xn, %narrowC
  
Name: narrow_mul
  %mul = mul i32 %x, C1
  %r = trunc i32 %mul to i8
  =>  
  %xn = trunc i32 %x to i8
  %narrowC = trunc i32 C1 to i8
  %r = mul i8 %xn, %narrowC


http://rise4fun.com/Alive/QpS

This doesn't solve PR34046 (failure to recognize rotate):
https://bugs.llvm.org/show_bug.cgi?id=34046
...but it reduces an extra complication in the description examples 
to a form that we can more easily match.

llvm-svn: 310141
2017-08-04 22:30:34 +00:00
..
Analysis [SCEV] Preserve NSW information for sext(subtract). 2017-08-04 20:19:46 +00:00
Assembler test: add an additional cfi_return_column test 2017-07-30 21:30:54 +00:00
Bindings
Bitcode [ThinLTO] Add FunctionAttrs to ThinLTO index 2017-08-04 16:00:58 +00:00
BugPoint
CodeGen Revert r310058, it caused PR34073. 2017-08-04 20:24:13 +00:00
DebugInfo Fix broken PDB tests. 2017-08-04 21:15:12 +00:00
DllTool [llvm-dlltool] Write correct weak externals 2017-07-31 11:18:41 +00:00
Examples
ExecutionEngine Don't pass the code model to MC 2017-08-02 20:32:26 +00:00
Feature
FileCheck [llvm] Remove redundant check-prefix=CHECK from tests. NFC. 2017-07-17 17:32:45 +00:00
Instrumentation [sanitizer-coverage] don't instrument available_externally functions 2017-07-31 20:00:22 +00:00
Integer
JitListener
LTO Update the new PM pipeline to make ICP aware if it is SamplePGO build. 2017-08-02 01:28:31 +00:00
LibDriver
Linker ThinLTO: Don't import aliases of any kind (even linkonce_odr) 2017-07-27 15:09:06 +00:00
MC [AMDGPU][MC] Enabled expressions as operands 2017-08-04 13:55:24 +00:00
Object [LTO] Prevent dead stripping and internalization of symbols with sections 2017-07-25 19:42:32 +00:00
ObjectYAML [codeview] Fix YAML for LF_TYPESERVER2 by hoisting PDB_UniqueId 2017-07-17 23:59:44 +00:00
Other Use profile summary to disable peeling for huge working sets 2017-08-03 23:42:58 +00:00
SafepointIRVerifier
SymbolRewriter
TableGen [GlobalISel] Only merge memory ops for mayLoad or mayStore instrs. 2017-08-03 14:48:22 +00:00
ThinLTO/X86 ThinLTO: Don't import aliases of any kind (even linkonce_odr) 2017-07-27 15:09:06 +00:00
Transforms [InstCombine] narrow truncated add/sub/mul with constant 2017-08-04 22:30:34 +00:00
Unit
Verifier Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
YAMLParser
tools Reland "[llvm][llvm-objcopy] Added support for outputting to binary in llvm-objcopy" 2017-08-04 21:09:26 +00:00
.clang-format
CMakeLists.txt Reland "[LLVM][llvm-objcopy] Added basic plumbing to get things started" 2017-08-01 00:33:58 +00:00
TestRunner.sh
lit.cfg Reland "[LLVM][llvm-objcopy] Added basic plumbing to get things started" 2017-08-01 00:33:58 +00:00
lit.site.cfg.in Correctly enable the llvm-mt tests, now that build flags changed. 2017-07-26 16:35:44 +00:00