[all-commits] [llvm/llvm-project] c1173e: [DAG] Use FoldConstantArithmetic for unary bitops ...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Tue Jan 9 10:55:30 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c1173e4e05375514b1416e00b092e1ea1468a46e
      https://github.com/llvm/llvm-project/commit/c1173e4e05375514b1416e00b092e1ea1468a46e
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2024-01-09 (Tue, 09 Jan 2024)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp

  Log Message:
  -----------
  [DAG] Use FoldConstantArithmetic for unary bitops constant folding.

BSWAP/BITREVERSE/CTPOP/CTLZ/CTLZ_ZERO_UNDEF/CTTZ/CTTZ_ZERO_UNDEF are all handled by FoldConstantArithmetic - so use directly instead of testing for isConstantIntBuildVectorOrConstantInt and relying on DAG.getNode() to perform the constant fold.


  Commit: 417df8ee4a149cc49b3fa7e68c64cb926fee8a6f
      https://github.com/llvm/llvm-project/commit/417df8ee4a149cc49b3fa7e68c64cb926fee8a6f
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2024-01-09 (Tue, 09 Jan 2024)

  Changed paths:
    A llvm/test/CodeGen/X86/pr77459.ll

  Log Message:
  -----------
  [X86] Add test coverage for #77459


Compare: https://github.com/llvm/llvm-project/compare/f972e4d34343...417df8ee4a14


More information about the All-commits mailing list