[all-commits] [llvm/llvm-project] 50ba89: [VectorCombine] support mismatching extract/insert...

hanbeom via All-commits all-commits at lists.llvm.org
Fri Nov 7 10:36:02 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 50ba89a22e452b47f79112e7277f40cbdab27bdf
      https://github.com/llvm/llvm-project/commit/50ba89a22e452b47f79112e7277f40cbdab27bdf
  Author: hanbeom <kese111 at gmail.com>
  Date:   2025-11-07 (Fri, 07 Nov 2025)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/VectorCombine.cpp
    M llvm/test/Transforms/PhaseOrdering/X86/addsub-inseltpoison.ll
    M llvm/test/Transforms/PhaseOrdering/X86/addsub.ll
    M llvm/test/Transforms/VectorCombine/X86/extract-fneg-insert.ll

  Log Message:
  -----------
  [VectorCombine] support mismatching extract/insert indices for foldInsExtFNeg (#126408)

insertelt DestVec, (fneg (extractelt SrcVec, Index)), Index 
-> shuffle DestVec, (shuffle (fneg SrcVec), poison, SrcMask), Mask

In previous, the above transform was only possible if the Extract/Insert
Index was the same; this patch makes the above transform possible
even if the two indexes are different.

Proof: https://alive2.llvm.org/ce/z/aDfdyG
Fixes: https://github.com/llvm/llvm-project/issues/125675



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