[all-commits] [llvm/llvm-project] aab1f5: [x86] use SETCC_CARRY instead of SBB node for sele...

Sanjay Patel via All-commits all-commits at lists.llvm.org
Sun Jan 9 04:00:28 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: aab1f55e33bbcfbe2266b41d0d1cfcc684addb86
      https://github.com/llvm/llvm-project/commit/aab1f55e33bbcfbe2266b41d0d1cfcc684addb86
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2022-01-09 (Sun, 09 Jan 2022)

  Changed paths:
    M llvm/lib/Target/X86/X86ISelLowering.cpp
    M llvm/test/CodeGen/X86/pr35972.ll
    M llvm/test/CodeGen/X86/sdiv_fix_sat.ll
    M llvm/test/CodeGen/X86/select.ll
    M llvm/test/CodeGen/X86/shl-crash-on-legalize.ll
    M llvm/test/CodeGen/X86/umul_fix_sat.ll

  Log Message:
  -----------
  [x86] use SETCC_CARRY instead of SBB node for select lowering

This is a suggested follow-up to D116765.
This removes a clear of the register operand, so it is better
for code size, but it does potentially create a false register
dependency on surrounding code. If that is a problem, it should
be solvable using dependency-breaking code that is used for
other instructions.

Differential Revision: https://reviews.llvm.org/D116804


  Commit: 0b13789d580ffdb9167f8cfc709f7662a08c611d
      https://github.com/llvm/llvm-project/commit/0b13789d580ffdb9167f8cfc709f7662a08c611d
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2022-01-09 (Sun, 09 Jan 2022)

  Changed paths:
    M llvm/test/Transforms/InstCombine/and-xor-or.ll

  Log Message:
  -----------
  [InstCombine] add tests for and(orn, xor); NFC


  Commit: 1d21667ce2442b171e2449235123c7ece3277084
      https://github.com/llvm/llvm-project/commit/1d21667ce2442b171e2449235123c7ece3277084
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2022-01-09 (Sun, 09 Jan 2022)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
    M llvm/test/Transforms/InstCombine/and-xor-or.ll

  Log Message:
  -----------
  [InstCombine] (~A | B) & (A ^ B) -> ~A & B

This is part of a set of 2-variable logic optimizations
suggested here:
https://lists.llvm.org/pipermail/llvm-dev/2021-December/154470.html

The 'not' op must not propagate undef elements of a vector,
so this patch creates a new 'full' not, but I am not counting
that as an extra-use restriction because it should get folded
with the existing value by CSE.

https://alive2.llvm.org/ce/z/7v65im


Compare: https://github.com/llvm/llvm-project/compare/80e2c587498a...1d21667ce244


More information about the All-commits mailing list