Skip to content
  1. Jan 07, 2005
  2. Jan 06, 2005
  3. Jan 05, 2005
  4. Jan 04, 2005
  5. Jan 03, 2005
  6. Jan 02, 2005
  7. Jan 01, 2005
    • Jeff Cohen's avatar
      Add functions for determining if the stdin/out/err is connected to a · b90c31fb
      Jeff Cohen authored
      console or not.
      
      llvm-svn: 19236
      b90c31fb
    • Reid Spencer's avatar
      Add functions for determining if the stdin/out/err is connected to a · 6f802ba8
      Reid Spencer authored
      console or not.
      
      llvm-svn: 19233
      6f802ba8
    • Chris Lattner's avatar
      This is a bulk commit that implements the following primary improvements: · 86102b8a
      Chris Lattner authored
        * We can now fold cast instructions into select instructions that
          have at least one constant operand.
        * We now optimize expressions more aggressively based on bits that are
          known to be zero.  These optimizations occur a lot in code that uses
          bitfields even in simple ways.
        * We now turn more cast-cast sequences into AND instructions.  Before we
          would only do this if it if all types were unsigned.  Now only the
          middle type needs to be unsigned (guaranteeing a zero extend).
        * We transform sign extensions into zero extensions in several cases.
      
      This corresponds to these test/Regression/Transforms/InstCombine testcases:
        2004-11-22-Missed-and-fold.ll
        and.ll: test28-29
        cast.ll: test21-24
        and-or-and.ll
        cast-cast-to-and.ll
        zeroext-and-reduce.ll
      
      llvm-svn: 19220
      86102b8a
    • Chris Lattner's avatar
      Fix a FIXME: Select instructions on longs were miscompiled. · 83df5d25
      Chris Lattner authored
      While we're at it, improve codegen of select instructions.  For this
      testcase:
      
      int %test(bool %C, int %A, int %B) {
        %D = select bool %C, int %A, int %B
        ret int %D
      }
      
      We used to generate this code:
      
      _test:
              cmpwi cr0, r3, 0
              bne .LBB_test_2 ;
      .LBB_test_1:    ;
              b .LBB_test_3   ;
      .LBB_test_2:    ;
              or r5, r4, r4
      .LBB_test_3:    ;
              or r3, r5, r5
              blr
      
      Now we emit:
      
      _test:
              cmpwi cr0, r3, 0
              bne .LBB_test_2 ;
      .LBB_test_1:    ;
              or r4, r5, r5
      .LBB_test_2:    ;
              or r3, r4, r4
              blr
      
      -Chris
      
      llvm-svn: 19214
      83df5d25
    • Chris Lattner's avatar
      Substantially improve the code generated by non-folded setcc instructions. · 78394258
      Chris Lattner authored
      In particular, instead of compiling this:
      
      bool %test(int %A, int %B) {
        %C = setlt int %A, %B
        ret bool %C
      }
      
      to this:
      
      test:
              save %sp, -96, %sp
              subcc %i0, %i1, %g0
              bl .LBBtest_1   !
              nop
              ba .LBBtest_2   !
              nop
      .LBBtest_1:     !
              or %g0, 1, %i0
              ba .LBBtest_3   !
              nop
      .LBBtest_2:     !
              or %g0, 0, %i0
              ba .LBBtest_3   !
              nop
      .LBBtest_3:     !
              restore %g0, %g0, %g0
              retl
              nop
      
      We now compile it to this:
      
      test:
              save %sp, -96, %sp
              subcc %i0, %i1, %g0
              or %g0, 1, %i0
              bl .LBBtest_2   !
              nop
      .LBBtest_1:     !
              or %g0, %g0, %i0
      .LBBtest_2:     !
              restore %g0, %g0, %g0
              retl
              nop
      
      llvm-svn: 19213
      78394258
    • Chris Lattner's avatar
      Implement SimplifyCFG/DeadSetCC.ll · 3215bb60
      Chris Lattner authored
      SimplifyCFG is one of those passes that we use for final cleanup: it should
      not rely on other passes to clean up its garbage.  This fixes the "why are
      trivially dead setcc's in the output of gccas" problem.
      
      llvm-svn: 19212
      3215bb60
    • Chris Lattner's avatar
      Allow getZeroExtend and getSignExtend to work with boolean inputs. · 1ece6f83
      Chris Lattner authored
      llvm-svn: 19210
      1ece6f83
  8. Dec 31, 2004
  9. Dec 30, 2004
Loading