[all-commits] [llvm/llvm-project] c1e95b: [RISCV] Fix matching bug in VLA shuffle lowering (...

Philip Reames via All-commits all-commits at lists.llvm.org
Tue Apr 8 07:20:49 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c1e95b2e5e61616eca20f6bc1bbd71470180e349
      https://github.com/llvm/llvm-project/commit/c1e95b2e5e61616eca20f6bc1bbd71470180e349
  Author: Philip Reames <preames at rivosinc.com>
  Date:   2025-04-08 (Tue, 08 Apr 2025)

  Changed paths:
    M llvm/lib/Target/RISCV/RISCVISelLowering.cpp
    M llvm/test/CodeGen/RISCV/rvv/fixed-vectors-shuffle-int.ll

  Log Message:
  -----------
  [RISCV] Fix matching bug in VLA shuffle lowering (#134750)

Fix https://github.com/llvm/llvm-project/issues/134126.

The matching code was previous written as if we were mutating the
indices to replace undef elements with preferred values, but the actual
lowering code just took a prefix of the index vector. This resulted in
us using undef indices for lanes which should have been defined,
resulting in incorrect codegen.

Longer term, we probably should rewrite the mask, but this seemed like
an easier tactical fix.



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