53 lines · plain
1; RUN: opt %s -passes='loop-interchange' -pass-remarks=loop-interchange -disable-output 2>&1 | FileCheck --allow-empty %s2 3target triple = "aarch64-unknown-linux-gnu"4 5; CHECK-NOT: Computed dependence info, invoking the transform.6 7; For the below test, backedge count cannot be computed. 8; Computing backedge count requires only SCEV and should9; not require dependence info. 10;11; void bar(int m, int n) {12; for (unsigned int i = 0; i < m; ++i) {13; for (unsigned int j = 0; j < m; ++j) {14; // dummy code15; }16; }17;}18 19define void @bar(i32 %m, i32 %n)20{21entry:22 br label %outer.header23 24outer.header:25 %m_temp1 = phi i32 [%m, %entry], [%m_temp, %outer.latch]26 br label %inner.header27 28 29inner.header:30 %n_temp1 = phi i32 [%n, %outer.header], [%n_temp, %inner.latch]31 32 br label %body33 34body:35 ; dummy code36 37br label %inner.latch 38 39inner.latch:40%n_temp = add i32 %n_temp1, 141%cmp2 = icmp eq i32 %n_temp, 1 42br i1 %cmp2, label %outer.latch, label %inner.header43 44outer.latch:45%m_temp = add i32 %n, 146%cmp3 = icmp eq i32 %m_temp, 1 47br i1 %cmp3, label %exit, label %outer.header48 49exit:50ret void51}52 53