Skip to content
  1. Sep 07, 2010
    • Chris Lattner's avatar
      in the case where an instruction only has one implementation · 339cc7bf
      Chris Lattner authored
      of a mneumonic, report operand errors with better location
      info.  For example, we now report:
      
      t.s:6:14: error: invalid operand for instruction
              cwtl $1
                   ^
      
      but we fail for common cases like:
      
      t.s:11:4: error: invalid operand for instruction
         addl $1, $1
         ^
      
      because we don't know if this is supposed to be the reg/imm or imm/reg
      form.
      
      llvm-svn: 113178
      339cc7bf
  2. Sep 06, 2010
  3. Sep 05, 2010
    • Chris Lattner's avatar
      update this. · 5cac0f71
      Chris Lattner authored
      llvm-svn: 113116
      5cac0f71
    • Chris Lattner's avatar
      implement rdar://6653118 - fastisel should fold loads where possible. · eeba0c73
      Chris Lattner authored
      Since mem2reg isn't run at -O0, we get a ton of reloads from the stack,
      for example, before, this code:
      
      int foo(int x, int y, int z) {
        return x+y+z;
      }
      
      used to compile into:
      
      _foo:                                   ## @foo
      	subq	$12, %rsp
      	movl	%edi, 8(%rsp)
      	movl	%esi, 4(%rsp)
      	movl	%edx, (%rsp)
      	movl	8(%rsp), %edx
      	movl	4(%rsp), %esi
      	addl	%edx, %esi
      	movl	(%rsp), %edx
      	addl	%esi, %edx
      	movl	%edx, %eax
      	addq	$12, %rsp
      	ret
      
      Now we produce:
      
      _foo:                                   ## @foo
      	subq	$12, %rsp
      	movl	%edi, 8(%rsp)
      	movl	%esi, 4(%rsp)
      	movl	%edx, (%rsp)
      	movl	8(%rsp), %edx
      	addl	4(%rsp), %edx    ## Folded load
      	addl	(%rsp), %edx     ## Folded load
      	movl	%edx, %eax
      	addq	$12, %rsp
      	ret
      
      Fewer instructions and less register use = faster compiles.
      
      llvm-svn: 113102
      eeba0c73
  4. Sep 04, 2010
  5. Sep 03, 2010
Loading