; LLVM IR from doyubkim/fluid-engine-dev :: src/jet (grid_single_phase_pressure_solver3)

; 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.anon = type { ptr, ptr, ptr, ptr }
%"class.jet::Size3" = type { i64, i64, i64 }
%class.anon.50 = type { ptr, ptr, ptr }
%"class.jet::GridSinglePhasePressureSolver3" = type { %"class.jet::GridPressureSolver3", %"struct.jet::FdmLinearSystem3", %"struct.jet::FdmCompressedLinearSystem3", %"class.std::shared_ptr", %"struct.jet::FdmMgLinearSystem3", %"class.std::shared_ptr.21", %"class.std::vector.24" }
%"class.jet::GridPressureSolver3" = type { ptr }
%"struct.jet::FdmLinearSystem3" = type { %"class.jet::Array", %"class.jet::Array.0", %"class.jet::Array.0" }
%"class.jet::Array" = type { %"class.jet::Size3", %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<jet::FdmMatrixRow3, std::allocator<jet::FdmMatrixRow3>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::FdmMatrixRow3, std::allocator<jet::FdmMatrixRow3>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::FdmMatrixRow3, std::allocator<jet::FdmMatrixRow3>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::FdmMatrixRow3, std::allocator<jet::FdmMatrixRow3>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.jet::Array.0" = type { %"class.jet::Size3", %"class.std::vector.1" }
%"class.std::vector.1" = type { %"struct.std::_Vector_base.2" }
%"struct.std::_Vector_base.2" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.jet::FdmCompressedLinearSystem3" = type { %"class.jet::MatrixCsr", %"class.jet::VectorN", %"class.jet::VectorN" }
%"class.jet::MatrixCsr" = type { %"class.jet::Size2", %"class.std::vector.1", %"class.std::vector.6", %"class.std::vector.6" }
%"class.jet::Size2" = type { i64, i64 }
%"class.std::vector.6" = type { %"struct.std::_Vector_base.7" }
%"struct.std::_Vector_base.7" = type { %"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl" }
%"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl" = type { %"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.jet::VectorN" = type { %"class.std::vector.1" }
%"class.std::shared_ptr" = type { %"class.std::__shared_ptr" }
%"class.std::__shared_ptr" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%"struct.jet::FdmMgLinearSystem3" = type { %"struct.jet::MgMatrix", %"struct.jet::MgVector", %"struct.jet::MgVector" }
%"struct.jet::MgMatrix" = type { %"class.std::vector.11" }
%"class.std::vector.11" = type { %"struct.std::_Vector_base.12" }
%"struct.std::_Vector_base.12" = type { %"struct.std::_Vector_base<jet::Array<jet::FdmMatrixRow3, 3>, std::allocator<jet::Array<jet::FdmMatrixRow3, 3>>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::Array<jet::FdmMatrixRow3, 3>, std::allocator<jet::Array<jet::FdmMatrixRow3, 3>>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::Array<jet::FdmMatrixRow3, 3>, std::allocator<jet::Array<jet::FdmMatrixRow3, 3>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::Array<jet::FdmMatrixRow3, 3>, std::allocator<jet::Array<jet::FdmMatrixRow3, 3>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.jet::MgVector" = type { %"class.std::vector.16" }
%"class.std::vector.16" = type { %"struct.std::_Vector_base.17" }
%"struct.std::_Vector_base.17" = type { %"struct.std::_Vector_base<jet::Array<double, 3>, std::allocator<jet::Array<double, 3>>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::Array<double, 3>, std::allocator<jet::Array<double, 3>>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::Array<double, 3>, std::allocator<jet::Array<double, 3>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::Array<double, 3>, std::allocator<jet::Array<double, 3>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::shared_ptr.21" = type { %"class.std::__shared_ptr.22" }
%"class.std::__shared_ptr.22" = type { ptr, %"class.std::__shared_count" }
%"class.std::vector.24" = type { %"struct.std::_Vector_base.25" }
%"struct.std::_Vector_base.25" = type { %"struct.std::_Vector_base<jet::Array<char, 3>, std::allocator<jet::Array<char, 3>>>::_Vector_impl" }
%"struct.std::_Vector_base<jet::Array<char, 3>, std::allocator<jet::Array<char, 3>>>::_Vector_impl" = type { %"struct.std::_Vector_base<jet::Array<char, 3>, std::allocator<jet::Array<char, 3>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<jet::Array<char, 3>, std::allocator<jet::Array<char, 3>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.jet::MgParameters" = type { i64, i32, i32, i32, i32, %"class.std::function.34", %"class.std::function.36", %"class.std::function.36", double }
%"class.std::function.34" = type { %"class.std::_Function_base", ptr }
%"class.std::_Function_base" = type { %"union.std::_Any_data", ptr }
%"union.std::_Any_data" = type { %"union.std::_Nocopy_types" }
%"union.std::_Nocopy_types" = type { { i64, i64 } }
%"class.std::function.36" = type { %"class.std::_Function_base", ptr }

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3jet30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESD_(ptr noundef nonnull align 8 dereferenceable(416) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(32) %2, ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #1 align 2 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i64, align 8
  %12 = alloca %class.anon, align 8
  %13 = alloca i64, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca %"class.jet::Size3", align 8
  %17 = alloca %class.anon.50, align 8
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !5
  %18 = load ptr, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  store i64 1, ptr %11, align 8, !tbaa !9
  %19 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 5
  %20 = call noundef zeroext i1 @_ZStneIN3jet12FdmMgSolver3EEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16) %19, ptr null) #5
  br i1 %20, label %21, label %27

21:                                               ; preds = %5
  %22 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 5
  %23 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN3jet12FdmMgSolver3ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %22) #5
  %24 = call noundef nonnull align 8 dereferenceable(128) ptr @_ZNK3jet12FdmMgSolver36paramsEv(ptr noundef nonnull align 8 dereferenceable(145) %23)
  %25 = getelementptr inbounds %"struct.jet::MgParameters", ptr %24, i32 0, i32 0
  %26 = load i64, ptr %25, align 8, !tbaa !11
  store i64 %26, ptr %11, align 8, !tbaa !9
  br label %27

27:                                               ; preds = %21, %5
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  %29 = load i64, ptr %11, align 8, !tbaa !9
  %30 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 6
  call void @_ZN3jet11FdmMgUtils321resizeArrayWithFinestIcEEvRKNS_5Size3EmPSt6vectorINS_5ArrayIT_Lm3EEESaIS8_EE(ptr noundef nonnull align 8 dereferenceable(24) %28, i64 noundef %29, ptr noundef %30)
  %31 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 6
  %32 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %31, i64 noundef 0) #5
  %33 = getelementptr inbounds %class.anon, ptr %12, i32 0, i32 0
  %34 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %34, ptr %33, align 8, !tbaa !5
  %35 = getelementptr inbounds %class.anon, ptr %12, i32 0, i32 1
  %36 = load ptr, ptr %9, align 8, !tbaa !5
  store ptr %36, ptr %35, align 8, !tbaa !5
  %37 = getelementptr inbounds %class.anon, ptr %12, i32 0, i32 2
  store ptr %18, ptr %37, align 8, !tbaa !18
  %38 = getelementptr inbounds %class.anon, ptr %12, i32 0, i32 3
  %39 = load ptr, ptr %10, align 8, !tbaa !5
  store ptr %39, ptr %38, align 8, !tbaa !5
  call void @"_ZNK3jet5ArrayIcLm3EE20parallelForEachIndexIZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESG_E3$_0EEvT_"(ptr noundef nonnull align 8 dereferenceable(48) %32, ptr noundef byval(%class.anon) align 8 %12)
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  store i64 1, ptr %13, align 8, !tbaa !9
  br label %40

40:                                               ; preds = %66, %27
  %41 = load i64, ptr %13, align 8, !tbaa !9
  %42 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 6
  %43 = call noundef i64 @_ZNKSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %42) #5
  %44 = icmp ult i64 %41, %43
  br i1 %44, label %46, label %45

45:                                               ; preds = %40
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  br label %69

46:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %47 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 6
  %48 = load i64, ptr %13, align 8, !tbaa !9
  %49 = sub i64 %48, 1
  %50 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %47, i64 noundef %49) #5
  store ptr %50, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  %51 = getelementptr inbounds %"class.jet::GridSinglePhasePressureSolver3", ptr %18, i32 0, i32 6
  %52 = load i64, ptr %13, align 8, !tbaa !9
  %53 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %51, i64 noundef %52) #5
  store ptr %53, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #5
  %54 = load ptr, ptr %15, align 8, !tbaa !5
  call void @_ZNK3jet5ArrayIcLm3EE4sizeEv(ptr dead_on_unwind writable sret(%"class.jet::Size3") align 8 %16, ptr noundef nonnull align 8 dereferenceable(48) %54)
  %55 = getelementptr inbounds %"class.jet::Size3", ptr %16, i32 0, i32 0
  %56 = load i64, ptr %55, align 8, !tbaa !20
  %57 = getelementptr inbounds %"class.jet::Size3", ptr %16, i32 0, i32 1
  %58 = load i64, ptr %57, align 8, !tbaa !22
  %59 = getelementptr inbounds %"class.jet::Size3", ptr %16, i32 0, i32 2
  %60 = load i64, ptr %59, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 24, ptr %17) #5
  %61 = getelementptr inbounds %class.anon.50, ptr %17, i32 0, i32 0
  store ptr %16, ptr %61, align 8, !tbaa !5
  %62 = getelementptr inbounds %class.anon.50, ptr %17, i32 0, i32 1
  %63 = load ptr, ptr %14, align 8, !tbaa !5
  store ptr %63, ptr %62, align 8, !tbaa !5
  %64 = getelementptr inbounds %class.anon.50, ptr %17, i32 0, i32 2
  %65 = load ptr, ptr %15, align 8, !tbaa !5
  store ptr %65, ptr %64, align 8, !tbaa !5
  call void @"_ZN3jet16parallelRangeForImZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESE_E3$_1EEvT_SG_SG_SG_SG_SG_RKT0_NS_15ExecutionPolicyE"(i64 noundef 0, i64 noundef %56, i64 noundef 0, i64 noundef %58, i64 noundef 0, i64 noundef %60, ptr noundef nonnull align 8 dereferenceable(24) %17, i32 noundef 1)
  call void @llvm.lifetime.end.p0(i64 24, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %66

66:                                               ; preds = %46
  %67 = load i64, ptr %13, align 8, !tbaa !9
  %68 = add i64 %67, 1
  store i64 %68, ptr %13, align 8, !tbaa !9
  br label %40, !llvm.loop !24

69:                                               ; preds = %45
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  ret void
}

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

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

declare noundef nonnull align 8 dereferenceable(128) ptr @_ZNK3jet12FdmMgSolver36paramsEv(ptr noundef nonnull align 8 dereferenceable(145)) #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3jet11FdmMgUtils321resizeArrayWithFinestIcEEvRKNS_5Size3EmPSt6vectorINS_5ArrayIT_Lm3EEESaIS8_EE(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef, ptr noundef) #1 align 2

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

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZNK3jet5ArrayIcLm3EE20parallelForEachIndexIZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESG_E3$_0EEvT_"(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef byval(%class.anon) align 8) #1 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3jet5ArrayIcLm3EE4sizeEv(ptr dead_on_unwind noalias writable sret(%"class.jet::Size3") align 8, ptr noundef nonnull align 8 dereferenceable(48)) #1 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZN3jet16parallelRangeForImZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESE_E3$_1EEvT_SG_SG_SG_SG_SG_RKT0_NS_15ExecutionPolicyE"(i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) #1

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !10, i64 0}
!12 = !{!"_ZTSN3jet12MgParametersINS_8FdmBlas3EEE", !10, i64 0, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !14, i64 24, !16, i64 56, !16, i64 88, !17, i64 120}
!13 = !{!"int", !7, i64 0}
!14 = !{!"_ZTSSt8functionIFvRKN3jet5ArrayINS0_13FdmMatrixRow3ELm3EEERKNS1_IdLm3EEEjdPS6_S9_EE", !15, i64 0, !6, i64 24}
!15 = !{!"_ZTSSt14_Function_base", !7, i64 0, !6, i64 16}
!16 = !{!"_ZTSSt8functionIFvRKN3jet5ArrayIdLm3EEEPS2_EE", !15, i64 0, !6, i64 24}
!17 = !{!"double", !7, i64 0}
!18 = !{!19, !6, i64 16}
!19 = !{!"_ZTSZN3jet30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESD_E3$_0", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!20 = !{!21, !10, i64 0}
!21 = !{!"_ZTSN3jet5Size3E", !10, i64 0, !10, i64 8, !10, i64 16}
!22 = !{!21, !10, i64 8}
!23 = !{!21, !10, i64 16}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}


; 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.anon = type { ptr, ptr, ptr, ptr }
%"class.jet::Size3" = type { i64, i64, i64 }
%class.anon.50 = type { ptr, ptr, ptr }

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

; 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 uwtable
define dso_local void @_ZN3jet30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESD_(ptr noundef nonnull align 8 dereferenceable(416) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(32) %2, ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) local_unnamed_addr #1 align 2 {
  %6 = alloca %class.anon, align 8
  %7 = alloca %"class.jet::Size3", align 8
  %8 = alloca %class.anon.50, align 8
  %9 = getelementptr inbounds i8, ptr %0, i64 376
  %10 = tail call noundef zeroext i1 @_ZStneIN3jet12FdmMgSolver3EEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr null) #5
  br i1 %10, label %11, label %15

11:                                               ; preds = %5
  %12 = tail call noundef ptr @_ZNKSt19__shared_ptr_accessIN3jet12FdmMgSolver3ELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %9) #5
  %13 = tail call noundef nonnull align 8 dereferenceable(128) ptr @_ZNK3jet12FdmMgSolver36paramsEv(ptr noundef nonnull align 8 dereferenceable(145) %12)
  %14 = load i64, ptr %13, align 8, !tbaa !5
  br label %15

15:                                               ; preds = %11, %5
  %.0 = phi i64 [ %14, %11 ], [ 1, %5 ]
  %16 = getelementptr inbounds i8, ptr %0, i64 392
  tail call void @_ZN3jet11FdmMgUtils321resizeArrayWithFinestIcEEvRKNS_5Size3EmPSt6vectorINS_5ArrayIT_Lm3EEESaIS8_EE(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %.0, ptr noundef nonnull %16)
  %17 = tail call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %16, i64 noundef 0) #5
  store ptr %2, ptr %6, align 8, !tbaa !16
  %18 = getelementptr inbounds i8, ptr %6, i64 8
  store ptr %3, ptr %18, align 8, !tbaa !16
  %19 = getelementptr inbounds i8, ptr %6, i64 16
  store ptr %0, ptr %19, align 8, !tbaa !17
  %20 = getelementptr inbounds i8, ptr %6, i64 24
  store ptr %4, ptr %20, align 8, !tbaa !16
  tail call void @"_ZNK3jet5ArrayIcLm3EE20parallelForEachIndexIZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESG_E3$_0EEvT_"(ptr noundef nonnull align 8 dereferenceable(48) %17, ptr noundef nonnull byval(%class.anon) align 8 %6)
  %21 = tail call noundef i64 @_ZNKSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #5
  %22 = icmp ugt i64 %21, 1
  br i1 %22, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %15
  %23 = getelementptr inbounds i8, ptr %7, i64 8
  %24 = getelementptr inbounds i8, ptr %7, i64 16
  %25 = getelementptr inbounds i8, ptr %8, i64 8
  %26 = getelementptr inbounds i8, ptr %8, i64 16
  br label %27

._crit_edge:                                      ; preds = %27, %15
  ret void

27:                                               ; preds = %.lr.ph, %27
  %.01213 = phi i64 [ 1, %.lr.ph ], [ %34, %27 ]
  %28 = add i64 %.01213, -1
  %29 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %16, i64 noundef %28) #5
  %30 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %16, i64 noundef %.01213) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #5
  call void @_ZNK3jet5ArrayIcLm3EE4sizeEv(ptr dead_on_unwind nonnull writable sret(%"class.jet::Size3") align 8 %7, ptr noundef nonnull align 8 dereferenceable(48) %30)
  %31 = load i64, ptr %7, align 8, !tbaa !19
  %32 = load i64, ptr %23, align 8, !tbaa !21
  %33 = load i64, ptr %24, align 8, !tbaa !22
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #5
  store ptr %7, ptr %8, align 8, !tbaa !16
  store ptr %29, ptr %25, align 8, !tbaa !16
  store ptr %30, ptr %26, align 8, !tbaa !16
  call void @"_ZN3jet16parallelRangeForImZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESE_E3$_1EEvT_SG_SG_SG_SG_SG_RKT0_NS_15ExecutionPolicyE"(i64 noundef 0, i64 noundef %31, i64 noundef 0, i64 noundef %32, i64 noundef 0, i64 noundef %33, ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 1)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #5
  %34 = add nuw i64 %.01213, 1
  %35 = call noundef i64 @_ZNKSt6vectorIN3jet5ArrayIcLm3EEESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #5
  %36 = icmp ult i64 %34, %35
  br i1 %36, label %27, label %._crit_edge, !llvm.loop !23
}

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

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

declare noundef nonnull align 8 dereferenceable(128) ptr @_ZNK3jet12FdmMgSolver36paramsEv(ptr noundef nonnull align 8 dereferenceable(145)) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3jet11FdmMgUtils321resizeArrayWithFinestIcEEvRKNS_5Size3EmPSt6vectorINS_5ArrayIT_Lm3EEESaIS8_EE(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef, ptr noundef) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZNK3jet5ArrayIcLm3EE20parallelForEachIndexIZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESG_E3$_0EEvT_"(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef byval(%class.anon) align 8) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK3jet5ArrayIcLm3EE4sizeEv(ptr dead_on_unwind noalias writable sret(%"class.jet::Size3") align 8, ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZN3jet16parallelRangeForImZNS_30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESE_E3$_1EEvT_SG_SG_SG_SG_SG_RKT0_NS_15ExecutionPolicyE"(i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, i64 noundef, ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) local_unnamed_addr #1

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 0}
!6 = !{!"_ZTSN3jet12MgParametersINS_8FdmBlas3EEE", !7, i64 0, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !11, i64 24, !14, i64 56, !14, i64 88, !15, i64 120}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"_ZTSSt8functionIFvRKN3jet5ArrayINS0_13FdmMatrixRow3ELm3EEERKNS1_IdLm3EEEjdPS6_S9_EE", !12, i64 0, !13, i64 24}
!12 = !{!"_ZTSSt14_Function_base", !8, i64 0, !13, i64 16}
!13 = !{!"any pointer", !8, i64 0}
!14 = !{!"_ZTSSt8functionIFvRKN3jet5ArrayIdLm3EEEPS2_EE", !12, i64 0, !13, i64 24}
!15 = !{!"double", !8, i64 0}
!16 = !{!13, !13, i64 0}
!17 = !{!18, !13, i64 16}
!18 = !{!"_ZTSZN3jet30GridSinglePhasePressureSolver312buildMarkersERKNS_5Size3ERKSt8functionIFNS_6VectorIdLm3EEEmmmEERKNS_12ScalarField3ESD_E3$_0", !13, i64 0, !13, i64 8, !13, i64 16, !13, i64 24}
!19 = !{!20, !7, i64 0}
!20 = !{!"_ZTSN3jet5Size3E", !7, i64 0, !7, i64 8, !7, i64 16}
!21 = !{!20, !7, i64 8}
!22 = !{!20, !7, i64 16}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}


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