; LLVM IR from buresjan/optim_lbm :: nomad/ext/sgtelib/src/Matrix.ll (ZNK7SGTELIB6Matrix3sumEi)

; 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.SGTELIB::Matrix" = type { ptr, %"class.std::__cxx11::basic_string", i32, i32, ptr }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@.str.4 = external hidden unnamed_addr constant [85 x i8], align 1
@_ZTIN7SGTELIB9ExceptionE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.80 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [49 x i8], align 1

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

declare i32 @__gxx_personality_v0(...)

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare ptr @__cxa_allocate_exception(i64)

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7SGTELIB9ExceptionC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiS8_(ptr noundef nonnull align 8 dereferenceable(112), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 align 2

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

declare void @__cxa_throw(ptr, ptr, ptr)

declare void @__cxa_free_exception(ptr)

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7SGTELIB6Matrix3sumEi(ptr dead_on_unwind noalias writable sret(%"class.SGTELIB::Matrix") align 8 %0, ptr noundef nonnull align 8 dereferenceable(56) %1, i32 noundef %2) #2 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca double, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i1, align 1
  %11 = alloca %"class.std::__cxx11::basic_string", align 8
  %12 = alloca %"class.std::allocator", align 1
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i1, align 1
  %17 = alloca %"class.std::__cxx11::basic_string", align 8
  %18 = alloca %"class.std::allocator", align 1
  %19 = alloca %"class.std::__cxx11::basic_string", align 8
  %20 = alloca %"class.std::allocator", align 1
  %21 = alloca %"class.std::__cxx11::basic_string", align 8
  %22 = alloca %"class.std::allocator", align 1
  %23 = alloca i1, align 1
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i32 %2, ptr %6, align 4, !tbaa !9
  %24 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  %25 = load i32, ptr %6, align 4, !tbaa !9
  %26 = icmp eq i32 %25, 1
  br i1 %26, label %27, label %84

27:                                               ; preds = %3
  store i1 false, ptr %10, align 1
  call void @llvm.lifetime.start.p0(i64 32, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %12) #3
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #3
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef @.str.80, ptr noundef nonnull align 1 dereferenceable(1) %12)
          to label %28 unwind label %59

28:                                               ; preds = %27
  %29 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 3
  %30 = load i32, ptr %29, align 4, !tbaa !11
  invoke void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(32) %11, i32 noundef 1, i32 noundef %30)
          to label %31 unwind label %63

31:                                               ; preds = %28
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #3
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #3
  store i32 0, ptr %9, align 4, !tbaa !9
  br label %32

32:                                               ; preds = %77, %31
  %33 = load i32, ptr %9, align 4, !tbaa !9
  %34 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 3
  %35 = load i32, ptr %34, align 4, !tbaa !11
  %36 = icmp slt i32 %33, %35
  br i1 %36, label %37, label %80

37:                                               ; preds = %32
  store double 0.000000e+00, ptr %7, align 8, !tbaa !16
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %38

38:                                               ; preds = %56, %37
  %39 = load i32, ptr %8, align 4, !tbaa !9
  %40 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 2
  %41 = load i32, ptr %40, align 8, !tbaa !18
  %42 = icmp slt i32 %39, %41
  br i1 %42, label %43, label %68

43:                                               ; preds = %38
  %44 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 4
  %45 = load ptr, ptr %44, align 8, !tbaa !19
  %46 = load i32, ptr %8, align 4, !tbaa !9
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds ptr, ptr %45, i64 %47
  %49 = load ptr, ptr %48, align 8, !tbaa !5
  %50 = load i32, ptr %9, align 4, !tbaa !9
  %51 = sext i32 %50 to i64
  %52 = getelementptr inbounds double, ptr %49, i64 %51
  %53 = load double, ptr %52, align 8, !tbaa !16
  %54 = load double, ptr %7, align 8, !tbaa !16
  %55 = fadd double %54, %53
  store double %55, ptr %7, align 8, !tbaa !16
  br label %56

56:                                               ; preds = %43
  %57 = load i32, ptr %8, align 4, !tbaa !9
  %58 = add nsw i32 %57, 1
  store i32 %58, ptr %8, align 4, !tbaa !9
  br label %38, !llvm.loop !20

59:                                               ; preds = %27
  %60 = landingpad { ptr, i32 }
          cleanup
  %61 = extractvalue { ptr, i32 } %60, 0
  store ptr %61, ptr %13, align 8
  %62 = extractvalue { ptr, i32 } %60, 1
  store i32 %62, ptr %14, align 4
  br label %67

63:                                               ; preds = %28
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %13, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %14, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #3
  br label %67

67:                                               ; preds = %63, %59
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #3
  br label %167

68:                                               ; preds = %38
  %69 = load double, ptr %7, align 8, !tbaa !16
  %70 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %0, i32 0, i32 4
  %71 = load ptr, ptr %70, align 8, !tbaa !19
  %72 = getelementptr inbounds ptr, ptr %71, i64 0
  %73 = load ptr, ptr %72, align 8, !tbaa !5
  %74 = load i32, ptr %9, align 4, !tbaa !9
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds double, ptr %73, i64 %75
  store double %69, ptr %76, align 8, !tbaa !16
  br label %77

77:                                               ; preds = %68
  %78 = load i32, ptr %9, align 4, !tbaa !9
  %79 = add nsw i32 %78, 1
  store i32 %79, ptr %9, align 4, !tbaa !9
  br label %32, !llvm.loop !22

80:                                               ; preds = %32
  store i1 true, ptr %10, align 1
  store i32 1, ptr %15, align 4
  %81 = load i1, ptr %10, align 1
  br i1 %81, label %83, label %82

82:                                               ; preds = %80
  call void @_ZN7SGTELIB6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(56) %0) #3
  br label %83

83:                                               ; preds = %82, %80
  br label %166

84:                                               ; preds = %3
  %85 = load i32, ptr %6, align 4, !tbaa !9
  %86 = icmp eq i32 %85, 2
  br i1 %86, label %87, label %144

87:                                               ; preds = %84
  store i1 false, ptr %16, align 1
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %18) #3
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #3
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %17, ptr noundef @.str.80, ptr noundef nonnull align 1 dereferenceable(1) %18)
          to label %88 unwind label %119

88:                                               ; preds = %87
  %89 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 2
  %90 = load i32, ptr %89, align 8, !tbaa !18
  invoke void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(32) %17, i32 noundef %90, i32 noundef 1)
          to label %91 unwind label %123

91:                                               ; preds = %88
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #3
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #3
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %92

92:                                               ; preds = %137, %91
  %93 = load i32, ptr %8, align 4, !tbaa !9
  %94 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 2
  %95 = load i32, ptr %94, align 8, !tbaa !18
  %96 = icmp slt i32 %93, %95
  br i1 %96, label %97, label %140

97:                                               ; preds = %92
  store double 0.000000e+00, ptr %7, align 8, !tbaa !16
  store i32 0, ptr %9, align 4, !tbaa !9
  br label %98

98:                                               ; preds = %116, %97
  %99 = load i32, ptr %9, align 4, !tbaa !9
  %100 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 3
  %101 = load i32, ptr %100, align 4, !tbaa !11
  %102 = icmp slt i32 %99, %101
  br i1 %102, label %103, label %128

103:                                              ; preds = %98
  %104 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %24, i32 0, i32 4
  %105 = load ptr, ptr %104, align 8, !tbaa !19
  %106 = load i32, ptr %8, align 4, !tbaa !9
  %107 = sext i32 %106 to i64
  %108 = getelementptr inbounds ptr, ptr %105, i64 %107
  %109 = load ptr, ptr %108, align 8, !tbaa !5
  %110 = load i32, ptr %9, align 4, !tbaa !9
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds double, ptr %109, i64 %111
  %113 = load double, ptr %112, align 8, !tbaa !16
  %114 = load double, ptr %7, align 8, !tbaa !16
  %115 = fadd double %114, %113
  store double %115, ptr %7, align 8, !tbaa !16
  br label %116

116:                                              ; preds = %103
  %117 = load i32, ptr %9, align 4, !tbaa !9
  %118 = add nsw i32 %117, 1
  store i32 %118, ptr %9, align 4, !tbaa !9
  br label %98, !llvm.loop !23

119:                                              ; preds = %87
  %120 = landingpad { ptr, i32 }
          cleanup
  %121 = extractvalue { ptr, i32 } %120, 0
  store ptr %121, ptr %13, align 8
  %122 = extractvalue { ptr, i32 } %120, 1
  store i32 %122, ptr %14, align 4
  br label %127

123:                                              ; preds = %88
  %124 = landingpad { ptr, i32 }
          cleanup
  %125 = extractvalue { ptr, i32 } %124, 0
  store ptr %125, ptr %13, align 8
  %126 = extractvalue { ptr, i32 } %124, 1
  store i32 %126, ptr %14, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #3
  br label %127

127:                                              ; preds = %123, %119
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #3
  br label %167

128:                                              ; preds = %98
  %129 = load double, ptr %7, align 8, !tbaa !16
  %130 = getelementptr inbounds %"class.SGTELIB::Matrix", ptr %0, i32 0, i32 4
  %131 = load ptr, ptr %130, align 8, !tbaa !19
  %132 = load i32, ptr %8, align 4, !tbaa !9
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds ptr, ptr %131, i64 %133
  %135 = load ptr, ptr %134, align 8, !tbaa !5
  %136 = getelementptr inbounds double, ptr %135, i64 0
  store double %129, ptr %136, align 8, !tbaa !16
  br label %137

137:                                              ; preds = %128
  %138 = load i32, ptr %8, align 4, !tbaa !9
  %139 = add nsw i32 %138, 1
  store i32 %139, ptr %8, align 4, !tbaa !9
  br label %92, !llvm.loop !24

140:                                              ; preds = %92
  store i1 true, ptr %16, align 1
  store i32 1, ptr %15, align 4
  %141 = load i1, ptr %16, align 1
  br i1 %141, label %143, label %142

142:                                              ; preds = %140
  call void @_ZN7SGTELIB6MatrixD1Ev(ptr noundef nonnull align 8 dereferenceable(56) %0) #3
  br label %143

143:                                              ; preds = %142, %140
  br label %166

144:                                              ; preds = %84
  store i1 true, ptr %23, align 1
  %145 = call ptr @__cxa_allocate_exception(i64 112) #3
  call void @llvm.lifetime.start.p0(i64 32, ptr %19) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %20) #3
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #3
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %19, ptr noundef @.str.4, ptr noundef nonnull align 1 dereferenceable(1) %20)
          to label %146 unwind label %149

146:                                              ; preds = %144
  call void @llvm.lifetime.start.p0(i64 32, ptr %21) #3
  call void @llvm.lifetime.start.p0(i64 1, ptr %22) #3
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #3
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %21, ptr noundef @.str.81, ptr noundef nonnull align 1 dereferenceable(1) %22)
          to label %147 unwind label %153

147:                                              ; preds = %146
  invoke void @_ZN7SGTELIB9ExceptionC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiS8_(ptr noundef nonnull align 8 dereferenceable(112) %145, ptr noundef nonnull align 8 dereferenceable(32) %19, i32 noundef 1781, ptr noundef nonnull align 8 dereferenceable(32) %21)
          to label %148 unwind label %157

148:                                              ; preds = %147
  store i1 false, ptr %23, align 1
  invoke void @__cxa_throw(ptr %145, ptr @_ZTIN7SGTELIB9ExceptionE, ptr @_ZN7SGTELIB9ExceptionD2Ev) #4
          to label %173 unwind label %157

149:                                              ; preds = %144
  %150 = landingpad { ptr, i32 }
          cleanup
  %151 = extractvalue { ptr, i32 } %150, 0
  store ptr %151, ptr %13, align 8
  %152 = extractvalue { ptr, i32 } %150, 1
  store i32 %152, ptr %14, align 4
  br label %162

153:                                              ; preds = %146
  %154 = landingpad { ptr, i32 }
          cleanup
  %155 = extractvalue { ptr, i32 } %154, 0
  store ptr %155, ptr %13, align 8
  %156 = extractvalue { ptr, i32 } %154, 1
  store i32 %156, ptr %14, align 4
  br label %161

157:                                              ; preds = %148, %147
  %158 = landingpad { ptr, i32 }
          cleanup
  %159 = extractvalue { ptr, i32 } %158, 0
  store ptr %159, ptr %13, align 8
  %160 = extractvalue { ptr, i32 } %158, 1
  store i32 %160, ptr %14, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %21) #3
  br label %161

161:                                              ; preds = %157, %153
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %22) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %22) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %21) #3
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %19) #3
  br label %162

162:                                              ; preds = %161, %149
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #3
  call void @llvm.lifetime.end.p0(i64 1, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 32, ptr %19) #3
  %163 = load i1, ptr %23, align 1
  br i1 %163, label %164, label %165

164:                                              ; preds = %162
  call void @__cxa_free_exception(ptr %145) #3
  br label %165

165:                                              ; preds = %164, %162
  br label %167

166:                                              ; preds = %143, %83
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #3
  ret void

167:                                              ; preds = %165, %127, %67
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #3
  br label %168

168:                                              ; preds = %167
  %169 = load ptr, ptr %13, align 8
  %170 = load i32, ptr %14, align 4
  %171 = insertvalue { ptr, i32 } poison, ptr %169, 0
  %172 = insertvalue { ptr, i32 } %171, i32 %170, 1
  resume { ptr, i32 } %172

173:                                              ; preds = %148
  unreachable
}

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

declare void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr, ptr, i32, i32)

declare void @_ZN7SGTELIB6MatrixD1Ev(ptr)

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 = { 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 #3 = { nounwind }
attributes #4 = { noreturn }

!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, !10, i64 44}
!12 = !{!"_ZTSN7SGTELIB6MatrixE", !13, i64 8, !10, i64 40, !10, i64 44, !6, i64 48}
!13 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !14, i64 0, !15, i64 8, !7, i64 16}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!15 = !{!"long", !7, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"double", !7, i64 0}
!18 = !{!12, !10, i64 40}
!19 = !{!12, !6, i64 48}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = distinct !{!22, !21}
!23 = distinct !{!23, !21}
!24 = distinct !{!24, !21}


; 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.SGTELIB::Matrix" = type { ptr, %"class.std::__cxx11::basic_string", i32, i32, ptr }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@.str.4 = external hidden unnamed_addr constant [85 x i8], align 1
@_ZTIN7SGTELIB9ExceptionE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.80 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [49 x i8], align 1

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

declare i32 @__gxx_personality_v0(...)

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7SGTELIB9ExceptionC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiS8_(ptr noundef nonnull align 8 dereferenceable(112), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #2 align 2

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

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

declare void @__cxa_free_exception(ptr) local_unnamed_addr

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7SGTELIB6Matrix3sumEi(ptr dead_on_unwind noalias writable sret(%"class.SGTELIB::Matrix") align 8 %0, ptr nocapture noundef nonnull readonly align 8 dereferenceable(56) %1, i32 noundef %2) local_unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca %"class.std::allocator", align 1
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca %"class.std::allocator", align 1
  %10 = alloca %"class.std::__cxx11::basic_string", align 8
  %11 = alloca %"class.std::allocator", align 1
  switch i32 %2, label %128 [
    i32 1, label %12
    i32 2, label %60
  ]

12:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #4
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #4
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull @.str.80, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %13 unwind label %55

13:                                               ; preds = %12
  %14 = getelementptr inbounds i8, ptr %1, i64 44
  %15 = load i32, ptr %14, align 4, !tbaa !5
  invoke void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(32) %4, i32 noundef 1, i32 noundef %15)
          to label %16 unwind label %57

16:                                               ; preds = %13
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #4
  %17 = load i32, ptr %14, align 4, !tbaa !5
  %18 = icmp sgt i32 %17, 0
  br i1 %18, label %.preheader.lr.ph, label %.loopexit

.preheader.lr.ph:                                 ; preds = %16
  %19 = getelementptr inbounds i8, ptr %1, i64 40
  %20 = load i32, ptr %19, align 8, !tbaa !14
  %21 = icmp sgt i32 %20, 0
  %22 = getelementptr inbounds i8, ptr %1, i64 48
  %23 = load ptr, ptr %22, align 8
  %24 = getelementptr inbounds i8, ptr %0, i64 48
  %25 = load ptr, ptr %24, align 8, !tbaa !15
  %26 = load ptr, ptr %25, align 8, !tbaa !16
  %wide.trip.count86 = zext nneg i32 %17 to i64
  br i1 %21, label %.preheader.us.preheader, label %.preheader.preheader

.preheader.preheader:                             ; preds = %.preheader.lr.ph
  %27 = shl nuw nsw i64 %wide.trip.count86, 3
  call void @llvm.memset.p0.i64(ptr align 8 %26, i8 0, i64 %27, i1 false), !tbaa !17
  br label %.loopexit

.preheader.us.preheader:                          ; preds = %.preheader.lr.ph
  %wide.trip.count81 = zext nneg i32 %20 to i64
  %xtraiter104 = and i64 %wide.trip.count81, 3
  %28 = icmp ult i32 %20, 4
  %unroll_iter108 = and i64 %wide.trip.count81, 2147483644
  %lcmp.mod106.not = icmp eq i64 %xtraiter104, 0
  br label %.preheader.us

.preheader.us:                                    ; preds = %.preheader.us.preheader, %._crit_edge.us58
  %indvars.iv83 = phi i64 [ 0, %.preheader.us.preheader ], [ %indvars.iv.next84, %._crit_edge.us58 ]
  br i1 %28, label %._crit_edge.us58.unr-lcssa, label %.preheader.us.new

.preheader.us.new:                                ; preds = %.preheader.us, %.preheader.us.new
  %indvars.iv78 = phi i64 [ %indvars.iv.next79.3, %.preheader.us.new ], [ 0, %.preheader.us ]
  %.03755.us = phi double [ %48, %.preheader.us.new ], [ 0.000000e+00, %.preheader.us ]
  %niter109 = phi i64 [ %niter109.next.3, %.preheader.us.new ], [ 0, %.preheader.us ]
  %29 = getelementptr inbounds ptr, ptr %23, i64 %indvars.iv78
  %30 = load ptr, ptr %29, align 8, !tbaa !16
  %31 = getelementptr inbounds double, ptr %30, i64 %indvars.iv83
  %32 = load double, ptr %31, align 8, !tbaa !17
  %33 = fadd double %.03755.us, %32
  %indvars.iv.next79 = or disjoint i64 %indvars.iv78, 1
  %34 = getelementptr inbounds ptr, ptr %23, i64 %indvars.iv.next79
  %35 = load ptr, ptr %34, align 8, !tbaa !16
  %36 = getelementptr inbounds double, ptr %35, i64 %indvars.iv83
  %37 = load double, ptr %36, align 8, !tbaa !17
  %38 = fadd double %33, %37
  %indvars.iv.next79.1 = or disjoint i64 %indvars.iv78, 2
  %39 = getelementptr inbounds ptr, ptr %23, i64 %indvars.iv.next79.1
  %40 = load ptr, ptr %39, align 8, !tbaa !16
  %41 = getelementptr inbounds double, ptr %40, i64 %indvars.iv83
  %42 = load double, ptr %41, align 8, !tbaa !17
  %43 = fadd double %38, %42
  %indvars.iv.next79.2 = or disjoint i64 %indvars.iv78, 3
  %44 = getelementptr inbounds ptr, ptr %23, i64 %indvars.iv.next79.2
  %45 = load ptr, ptr %44, align 8, !tbaa !16
  %46 = getelementptr inbounds double, ptr %45, i64 %indvars.iv83
  %47 = load double, ptr %46, align 8, !tbaa !17
  %48 = fadd double %43, %47
  %indvars.iv.next79.3 = add nuw nsw i64 %indvars.iv78, 4
  %niter109.next.3 = add i64 %niter109, 4
  %niter109.ncmp.3 = icmp eq i64 %niter109.next.3, %unroll_iter108
  br i1 %niter109.ncmp.3, label %._crit_edge.us58.unr-lcssa, label %.preheader.us.new, !llvm.loop !19

._crit_edge.us58.unr-lcssa:                       ; preds = %.preheader.us.new, %.preheader.us
  %.lcssa.ph = phi double [ poison, %.preheader.us ], [ %48, %.preheader.us.new ]
  %indvars.iv78.unr = phi i64 [ 0, %.preheader.us ], [ %indvars.iv.next79.3, %.preheader.us.new ]
  %.03755.us.unr = phi double [ 0.000000e+00, %.preheader.us ], [ %48, %.preheader.us.new ]
  br i1 %lcmp.mod106.not, label %._crit_edge.us58, label %.epil.preheader103

.epil.preheader103:                               ; preds = %._crit_edge.us58.unr-lcssa, %.epil.preheader103
  %indvars.iv78.epil = phi i64 [ %indvars.iv.next79.epil, %.epil.preheader103 ], [ %indvars.iv78.unr, %._crit_edge.us58.unr-lcssa ]
  %.03755.us.epil = phi double [ %53, %.epil.preheader103 ], [ %.03755.us.unr, %._crit_edge.us58.unr-lcssa ]
  %epil.iter105 = phi i64 [ %epil.iter105.next, %.epil.preheader103 ], [ 0, %._crit_edge.us58.unr-lcssa ]
  %49 = getelementptr inbounds ptr, ptr %23, i64 %indvars.iv78.epil
  %50 = load ptr, ptr %49, align 8, !tbaa !16
  %51 = getelementptr inbounds double, ptr %50, i64 %indvars.iv83
  %52 = load double, ptr %51, align 8, !tbaa !17
  %53 = fadd double %.03755.us.epil, %52
  %indvars.iv.next79.epil = add nuw nsw i64 %indvars.iv78.epil, 1
  %epil.iter105.next = add i64 %epil.iter105, 1
  %epil.iter105.cmp.not = icmp eq i64 %epil.iter105.next, %xtraiter104
  br i1 %epil.iter105.cmp.not, label %._crit_edge.us58, label %.epil.preheader103, !llvm.loop !21

._crit_edge.us58:                                 ; preds = %.epil.preheader103, %._crit_edge.us58.unr-lcssa
  %.lcssa = phi double [ %.lcssa.ph, %._crit_edge.us58.unr-lcssa ], [ %53, %.epil.preheader103 ]
  %54 = getelementptr inbounds double, ptr %26, i64 %indvars.iv83
  store double %.lcssa, ptr %54, align 8, !tbaa !17
  %indvars.iv.next84 = add nuw nsw i64 %indvars.iv83, 1
  %exitcond87.not = icmp eq i64 %indvars.iv.next84, %wide.trip.count86
  br i1 %exitcond87.not, label %.loopexit, label %.preheader.us, !llvm.loop !23

55:                                               ; preds = %12
  %56 = landingpad { ptr, i32 }
          cleanup
  br label %59

57:                                               ; preds = %13
  %58 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #4
  br label %59

59:                                               ; preds = %57, %55
  %.pn44 = phi { ptr, i32 } [ %58, %57 ], [ %56, %55 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #4
  br label %142

60:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #4
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #4
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull @.str.80, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %61 unwind label %123

61:                                               ; preds = %60
  %62 = getelementptr inbounds i8, ptr %1, i64 40
  %63 = load i32, ptr %62, align 8, !tbaa !14
  invoke void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(32) %6, i32 noundef %63, i32 noundef 1)
          to label %64 unwind label %125

64:                                               ; preds = %61
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #4
  %65 = load i32, ptr %62, align 8, !tbaa !14
  %66 = icmp sgt i32 %65, 0
  br i1 %66, label %.preheader50.lr.ph, label %.loopexit

.preheader50.lr.ph:                               ; preds = %64
  %67 = getelementptr inbounds i8, ptr %1, i64 44
  %68 = load i32, ptr %67, align 4, !tbaa !5
  %69 = icmp sgt i32 %68, 0
  %70 = getelementptr inbounds i8, ptr %1, i64 48
  %71 = load ptr, ptr %70, align 8
  %72 = getelementptr inbounds i8, ptr %0, i64 48
  %73 = load ptr, ptr %72, align 8, !tbaa !15
  %wide.trip.count73 = zext nneg i32 %65 to i64
  br i1 %69, label %.preheader50.us.preheader, label %.preheader50.preheader

.preheader50.preheader:                           ; preds = %.preheader50.lr.ph
  %xtraiter = and i64 %wide.trip.count73, 7
  %74 = icmp ult i32 %65, 8
  br i1 %74, label %.loopexit.loopexit96.unr-lcssa, label %.preheader50.preheader.new

.preheader50.preheader.new:                       ; preds = %.preheader50.preheader
  %unroll_iter = and i64 %wide.trip.count73, 2147483640
  br label %.preheader50

.preheader50.us.preheader:                        ; preds = %.preheader50.lr.ph
  %wide.trip.count68 = zext nneg i32 %68 to i64
  %xtraiter97 = and i64 %wide.trip.count68, 7
  %75 = icmp ult i32 %68, 8
  %unroll_iter101 = and i64 %wide.trip.count68, 2147483640
  %lcmp.mod99.not = icmp eq i64 %xtraiter97, 0
  br label %.preheader50.us

.preheader50.us:                                  ; preds = %.preheader50.us.preheader, %._crit_edge.us
  %indvars.iv70 = phi i64 [ 0, %.preheader50.us.preheader ], [ %indvars.iv.next71, %._crit_edge.us ]
  %76 = getelementptr inbounds ptr, ptr %71, i64 %indvars.iv70
  %77 = load ptr, ptr %76, align 8, !tbaa !16
  br i1 %75, label %._crit_edge.us.unr-lcssa, label %.preheader50.us.new

.preheader50.us.new:                              ; preds = %.preheader50.us, %.preheader50.us.new
  %indvars.iv65 = phi i64 [ %indvars.iv.next66.7, %.preheader50.us.new ], [ 0, %.preheader50.us ]
  %.13852.us = phi double [ %101, %.preheader50.us.new ], [ 0.000000e+00, %.preheader50.us ]
  %niter102 = phi i64 [ %niter102.next.7, %.preheader50.us.new ], [ 0, %.preheader50.us ]
  %78 = getelementptr inbounds double, ptr %77, i64 %indvars.iv65
  %79 = load double, ptr %78, align 8, !tbaa !17
  %80 = fadd double %.13852.us, %79
  %indvars.iv.next66 = or disjoint i64 %indvars.iv65, 1
  %81 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66
  %82 = load double, ptr %81, align 8, !tbaa !17
  %83 = fadd double %80, %82
  %indvars.iv.next66.1 = or disjoint i64 %indvars.iv65, 2
  %84 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.1
  %85 = load double, ptr %84, align 8, !tbaa !17
  %86 = fadd double %83, %85
  %indvars.iv.next66.2 = or disjoint i64 %indvars.iv65, 3
  %87 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.2
  %88 = load double, ptr %87, align 8, !tbaa !17
  %89 = fadd double %86, %88
  %indvars.iv.next66.3 = or disjoint i64 %indvars.iv65, 4
  %90 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.3
  %91 = load double, ptr %90, align 8, !tbaa !17
  %92 = fadd double %89, %91
  %indvars.iv.next66.4 = or disjoint i64 %indvars.iv65, 5
  %93 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.4
  %94 = load double, ptr %93, align 8, !tbaa !17
  %95 = fadd double %92, %94
  %indvars.iv.next66.5 = or disjoint i64 %indvars.iv65, 6
  %96 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.5
  %97 = load double, ptr %96, align 8, !tbaa !17
  %98 = fadd double %95, %97
  %indvars.iv.next66.6 = or disjoint i64 %indvars.iv65, 7
  %99 = getelementptr inbounds double, ptr %77, i64 %indvars.iv.next66.6
  %100 = load double, ptr %99, align 8, !tbaa !17
  %101 = fadd double %98, %100
  %indvars.iv.next66.7 = add nuw nsw i64 %indvars.iv65, 8
  %niter102.next.7 = add i64 %niter102, 8
  %niter102.ncmp.7 = icmp eq i64 %niter102.next.7, %unroll_iter101
  br i1 %niter102.ncmp.7, label %._crit_edge.us.unr-lcssa, label %.preheader50.us.new, !llvm.loop !24

._crit_edge.us.unr-lcssa:                         ; preds = %.preheader50.us.new, %.preheader50.us
  %.lcssa95.ph = phi double [ poison, %.preheader50.us ], [ %101, %.preheader50.us.new ]
  %indvars.iv65.unr = phi i64 [ 0, %.preheader50.us ], [ %indvars.iv.next66.7, %.preheader50.us.new ]
  %.13852.us.unr = phi double [ 0.000000e+00, %.preheader50.us ], [ %101, %.preheader50.us.new ]
  br i1 %lcmp.mod99.not, label %._crit_edge.us, label %.epil.preheader

.epil.preheader:                                  ; preds = %._crit_edge.us.unr-lcssa, %.epil.preheader
  %indvars.iv65.epil = phi i64 [ %indvars.iv.next66.epil, %.epil.preheader ], [ %indvars.iv65.unr, %._crit_edge.us.unr-lcssa ]
  %.13852.us.epil = phi double [ %104, %.epil.preheader ], [ %.13852.us.unr, %._crit_edge.us.unr-lcssa ]
  %epil.iter98 = phi i64 [ %epil.iter98.next, %.epil.preheader ], [ 0, %._crit_edge.us.unr-lcssa ]
  %102 = getelementptr inbounds double, ptr %77, i64 %indvars.iv65.epil
  %103 = load double, ptr %102, align 8, !tbaa !17
  %104 = fadd double %.13852.us.epil, %103
  %indvars.iv.next66.epil = add nuw nsw i64 %indvars.iv65.epil, 1
  %epil.iter98.next = add i64 %epil.iter98, 1
  %epil.iter98.cmp.not = icmp eq i64 %epil.iter98.next, %xtraiter97
  br i1 %epil.iter98.cmp.not, label %._crit_edge.us, label %.epil.preheader, !llvm.loop !25

._crit_edge.us:                                   ; preds = %.epil.preheader, %._crit_edge.us.unr-lcssa
  %.lcssa95 = phi double [ %.lcssa95.ph, %._crit_edge.us.unr-lcssa ], [ %104, %.epil.preheader ]
  %105 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv70
  %106 = load ptr, ptr %105, align 8, !tbaa !16
  store double %.lcssa95, ptr %106, align 8, !tbaa !17
  %indvars.iv.next71 = add nuw nsw i64 %indvars.iv70, 1
  %exitcond74.not = icmp eq i64 %indvars.iv.next71, %wide.trip.count73
  br i1 %exitcond74.not, label %.loopexit, label %.preheader50.us, !llvm.loop !26

.preheader50:                                     ; preds = %.preheader50, %.preheader50.preheader.new
  %indvars.iv = phi i64 [ 0, %.preheader50.preheader.new ], [ %indvars.iv.next.7, %.preheader50 ]
  %niter = phi i64 [ 0, %.preheader50.preheader.new ], [ %niter.next.7, %.preheader50 ]
  %107 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv
  %108 = load ptr, ptr %107, align 8, !tbaa !16
  store double 0.000000e+00, ptr %108, align 8, !tbaa !17
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %109 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next
  %110 = load ptr, ptr %109, align 8, !tbaa !16
  store double 0.000000e+00, ptr %110, align 8, !tbaa !17
  %indvars.iv.next.1 = or disjoint i64 %indvars.iv, 2
  %111 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.1
  %112 = load ptr, ptr %111, align 8, !tbaa !16
  store double 0.000000e+00, ptr %112, align 8, !tbaa !17
  %indvars.iv.next.2 = or disjoint i64 %indvars.iv, 3
  %113 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.2
  %114 = load ptr, ptr %113, align 8, !tbaa !16
  store double 0.000000e+00, ptr %114, align 8, !tbaa !17
  %indvars.iv.next.3 = or disjoint i64 %indvars.iv, 4
  %115 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.3
  %116 = load ptr, ptr %115, align 8, !tbaa !16
  store double 0.000000e+00, ptr %116, align 8, !tbaa !17
  %indvars.iv.next.4 = or disjoint i64 %indvars.iv, 5
  %117 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.4
  %118 = load ptr, ptr %117, align 8, !tbaa !16
  store double 0.000000e+00, ptr %118, align 8, !tbaa !17
  %indvars.iv.next.5 = or disjoint i64 %indvars.iv, 6
  %119 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.5
  %120 = load ptr, ptr %119, align 8, !tbaa !16
  store double 0.000000e+00, ptr %120, align 8, !tbaa !17
  %indvars.iv.next.6 = or disjoint i64 %indvars.iv, 7
  %121 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.next.6
  %122 = load ptr, ptr %121, align 8, !tbaa !16
  store double 0.000000e+00, ptr %122, align 8, !tbaa !17
  %indvars.iv.next.7 = add nuw nsw i64 %indvars.iv, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %.loopexit.loopexit96.unr-lcssa, label %.preheader50, !llvm.loop !26

123:                                              ; preds = %60
  %124 = landingpad { ptr, i32 }
          cleanup
  br label %127

125:                                              ; preds = %61
  %126 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #4
  br label %127

127:                                              ; preds = %125, %123
  %.pn42 = phi { ptr, i32 } [ %126, %125 ], [ %124, %123 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #4
  br label %142

128:                                              ; preds = %3
  %129 = tail call ptr @__cxa_allocate_exception(i64 112) #4
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %9) #4
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #4
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull @.str.4, ptr noundef nonnull align 1 dereferenceable(1) %9)
          to label %130 unwind label %.thread

130:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %11) #4
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #4
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %10, ptr noundef nonnull @.str.81, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %131 unwind label %134

131:                                              ; preds = %130
  invoke void @_ZN7SGTELIB9ExceptionC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiS8_(ptr noundef nonnull align 8 dereferenceable(112) %129, ptr noundef nonnull align 8 dereferenceable(32) %8, i32 noundef 1781, ptr noundef nonnull align 8 dereferenceable(32) %10)
          to label %132 unwind label %136

132:                                              ; preds = %131
  invoke void @__cxa_throw(ptr nonnull %129, ptr nonnull @_ZTIN7SGTELIB9ExceptionE, ptr nonnull @_ZN7SGTELIB9ExceptionD2Ev) #5
          to label %143 unwind label %136

.thread:                                          ; preds = %128
  %133 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #4
  br label %139

134:                                              ; preds = %130
  %135 = landingpad { ptr, i32 }
          cleanup
  br label %138

136:                                              ; preds = %132, %131
  %.0 = phi i1 [ false, %132 ], [ true, %131 ]
  %137 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #4
  br label %138

138:                                              ; preds = %134, %136
  %.pn = phi { ptr, i32 } [ %137, %136 ], [ %135, %134 ]
  %.1 = phi i1 [ %.0, %136 ], [ true, %134 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %10) #4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #4
  br i1 %.1, label %139, label %142

139:                                              ; preds = %.thread, %138
  %.pn.pn49 = phi { ptr, i32 } [ %133, %.thread ], [ %.pn, %138 ]
  call void @__cxa_free_exception(ptr %129) #4
  br label %142

.loopexit.loopexit96.unr-lcssa:                   ; preds = %.preheader50, %.preheader50.preheader
  %indvars.iv.unr = phi i64 [ 0, %.preheader50.preheader ], [ %indvars.iv.next.7, %.preheader50 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.loopexit, label %.preheader50.epil

.preheader50.epil:                                ; preds = %.loopexit.loopexit96.unr-lcssa, %.preheader50.epil
  %indvars.iv.epil = phi i64 [ %indvars.iv.next.epil, %.preheader50.epil ], [ %indvars.iv.unr, %.loopexit.loopexit96.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.preheader50.epil ], [ 0, %.loopexit.loopexit96.unr-lcssa ]
  %140 = getelementptr inbounds ptr, ptr %73, i64 %indvars.iv.epil
  %141 = load ptr, ptr %140, align 8, !tbaa !16
  store double 0.000000e+00, ptr %141, align 8, !tbaa !17
  %indvars.iv.next.epil = add nuw nsw i64 %indvars.iv.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.loopexit, label %.preheader50.epil, !llvm.loop !27

.loopexit:                                        ; preds = %.loopexit.loopexit96.unr-lcssa, %.preheader50.epil, %._crit_edge.us, %._crit_edge.us58, %.preheader.preheader, %64, %16
  ret void

142:                                              ; preds = %138, %139, %127, %59
  %.pn44.pn = phi { ptr, i32 } [ %.pn44, %59 ], [ %.pn42, %127 ], [ %.pn.pn49, %139 ], [ %.pn, %138 ]
  resume { ptr, i32 } %.pn44.pn

143:                                              ; preds = %132
  unreachable
}

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

declare void @_ZN7SGTELIB6MatrixC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii(ptr, ptr, i32, i32) local_unnamed_addr

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 = { 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 #3 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { nounwind }
attributes #5 = { noreturn }

!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, !13, i64 44}
!6 = !{!"_ZTSN7SGTELIB6MatrixE", !7, i64 8, !13, i64 40, !13, i64 44, !9, i64 48}
!7 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !8, i64 0, !12, i64 8, !10, i64 16}
!8 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !9, i64 0}
!9 = !{!"any pointer", !10, i64 0}
!10 = !{!"omnipotent char", !11, i64 0}
!11 = !{!"Simple C++ TBAA"}
!12 = !{!"long", !10, i64 0}
!13 = !{!"int", !10, i64 0}
!14 = !{!6, !13, i64 40}
!15 = !{!6, !9, i64 48}
!16 = !{!9, !9, i64 0}
!17 = !{!18, !18, i64 0}
!18 = !{!"double", !10, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.unroll.disable"}
!23 = distinct !{!23, !20}
!24 = distinct !{!24, !20}
!25 = distinct !{!25, !22}
!26 = distinct !{!26, !20}
!27 = distinct !{!27, !22}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass