; LLVM IR from ox-vgg/vise :: src/search_engine/relja_retrival/external/KMCode_relja/matrix (inverse)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%class.Matrix = type { ptr, ptr, i32, i32 }
%class.Vector = type { %class.Matrix, ptr }

@.str = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK6Matrix7inverseEv(ptr dead_on_unwind noalias writable sret(%class.Matrix) align 8 %0, ptr noundef nonnull align 8 dereferenceable(24) %1) #0 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca double, align 8
  %6 = alloca %class.Matrix, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i1, align 1
  %11 = alloca %class.Vector, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  %15 = load ptr, ptr %4, align 8
  %16 = call noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24) %15)
  %17 = call noundef i32 @_ZNK6Matrix6nbColsEv(ptr noundef nonnull align 8 dereferenceable(24) %15)
  %18 = icmp ne i32 %16, %17
  br i1 %18, label %19, label %20

19:                                               ; preds = %2
  call void @_ZNK6Matrix5errorEPc(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef @.str)
  br label %20

20:                                               ; preds = %19, %2
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %6) #8
  call void @_ZN6MatrixC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %15)
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  %21 = invoke noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24) %6)
          to label %22 unwind label %44

22:                                               ; preds = %20
  store i32 %21, ptr %7, align 4, !tbaa !9
  store i1 false, ptr %10, align 1
  %23 = load i32, ptr %7, align 4, !tbaa !9
  %24 = load i32, ptr %7, align 4, !tbaa !9
  invoke void @_ZN6MatrixC1Eii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %23, i32 noundef %24)
          to label %25 unwind label %44

25:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 32, ptr %11) #8
  %26 = load i32, ptr %7, align 4, !tbaa !9
  invoke void @_ZN6VectorC1Ei(ptr noundef nonnull align 8 dereferenceable(32) %11, i32 noundef %26)
          to label %27 unwind label %48

27:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %28 = load i32, ptr %7, align 4, !tbaa !9
  %29 = sext i32 %28 to i64
  %30 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %29, i64 4)
  %31 = extractvalue { i64, i1 } %30, 1
  %32 = extractvalue { i64, i1 } %30, 0
  %33 = select i1 %31, i64 -1, i64 %32
  %34 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %33) #9
          to label %35 unwind label %52

35:                                               ; preds = %27
  %36 = getelementptr inbounds i32, ptr %34, i64 -1
  store ptr %36, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #8
  %37 = load ptr, ptr %12, align 8, !tbaa !5
  invoke void @_ZL6ludcmpR6MatrixPiRd(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef %37, ptr noundef nonnull align 8 dereferenceable(8) %5)
          to label %38 unwind label %56

38:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #8
  store i32 1, ptr %14, align 4, !tbaa !9
  br label %39

39:                                               ; preds = %99, %38
  %40 = load i32, ptr %14, align 4, !tbaa !9
  %41 = load i32, ptr %7, align 4, !tbaa !9
  %42 = icmp sle i32 %40, %41
  br i1 %42, label %60, label %43

43:                                               ; preds = %39
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #8
  br label %102

44:                                               ; preds = %22, %20
  %45 = landingpad { ptr, i32 }
          cleanup
  %46 = extractvalue { ptr, i32 } %45, 0
  store ptr %46, ptr %8, align 8
  %47 = extractvalue { ptr, i32 } %45, 1
  store i32 %47, ptr %9, align 4
  br label %114

48:                                               ; preds = %25
  %49 = landingpad { ptr, i32 }
          cleanup
  %50 = extractvalue { ptr, i32 } %49, 0
  store ptr %50, ptr %8, align 8
  %51 = extractvalue { ptr, i32 } %49, 1
  store i32 %51, ptr %9, align 4
  br label %111

52:                                               ; preds = %27
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %8, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %9, align 4
  br label %110

56:                                               ; preds = %35
  %57 = landingpad { ptr, i32 }
          cleanup
  %58 = extractvalue { ptr, i32 } %57, 0
  store ptr %58, ptr %8, align 8
  %59 = extractvalue { ptr, i32 } %57, 1
  store i32 %59, ptr %9, align 4
  br label %109

60:                                               ; preds = %39
  store i32 1, ptr %13, align 4, !tbaa !9
  br label %61

61:                                               ; preds = %69, %60
  %62 = load i32, ptr %13, align 4, !tbaa !9
  %63 = load i32, ptr %7, align 4, !tbaa !9
  %64 = icmp sle i32 %62, %63
  br i1 %64, label %65, label %76

65:                                               ; preds = %61
  %66 = load i32, ptr %13, align 4, !tbaa !9
  %67 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %11, i32 noundef %66)
          to label %68 unwind label %72

68:                                               ; preds = %65
  store double 0.000000e+00, ptr %67, align 8, !tbaa !11
  br label %69

69:                                               ; preds = %68
  %70 = load i32, ptr %13, align 4, !tbaa !9
  %71 = add nsw i32 %70, 1
  store i32 %71, ptr %13, align 4, !tbaa !9
  br label %61, !llvm.loop !13

72:                                               ; preds = %89, %86, %79, %76, %65
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %8, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #8
  br label %109

76:                                               ; preds = %61
  %77 = load i32, ptr %14, align 4, !tbaa !9
  %78 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %11, i32 noundef %77)
          to label %79 unwind label %72

79:                                               ; preds = %76
  store double 1.000000e+00, ptr %78, align 8, !tbaa !11
  %80 = load ptr, ptr %12, align 8, !tbaa !5
  invoke void @_ZL6lubksbRK6MatrixPiR6Vector(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef %80, ptr noundef nonnull align 8 dereferenceable(32) %11)
          to label %81 unwind label %72

81:                                               ; preds = %79
  store i32 1, ptr %13, align 4, !tbaa !9
  br label %82

82:                                               ; preds = %95, %81
  %83 = load i32, ptr %13, align 4, !tbaa !9
  %84 = load i32, ptr %7, align 4, !tbaa !9
  %85 = icmp sle i32 %83, %84
  br i1 %85, label %86, label %98

86:                                               ; preds = %82
  %87 = load i32, ptr %13, align 4, !tbaa !9
  %88 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %11, i32 noundef %87)
          to label %89 unwind label %72

89:                                               ; preds = %86
  %90 = load double, ptr %88, align 8, !tbaa !11
  %91 = load i32, ptr %13, align 4, !tbaa !9
  %92 = load i32, ptr %14, align 4, !tbaa !9
  %93 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %91, i32 noundef %92)
          to label %94 unwind label %72

94:                                               ; preds = %89
  store double %90, ptr %93, align 8, !tbaa !11
  br label %95

95:                                               ; preds = %94
  %96 = load i32, ptr %13, align 4, !tbaa !9
  %97 = add nsw i32 %96, 1
  store i32 %97, ptr %13, align 4, !tbaa !9
  br label %82, !llvm.loop !15

98:                                               ; preds = %82
  br label %99

99:                                               ; preds = %98
  %100 = load i32, ptr %14, align 4, !tbaa !9
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %14, align 4, !tbaa !9
  br label %39, !llvm.loop !16

102:                                              ; preds = %43
  %103 = load ptr, ptr %12, align 8, !tbaa !5
  %104 = getelementptr inbounds i32, ptr %103, i64 1
  %105 = icmp eq ptr %104, null
  br i1 %105, label %107, label %106

106:                                              ; preds = %102
  call void @_ZdaPv(ptr noundef %104) #10
  br label %107

107:                                              ; preds = %106, %102
  store i1 true, ptr %10, align 1
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #8
  %108 = load i1, ptr %10, align 1
  br i1 %108, label %113, label %112

109:                                              ; preds = %72, %56
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  br label %110

110:                                              ; preds = %109, %52
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #8
  br label %111

111:                                              ; preds = %110, %48
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #8
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #8
  br label %114

112:                                              ; preds = %107
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #8
  br label %113

113:                                              ; preds = %112, %107
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  ret void

114:                                              ; preds = %111, %44
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  br label %115

115:                                              ; preds = %114
  %116 = load ptr, ptr %8, align 8
  %117 = load i32, ptr %9, align 4
  %118 = insertvalue { ptr, i32 } poison, ptr %116, 0
  %119 = insertvalue { ptr, i32 } %118, i32 %117, 1
  resume { ptr, i32 } %119
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Matrix6nbColsEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

declare void @_ZNK6Matrix5errorEPc(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) #2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #3

declare void @_ZN6MatrixC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare i32 @__gxx_personality_v0(...)

declare void @_ZN6MatrixC1Eii(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef) unnamed_addr #2

declare void @_ZN6VectorC1Ei(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #4

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #5

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL6ludcmpR6MatrixPiRd(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef, ptr noundef nonnull align 8 dereferenceable(8)) #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL6lubksbRK6MatrixPiR6Vector(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef, ptr noundef nonnull align 8 dereferenceable(32)) #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEii(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef) unnamed_addr #1 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #3

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) #6

; Function Attrs: nounwind
declare void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #7

; Function Attrs: nounwind
declare void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #7

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { nounwind }
attributes #9 = { builtin allocsize(0) }
attributes #10 = { builtin nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%class.Matrix = type { ptr, ptr, i32, i32 }
%class.Vector = type { %class.Matrix, ptr }

@.str = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK6Matrix7inverseEv(ptr dead_on_unwind noalias writable sret(%class.Matrix) align 8 %0, ptr noundef nonnull align 8 dereferenceable(24) %1) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca double, align 8
  %4 = alloca %class.Matrix, align 8
  %5 = alloca %class.Vector, align 8
  %6 = tail call noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %7 = tail call noundef i32 @_ZNK6Matrix6nbColsEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %.not = icmp eq i32 %6, %7
  br i1 %.not, label %9, label %8

8:                                                ; preds = %2
  tail call void @_ZNK6Matrix5errorEPc(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull @.str)
  br label %9

9:                                                ; preds = %8, %2
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #7
  call void @_ZN6MatrixC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24) %4, ptr noundef nonnull align 8 dereferenceable(24) %1)
  %10 = call noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24) %4)
  invoke void @_ZN6MatrixC1Eii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %10, i32 noundef %10)
          to label %11 unwind label %20

11:                                               ; preds = %9
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  invoke void @_ZN6VectorC1Ei(ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef %10)
          to label %12 unwind label %22

12:                                               ; preds = %11
  %13 = zext nneg i32 %10 to i64
  %14 = icmp slt i32 %10, 0
  %15 = shl nuw nsw i64 %13, 2
  %16 = select i1 %14, i64 -1, i64 %15
  %17 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %16) #8
          to label %18 unwind label %24

18:                                               ; preds = %12
  %19 = getelementptr inbounds i8, ptr %17, i64 -4
  invoke void @_ZL6ludcmpR6MatrixPiRd(ptr noundef nonnull align 8 dereferenceable(24) %4, ptr noundef nonnull %19, ptr noundef nonnull align 8 dereferenceable(8) %3)
          to label %.preheader40 unwind label %26

.preheader40:                                     ; preds = %18
  %.not3247 = icmp slt i32 %10, 1
  br i1 %.not3247, label %._crit_edge49, label %.preheader39

.preheader39:                                     ; preds = %.preheader40, %._crit_edge46
  %.048 = phi i32 [ %37, %._crit_edge46 ], [ 1, %.preheader40 ]
  br label %28

20:                                               ; preds = %9
  %21 = landingpad { ptr, i32 }
          cleanup
  br label %39

22:                                               ; preds = %11
  %23 = landingpad { ptr, i32 }
          cleanup
  br label %38

24:                                               ; preds = %12
  %25 = landingpad { ptr, i32 }
          cleanup
  br label %.split.us

26:                                               ; preds = %18
  %27 = landingpad { ptr, i32 }
          cleanup
  br label %.split.us

28:                                               ; preds = %.preheader39, %28
  %.02442 = phi i32 [ 1, %.preheader39 ], [ %30, %28 ]
  %29 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef %.02442)
  store double 0.000000e+00, ptr %29, align 8, !tbaa !5
  %30 = add nuw i32 %.02442, 1
  %exitcond.not = icmp eq i32 %.02442, %10
  br i1 %exitcond.not, label %._crit_edge, label %28, !llvm.loop !9

.split.split:                                     ; preds = %._crit_edge
  %31 = landingpad { ptr, i32 }
          cleanup
  br label %.split.us

._crit_edge:                                      ; preds = %28
  %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef %.048)
  store double 1.000000e+00, ptr %32, align 8, !tbaa !5
  invoke void @_ZL6lubksbRK6MatrixPiR6Vector(ptr noundef nonnull align 8 dereferenceable(24) %4, ptr noundef nonnull %19, ptr noundef nonnull align 8 dereferenceable(32) %5)
          to label %.preheader unwind label %.split.split

.preheader:                                       ; preds = %._crit_edge, %.preheader
  %.144 = phi i32 [ %36, %.preheader ], [ 1, %._crit_edge ]
  %33 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32) %5, i32 noundef %.144)
  %34 = load double, ptr %33, align 8, !tbaa !5
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEii(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef %.144, i32 noundef %.048)
  store double %34, ptr %35, align 8, !tbaa !5
  %36 = add nuw i32 %.144, 1
  %exitcond56.not = icmp eq i32 %.144, %10
  br i1 %exitcond56.not, label %._crit_edge46, label %.preheader, !llvm.loop !11

._crit_edge46:                                    ; preds = %.preheader
  %37 = add nuw i32 %.048, 1
  %exitcond57.not = icmp eq i32 %.048, %10
  br i1 %exitcond57.not, label %._crit_edge49, label %.preheader39, !llvm.loop !12

._crit_edge49:                                    ; preds = %._crit_edge46, %.preheader40
  call void @_ZdaPv(ptr noundef nonnull %17) #9
  call void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  ret void

.split.us:                                        ; preds = %.split.split, %26, %24
  %.pn.pn = phi { ptr, i32 } [ %25, %24 ], [ %27, %26 ], [ %31, %.split.split ]
  call void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  br label %38

38:                                               ; preds = %.split.us, %22
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %.split.us ], [ %23, %22 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #7
  br label %39

39:                                               ; preds = %38, %20
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %38 ], [ %21, %20 ]
  call void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  resume { ptr, i32 } %.pn.pn.pn.pn
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Matrix6nbRowsEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK6Matrix6nbColsEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

declare void @_ZNK6Matrix5errorEPc(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #3

declare void @_ZN6MatrixC1ERKS_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #2

declare i32 @__gxx_personality_v0(...)

declare void @_ZN6MatrixC1Eii(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef) unnamed_addr #2

declare void @_ZN6VectorC1Ei(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #2

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL6ludcmpR6MatrixPiRd(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZN6VectorclEi(ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL6lubksbRK6MatrixPiR6Vector(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef, ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEii(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef) unnamed_addr #1 align 2

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #3

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) local_unnamed_addr #5

; Function Attrs: nounwind
declare void @_ZN6VectorD1Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #6

; Function Attrs: nounwind
declare void @_ZN6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #6

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }
attributes #9 = { builtin nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}
!12 = distinct !{!12, !10}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass