[all-commits] [llvm/llvm-project] 85cc99: [SLP]Drop nsw when shl by BW-1 is converted to mul

Alexey Bataev via All-commits all-commits at lists.llvm.org
Thu Jul 16 12:39:21 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 85cc99660cf051157f0ce50e3a976312b1f829bd
      https://github.com/llvm/llvm-project/commit/85cc99660cf051157f0ce50e3a976312b1f829bd
  Author: Alexey Bataev <a.bataev at outlook.com>
  Date:   2026-07-16 (Thu, 16 Jul 2026)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
    M llvm/test/Transforms/SLPVectorizer/X86/mul-shl-nsw-intmin.ll

  Log Message:
  -----------
  [SLP]Drop nsw when shl by BW-1 is converted to mul

shl nsw X, BW-1 is valid at X = -1, but mul X, INT_MIN is not nsw-safe
there. Drop nsw on the vector mul when a shl lane with shift amount
BW-1 is unified into mul during opcode interchange.

Fixes #210093

Reviewers: 

Pull Request: https://github.com/llvm/llvm-project/pull/210152



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