[all-commits] [llvm/llvm-project] 619e4b: [MLIR][Arith] SelectOp fix invalid folding (#117555)

7FM via All-commits all-commits at lists.llvm.org
Tue Nov 26 06:11:22 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 619e4b7154606f315572ba54c0fe6c1f6c8848a0
      https://github.com/llvm/llvm-project/commit/619e4b7154606f315572ba54c0fe6c1f6c8848a0
  Author: 7FM <chill_dein_leben at gmx.de>
  Date:   2024-11-26 (Tue, 26 Nov 2024)

  Changed paths:
    M mlir/lib/Dialect/Arith/IR/ArithOps.cpp
    M mlir/test/Dialect/Arith/canonicalize.mlir

  Log Message:
  -----------
  [MLIR][Arith] SelectOp fix invalid folding (#117555)

The pattern `select %x, true, false => %x` is only valid in case that
the return type is identical to the type of `%x` (i.e., i1). Hence, the
check `isInteger(1)` was replaced with `isSignlessInteger(1)`.

Fixes: https://github.com/llvm/llvm-project/issues/117554



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