[all-commits] [llvm/llvm-project] 0da9aa: [InstCombine] Extend bitmask mul combine to handle...

Jeffrey Byrnes via All-commits all-commits at lists.llvm.org
Mon Jul 7 13:51:04 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0da9aacf4898fc9debfd930ab3dfbac7084c5e2a
      https://github.com/llvm/llvm-project/commit/0da9aacf4898fc9debfd930ab3dfbac7084c5e2a
  Author: Jeffrey Byrnes <jeffrey.byrnes at amd.com>
  Date:   2025-07-07 (Mon, 07 Jul 2025)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
    M llvm/lib/Transforms/InstCombine/InstCombineInternal.h
    M llvm/test/Transforms/InstCombine/or-bitmask.ll

  Log Message:
  -----------
  [InstCombine] Extend bitmask mul combine to handle independent operands (#142503)

This extends https://github.com/llvm/llvm-project/pull/136013 to capture
cases where the combineable bitmask muls are nested under multiple
or-disjoints.

This PR is meant for commits starting at
8c403c912046505ffc10378560c2fc48f214af6a

op1 = or-disjoint mul(and (X, C1), D) , reg1
op2 = or-disjoint mul(and (X, C2), D) , reg2
out = or-disjoint op1, op2

->

temp1 = or-disjoint reg1, reg2
out = or-disjoint mul(and (X, (C1 + C2)), D), temp1


Case1: https://alive2.llvm.org/ce/z/dHApyV
Case2: https://alive2.llvm.org/ce/z/Jz-Nag
Case3: https://alive2.llvm.org/ce/z/3xBnEV



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list