[llvm] [DA] Add tests where dependencies are missed due to overflow (NFC) (PR #164246)

Michael Kruse via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 28 08:15:49 PDT 2025


================
@@ -0,0 +1,68 @@
+; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py UTC_ARGS: --version 6
+; RUN: opt < %s -disable-output "-passes=print<da>" 2>&1 \
+; RUN:     | FileCheck %s --check-prefixes=CHECK,CHECK-ALL
+; RUN: opt < %s -disable-output "-passes=print<da>" -da-enable-dependence-test=strong-siv 2>&1 \
+; RUN:     | FileCheck %s --check-prefixes=CHECK,CHECK-STRONG-SIV
+
+; offset0 = -2;
+; offset1 = -4;
+; for (i = 0; i < (1LL << 62); i++, offset0 += 2, offset1 += 2) {
+;   if (0 <= offset0)
+;     A[offset0] = 1;
+;   if (0 <= offset1)
+;     A[offset1] = 2;
+; }
+;
+; FIXME: DependenceAnalysis currently detects no dependency between the two
+; stores, but it does exist.
----------------
Meinersbur wrote:

Do you know at which values of `i`, `offset0` and `offset1`?

https://github.com/llvm/llvm-project/pull/164246


More information about the llvm-commits mailing list