; LLVM IR from LukeMcCulloch/cfd_solvers_cpp :: src/EulerUnsteady2D.ll (ZN13EulerSolver2D10MainData2DD2Ev)

; 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.EulerSolver2D::MainData2D" = type { %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", i64, %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", double, %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", i64, double, double, double, double, double, double, double, double, i64, ptr, i64, i64, i64, ptr, i64, ptr, i64, ptr, i64, ptr, i64 }
%"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.EulerSolver2D::node_type" = type { double, double, i32, ptr, i32, %class.Vector1D, double, i32, i32, ptr, double, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, double, double, double, ptr, ptr, ptr }
%class.Vector1D = type { %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.EulerSolver2D::elm_type" = type <{ i32, [4 x i8], ptr, i32, [4 x i8], ptr, double, double, double, ptr, ptr, ptr, ptr, ptr, double, double, i32, i32, %class.Vector1D, double, ptr, ptr, i32, [4 x i8] }>
%"class.EulerSolver2D::edge_type" = type { i32, i32, i32, i32, %class.Array2D, double, %class.Array2D, double, i32, i32 }
%class.Array2D = type { i32, i32, i32, i32, i32, i32, i8, i8, ptr }
%"class.EulerSolver2D::bgrid_type" = type { %"class.std::__cxx11::basic_string", i64, ptr, i64, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZN13EulerSolver2D10MainData2DD2Ev(ptr noundef nonnull align 8 dereferenceable(512) %0) unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %3 = load ptr, ptr %2, align 8
  %4 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.8)
          to label %5 unwind label %80

5:                                                ; preds = %1
  %6 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 22
  %7 = load ptr, ptr %6, align 8, !tbaa !9
  %8 = icmp eq ptr %7, null
  br i1 %8, label %21, label %9

9:                                                ; preds = %5
  %10 = getelementptr inbounds i8, ptr %7, i64 -8
  %11 = load i64, ptr %10, align 8
  %12 = getelementptr inbounds %"class.EulerSolver2D::node_type", ptr %7, i64 %11
  %13 = icmp eq ptr %7, %12
  br i1 %13, label %18, label %14

14:                                               ; preds = %14, %9
  %15 = phi ptr [ %12, %9 ], [ %16, %14 ]
  %16 = getelementptr inbounds %"class.EulerSolver2D::node_type", ptr %15, i64 -1
  call void @_ZN13EulerSolver2D9node_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(248) %16) #4
  %17 = icmp eq ptr %16, %7
  br i1 %17, label %18, label %14

18:                                               ; preds = %14, %9
  %19 = mul i64 248, %11
  %20 = add i64 %19, 8
  call void @_ZdaPvm(ptr noundef %10, i64 noundef %20) #5
  br label %21

21:                                               ; preds = %18, %5
  %22 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 26
  %23 = load ptr, ptr %22, align 8, !tbaa !15
  %24 = icmp eq ptr %23, null
  br i1 %24, label %37, label %25

25:                                               ; preds = %21
  %26 = getelementptr inbounds i8, ptr %23, i64 -8
  %27 = load i64, ptr %26, align 8
  %28 = getelementptr inbounds %"class.EulerSolver2D::elm_type", ptr %23, i64 %27
  %29 = icmp eq ptr %23, %28
  br i1 %29, label %34, label %30

30:                                               ; preds = %30, %25
  %31 = phi ptr [ %28, %25 ], [ %32, %30 ]
  %32 = getelementptr inbounds %"class.EulerSolver2D::elm_type", ptr %31, i64 -1
  call void @_ZN13EulerSolver2D8elm_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(172) %32) #4
  %33 = icmp eq ptr %32, %23
  br i1 %33, label %34, label %30

34:                                               ; preds = %30, %25
  %35 = mul i64 176, %27
  %36 = add i64 %35, 8
  call void @_ZdaPvm(ptr noundef %26, i64 noundef %36) #5
  br label %37

37:                                               ; preds = %34, %21
  %38 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 28
  %39 = load ptr, ptr %38, align 8, !tbaa !16
  %40 = icmp eq ptr %39, null
  br i1 %40, label %53, label %41

41:                                               ; preds = %37
  %42 = getelementptr inbounds i8, ptr %39, i64 -8
  %43 = load i64, ptr %42, align 8
  %44 = getelementptr inbounds %"class.EulerSolver2D::edge_type", ptr %39, i64 %43
  %45 = icmp eq ptr %39, %44
  br i1 %45, label %50, label %46

46:                                               ; preds = %46, %41
  %47 = phi ptr [ %44, %41 ], [ %48, %46 ]
  %48 = getelementptr inbounds %"class.EulerSolver2D::edge_type", ptr %47, i64 -1
  call void @_ZN13EulerSolver2D9edge_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(120) %48) #4
  %49 = icmp eq ptr %48, %39
  br i1 %49, label %50, label %46

50:                                               ; preds = %46, %41
  %51 = mul i64 120, %43
  %52 = add i64 %51, 8
  call void @_ZdaPvm(ptr noundef %42, i64 noundef %52) #5
  br label %53

53:                                               ; preds = %50, %37
  %54 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 30
  %55 = load ptr, ptr %54, align 8, !tbaa !17
  %56 = icmp eq ptr %55, null
  br i1 %56, label %69, label %57

57:                                               ; preds = %53
  %58 = getelementptr inbounds i8, ptr %55, i64 -8
  %59 = load i64, ptr %58, align 8
  %60 = getelementptr inbounds %"class.EulerSolver2D::bgrid_type", ptr %55, i64 %59
  %61 = icmp eq ptr %55, %60
  br i1 %61, label %66, label %62

62:                                               ; preds = %62, %57
  %63 = phi ptr [ %60, %57 ], [ %64, %62 ]
  %64 = getelementptr inbounds %"class.EulerSolver2D::bgrid_type", ptr %63, i64 -1
  call void @_ZN13EulerSolver2D10bgrid_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(128) %64) #4
  %65 = icmp eq ptr %64, %55
  br i1 %65, label %66, label %62

66:                                               ; preds = %62, %57
  %67 = mul i64 128, %59
  %68 = add i64 %67, 8
  call void @_ZdaPvm(ptr noundef %58, i64 noundef %68) #5
  br label %69

69:                                               ; preds = %66, %53
  %70 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %70) #4
  %71 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %71) #4
  %72 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 8
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %72) #4
  %73 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %73) #4
  %74 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %74) #4
  %75 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %75) #4
  %76 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 3
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %76) #4
  %77 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 2
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %77) #4
  %78 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 1
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %78) #4
  %79 = getelementptr inbounds %"class.EulerSolver2D::MainData2D", ptr %3, i32 0, i32 0
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %79) #4
  ret void

80:                                               ; preds = %1
  %81 = landingpad { ptr, i32 }
          catch ptr null
  %82 = extractvalue { ptr, i32 } %81, 0
  call void @__clang_call_terminate(ptr %82) #6
  unreachable
}

declare i32 @printf(ptr noundef, ...) #1

; Function Attrs: noinline noreturn nounwind uwtable
declare hidden void @__clang_call_terminate(ptr noundef) #2

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPvm(ptr noundef, i64 noundef) #3

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

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

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

attributes #0 = { 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 #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { noinline noreturn nounwind uwtable "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 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind }
attributes #5 = { builtin nounwind }
attributes #6 = { noreturn 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, !6, i64 416}
!10 = !{!"_ZTSN13EulerSolver2D10MainData2DE", !11, i64 0, !11, i64 32, !11, i64 64, !11, i64 96, !11, i64 128, !11, i64 160, !13, i64 192, !11, i64 200, !11, i64 232, !14, i64 264, !11, i64 272, !11, i64 304, !13, i64 336, !14, i64 344, !14, i64 352, !14, i64 360, !14, i64 368, !14, i64 376, !14, i64 384, !14, i64 392, !14, i64 400, !13, i64 408, !6, i64 416, !13, i64 424, !13, i64 432, !13, i64 440, !6, i64 448, !13, i64 456, !6, i64 464, !13, i64 472, !6, i64 480, !13, i64 488, !6, i64 496, !13, i64 504}
!11 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !12, i64 0, !13, i64 8, !7, i64 16}
!12 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!13 = !{!"long", !7, i64 0}
!14 = !{!"double", !7, i64 0}
!15 = !{!10, !6, i64 448}
!16 = !{!10, !6, i64 464}
!17 = !{!10, !6, i64 480}


; 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.EulerSolver2D::node_type" = type { double, double, i32, ptr, i32, %class.Vector1D, double, i32, i32, ptr, double, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, double, double, double, ptr, ptr, ptr }
%class.Vector1D = type { %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.EulerSolver2D::elm_type" = type <{ i32, [4 x i8], ptr, i32, [4 x i8], ptr, double, double, double, ptr, ptr, ptr, ptr, ptr, double, double, i32, i32, %class.Vector1D, double, ptr, ptr, i32, [4 x i8] }>
%"class.EulerSolver2D::edge_type" = type { i32, i32, i32, i32, %class.Array2D, double, %class.Array2D, double, i32, i32 }
%class.Array2D = type { i32, i32, i32, i32, i32, i32, i8, i8, ptr }
%"class.EulerSolver2D::bgrid_type" = type { %"class.std::__cxx11::basic_string", i64, ptr, i64, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, 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] }

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZN13EulerSolver2D10MainData2DD2Ev(ptr noundef nonnull align 8 dereferenceable(512) %0) unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %2 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8)
  %3 = getelementptr inbounds i8, ptr %0, i64 416
  %4 = load ptr, ptr %3, align 8, !tbaa !5
  %5 = icmp eq ptr %4, null
  br i1 %5, label %16, label %6

6:                                                ; preds = %1
  %7 = getelementptr inbounds i8, ptr %4, i64 -8
  %8 = load i64, ptr %7, align 8
  %9 = icmp eq i64 %8, 0
  br i1 %9, label %.loopexit13, label %.preheader12.preheader

.preheader12.preheader:                           ; preds = %6
  %10 = getelementptr inbounds %"class.EulerSolver2D::node_type", ptr %4, i64 %8
  br label %.preheader12

.preheader12:                                     ; preds = %.preheader12.preheader, %.preheader12
  %11 = phi ptr [ %12, %.preheader12 ], [ %10, %.preheader12.preheader ]
  %12 = getelementptr inbounds i8, ptr %11, i64 -248
  tail call void @_ZN13EulerSolver2D9node_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(248) %12) #3
  %13 = icmp eq ptr %12, %4
  br i1 %13, label %.loopexit13, label %.preheader12

.loopexit13:                                      ; preds = %.preheader12, %6
  %14 = mul i64 %8, 248
  %15 = add i64 %14, 8
  tail call void @_ZdaPvm(ptr noundef nonnull %7, i64 noundef %15) #4
  br label %16

16:                                               ; preds = %.loopexit13, %1
  %17 = getelementptr inbounds i8, ptr %0, i64 448
  %18 = load ptr, ptr %17, align 8, !tbaa !14
  %19 = icmp eq ptr %18, null
  br i1 %19, label %30, label %20

20:                                               ; preds = %16
  %21 = getelementptr inbounds i8, ptr %18, i64 -8
  %22 = load i64, ptr %21, align 8
  %23 = icmp eq i64 %22, 0
  br i1 %23, label %.loopexit11, label %.preheader10.preheader

.preheader10.preheader:                           ; preds = %20
  %24 = getelementptr inbounds %"class.EulerSolver2D::elm_type", ptr %18, i64 %22
  br label %.preheader10

.preheader10:                                     ; preds = %.preheader10.preheader, %.preheader10
  %25 = phi ptr [ %26, %.preheader10 ], [ %24, %.preheader10.preheader ]
  %26 = getelementptr inbounds i8, ptr %25, i64 -176
  tail call void @_ZN13EulerSolver2D8elm_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(172) %26) #3
  %27 = icmp eq ptr %26, %18
  br i1 %27, label %.loopexit11, label %.preheader10

.loopexit11:                                      ; preds = %.preheader10, %20
  %28 = mul i64 %22, 176
  %29 = or disjoint i64 %28, 8
  tail call void @_ZdaPvm(ptr noundef nonnull %21, i64 noundef %29) #4
  br label %30

30:                                               ; preds = %.loopexit11, %16
  %31 = getelementptr inbounds i8, ptr %0, i64 464
  %32 = load ptr, ptr %31, align 8, !tbaa !15
  %33 = icmp eq ptr %32, null
  br i1 %33, label %44, label %34

34:                                               ; preds = %30
  %35 = getelementptr inbounds i8, ptr %32, i64 -8
  %36 = load i64, ptr %35, align 8
  %37 = icmp eq i64 %36, 0
  br i1 %37, label %.loopexit9, label %.preheader8.preheader

.preheader8.preheader:                            ; preds = %34
  %38 = getelementptr inbounds %"class.EulerSolver2D::edge_type", ptr %32, i64 %36
  br label %.preheader8

.preheader8:                                      ; preds = %.preheader8.preheader, %.preheader8
  %39 = phi ptr [ %40, %.preheader8 ], [ %38, %.preheader8.preheader ]
  %40 = getelementptr inbounds i8, ptr %39, i64 -120
  tail call void @_ZN13EulerSolver2D9edge_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(120) %40) #3
  %41 = icmp eq ptr %40, %32
  br i1 %41, label %.loopexit9, label %.preheader8

.loopexit9:                                       ; preds = %.preheader8, %34
  %42 = mul i64 %36, 120
  %43 = add i64 %42, 8
  tail call void @_ZdaPvm(ptr noundef nonnull %35, i64 noundef %43) #4
  br label %44

44:                                               ; preds = %.loopexit9, %30
  %45 = getelementptr inbounds i8, ptr %0, i64 480
  %46 = load ptr, ptr %45, align 8, !tbaa !16
  %47 = icmp eq ptr %46, null
  br i1 %47, label %58, label %48

48:                                               ; preds = %44
  %49 = getelementptr inbounds i8, ptr %46, i64 -8
  %50 = load i64, ptr %49, align 8
  %51 = icmp eq i64 %50, 0
  br i1 %51, label %.loopexit, label %.preheader.preheader

.preheader.preheader:                             ; preds = %48
  %52 = getelementptr inbounds %"class.EulerSolver2D::bgrid_type", ptr %46, i64 %50
  br label %.preheader

.preheader:                                       ; preds = %.preheader.preheader, %.preheader
  %53 = phi ptr [ %54, %.preheader ], [ %52, %.preheader.preheader ]
  %54 = getelementptr inbounds i8, ptr %53, i64 -128
  tail call void @_ZN13EulerSolver2D10bgrid_typeD2Ev(ptr noundef nonnull align 8 dereferenceable(128) %54) #3
  %55 = icmp eq ptr %54, %46
  br i1 %55, label %.loopexit, label %.preheader

.loopexit:                                        ; preds = %.preheader, %48
  %56 = shl i64 %50, 7
  %57 = or disjoint i64 %56, 8
  tail call void @_ZdaPvm(ptr noundef nonnull %49, i64 noundef %57) #4
  br label %58

58:                                               ; preds = %.loopexit, %44
  %59 = getelementptr inbounds i8, ptr %0, i64 304
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %59) #3
  %60 = getelementptr inbounds i8, ptr %0, i64 272
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %60) #3
  %61 = getelementptr inbounds i8, ptr %0, i64 232
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %61) #3
  %62 = getelementptr inbounds i8, ptr %0, i64 200
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %62) #3
  %63 = getelementptr inbounds i8, ptr %0, i64 160
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %63) #3
  %64 = getelementptr inbounds i8, ptr %0, i64 128
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %64) #3
  %65 = getelementptr inbounds i8, ptr %0, i64 96
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %65) #3
  %66 = getelementptr inbounds i8, ptr %0, i64 64
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %66) #3
  %67 = getelementptr inbounds i8, ptr %0, i64 32
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %67) #3
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %0) #3
  ret void
}

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #1

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPvm(ptr noundef, i64 noundef) local_unnamed_addr #2

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

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

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

attributes #0 = { 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 #1 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }
attributes #4 = { builtin nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !9, i64 416}
!6 = !{!"_ZTSN13EulerSolver2D10MainData2DE", !7, i64 0, !7, i64 32, !7, i64 64, !7, i64 96, !7, i64 128, !7, i64 160, !12, i64 192, !7, i64 200, !7, i64 232, !13, i64 264, !7, i64 272, !7, i64 304, !12, i64 336, !13, i64 344, !13, i64 352, !13, i64 360, !13, i64 368, !13, i64 376, !13, i64 384, !13, i64 392, !13, i64 400, !12, i64 408, !9, i64 416, !12, i64 424, !12, i64 432, !12, i64 440, !9, i64 448, !12, i64 456, !9, i64 464, !12, i64 472, !9, i64 480, !12, i64 488, !9, i64 496, !12, i64 504}
!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 = !{!"double", !10, i64 0}
!14 = !{!6, !9, i64 448}
!15 = !{!6, !9, i64 464}
!16 = !{!6, !9, i64 480}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass