aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode
diff options
context:
space:
mode:
authorMatthias Springer <me@m-sp.org>2024-04-05 13:14:00 +0900
committerGitHub <noreply@github.com>2024-04-05 13:14:00 +0900
commit6b30ffef28c35c24bfd8190e06eeaa0c5cd73cbd (patch)
treea5c267162a4206772682036ba866da8fea819a68 /llvm/lib/Bitcode
parent843cc474faefad1d639f4c44c1cf3ad7dbda76c8 (diff)
downloadllvm-6b30ffef28c35c24bfd8190e06eeaa0c5cd73cbd.zip
llvm-6b30ffef28c35c24bfd8190e06eeaa0c5cd73cbd.tar.gz
llvm-6b30ffef28c35c24bfd8190e06eeaa0c5cd73cbd.tar.bz2
[mlir][SCF] `ValueBoundsConstraintSet`: Support `scf.if` (branches) (#85895)
This commit adds support for `scf.if` to `ValueBoundsConstraintSet`. Example: ``` %0 = scf.if ... -> index { scf.yield %a : index } else { scf.yield %b : index } ``` The following constraints hold for %0: * %0 >= min(%a, %b) * %0 <= max(%a, %b) Such constraints cannot be added to the constraint set; min/max is not supported by `IntegerRelation`. However, if we know which one of %a and %b is larger, we can add constraints for %0. E.g., if %a <= %b: * %0 >= %a * %0 <= %b This commit required a few minor changes to the `ValueBoundsConstraintSet` infrastructure, so that values can be compared while we are still in the process of traversing the IR/adding constraints.
Diffstat (limited to 'llvm/lib/Bitcode')
0 files changed, 0 insertions, 0 deletions