[all-commits] [llvm/llvm-project] 1ba5c5: [DAG] Improve folding (sext_in_reg (*_extend_vecto...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Thu Mar 18 08:35:31 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1ba5c550d418e12a5bdbb884d2f7d94e0efc64ee
      https://github.com/llvm/llvm-project/commit/1ba5c550d418e12a5bdbb884d2f7d94e0efc64ee
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2021-03-18 (Thu, 18 Mar 2021)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
    M llvm/test/CodeGen/X86/vec_saddo.ll
    M llvm/test/CodeGen/X86/vec_smulo.ll
    M llvm/test/CodeGen/X86/vec_ssubo.ll
    M llvm/test/CodeGen/X86/vec_uaddo.ll
    M llvm/test/CodeGen/X86/vec_umulo.ll
    M llvm/test/CodeGen/X86/vec_usubo.ll
    M llvm/test/CodeGen/X86/vsplit-and.ll

  Log Message:
  -----------
  [DAG] Improve folding (sext_in_reg (*_extend_vector_inreg x)) -> (sext_vector_inreg x)

Extend this to support ComputeNumSignBits of the (used) source vector elements so that we can handle more than just the case where we're sext_in_reg from the source element signbit.

Noticed while investigating the poor codegen in D98587.




More information about the All-commits mailing list