Skip to content
  1. Jun 24, 2013
  2. Jun 23, 2013
    • Andrew Trick's avatar
      Add MI-Sched support for x86 macro fusion. · 47740deb
      Andrew Trick authored
      This is an awful implementation of the target hook. But we don't have
      abstractions yet for common machine ops, and I don't see any quick way
      to make it table-driven.
      
      llvm-svn: 184664
      47740deb
  3. Jun 22, 2013
  4. Jun 21, 2013
    • Justin Holewinski's avatar
      [NVPTX] Add support for selecting CUDA vs OCL mode based on triple · b6e6cd35
      Justin Holewinski authored
      IR for CUDA should use "nvptx[64]-nvidia-cuda", and IR for NV OpenCL should use "nvptx[64]-nvidia-nvcl"
      
      llvm-svn: 184579
      b6e6cd35
    • Andrew Trick's avatar
      7201f4f7
    • Ulrich Weigand's avatar
      · 91add7df
      Ulrich Weigand authored
      [PowerPC] Support R_PPC_REL16 family of relocations
      
      The GNU assembler supports (as extension to the ABI) use of PC-relative
      relocations in half16 fields, which allows writing code like:
      
        li 1, base-.
      
      This patch adds support for those relocation types in the assembler.
      
      llvm-svn: 184552
      91add7df
    • Ulrich Weigand's avatar
      · 876a0d01
      Ulrich Weigand authored
      [PowerPC] Support various tls-related modifiers
      
      The current code base only supports the minimum set of tls-related
      relocations and @modifiers that are necessary to support compiler-
      generated code.  This patch extends this to the full set defined
      in the ABI (and supported by the GNU assembler) for the benefit
      of the assembler parser.
      
      llvm-svn: 184551
      876a0d01
    • Ulrich Weigand's avatar
      · e9126f55
      Ulrich Weigand authored
      [PowerPC] Support @higher et.al. modifiers
      
      This adds support for the @higher, @highera, @highest, and @highesta
      modifers, including some missing relocation types.
      
      llvm-svn: 184550
      e9126f55
    • Ulrich Weigand's avatar
      · 72ddbd65
      Ulrich Weigand authored
      [PowerPC] Support @toc@h modifier
      
      This adds the relocation type and other necessary infrastructure
      to use the @toc@h modifier in the assembler.
      
      llvm-svn: 184549
      72ddbd65
    • Ulrich Weigand's avatar
      · e67c565d
      Ulrich Weigand authored
      [PowerPC] Support @h modifier
      
      This adds necessary infrastructure to support the @h modifier.
      Note that all required relocation types were already present
      (and unused).
      
      This patch provides support for using @h in the assembler;
      it would also be possible to now use this feature in code
      generated by the compiler, but this is not done yet.
      
      llvm-svn: 184548
      e67c565d
    • Ulrich Weigand's avatar
      · d51c09f5
      Ulrich Weigand authored
      [PowerPC] Rename some more VK_PPC_ enums
      
      This renames more VK_PPC_ enums, to make them more closely reflect
      the @modifier string they represent.  This also prepares for adding
      a bunch of new VK_PPC_ enums in upcoming patches.
      
      For consistency, some MO_ flags related to VK_PPC_ enums are
      likewise renamed.
      
      No change in behaviour.
      
      llvm-svn: 184547
      d51c09f5
    • Quentin Colombet's avatar
      ARM: Remove a (false) dependency on the memoryoperand's value as we do not use · 663150f6
      Quentin Colombet authored
      it at the moment.
      This allows to form more paired loads even when stack coloring pass destroys the
      memoryoperand's value.
      
      <rdar://problem/13978317>
      
      llvm-svn: 184492
      663150f6
    • Ulrich Weigand's avatar
      · 68e2e1b3
      Ulrich Weigand authored
      [PowerPC] Clean up VK_PPC_TOC... names
      
      This is another minor cleanup; to bring enum names in line
      with the corresponding @modifier names, this renames:
      
        VK_PPC_TOC -> VK_PPC_TOCBASE
        VK_PPC_TOC_ENTRY -> VK_PPC_TOC16
      
      No code change intended.
      
      llvm-svn: 184491
      68e2e1b3
    • Kevin Enderby's avatar
      Update the X86 disassembler to use xacquire and xrelease when appropriate. · 35fd7923
      Kevin Enderby authored
      This is a bit tricky as the xacquire and xrelease hints use the same bytes,
      0xf2 and 0xf3, as the repne and rep prefixes.
      
      Fortunately llvm has different llvm MCInst Opcode enums for rep/xrelease
      and repne/xacquire. So to make this work a boolean was added the
      InternalInstruction struct as part of the Prefix state which is set with the
      added logic in readPrefixes() when decoding an instruction to determine
      if these prefix bytes are to be disassembled as xacquire or xrelease.  Then
      we let the matcher pick the normal prefix instructionID and we change the
      Opcode after that when it is set into the MCInst being created.
      
      rdar://11019859
      
      llvm-svn: 184490
      35fd7923
    • Ulrich Weigand's avatar
      · 9e90b3c8
      Ulrich Weigand authored
      [PowerPC] Minor cleanup in PPCELFObjectWriter::getRelocTypeInner
      
      This just re-sorts the big switch statement in
      PPCELFObjectWriter::getRelocTypeInner to follow
      the (numerical) order of the reloc types, and
      fixes a couple of whitespace issues.
      
      llvm-svn: 184485
      9e90b3c8
  5. Jun 20, 2013
    • Tom Stellard's avatar
      R600/SI: Expand sub for v2i32 and v4i32 for SI · 96d38760
      Tom Stellard authored
      
      
      Also add a v2i32 test to the existing v4i32 test.
      
      Patch by: Aaron Watry
      
      Reviewed-by: default avatarTom Stellard <thomas.stellard@amd.com>
      Signed-off-by: default avatarAaron <Watry&lt;awatry@gmail.com>
      llvm-svn: 184482
      96d38760
    • Tom Stellard's avatar
      R600/SI: Expand add for v2i32 and v4i32 · 043795e8
      Tom Stellard authored
      
      
      Also add SI tests to existing file and a v2i32 test for both
      R600 and SI.
      
      Patch by: Aaron Watry
      
      Reviewed-by: default avatarTom Stellard <thomas.stellard@amd.com>
      Signed-off-by: default avatarAaron Watry <awatry@gmail.com>
      llvm-svn: 184481
      043795e8
    • Tom Stellard's avatar
      R600: Expand v2i32 load/store instead of custom lowering · 6ec9e804
      Tom Stellard authored
      
      
      The custom lowering causes llc to crash with a segfault.
      
      Ideally, the custom lowering can be fixed, but this allows
      programs which load/store v2i32 to work without crashing.
      
      Patch by: Aaron Watry
      
      Reviewed-by: default avatarTom Stellard <thomas.stellard@amd.com>
      Signed-off-by: default avatarAaron <Watry&lt;awatry@gmail.com>
      llvm-svn: 184480
      6ec9e804
    • Joey Gouly's avatar
      This reverts r155000. · f81d036e
      Joey Gouly authored
      The cdp2 instruction should have the same restrictions as cdp on the
      co-processor registers.
      
      VFP instructions on v8/AArch32 share the same encoding space as cdp2.
      
      llvm-svn: 184445
      f81d036e
    • Ulrich Weigand's avatar
      · 4727888f
      Ulrich Weigand authored
      [PowerPC] Remove unused parameter
      
      The isDarwin parameter to the llvm::LowerPPCMachineInstrToMCInst
      routine is now no longer needed; remove it.
      
      llvm-svn: 184441
      4727888f
    • Ulrich Weigand's avatar
      · 22dff957
      Ulrich Weigand authored
      [PowerPC] Add missing build dependency
      
      This (hopefully) fixes build failures resulting from r184436;
      the PowerPC asm parser now depends on PowerPC target expresssions.
      
      llvm-svn: 184439
      22dff957
    • Ulrich Weigand's avatar
      · 96e65783
      Ulrich Weigand authored
      [PowerPC] Optimize @ha/@l constructs
      
      This patch adds support for having the assembler optimize fixups
      to constructs like "symbol@ha" or "symbol@l" if "symbol" can be
      resolved at assembler time.
      
      This optimization is already present in the PPCMCExpr.cpp code
      for handling PPC_HA16/PPC_LO16 target expressions.  However,
      those target expression were used only on Darwin targets.
      
      This patch changes target expression code so that they are
      usable also with the GNU assembler (using the @ha / @l syntax
      instead of the ha16() / lo16() syntax), and changes the
      MCInst lowering code to generate those target expressions
      where appropriate.
      
      It also changes the asm parser to generate HA16/LO16 target
      expressions when parsing assembler source that uses the
      @ha / @l modifiers.  The effect is that now the above-
      mentioned optimization automatically becomes available
      for those situations too.
       
      
      llvm-svn: 184436
      96e65783
    • Ulrich Weigand's avatar
      · 865a1efc
      Ulrich Weigand authored
      [PowerPC] Support compare mnemonics with implied CR0
      
      Just like for branch mnemonics (where support was recently added), the
      assembler is supposed to support extended mnemonics for the compare
      instructions where no condition register is specified explicitly
      (and CR0 is assumed implicitly).
      
      This patch adds support for those extended compare mnemonics.
      
      
      Index: llvm-head/test/MC/PowerPC/ppc64-encoding-ext.s
      ===================================================================
      --- llvm-head.orig/test/MC/PowerPC/ppc64-encoding-ext.s
      +++ llvm-head/test/MC/PowerPC/ppc64-encoding-ext.s
      @@ -449,21 +449,37 @@
       
       # CHECK: cmpdi 2, 3, 128                 # encoding: [0x2d,0x23,0x00,0x80]
                cmpdi 2, 3, 128
      +# CHECK: cmpdi 0, 3, 128                 # encoding: [0x2c,0x23,0x00,0x80]
      +         cmpdi 3, 128
       # CHECK: cmpd 2, 3, 4                    # encoding: [0x7d,0x23,0x20,0x00]
                cmpd 2, 3, 4
      +# CHECK: cmpd 0, 3, 4                    # encoding: [0x7c,0x23,0x20,0x00]
      +         cmpd 3, 4
       # CHECK: cmpldi 2, 3, 128                # encoding: [0x29,0x23,0x00,0x80]
                cmpldi 2, 3, 128
      +# CHECK: cmpldi 0, 3, 128                # encoding: [0x28,0x23,0x00,0x80]
      +         cmpldi 3, 128
       # CHECK: cmpld 2, 3, 4                   # encoding: [0x7d,0x23,0x20,0x40]
                cmpld 2, 3, 4
      +# CHECK: cmpld 0, 3, 4                   # encoding: [0x7c,0x23,0x20,0x40]
      +         cmpld 3, 4
       
       # CHECK: cmpwi 2, 3, 128                 # encoding: [0x2d,0x03,0x00,0x80]
                cmpwi 2, 3, 128
      +# CHECK: cmpwi 0, 3, 128                 # encoding: [0x2c,0x03,0x00,0x80]
      +         cmpwi 3, 128
       # CHECK: cmpw 2, 3, 4                    # encoding: [0x7d,0x03,0x20,0x00]
                cmpw 2, 3, 4
      +# CHECK: cmpw 0, 3, 4                    # encoding: [0x7c,0x03,0x20,0x00]
      +         cmpw 3, 4
       # CHECK: cmplwi 2, 3, 128                # encoding: [0x29,0x03,0x00,0x80]
                cmplwi 2, 3, 128
      +# CHECK: cmplwi 0, 3, 128                # encoding: [0x28,0x03,0x00,0x80]
      +         cmplwi 3, 128
       # CHECK: cmplw 2, 3, 4                   # encoding: [0x7d,0x03,0x20,0x40]
                cmplw 2, 3, 4
      +# CHECK: cmplw 0, 3, 4                   # encoding: [0x7c,0x03,0x20,0x40]
      +         cmplw 3, 4
       
       # FIXME: Trap mnemonics
       
      Index: llvm-head/lib/Target/PowerPC/PPCInstrInfo.td
      ===================================================================
      --- llvm-head.orig/lib/Target/PowerPC/PPCInstrInfo.td
      +++ llvm-head/lib/Target/PowerPC/PPCInstrInfo.td
      @@ -2201,3 +2201,12 @@ defm : BranchExtendedMnemonic<"ne", 68>;
       defm : BranchExtendedMnemonic<"nu", 100>;
       defm : BranchExtendedMnemonic<"ns", 100>;
       
      +def : InstAlias<"cmpwi $rA, $imm", (CMPWI CR0, gprc:$rA, s16imm:$imm)>;
      +def : InstAlias<"cmpw $rA, $rB", (CMPW CR0, gprc:$rA, gprc:$rB)>;
      +def : InstAlias<"cmplwi $rA, $imm", (CMPLWI CR0, gprc:$rA, u16imm:$imm)>;
      +def : InstAlias<"cmplw $rA, $rB", (CMPLW CR0, gprc:$rA, gprc:$rB)>;
      +def : InstAlias<"cmpdi $rA, $imm", (CMPDI CR0, g8rc:$rA, s16imm:$imm)>;
      +def : InstAlias<"cmpd $rA, $rB", (CMPD CR0, g8rc:$rA, g8rc:$rB)>;
      +def : InstAlias<"cmpldi $rA, $imm", (CMPLDI CR0, g8rc:$rA, u16imm:$imm)>;
      +def : InstAlias<"cmpld $rA, $rB", (CMPLD CR0, g8rc:$rA, g8rc:$rB)>;
      +
      
      llvm-svn: 184435
      865a1efc
    • Vladimir Medic's avatar
  6. Jun 19, 2013
  7. Jun 18, 2013
Loading