-; RUN: opt < %s -loop-accesses -analyze | FileCheck %s
+; RUN: opt < %s -loop-accesses -analyze | FileCheck -check-prefix=OLDPM %s
+; RUN: opt -passes='require<scalar-evolution>,require<aa>,loop(print-access-info)' -disable-output < %s 2>&1 | FileCheck -check-prefix=NEWPM %s
; Test to confirm LAA will find store to invariant address.
; Inner loop has a store to invariant address.
; }
; }
-; CHECK: Store to invariant address was found in loop.
-; CHECK-NOT: Store to invariant address was not found in loop.
+; The LAA with the new PM is a loop pass so we go from inner to outer loops.
+
+; OLDPM: for.cond1.preheader:
+; OLDPM: Store to invariant address was not found in loop.
+; OLDPM: for.body3:
+; OLDPM: Store to invariant address was found in loop.
+
+; NEWPM: for.body3:
+; NEWPM: Store to invariant address was found in loop.
+; NEWPM: for.cond1.preheader:
+; NEWPM: Store to invariant address was not found in loop.
define i32 @foo(i32* nocapture %var1, i32* nocapture readonly %var2, i32 %itr) #0 {
entry: