[all-commits] [llvm/llvm-project] 486f83: [mlir][Transforms][NFC] Simplify `buildUnresolvedM...

Matthias Springer via All-commits all-commits at lists.llvm.org
Sun Jan 5 08:32:29 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 486f83faa31ae5356523da868a557619601a0e3e
      https://github.com/llvm/llvm-project/commit/486f83faa31ae5356523da868a557619601a0e3e
  Author: Matthias Springer <me at m-sp.org>
  Date:   2025-01-05 (Sun, 05 Jan 2025)

  Changed paths:
    M mlir/lib/Transforms/Utils/DialectConversion.cpp

  Log Message:
  -----------
  [mlir][Transforms][NFC] Simplify `buildUnresolvedMaterialization` implementation (#121651)

The `buildUnresolvedMaterialization` implementation used to check if a
materialization is necessary. A materialization is not necessary if the
desired types already match the input. However, this situation can never
happen: we look for mapped values with the desired type at the call
sites before requesting a new unresolved materialization.

The previous implementation seemed incorrect because
`buildUnresolvedMaterialization` created a mapping that is never rolled
back. (When in reality that code was never executed, so it is
technically not incorrect.)

Also fix a comment that in `findOrBuildReplacementValue` that was
incorrect.



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