; LLVM IR from davidomanovic/CFD-FlowSolver :: src/Mesh.ll (ZNK4Mesh23assembleGlobalStiffnessEv)

; 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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%class.Matrix = type { i64, i64, %"class.std::vector.18" }
%"class.std::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator.16" = type { ptr }
%class.Mesh = type { %"class.std::vector", %"class.std::vector.0" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl" = type { %"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Node, std::allocator<Node>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<Element, std::allocator<Element>>::_Vector_impl" }
%"struct.std::_Vector_base<Element, std::allocator<Element>>::_Vector_impl" = type { %"struct.std::_Vector_base<Element, std::allocator<Element>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Element, std::allocator<Element>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.Node = type <{ i32, [4 x i8], double, double, i8, [7 x i8] }>

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.10 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [3 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: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #1

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPK7ElementSt6vectorIS1_SaIS1_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #4

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

declare noundef i32 @_ZNK7Element5getIdEv(ptr noundef nonnull align 8 dereferenceable(32)) #2

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7Element8getNodesEv(ptr noundef nonnull align 8 dereferenceable(32)) #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK4Mesh23assembleGlobalStiffnessEv(ptr dead_on_unwind noalias writable sret(%class.Matrix) align 8 %0, ptr noundef nonnull align 8 dereferenceable(48) %1) #5 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i64, align 8
  %6 = alloca i1, align 1
  %7 = alloca ptr, align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator.16", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator.16", align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca %class.Matrix, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  %18 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #6
  %19 = getelementptr inbounds %class.Mesh, ptr %18, i32 0, i32 0
  %20 = call noundef i64 @_ZNKSt6vectorI4NodeSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %19) #6
  store i64 %20, ptr %5, align 8, !tbaa !9
  store i1 false, ptr %6, align 1
  %21 = load i64, ptr %5, align 8, !tbaa !9
  %22 = load i64, ptr %5, align 8, !tbaa !9
  call void @_ZN6MatrixC1Emm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %21, i64 noundef %22)
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  %23 = getelementptr inbounds %class.Mesh, ptr %18, i32 0, i32 1
  store ptr %23, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  %24 = load ptr, ptr %7, align 8, !tbaa !5
  %25 = call ptr @_ZNKSt6vectorI7ElementSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %24) #6
  %26 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.16", ptr %8, i32 0, i32 0
  store ptr %25, ptr %26, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  %27 = load ptr, ptr %7, align 8, !tbaa !5
  %28 = call ptr @_ZNKSt6vectorI7ElementSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %27) #6
  %29 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator.16", ptr %9, i32 0, i32 0
  store ptr %28, ptr %29, align 8
  br label %30

30:                                               ; preds = %107, %2
  %31 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPK7ElementSt6vectorIS1_SaIS1_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  br i1 %31, label %33, label %32

32:                                               ; preds = %30
  store i32 2, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  br label %112

33:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %34 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPK7ElementSt6vectorIS1_SaIS1_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  store ptr %34, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %35 = load ptr, ptr %11, align 8, !tbaa !5
  %36 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7Element8getNodesEv(ptr noundef nonnull align 8 dereferenceable(32) %35)
          to label %37 unwind label %54

37:                                               ; preds = %33
  store ptr %36, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 40, ptr %15) #6
  %38 = load ptr, ptr %12, align 8, !tbaa !5
  invoke void @_ZN14LocalStiffness7computeERKSt6vectorIP4NodeSaIS2_EE(ptr dead_on_unwind writable sret(%class.Matrix) align 8 %15, ptr noundef nonnull align 8 dereferenceable(24) %38)
          to label %39 unwind label %58

39:                                               ; preds = %37
  %40 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef @.str.10)
          to label %41 unwind label %62

41:                                               ; preds = %39
  %42 = load ptr, ptr %11, align 8, !tbaa !5
  %43 = invoke noundef i32 @_ZNK7Element5getIdEv(ptr noundef nonnull align 8 dereferenceable(32) %42)
          to label %44 unwind label %62

44:                                               ; preds = %41
  %45 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %40, i32 noundef %43)
          to label %46 unwind label %62

46:                                               ; preds = %44
  %47 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %45, ptr noundef @.str.11)
          to label %48 unwind label %62

48:                                               ; preds = %46
  invoke void @_ZNK6Matrix5printEv(ptr noundef nonnull align 8 dereferenceable(40) %15)
          to label %49 unwind label %62

49:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  store i64 0, ptr %16, align 8, !tbaa !9
  br label %50

50:                                               ; preds = %103, %49
  %51 = load i64, ptr %16, align 8, !tbaa !9
  %52 = icmp ult i64 %51, 3
  br i1 %52, label %66, label %53

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

54:                                               ; preds = %33
  %55 = landingpad { ptr, i32 }
          cleanup
  %56 = extractvalue { ptr, i32 } %55, 0
  store ptr %56, ptr %13, align 8
  %57 = extractvalue { ptr, i32 } %55, 1
  store i32 %57, ptr %14, align 4
  br label %111

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

62:                                               ; preds = %48, %46, %44, %41, %39
  %63 = landingpad { ptr, i32 }
          cleanup
  %64 = extractvalue { ptr, i32 } %63, 0
  store ptr %64, ptr %13, align 8
  %65 = extractvalue { ptr, i32 } %63, 1
  store i32 %65, ptr %14, align 4
  br label %109

66:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  store i64 0, ptr %17, align 8, !tbaa !9
  br label %67

67:                                               ; preds = %95, %66
  %68 = load i64, ptr %17, align 8, !tbaa !9
  %69 = icmp ult i64 %68, 3
  br i1 %69, label %71, label %70

70:                                               ; preds = %67
  store i32 7, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  br label %102

71:                                               ; preds = %67
  %72 = load i64, ptr %16, align 8, !tbaa !9
  %73 = load i64, ptr %17, align 8, !tbaa !9
  %74 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %15, i64 noundef %72, i64 noundef %73)
          to label %75 unwind label %98

75:                                               ; preds = %71
  %76 = load double, ptr %74, align 8, !tbaa !11
  %77 = load ptr, ptr %12, align 8, !tbaa !5
  %78 = load i64, ptr %16, align 8, !tbaa !9
  %79 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %77, i64 noundef %78) #6
  %80 = load ptr, ptr %79, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.Node, ptr %80, i32 0, i32 0
  %82 = load i32, ptr %81, align 8, !tbaa !13
  %83 = sext i32 %82 to i64
  %84 = load ptr, ptr %12, align 8, !tbaa !5
  %85 = load i64, ptr %17, align 8, !tbaa !9
  %86 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %84, i64 noundef %85) #6
  %87 = load ptr, ptr %86, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.Node, ptr %87, i32 0, i32 0
  %89 = load i32, ptr %88, align 8, !tbaa !13
  %90 = sext i32 %89 to i64
  %91 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %83, i64 noundef %90)
          to label %92 unwind label %98

92:                                               ; preds = %75
  %93 = load double, ptr %91, align 8, !tbaa !11
  %94 = fadd double %93, %76
  store double %94, ptr %91, align 8, !tbaa !11
  br label %95

95:                                               ; preds = %92
  %96 = load i64, ptr %17, align 8, !tbaa !9
  %97 = add i64 %96, 1
  store i64 %97, ptr %17, align 8, !tbaa !9
  br label %67, !llvm.loop !17

98:                                               ; preds = %75, %71
  %99 = landingpad { ptr, i32 }
          cleanup
  %100 = extractvalue { ptr, i32 } %99, 0
  store ptr %100, ptr %13, align 8
  %101 = extractvalue { ptr, i32 } %99, 1
  store i32 %101, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %109

102:                                              ; preds = %70
  br label %103

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

106:                                              ; preds = %53
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %15) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %107

107:                                              ; preds = %106
  %108 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPK7ElementSt6vectorIS1_SaIS1_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  br label %30

109:                                              ; preds = %98, %62
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %15) #6
  br label %110

110:                                              ; preds = %109, %58
  call void @llvm.lifetime.end.p0(i64 40, ptr %15) #6
  br label %111

111:                                              ; preds = %110, %54
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %0) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  br label %116

112:                                              ; preds = %32
  store i1 true, ptr %6, align 1
  store i32 1, ptr %10, align 4
  %113 = load i1, ptr %6, align 1
  br i1 %113, label %115, label %114

114:                                              ; preds = %112
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %0) #6
  br label %115

115:                                              ; preds = %114, %112
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  ret void

116:                                              ; preds = %111
  %117 = load ptr, ptr %13, align 8
  %118 = load i32, ptr %14, align 4
  %119 = insertvalue { ptr, i32 } poison, ptr %117, 0
  %120 = insertvalue { ptr, i32 } %119, i32 %118, 1
  resume { ptr, i32 } %120
}

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

declare void @_ZN6MatrixC1Emm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef, i64 noundef) unnamed_addr #2

declare void @_ZN14LocalStiffness7computeERKSt6vectorIP4NodeSaIS2_EE(ptr dead_on_unwind writable sret(%class.Matrix) align 8, ptr noundef nonnull align 8 dereferenceable(24)) #2

declare void @_ZNK6Matrix5printEv(ptr noundef nonnull align 8 dereferenceable(40)) #2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef, i64 noundef) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #3 align 2

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { inlinehint 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 #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 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 #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 = { 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 #6 = { 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, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !15, i64 0}
!14 = !{!"_ZTS4Node", !15, i64 0, !12, i64 8, !12, i64 16, !16, i64 24}
!15 = !{!"int", !7, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !18}


; 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::basic_ostream" = type { ptr, %"class.std::basic_ios" }
%"class.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }
%"class.std::locale" = type { ptr }
%class.Matrix = type { i64, i64, %"class.std::vector.18" }
%"class.std::vector.18" = type { %"struct.std::_Vector_base.19" }
%"struct.std::_Vector_base.19" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator.16" = type { ptr }

@_ZSt4cout = external global %"class.std::basic_ostream", align 8
@.str.10 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [3 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: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #1

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #2

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPK7ElementSt6vectorIS1_SaIS1_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

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

declare noundef i32 @_ZNK7Element5getIdEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7Element8getNodesEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK4Mesh23assembleGlobalStiffnessEv(ptr dead_on_unwind noalias writable sret(%class.Matrix) align 8 %0, ptr noundef nonnull align 8 dereferenceable(48) %1) local_unnamed_addr #5 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.__gnu_cxx::__normal_iterator.16", align 8
  %4 = alloca %"class.__gnu_cxx::__normal_iterator.16", align 8
  %5 = alloca %class.Matrix, align 8
  %6 = tail call noundef i64 @_ZNKSt6vectorI4NodeSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #6
  tail call void @_ZN6MatrixC1Emm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %6, i64 noundef %6)
  %7 = getelementptr inbounds i8, ptr %1, i64 24
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #6
  %8 = tail call ptr @_ZNKSt6vectorI7ElementSaIS0_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %8, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #6
  %9 = tail call ptr @_ZNKSt6vectorI7ElementSaIS0_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %9, ptr %4, align 8
  %10 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPK7ElementSt6vectorIS1_SaIS1_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #6
  br i1 %10, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %159, %2
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #6
  ret void

.lr.ph:                                           ; preds = %2, %159
  %11 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPK7ElementSt6vectorIS1_SaIS1_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #6
  %12 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7Element8getNodesEv(ptr noundef nonnull align 8 dereferenceable(32) %11)
          to label %13 unwind label %24

13:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #6
  invoke void @_ZN14LocalStiffness7computeERKSt6vectorIP4NodeSaIS2_EE(ptr dead_on_unwind nonnull writable sret(%class.Matrix) align 8 %5, ptr noundef nonnull align 8 dereferenceable(24) %12)
          to label %14 unwind label %26

14:                                               ; preds = %13
  %15 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) @_ZSt4cout, ptr noundef nonnull @.str.10)
          to label %16 unwind label %28

16:                                               ; preds = %14
  %17 = invoke noundef i32 @_ZNK7Element5getIdEv(ptr noundef nonnull align 8 dereferenceable(32) %11)
          to label %18 unwind label %28

18:                                               ; preds = %16
  %19 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEi(ptr noundef nonnull align 8 dereferenceable(8) %15, i32 noundef %17)
          to label %20 unwind label %28

20:                                               ; preds = %18
  %21 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %19, ptr noundef nonnull @.str.11)
          to label %22 unwind label %28

22:                                               ; preds = %20
  invoke void @_ZNK6Matrix5printEv(ptr noundef nonnull align 8 dereferenceable(40) %5)
          to label %.preheader.preheader unwind label %28

.preheader.preheader:                             ; preds = %22
  %23 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 0, i64 noundef 0)
          to label %30 unwind label %164

24:                                               ; preds = %.lr.ph
  %25 = landingpad { ptr, i32 }
          cleanup
  br label %168

26:                                               ; preds = %13
  %27 = landingpad { ptr, i32 }
          cleanup
  br label %167

28:                                               ; preds = %22, %20, %18, %16, %14
  %29 = landingpad { ptr, i32 }
          cleanup
  br label %166

30:                                               ; preds = %.preheader.preheader
  %31 = load double, ptr %23, align 8, !tbaa !5
  %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %33 = load ptr, ptr %32, align 8, !tbaa !9
  %34 = load i32, ptr %33, align 8, !tbaa !11
  %35 = sext i32 %34 to i64
  %36 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %37 = load ptr, ptr %36, align 8, !tbaa !9
  %38 = load i32, ptr %37, align 8, !tbaa !11
  %39 = sext i32 %38 to i64
  %40 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %35, i64 noundef %39)
          to label %41 unwind label %164

41:                                               ; preds = %30
  %42 = load double, ptr %40, align 8, !tbaa !5
  %43 = fadd double %31, %42
  store double %43, ptr %40, align 8, !tbaa !5
  %44 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 0, i64 noundef 1)
          to label %45 unwind label %164

45:                                               ; preds = %41
  %46 = load double, ptr %44, align 8, !tbaa !5
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %48 = load ptr, ptr %47, align 8, !tbaa !9
  %49 = load i32, ptr %48, align 8, !tbaa !11
  %50 = sext i32 %49 to i64
  %51 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %52 = load ptr, ptr %51, align 8, !tbaa !9
  %53 = load i32, ptr %52, align 8, !tbaa !11
  %54 = sext i32 %53 to i64
  %55 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %50, i64 noundef %54)
          to label %56 unwind label %164

56:                                               ; preds = %45
  %57 = load double, ptr %55, align 8, !tbaa !5
  %58 = fadd double %46, %57
  store double %58, ptr %55, align 8, !tbaa !5
  %59 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 0, i64 noundef 2)
          to label %60 unwind label %164

60:                                               ; preds = %56
  %61 = load double, ptr %59, align 8, !tbaa !5
  %62 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %63 = load ptr, ptr %62, align 8, !tbaa !9
  %64 = load i32, ptr %63, align 8, !tbaa !11
  %65 = sext i32 %64 to i64
  %66 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %67 = load ptr, ptr %66, align 8, !tbaa !9
  %68 = load i32, ptr %67, align 8, !tbaa !11
  %69 = sext i32 %68 to i64
  %70 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %65, i64 noundef %69)
          to label %.preheader.1 unwind label %164

.preheader.1:                                     ; preds = %60
  %71 = load double, ptr %70, align 8, !tbaa !5
  %72 = fadd double %61, %71
  store double %72, ptr %70, align 8, !tbaa !5
  %73 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 1, i64 noundef 0)
          to label %74 unwind label %164

74:                                               ; preds = %.preheader.1
  %75 = load double, ptr %73, align 8, !tbaa !5
  %76 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %77 = load ptr, ptr %76, align 8, !tbaa !9
  %78 = load i32, ptr %77, align 8, !tbaa !11
  %79 = sext i32 %78 to i64
  %80 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %81 = load ptr, ptr %80, align 8, !tbaa !9
  %82 = load i32, ptr %81, align 8, !tbaa !11
  %83 = sext i32 %82 to i64
  %84 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %79, i64 noundef %83)
          to label %85 unwind label %164

85:                                               ; preds = %74
  %86 = load double, ptr %84, align 8, !tbaa !5
  %87 = fadd double %75, %86
  store double %87, ptr %84, align 8, !tbaa !5
  %88 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 1, i64 noundef 1)
          to label %89 unwind label %164

89:                                               ; preds = %85
  %90 = load double, ptr %88, align 8, !tbaa !5
  %91 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %92 = load ptr, ptr %91, align 8, !tbaa !9
  %93 = load i32, ptr %92, align 8, !tbaa !11
  %94 = sext i32 %93 to i64
  %95 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %96 = load ptr, ptr %95, align 8, !tbaa !9
  %97 = load i32, ptr %96, align 8, !tbaa !11
  %98 = sext i32 %97 to i64
  %99 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %94, i64 noundef %98)
          to label %100 unwind label %164

100:                                              ; preds = %89
  %101 = load double, ptr %99, align 8, !tbaa !5
  %102 = fadd double %90, %101
  store double %102, ptr %99, align 8, !tbaa !5
  %103 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 1, i64 noundef 2)
          to label %104 unwind label %164

104:                                              ; preds = %100
  %105 = load double, ptr %103, align 8, !tbaa !5
  %106 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %107 = load ptr, ptr %106, align 8, !tbaa !9
  %108 = load i32, ptr %107, align 8, !tbaa !11
  %109 = sext i32 %108 to i64
  %110 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %111 = load ptr, ptr %110, align 8, !tbaa !9
  %112 = load i32, ptr %111, align 8, !tbaa !11
  %113 = sext i32 %112 to i64
  %114 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %109, i64 noundef %113)
          to label %.preheader.2 unwind label %164

.preheader.2:                                     ; preds = %104
  %115 = load double, ptr %114, align 8, !tbaa !5
  %116 = fadd double %105, %115
  store double %116, ptr %114, align 8, !tbaa !5
  %117 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 2, i64 noundef 0)
          to label %118 unwind label %164

118:                                              ; preds = %.preheader.2
  %119 = load double, ptr %117, align 8, !tbaa !5
  %120 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %121 = load ptr, ptr %120, align 8, !tbaa !9
  %122 = load i32, ptr %121, align 8, !tbaa !11
  %123 = sext i32 %122 to i64
  %124 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 0) #6
  %125 = load ptr, ptr %124, align 8, !tbaa !9
  %126 = load i32, ptr %125, align 8, !tbaa !11
  %127 = sext i32 %126 to i64
  %128 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %123, i64 noundef %127)
          to label %129 unwind label %164

129:                                              ; preds = %118
  %130 = load double, ptr %128, align 8, !tbaa !5
  %131 = fadd double %119, %130
  store double %131, ptr %128, align 8, !tbaa !5
  %132 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 2, i64 noundef 1)
          to label %133 unwind label %164

133:                                              ; preds = %129
  %134 = load double, ptr %132, align 8, !tbaa !5
  %135 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %136 = load ptr, ptr %135, align 8, !tbaa !9
  %137 = load i32, ptr %136, align 8, !tbaa !11
  %138 = sext i32 %137 to i64
  %139 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 1) #6
  %140 = load ptr, ptr %139, align 8, !tbaa !9
  %141 = load i32, ptr %140, align 8, !tbaa !11
  %142 = sext i32 %141 to i64
  %143 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %138, i64 noundef %142)
          to label %144 unwind label %164

144:                                              ; preds = %133
  %145 = load double, ptr %143, align 8, !tbaa !5
  %146 = fadd double %134, %145
  store double %146, ptr %143, align 8, !tbaa !5
  %147 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %5, i64 noundef 2, i64 noundef 2)
          to label %148 unwind label %164

148:                                              ; preds = %144
  %149 = load double, ptr %147, align 8, !tbaa !5
  %150 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %151 = load ptr, ptr %150, align 8, !tbaa !9
  %152 = load i32, ptr %151, align 8, !tbaa !11
  %153 = sext i32 %152 to i64
  %154 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef 2) #6
  %155 = load ptr, ptr %154, align 8, !tbaa !9
  %156 = load i32, ptr %155, align 8, !tbaa !11
  %157 = sext i32 %156 to i64
  %158 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40) %0, i64 noundef %153, i64 noundef %157)
          to label %159 unwind label %164

159:                                              ; preds = %148
  %160 = load double, ptr %158, align 8, !tbaa !5
  %161 = fadd double %149, %160
  store double %161, ptr %158, align 8, !tbaa !5
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %5) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  %162 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPK7ElementSt6vectorIS1_SaIS1_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #6
  %163 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPK7ElementSt6vectorIS1_SaIS1_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #6
  br i1 %163, label %.lr.ph, label %._crit_edge

164:                                              ; preds = %148, %144, %133, %129, %118, %.preheader.2, %104, %100, %89, %85, %74, %.preheader.1, %60, %56, %45, %41, %30, %.preheader.preheader
  %165 = landingpad { ptr, i32 }
          cleanup
  br label %166

166:                                              ; preds = %164, %28
  %.pn = phi { ptr, i32 } [ %165, %164 ], [ %29, %28 ]
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %5) #6
  br label %167

167:                                              ; preds = %166, %26
  %.pn.pn = phi { ptr, i32 } [ %.pn, %166 ], [ %27, %26 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  br label %168

168:                                              ; preds = %167, %24
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %167 ], [ %25, %24 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #6
  call void @_ZN6MatrixD2Ev(ptr noundef nonnull align 8 dereferenceable(40) %0) #6
  resume { ptr, i32 } %.pn.pn.pn
}

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

declare void @_ZN6MatrixC1Emm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef, i64 noundef) unnamed_addr #2

declare void @_ZN14LocalStiffness7computeERKSt6vectorIP4NodeSaIS2_EE(ptr dead_on_unwind writable sret(%class.Matrix) align 8, ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2

declare void @_ZNK6Matrix5printEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN6MatrixclEmm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef, i64 noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIP4NodeSaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #3 align 2

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { inlinehint 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 #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 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 #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 = { 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 #6 = { 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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !13, i64 0}
!12 = !{!"_ZTS4Node", !13, i64 0, !6, i64 8, !6, i64 16, !14, i64 24}
!13 = !{!"int", !7, i64 0}
!14 = !{!"bool", !7, i64 0}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass