[all-commits] [llvm/llvm-project] 7b6e0d: [Matrix] Use DenseMap for ShapeMap instead of Valu...

Florian Hahn via All-commits all-commits at lists.llvm.org
Wed Dec 4 06:51:53 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7b6e0d9fc3993f3e3df596fd16d97e2ed2e1d0aa
      https://github.com/llvm/llvm-project/commit/7b6e0d9fc3993f3e3df596fd16d97e2ed2e1d0aa
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2024-12-04 (Wed, 04 Dec 2024)

  Changed paths:
    M llvm/lib/Transforms/Scalar/LowerMatrixIntrinsics.cpp
    M llvm/test/Transforms/LowerMatrixIntrinsics/dot-product-transpose-int.ll
    M llvm/test/Transforms/LowerMatrixIntrinsics/transpose-opts-lifting.ll

  Log Message:
  -----------
  [Matrix] Use DenseMap for ShapeMap instead of ValueMap. (#118282)

ValueMap automatically updates entries with the new value if they have
been RAUW. This can lead to instructions that are expected to not have
shape info to be added to the map (e.g. shufflevector as in the added
test case).

This leads to incorrect results. Originally it was used for transpose
optimizations, but they now all use updateShapeAndReplaceAllUsesWith,
which takes care of updating the shape info as needed.

This fixes a crash in the newly added test cases.

PR: https://github.com/llvm/llvm-project/pull/118282



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