llvm-mirror/lib
Benjamin Kramer 44c76d239a Emit a more efficient magic number multiplication for exact sdivs.
We have to do this in DAGBuilder instead of DAGCombiner, because the exact bit is lost after building.

  struct foo { char x[24]; };
  long bar(struct foo *a, struct foo *b) { return a-b; }
is now compiled into
  movl	4(%esp), %eax
  subl	8(%esp), %eax
  sarl	$3, %eax
  imull	$-1431655765, %eax, %eax
instead of
  movl	4(%esp), %eax
  subl	8(%esp), %eax
  movl	$715827883, %ecx
  imull	%ecx
  movl	%edx, %eax
  shrl	$31, %eax
  sarl	$2, %edx
  addl	%eax, %edx
  movl	%edx, %eax

llvm-svn: 134695
2011-07-08 10:31:30 +00:00
..
Analysis Preserve debug loc. 2011-07-05 21:48:22 +00:00
Archive Revert PathV2 changes, as sys::fs::unique_file is not finished yet. 2011-03-01 19:50:55 +00:00
AsmParser Replace the existing forms of ConstantArray::get() with a single form 2011-06-22 09:24:39 +00:00
Bitcode type can be null 2011-07-07 05:29:18 +00:00
CodeGen Emit a more efficient magic number multiplication for exact sdivs. 2011-07-08 10:31:30 +00:00
CompilerDriver Build CompilerDriver library. 2011-03-12 22:01:42 +00:00
ExecutionEngine Fix the ridiculous SubtargetFeatures API where it implicitly expects CPU name to 2011-06-30 01:53:36 +00:00
Linker Set the unnamed_addr only when we're creating a new GV in the dest module. 2011-03-29 23:31:06 +00:00
MC Eliminate asm parser's dependency on TargetMachine: 2011-07-08 01:53:10 +00:00
Object Use memcmp. 2011-07-05 20:28:00 +00:00
Support Recognize mipseb as alias for mips for symmetry with mipsel. 2011-07-07 16:53:52 +00:00
Target Eliminate asm parser's dependency on TargetMachine: 2011-07-08 01:53:10 +00:00
Transforms Make GVN look through extractvalues for recognised intrinsics. GVN can then CSE ops that match values produced by the intrinsics. 2011-07-08 01:50:54 +00:00
VMCore Introduce "expect" intrinsic instructions. 2011-07-06 18:22:43 +00:00
CMakeLists.txt Build CompilerDriver library. 2011-03-12 22:01:42 +00:00
Makefile Add LLVMObject Library. 2010-11-15 03:21:41 +00:00