llvm-project/polly/test/CodeGen/phi-defined-before-scop.ll
Aiden Grossman a22d1c2225 Revert "[Polly] Introduce PhaseManager and remove LPM support (#125442)"
This reverts commit e987ab11a6f3d3965ef26fc42c82db3e8b1d56f5.

This broke premerge:
1. https://lab.llvm.org/staging/#/builders/192/builds/9521
2. https://github.com/llvm/llvm-project/actions/runs/19054182009

Notably this did not break inside the PR. Not exactly sure why. I realize that
there is a lot of test churn here, but they're largely in polly where commit
frequency is much lower, so a reapply of the patch should be clean.
2025-11-04 01:31:18 +00:00

51 lines
1.5 KiB
LLVM

; RUN: opt %loadNPMPolly -passes=polly-codegen -S < %s | FileCheck %s
; CHECK-LABEL: polly.merge_new_and_old:
; CHECK-NEXT: %tmp7.ph.merge = phi ptr [ %tmp7.ph.final_reload, %polly.exiting ], [ %tmp7.ph, %bb6.region_exiting ]
; CHECK-LABEL: polly.stmt.bb3:
; CHECK-NEXT: store ptr %tmp2, ptr %tmp7.s2a
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
%struct.blam = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.wibble = type { i32, ptr, ptr }
@global = external global ptr, align 8
; Function Attrs: nounwind uwtable
define void @wobble() {
bb:
br label %bb1
bb1: ; preds = %bb6, %bb
%tmp2 = phi ptr [ %tmp7, %bb6 ], [ poison, %bb ]
%tmp = load ptr, ptr @global, align 8, !tbaa !1
br label %bb3
bb3: ; preds = %bb1
%tmp4 = getelementptr inbounds %struct.blam, ptr %tmp, i64 0, i32 1
br i1 false, label %bb6, label %bb5
bb5: ; preds = %bb3
br label %bb6
bb6: ; preds = %bb5, %bb3
%tmp7 = phi ptr [ %tmp2, %bb3 ], [ poison, %bb5 ]
br i1 undef, label %bb8, label %bb1
bb8: ; preds = %bb6
br label %bb9
bb9: ; preds = %bb8
unreachable
}
!llvm.ident = !{!0}
!0 = !{!"clang version 3.8.0 (trunk 250010) (llvm/trunk 250018)"}
!1 = !{!2, !2, i64 0}
!2 = !{!"any pointer", !3, i64 0}
!3 = !{!"omnipotent char", !4, i64 0}
!4 = !{!"Simple C/C++ TBAA"}