Skip to content
  1. Sep 01, 2012
  2. Aug 31, 2012
  3. Aug 30, 2012
    • Chad Rosier's avatar
      Whitespace. · 7578a47f
      Chad Rosier authored
      llvm-svn: 162946
      7578a47f
    • Chad Rosier's avatar
      Whitespace. · c19f8823
      Chad Rosier authored
      llvm-svn: 162945
      c19f8823
    • Chad Rosier's avatar
      Hoist a check to eliminate obvious mismatches as early as possible. Also, fix · eac13a36
      Chad Rosier authored
      an 80-column violation in the generated code.  No functional change intended.
      
      llvm-svn: 162944
      eac13a36
    • Nadav Rotem's avatar
      · ea973bda
      Nadav Rotem authored
      Currently targets that do not support selects with scalar conditions and vector operands - scalarize the code. ARM is such a target
      because it does not support CMOV of vectors. To implement this efficientlyi, we broadcast the condition bit and use a sequence of NAND-OR
      to select between the two operands. This is the same sequence we use for targets that don't have vector BLENDs (like SSE2).
      
      rdar://12201387
      
      llvm-svn: 162926
      ea973bda
    • Chad Rosier's avatar
      [ms-inline asm] Add a new function, GetMCInstOperandNum, to the · 738ea259
      Chad Rosier authored
      AsmMatcherEmitter.  This function maps inline assembly operands to MCInst
      operands.
      
      For example, '__asm mov j, eax' is represented by the follow MCInst:
      
      <MCInst 1460 <MCOperand Reg:0> <MCOperand Imm:1> <MCOperand Reg:0> 
                   <MCOperand Expr:(j)> <MCOperand Reg:0> <MCOperand Reg:43>>
      
      The first 5 MCInst operands are a result of j matching as a memory operand
      consisting of a BaseReg (Reg:0), MemScale (Imm:1), MemIndexReg(Reg:0), 
      Expr (Expr:(j), and a MemSegReg (Reg:0).  The 6th MCInst operand represents
      the eax register (Reg:43).
      
      This translation is necessary to determine the Input and Output Exprs.  If a
      single asm operand maps to multiple MCInst operands, the index of the first
      MCInst operand is returned.  Ideally, it would return the operand we really
      care out (i.e., the Expr:(j) in this case), but I haven't found an easy way
      of doing this yet.
      
      llvm-svn: 162920
      738ea259
    • Michael Liao's avatar
      Introduce 'UseSSEx' to force SSE legacy encoding · bbd10792
      Michael Liao authored
      - Add 'UseSSEx' to force SSE legacy insn not being selected when AVX is
        enabled.
      
        As the penalty of inter-mixing SSE and AVX instructions, we need
        prevent SSE legacy insn from being generated except explicitly
        specified through some intrinsics. For patterns supported by both
        SSE and AVX, so far, we force AVX insn will be tried first relying on
        AddedComplexity or position in td file. It's error-prone and
        introduces bugs accidentally.
      
        'UseSSEx' is disabled when AVX is turned on. For SSE insns inherited
        by AVX, we need this predicate to force VEX encoding or SSE legacy
        encoding only.
      
        For insns not inherited by AVX, we still use the previous predicates,
        i.e. 'HasSSEx'. So far, these insns fall into the following
        categories:
        * SSE insns with MMX operands
        * SSE insns with GPR/MEM operands only (xFENCE, PREFETCH, CLFLUSH,
          CRC, and etc.)
        * SSE4A insns.
        * MMX insns.
        * x87 insns added by SSE.
      
      2 test cases are modified:
      
       - test/CodeGen/X86/fast-isel-x86-64.ll
         AVX code generation is different from SSE one. 'vcvtsi2sdq' cannot be
         selected by fast-isel due to complicated pattern and fast-isel
         fallback to materialize it from constant pool.
      
       - test/CodeGen/X86/widen_load-1.ll
         AVX code generation is different from SSE one after fixing SSE/AVX
         inter-mixing. Exec-domain fixing prefers 'vmovapd' instead of
         'vmovaps'.
      
      llvm-svn: 162919
      bbd10792
    • NAKAMURA Takumi's avatar
Loading