Skip to content
  1. Sep 21, 2009
    • Chris Lattner's avatar
      convert an std::pair to an explicit struct. · 0cdc17eb
      Chris Lattner authored
      llvm-svn: 82446
      0cdc17eb
    • Chris Lattner's avatar
      move some functions, add a comment. · d28f9089
      Chris Lattner authored
      llvm-svn: 82444
      d28f9089
    • Chris Lattner's avatar
      split HandleLoadFromClobberingStore in two pieces: one that does the · 9d7fb295
      Chris Lattner authored
      analysis, one that does the xform.
      
      llvm-svn: 82443
      9d7fb295
    • Chris Lattner's avatar
      Improve GVN to be able to forward substitute a small load · 0a9616d9
      Chris Lattner authored
      from a piece of a large store when both are in the same block.
      
      This allows clang to compile the testcase in PR4216 to this code:
      
      _test_bitfield:
      	movl	4(%esp), %eax
      	movl	%eax, %ecx
      	andl	$-65536, %ecx
      	orl	$32962, %eax
      	andl	$40186, %eax
      	orl	%ecx, %eax
      	ret
      
      This is not ideal, but is a whole lot better than the code produced
      by llvm-gcc:
      
      _test_bitfield:
      	movw	$-32574, %ax
      	orw	4(%esp), %ax
      	andw	$-25350, %ax
      	movw	%ax, 4(%esp)
      	movw	7(%esp), %cx
      	shlw	$8, %cx
      	movzbl	6(%esp), %edx
      	orw	%cx, %dx
      	movzwl	%dx, %ecx
      	shll	$16, %ecx
      	movzwl	%ax, %eax
      	orl	%ecx, %eax
      	ret
      
      and dramatically better than that produced by gcc 4.2:
      
      _test_bitfield:
      	pushl	%ebx
      	call	L3
      "L00000000001$pb":
      L3:
      	popl	%ebx
      	movl	8(%esp), %eax
      	leal	0(,%eax,4), %edx
      	sarb	$7, %dl
      	movl	%eax, %ecx
      	andl	$7168, %ecx
      	andl	$-7201, %ebx
      	movzbl	%dl, %edx
      	andl	$1, %edx
      	sall	$5, %edx
      	orl	%ecx, %ebx
      	orl	%edx, %ebx
      	andl	$24, %eax
      	andl	$-58336, %ebx
      	orl	%eax, %ebx
      	orl	$32962, %ebx
      	movl	%ebx, %eax
      	popl	%ebx
      	ret
      
      llvm-svn: 82439
      0a9616d9
    • Chris Lattner's avatar
      formatting cleanups, no functionality change. · 1eefa9c4
      Chris Lattner authored
      llvm-svn: 82426
      1eefa9c4
  2. Sep 20, 2009
  3. Sep 19, 2009
  4. Sep 18, 2009
    • Victor Hernandez's avatar
      Update malloc call creation code (AllocType is now the element type of the... · 788eaabd
      Victor Hernandez authored
      Update malloc call creation code (AllocType is now the element type of the malloc, not the resulting type).
      
      In getMallocArraySize(), fix bug in the case that array size is the product of 2 constants.
      
      Extend isArrayMalloc() and getMallocArraySize() to handle case where malloc is used as char array.
      
      Ensure that ArraySize in LowerAllocations::runOnBasicBlock() is correct type.
      
      Extend Instruction::isSafeToSpeculativelyExecute() to handle malloc calls.
      
      Add verification for malloc calls.
      
      Reviewed by Dan Gohman.
      
      llvm-svn: 82257
      788eaabd
  5. Sep 17, 2009
  6. Sep 16, 2009
  7. Sep 15, 2009
  8. Sep 11, 2009
  9. Sep 10, 2009
  10. Sep 09, 2009
  11. Sep 08, 2009
Loading