; LLVM IR from moarseniy/CudaFEMproject :: FEMproject/fem_utils/src/cpu_fem_utils.ll (ZN16CPU_ElementsData13calculateAreaEv)

; 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.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.7" }
%"struct.std::_Head_base.7" = type { ptr }
%class.ElementsData = type { ptr, i64, i64, i64, i64, i64, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, %struct.CGMData, ptr, ptr, ptr }
%struct.CGMData = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

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

declare noundef ptr @_ZNK6Matrix8get_dataEv(ptr noundef nonnull align 8 dereferenceable(49)) #1

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

declare void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8, ptr noundef nonnull align 8 dereferenceable(49), i64 noundef) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

declare noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(49), i64 noundef, i64 noundef) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(49) ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2 align 2

declare noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixixEm(ptr noundef nonnull align 8 dereferenceable(49), i64 noundef) #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16CPU_ElementsData13calculateAreaEv(ptr noundef nonnull align 8 dereferenceable(336) %0) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca i64, align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.std::unique_ptr", align 8
  %6 = alloca %"class.std::unique_ptr", align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %11 = load ptr, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #5
  store i64 0, ptr %3, align 8, !tbaa !9
  br label %12

12:                                               ; preds = %120, %1
  %13 = load i64, ptr %3, align 8, !tbaa !9
  %14 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 2
  %15 = load i64, ptr %14, align 8, !tbaa !11
  %16 = icmp ult i64 %13, %15
  br i1 %16, label %18, label %17

17:                                               ; preds = %12
  store i32 2, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  br label %125

18:                                               ; preds = %12
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  %19 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 24
  %20 = load ptr, ptr %19, align 8, !tbaa !15
  %21 = load i64, ptr %3, align 8, !tbaa !9
  call void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8 %5, ptr noundef nonnull align 8 dereferenceable(49) %20, i64 noundef %21)
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %22 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 30
  %23 = load ptr, ptr %22, align 8, !tbaa !16
  %24 = load i64, ptr %3, align 8, !tbaa !9
  invoke void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8 %6, ptr noundef nonnull align 8 dereferenceable(49) %23, i64 noundef %24)
          to label %25 unwind label %54

25:                                               ; preds = %18
  %26 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  %27 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %28 = load i64, ptr %27, align 8, !tbaa !17
  %29 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %30 = load i64, ptr %29, align 8, !tbaa !17
  %31 = add i64 %30, 1
  %32 = load ptr, ptr %26, align 8, !tbaa !18
  %33 = getelementptr inbounds ptr, ptr %32, i64 26
  %34 = load ptr, ptr %33, align 8
  invoke void %34(ptr noundef nonnull align 8 dereferenceable(49) %26, i64 noundef %28, i64 noundef %31)
          to label %35 unwind label %58

35:                                               ; preds = %25
  %36 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  %37 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %38 = load i64, ptr %37, align 8, !tbaa !17
  %39 = add i64 %38, 1
  %40 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %41 = load i64, ptr %40, align 8, !tbaa !17
  %42 = add i64 %41, 1
  %43 = load ptr, ptr %36, align 8, !tbaa !18
  %44 = getelementptr inbounds ptr, ptr %43, i64 26
  %45 = load ptr, ptr %44, align 8
  invoke void %45(ptr noundef nonnull align 8 dereferenceable(49) %36, i64 noundef %39, i64 noundef %42)
          to label %46 unwind label %58

46:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  store i64 0, ptr %9, align 8, !tbaa !9
  br label %47

47:                                               ; preds = %103, %46
  %48 = load i64, ptr %9, align 8, !tbaa !9
  %49 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %50 = load i64, ptr %49, align 8, !tbaa !17
  %51 = add i64 %50, 1
  %52 = icmp ult i64 %48, %51
  br i1 %52, label %62, label %53

53:                                               ; preds = %47
  store i32 5, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %106

54:                                               ; preds = %18
  %55 = landingpad { ptr, i32 }
          cleanup
  %56 = extractvalue { ptr, i32 } %55, 0
  store ptr %56, ptr %7, align 8
  %57 = extractvalue { ptr, i32 } %55, 1
  store i32 %57, ptr %8, align 4
  br label %124

58:                                               ; preds = %114, %112, %106, %35, %25
  %59 = landingpad { ptr, i32 }
          cleanup
  %60 = extractvalue { ptr, i32 } %59, 0
  store ptr %60, ptr %7, align 8
  %61 = extractvalue { ptr, i32 } %59, 1
  store i32 %61, ptr %8, align 4
  br label %123

62:                                               ; preds = %47
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  store i64 0, ptr %10, align 8, !tbaa !9
  br label %63

63:                                               ; preds = %95, %62
  %64 = load i64, ptr %10, align 8, !tbaa !9
  %65 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %66 = load i64, ptr %65, align 8, !tbaa !17
  %67 = add i64 %66, 1
  %68 = icmp ult i64 %64, %67
  br i1 %68, label %70, label %69

69:                                               ; preds = %63
  store i32 8, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  br label %102

70:                                               ; preds = %63
  %71 = load i64, ptr %10, align 8, !tbaa !9
  %72 = icmp eq i64 %71, 0
  br i1 %72, label %73, label %74

73:                                               ; preds = %70
  br label %82

74:                                               ; preds = %70
  %75 = call noundef nonnull align 8 dereferenceable(49) ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  %76 = load i64, ptr %10, align 8, !tbaa !9
  %77 = sub i64 %76, 1
  %78 = load i64, ptr %9, align 8, !tbaa !9
  %79 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(49) %75, i64 noundef %77, i64 noundef %78)
          to label %80 unwind label %98

80:                                               ; preds = %74
  %81 = load float, ptr %79, align 4, !tbaa !20
  br label %82

82:                                               ; preds = %80, %73
  %83 = phi float [ 1.000000e+00, %73 ], [ %81, %80 ]
  %84 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  %85 = invoke noundef ptr @_ZNK6Matrix8get_dataEv(ptr noundef nonnull align 8 dereferenceable(49) %84)
          to label %86 unwind label %98

86:                                               ; preds = %82
  %87 = load i64, ptr %10, align 8, !tbaa !9
  %88 = load i64, ptr %9, align 8, !tbaa !9
  %89 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 1
  %90 = load i64, ptr %89, align 8, !tbaa !17
  %91 = add i64 %90, 1
  %92 = mul i64 %88, %91
  %93 = add i64 %87, %92
  %94 = getelementptr inbounds float, ptr %85, i64 %93
  store float %83, ptr %94, align 4, !tbaa !20
  br label %95

95:                                               ; preds = %86
  %96 = load i64, ptr %10, align 8, !tbaa !9
  %97 = add i64 %96, 1
  store i64 %97, ptr %10, align 8, !tbaa !9
  br label %63, !llvm.loop !22

98:                                               ; preds = %82, %74
  %99 = landingpad { ptr, i32 }
          cleanup
  %100 = extractvalue { ptr, i32 } %99, 0
  store ptr %100, ptr %7, align 8
  %101 = extractvalue { ptr, i32 } %99, 1
  store i32 %101, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %123

102:                                              ; preds = %69
  br label %103

103:                                              ; preds = %102
  %104 = load i64, ptr %9, align 8, !tbaa !9
  %105 = add i64 %104, 1
  store i64 %105, ptr %9, align 8, !tbaa !9
  br label %47, !llvm.loop !24

106:                                              ; preds = %53
  %107 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  %108 = load ptr, ptr %107, align 8, !tbaa !18
  %109 = getelementptr inbounds ptr, ptr %108, i64 15
  %110 = load ptr, ptr %109, align 8
  %111 = invoke noundef float %110(ptr noundef nonnull align 8 dereferenceable(49) %107)
          to label %112 unwind label %58

112:                                              ; preds = %106
  %113 = invoke noundef float @_ZSt3absf(float noundef %111)
          to label %114 unwind label %58

114:                                              ; preds = %112
  %115 = getelementptr inbounds %class.ElementsData, ptr %11, i32 0, i32 28
  %116 = load ptr, ptr %115, align 8, !tbaa !25
  %117 = load i64, ptr %3, align 8, !tbaa !9
  %118 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixixEm(ptr noundef nonnull align 8 dereferenceable(49) %116, i64 noundef %117)
          to label %119 unwind label %58

119:                                              ; preds = %114
  store float %113, ptr %118, align 4, !tbaa !20
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  br label %120

120:                                              ; preds = %119
  %121 = load i64, ptr %3, align 8, !tbaa !9
  %122 = add i64 %121, 1
  store i64 %122, ptr %3, align 8, !tbaa !9
  br label %12, !llvm.loop !26

123:                                              ; preds = %98, %58
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  br label %124

124:                                              ; preds = %123, %54
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  br label %126

125:                                              ; preds = %17
  ret void

126:                                              ; preds = %124
  %127 = load ptr, ptr %7, align 8
  %128 = load i32, ptr %8, align 4
  %129 = insertvalue { ptr, i32 } poison, ptr %127, 0
  %130 = insertvalue { ptr, i32 } %129, i32 %128, 1
  resume { ptr, i32 } %130
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3absf(float noundef) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { 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 #3 = { 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 #4 = { 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 #5 = { 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 = !{!"long", !7, i64 0}
!11 = !{!12, !10, i64 16}
!12 = !{!"_ZTS12ElementsData", !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !13, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !14, i64 256, !6, i64 312, !6, i64 320, !6, i64 328}
!13 = !{!"_ZTS11DEVICE_NAME", !7, i64 0}
!14 = !{!"_ZTS7CGMData", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48}
!15 = !{!12, !6, i64 192}
!16 = !{!12, !6, i64 240}
!17 = !{!12, !10, i64 8}
!18 = !{!19, !19, i64 0}
!19 = !{!"vtable pointer", !8, i64 0}
!20 = !{!21, !21, i64 0}
!21 = !{!"float", !7, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = distinct !{!24, !23}
!25 = !{!12, !6, i64 224}
!26 = distinct !{!26, !23}


; 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.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.7" }
%"struct.std::_Head_base.7" = type { ptr }

declare i32 @__gxx_personality_v0(...)

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

declare noundef ptr @_ZNK6Matrix8get_dataEv(ptr noundef nonnull align 8 dereferenceable(49)) local_unnamed_addr #1

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

declare void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8, ptr noundef nonnull align 8 dereferenceable(49), i64 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

declare noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(49), i64 noundef, i64 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(49) ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2 align 2

declare noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixixEm(ptr noundef nonnull align 8 dereferenceable(49), i64 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16CPU_ElementsData13calculateAreaEv(ptr nocapture noundef nonnull readonly align 8 dereferenceable(336) %0) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.std::unique_ptr", align 8
  %3 = alloca %"class.std::unique_ptr", align 8
  %4 = getelementptr inbounds i8, ptr %0, i64 16
  %5 = load i64, ptr %4, align 8, !tbaa !5
  %.not = icmp eq i64 %5, 0
  br i1 %.not, label %._crit_edge30, label %.lr.ph29

.lr.ph29:                                         ; preds = %1
  %6 = getelementptr inbounds i8, ptr %0, i64 192
  %7 = getelementptr inbounds i8, ptr %0, i64 240
  %8 = getelementptr inbounds i8, ptr %0, i64 8
  %9 = getelementptr inbounds i8, ptr %0, i64 224
  br label %10

._crit_edge30:                                    ; preds = %68, %1
  ret void

10:                                               ; preds = %.lr.ph29, %68
  %.02027 = phi i64 [ 0, %.lr.ph29 ], [ %69, %68 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #5
  %11 = load ptr, ptr %6, align 8, !tbaa !13
  call void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind nonnull writable sret(%"class.std::unique_ptr") align 8 %2, ptr noundef nonnull align 8 dereferenceable(49) %11, i64 noundef %.02027)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %12 = load ptr, ptr %7, align 8, !tbaa !14
  invoke void @_ZNK6Matrix6getRowEm(ptr dead_on_unwind nonnull writable sret(%"class.std::unique_ptr") align 8 %3, ptr noundef nonnull align 8 dereferenceable(49) %12, i64 noundef %.02027)
          to label %13 unwind label %41

13:                                               ; preds = %10
  %14 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  %15 = load i64, ptr %8, align 8, !tbaa !15
  %16 = add i64 %15, 1
  %17 = load ptr, ptr %14, align 8, !tbaa !16
  %18 = getelementptr inbounds i8, ptr %17, i64 208
  %19 = load ptr, ptr %18, align 8
  invoke void %19(ptr noundef nonnull align 8 dereferenceable(49) %14, i64 noundef %15, i64 noundef %16)
          to label %20 unwind label %43

20:                                               ; preds = %13
  %21 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  %22 = load i64, ptr %8, align 8, !tbaa !15
  %23 = add i64 %22, 1
  %24 = load ptr, ptr %21, align 8, !tbaa !16
  %25 = getelementptr inbounds i8, ptr %24, i64 208
  %26 = load ptr, ptr %25, align 8
  invoke void %26(ptr noundef nonnull align 8 dereferenceable(49) %21, i64 noundef %23, i64 noundef %23)
          to label %.preheader23 unwind label %43

.preheader23:                                     ; preds = %20
  %27 = load i64, ptr %8, align 8, !tbaa !15
  %.not31 = icmp eq i64 %27, -1
  br i1 %.not31, label %._crit_edge26, label %.preheader.preheader

.preheader.preheader:                             ; preds = %.preheader23, %._crit_edge
  %.01625 = phi i64 [ %46, %._crit_edge ], [ 0, %.preheader23 ]
  %28 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  %29 = invoke noundef ptr @_ZNK6Matrix8get_dataEv(ptr noundef nonnull align 8 dereferenceable(49) %28)
          to label %30 unwind label %.loopexit.split-lp

30:                                               ; preds = %.preheader.preheader
  %31 = load i64, ptr %8, align 8, !tbaa !15
  %32 = add i64 %31, 1
  %33 = mul i64 %32, %.01625
  %34 = getelementptr float, ptr %29, i64 %33
  store float 1.000000e+00, ptr %34, align 4, !tbaa !18
  %35 = icmp ugt i64 %32, 1
  br i1 %35, label %.lr.ph.peel.next, label %._crit_edge

._crit_edge26:                                    ; preds = %._crit_edge, %.preheader23
  %36 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  %37 = load ptr, ptr %36, align 8, !tbaa !16
  %38 = getelementptr inbounds i8, ptr %37, i64 120
  %39 = load ptr, ptr %38, align 8
  %40 = invoke noundef float %39(ptr noundef nonnull align 8 dereferenceable(49) %36)
          to label %64 unwind label %43

41:                                               ; preds = %10
  %42 = landingpad { ptr, i32 }
          cleanup
  br label %73

43:                                               ; preds = %64, %._crit_edge26, %20, %13
  %44 = landingpad { ptr, i32 }
          cleanup
  br label %72

._crit_edge:                                      ; preds = %56, %30
  %45 = phi i64 [ %31, %30 ], [ %57, %56 ]
  %46 = add nuw i64 %.01625, 1
  %47 = add i64 %45, 1
  %48 = icmp ult i64 %46, %47
  br i1 %48, label %.preheader.preheader, label %._crit_edge26, !llvm.loop !20

.lr.ph.peel.next:                                 ; preds = %30, %56
  %.024 = phi i64 [ %62, %56 ], [ 1, %30 ]
  %49 = call noundef nonnull align 8 dereferenceable(49) ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  %50 = add i64 %.024, -1
  %51 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(49) %49, i64 noundef %50, i64 noundef %.01625)
          to label %52 unwind label %.loopexit

52:                                               ; preds = %.lr.ph.peel.next
  %53 = load float, ptr %51, align 4, !tbaa !18
  %54 = call noundef ptr @_ZNKSt10unique_ptrI6MatrixSt14default_deleteIS0_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  %55 = invoke noundef ptr @_ZNK6Matrix8get_dataEv(ptr noundef nonnull align 8 dereferenceable(49) %54)
          to label %56 unwind label %.loopexit

56:                                               ; preds = %52
  %57 = load i64, ptr %8, align 8, !tbaa !15
  %58 = add i64 %57, 1
  %59 = mul i64 %58, %.01625
  %60 = getelementptr float, ptr %55, i64 %.024
  %61 = getelementptr float, ptr %60, i64 %59
  store float %53, ptr %61, align 4, !tbaa !18
  %62 = add nuw i64 %.024, 1
  %63 = icmp ult i64 %62, %58
  br i1 %63, label %.lr.ph.peel.next, label %._crit_edge, !llvm.loop !22

.loopexit:                                        ; preds = %.lr.ph.peel.next, %52
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %72

.loopexit.split-lp:                               ; preds = %.preheader.preheader
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %72

64:                                               ; preds = %._crit_edge26
  %65 = call noundef float @_ZSt3absf(float noundef %40)
  %66 = load ptr, ptr %9, align 8, !tbaa !24
  %67 = invoke noundef nonnull align 4 dereferenceable(4) ptr @_ZN6MatrixixEm(ptr noundef nonnull align 8 dereferenceable(49) %66, i64 noundef %.02027)
          to label %68 unwind label %43

68:                                               ; preds = %64
  store float %65, ptr %67, align 4, !tbaa !18
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  %69 = add nuw i64 %.02027, 1
  %70 = load i64, ptr %4, align 8, !tbaa !5
  %71 = icmp ult i64 %69, %70
  br i1 %71, label %10, label %._crit_edge30, !llvm.loop !25

72:                                               ; preds = %.loopexit, %.loopexit.split-lp, %43
  %.pn = phi { ptr, i32 } [ %44, %43 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %3) #5
  br label %73

73:                                               ; preds = %72, %41
  %.pn.pn = phi { ptr, i32 } [ %.pn, %72 ], [ %42, %41 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  call void @_ZNSt10unique_ptrI6MatrixSt14default_deleteIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %2) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #5
  resume { ptr, i32 } %.pn.pn
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZSt3absf(float noundef) local_unnamed_addr #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { 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 #3 = { 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 #4 = { 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 #5 = { 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, !7, i64 16}
!6 = !{!"_ZTS12ElementsData", !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !10, i64 48, !11, i64 56, !11, i64 64, !11, i64 72, !11, i64 80, !11, i64 88, !11, i64 96, !11, i64 104, !11, i64 112, !11, i64 120, !11, i64 128, !11, i64 136, !11, i64 144, !11, i64 152, !11, i64 160, !11, i64 168, !11, i64 176, !11, i64 184, !11, i64 192, !11, i64 200, !11, i64 208, !11, i64 216, !11, i64 224, !11, i64 232, !11, i64 240, !11, i64 248, !12, i64 256, !11, i64 312, !11, i64 320, !11, i64 328}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTS11DEVICE_NAME", !8, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!"_ZTS7CGMData", !11, i64 0, !11, i64 8, !11, i64 16, !11, i64 24, !11, i64 32, !11, i64 40, !11, i64 48}
!13 = !{!6, !11, i64 192}
!14 = !{!6, !11, i64 240}
!15 = !{!6, !7, i64 8}
!16 = !{!17, !17, i64 0}
!17 = !{!"vtable pointer", !9, i64 0}
!18 = !{!19, !19, i64 0}
!19 = !{!"float", !8, i64 0}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = distinct !{!22, !21, !23}
!23 = !{!"llvm.loop.peeled.count", i32 1}
!24 = !{!6, !11, i64 224}
!25 = distinct !{!25, !21}


; Effective O3 passes: ADCEPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopFullUnrollPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass