Skip to content
  1. Dec 12, 2012
  2. Dec 11, 2012
    • Nadav Rotem's avatar
    • Tom Stellard's avatar
      Add R600 backend · 75aadc28
      Tom Stellard authored
      A new backend supporting AMD GPUs: Radeon HD2XXX - HD7XXX
      
      llvm-svn: 169915
      75aadc28
    • Bill Schmidt's avatar
      This patch implements the general dynamic TLS model for 64-bit PowerPC. · c56f1d34
      Bill Schmidt authored
      Given a thread-local symbol x with global-dynamic access, the generated
      code to obtain x's address is:
      
           Instruction                            Relocation            Symbol
        addis ra,r2,x@got@tlsgd@ha           R_PPC64_GOT_TLSGD16_HA       x
        addi  r3,ra,x@got@tlsgd@l            R_PPC64_GOT_TLSGD16_L        x
        bl __tls_get_addr(x@tlsgd)           R_PPC64_TLSGD                x
                                             R_PPC64_REL24           __tls_get_addr
        nop
        <use address in r3>
      
      The implementation borrows from the medium code model work for introducing
      special forms of ADDIS and ADDI into the DAG representation.  This is made
      slightly more complicated by having to introduce a call to the external
      function __tls_get_addr.  Using the full call machinery is overkill and,
      more importantly, makes it difficult to add a special relocation.  So I've
      introduced another opcode GET_TLS_ADDR to represent the function call, and
      surrounded it with register copies to set up the parameter and return value.
      
      Most of the code is pretty straightforward.  I ran into one peculiarity
      when I introduced a new PPC opcode BL8_NOP_ELF_TLSGD, which is just like
      BL8_NOP_ELF except that it takes another parameter to represent the symbol
      ("x" above) that requires a relocation on the call.  Something in the 
      TblGen machinery causes BL8_NOP_ELF and BL8_NOP_ELF_TLSGD to be treated
      identically during the emit phase, so this second operand was never
      visited to generate relocations.  This is the reason for the slightly
      messy workaround in PPCMCCodeEmitter.cpp:getDirectBrEncoding().
      
      Two new tests are included to demonstrate correct external assembly and
      correct generation of relocations using the integrated assembler.
      
      Comments welcome!
      
      Thanks,
      Bill
      
      llvm-svn: 169910
      c56f1d34
    • Eric Christopher's avatar
      Update some comments. · d692c1db
      Eric Christopher authored
      llvm-svn: 169907
      d692c1db
    • Nadav Rotem's avatar
      Loop Vectorize: optimize the vectorization of trunc(induction_var). The... · e266efb7
      Nadav Rotem authored
      Loop Vectorize: optimize the vectorization of trunc(induction_var). The truncation is now done on scalars.
      
      llvm-svn: 169904
      e266efb7
    • Eli Bendersky's avatar
      Remove the RelaxAll overrule in MCAssembler::fixupNeedsRelaxation, · 0f74f173
      Eli Bendersky authored
      because that method is only getting called for MCInstFragment. These
      fragments aren't even generated when RelaxAll is set, which is why the
      flag reference here is superfluous. Removing it simplifies the code
      with no harmful effects.
      
      An assertion is added higher up to make sure this path is never
      reached.
      
      llvm-svn: 169886
      0f74f173
    • Rafael Espindola's avatar
      Use an ArrayRef instead of a std::vector&. · a92da5b3
      Rafael Espindola authored
      llvm-svn: 169881
      a92da5b3
    • Joel Jones's avatar
      Add comment for load folding · 24e440d0
      Joel Jones authored
      llvm-svn: 169880
      24e440d0
    • Evgeniy Stepanov's avatar
      [msan] Use explicitely aligned stores and loads with function argument shadow. · d2bd319a
      Evgeniy Stepanov authored
      Use explicitely aligned store and load instructions to deal with argument and
      retval shadow. This matters when an argument's alignment is higher than
      __msan_param_tls alignment (which is the case with __m128i).
      
      llvm-svn: 169859
      d2bd319a
    • Patrik Hagglund's avatar
      Revert EVT->MVT changes, r169836-169851, due to buildbot failures. · e98b7a03
      Patrik Hagglund authored
      llvm-svn: 169854
      e98b7a03
    • Chandler Carruth's avatar
      Holding my nose and moving the accumulation routine to GEPOperator · 7ec41c78
      Chandler Carruth authored
      instead of the instruction. I've left a forwarding wrapper for the
      instruction so users with the instruction don't need to create
      a GEPOperator themselves.
      
      This lets us remove the copy of this code in instsimplify.
      
      I've looked at most of the other copies of similar code, and this is the
      only one I've found that is actually exactly the same. The one in
      InlineCost is very close, but it requires re-mapping non-constant
      indices through the cost analysis value simplification map. I could add
      direct support for this to the generic routine, but it seems overly
      specific.
      
      llvm-svn: 169853
      7ec41c78
    • Chandler Carruth's avatar
      Hoist the GEP constant address offset computation to a common home on · 1e14053d
      Chandler Carruth authored
      the GEP instruction class.
      
      This is part of the continued refactoring and cleaning of the
      infrastructure used by SROA. This particular operation is also done in
      a few other places which I'll try to refactor to share this
      implementation.
      
      llvm-svn: 169852
      1e14053d
Loading