; LLVM IR from pictools/pica :: test/src/grid/YeeGridTests.ll (ZN31YeeGridTest3d_GetCellIndex_Test8TestBodyEv)

; 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.testing::internal::String" = type { ptr, i64 }
%"struct.pica::Vector3" = type { double, double, double }
%"struct.pica::Vector3.15" = type { i32, i32, i32 }
%"class.testing::AssertionResult" = type { i8, %"class.testing::internal::scoped_ptr" }
%"class.testing::internal::scoped_ptr" = type { ptr }
%"class.testing::Message" = type { %"class.testing::internal::scoped_ptr.1" }
%"class.testing::internal::scoped_ptr.1" = type { ptr }
%"class.testing::internal::AssertHelper" = type { ptr }
%class.YeeGridTest3d = type <{ %"class.testing::Test", %"class.std::auto_ptr.14", %"struct.pica::Vector3", %"struct.pica::Vector3", %"struct.pica::Vector3.15", [4 x i8] }>
%"class.testing::Test" = type { ptr, ptr }
%"class.std::auto_ptr.14" = type { ptr }

@.str.3 = external hidden unnamed_addr constant [78 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [51 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7testing15AssertionResultC2Eb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) unnamed_addr #1 align 2

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

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

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

declare void @_ZN7testing8internal30GetBoolAssertionFailureMessageERKNS_15AssertionResultEPKcS5_S5_(ptr dead_on_unwind writable sret(%"class.testing::internal::String") align 8, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef, ptr noundef, ptr noundef) #3

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

declare void @_ZN7testing8internal12AssertHelperC1ENS_14TestPartResult4TypeEPKciS5_(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef, ptr noundef, i32 noundef, ptr noundef) unnamed_addr #3

declare void @_ZNK7testing8internal12AssertHelperaSERKNS_7MessageE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #3

; Function Attrs: nounwind
declare void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #4

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4pica4GridILNS_9DimensionE3EdE9getOriginEv(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(408)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4pica4GridILNS_9DimensionE3EdE7getStepEv(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(408)) #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408)) #1 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN31YeeGridTest3d_GetCellIndex_Test8TestBodyEv(ptr noundef nonnull align 8 dereferenceable(84) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca %"struct.pica::Vector3.15", align 4
  %5 = alloca { i64, i32 }, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca %"struct.pica::Vector3.15", align 4
  %9 = alloca { i64, i32 }, align 8
  %10 = alloca i32, align 4
  %11 = alloca %"struct.pica::Vector3.15", align 4
  %12 = alloca { i64, i32 }, align 8
  %13 = alloca %"struct.pica::Vector3", align 8
  %14 = alloca %"struct.pica::Vector3", align 8
  %15 = alloca %"struct.pica::Vector3", align 8
  %16 = alloca %"struct.pica::Vector3", align 8
  %17 = alloca %"struct.pica::Vector3", align 8
  %18 = alloca %"class.testing::AssertionResult", align 8
  %19 = alloca %"struct.pica::Vector3.15", align 4
  %20 = alloca %"struct.pica::Vector3.15", align 4
  %21 = alloca { i64, i32 }, align 8
  %22 = alloca ptr, align 8
  %23 = alloca i32, align 4
  %24 = alloca %"class.testing::Message", align 8
  %25 = alloca %"class.testing::internal::AssertHelper", align 8
  %26 = alloca %"class.testing::internal::String", align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %27 = load ptr, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #8
  store i32 0, ptr %3, align 4, !tbaa !9
  br label %28

28:                                               ; preds = %121, %1
  %29 = load i32, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 12, ptr %4) #8
  %30 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %31 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %30) #8
  %32 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %31)
  store { i64, i32 } %32, ptr %5, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %4, ptr align 8 %5, i64 12, i1 false)
  %33 = getelementptr inbounds %"struct.pica::Vector3.15", ptr %4, i32 0, i32 0
  %34 = load i32, ptr %33, align 4, !tbaa !11
  %35 = icmp slt i32 %29, %34
  call void @llvm.lifetime.end.p0(i64 12, ptr %4) #8
  br i1 %35, label %37, label %36

36:                                               ; preds = %28
  store i32 2, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  br label %124

37:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %38

38:                                               ; preds = %117, %37
  %39 = load i32, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 12, ptr %8) #8
  %40 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %41 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %40) #8
  %42 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %41)
  store { i64, i32 } %42, ptr %9, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %8, ptr align 8 %9, i64 12, i1 false)
  %43 = getelementptr inbounds %"struct.pica::Vector3.15", ptr %8, i32 0, i32 1
  %44 = load i32, ptr %43, align 4, !tbaa !13
  %45 = icmp slt i32 %39, %44
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #8
  br i1 %45, label %47, label %46

46:                                               ; preds = %38
  store i32 5, ptr %6, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  br label %120

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

48:                                               ; preds = %112, %47
  %49 = load i32, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 12, ptr %11) #8
  %50 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %51 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %50) #8
  %52 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %51)
  store { i64, i32 } %52, ptr %12, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %11, ptr align 8 %12, i64 12, i1 false)
  %53 = getelementptr inbounds %"struct.pica::Vector3.15", ptr %11, i32 0, i32 2
  %54 = load i32, ptr %53, align 4, !tbaa !14
  %55 = icmp slt i32 %49, %54
  call void @llvm.lifetime.end.p0(i64 12, ptr %11) #8
  br i1 %55, label %57, label %56

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

57:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %14) #8
  %58 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %59 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %58) #8
  call void @_ZNK4pica4GridILNS_9DimensionE3EdE9getOriginEv(ptr dead_on_unwind writable sret(%"struct.pica::Vector3") align 8 %14, ptr noundef nonnull align 8 dereferenceable(408) %59)
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #8
  %60 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %61 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %60) #8
  call void @_ZNK4pica4GridILNS_9DimensionE3EdE7getStepEv(ptr dead_on_unwind writable sret(%"struct.pica::Vector3") align 8 %16, ptr noundef nonnull align 8 dereferenceable(408) %61)
  call void @llvm.lifetime.start.p0(i64 24, ptr %17) #8
  %62 = load i32, ptr %3, align 4, !tbaa !9
  %63 = sitofp i32 %62 to double
  %64 = fadd double %63, 5.000000e-01
  %65 = load i32, ptr %7, align 4, !tbaa !9
  %66 = sitofp i32 %65 to double
  %67 = fadd double %66, 5.000000e-01
  %68 = load i32, ptr %10, align 4, !tbaa !9
  %69 = sitofp i32 %68 to double
  %70 = fadd double %69, 5.000000e-01
  call void @_ZN4pica7Vector3IdEC2Eddd(ptr noundef nonnull align 8 dereferenceable(24) %17, double noundef %64, double noundef %67, double noundef %70)
  call void @_ZN4picamlIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind writable sret(%"struct.pica::Vector3") align 8 %15, ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(24) %17)
  call void @_ZN4picaplIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind writable sret(%"struct.pica::Vector3") align 8 %13, ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %15)
  call void @llvm.lifetime.end.p0(i64 24, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #8
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %19) #8
  %71 = load i32, ptr %3, align 4, !tbaa !9
  %72 = load i32, ptr %7, align 4, !tbaa !9
  %73 = load i32, ptr %10, align 4, !tbaa !9
  call void @_ZN4pica7Vector3IiEC2Eiii(ptr noundef nonnull align 4 dereferenceable(12) %19, i32 noundef %71, i32 noundef %72, i32 noundef %73)
  call void @llvm.lifetime.start.p0(i64 12, ptr %20) #8
  %74 = getelementptr inbounds %class.YeeGridTest3d, ptr %27, i32 0, i32 1
  %75 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %74) #8
  %76 = call { i64, i32 } @_ZN4pica4GridILNS_9DimensionE3EdE12getCellIndexERKNS_7Vector3IdEE(ptr noundef nonnull align 8 dereferenceable(408) %75, ptr noundef nonnull align 8 dereferenceable(24) %13)
  store { i64, i32 } %76, ptr %21, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %20, ptr align 8 %21, i64 12, i1 false)
  %77 = call noundef zeroext i1 @_ZN4picaeqIiEEbRKNS_7Vector3IT_EES5_(ptr noundef nonnull align 4 dereferenceable(12) %19, ptr noundef nonnull align 4 dereferenceable(12) %20)
  call void @_ZN7testing15AssertionResultC2Eb(ptr noundef nonnull align 8 dereferenceable(16) %18, i1 noundef zeroext %77)
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %19) #8
  %78 = invoke noundef zeroext i1 @_ZNK7testing15AssertionResultcvbEv(ptr noundef nonnull align 8 dereferenceable(16) %18)
          to label %79 unwind label %81

79:                                               ; preds = %57
  br i1 %78, label %80, label %85

80:                                               ; preds = %79
  br label %111

81:                                               ; preds = %57
  %82 = landingpad { ptr, i32 }
          cleanup
  %83 = extractvalue { ptr, i32 } %82, 0
  store ptr %83, ptr %22, align 8
  %84 = extractvalue { ptr, i32 } %82, 1
  store i32 %84, ptr %23, align 4
  br label %115

85:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #8
  invoke void @_ZN7testing7MessageC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %24)
          to label %86 unwind label %92

86:                                               ; preds = %85
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #8
  call void @llvm.lifetime.start.p0(i64 16, ptr %26) #8
  invoke void @_ZN7testing8internal30GetBoolAssertionFailureMessageERKNS_15AssertionResultEPKcS5_S5_(ptr dead_on_unwind writable sret(%"class.testing::internal::String") align 8 %26, ptr noundef nonnull align 8 dereferenceable(16) %18, ptr noundef @.str.27, ptr noundef @.str.5, ptr noundef @.str.6)
          to label %87 unwind label %96

87:                                               ; preds = %86
  %88 = invoke noundef ptr @_ZNK7testing8internal6String5c_strEv(ptr noundef nonnull align 8 dereferenceable(16) %26)
          to label %89 unwind label %100

89:                                               ; preds = %87
  invoke void @_ZN7testing8internal12AssertHelperC1ENS_14TestPartResult4TypeEPKciS5_(ptr noundef nonnull align 8 dereferenceable(8) %25, i32 noundef 1, ptr noundef @.str.3, i32 noundef 132, ptr noundef %88)
          to label %90 unwind label %100

90:                                               ; preds = %89
  invoke void @_ZNK7testing8internal12AssertHelperaSERKNS_7MessageE(ptr noundef nonnull align 8 dereferenceable(8) %25, ptr noundef nonnull align 8 dereferenceable(8) %24)
          to label %91 unwind label %104

91:                                               ; preds = %90
  call void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %25) #8
  call void @_ZN7testing8internal6StringD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %26) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @_ZN7testing7MessageD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %24) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  br label %111

92:                                               ; preds = %85
  %93 = landingpad { ptr, i32 }
          cleanup
  %94 = extractvalue { ptr, i32 } %93, 0
  store ptr %94, ptr %22, align 8
  %95 = extractvalue { ptr, i32 } %93, 1
  store i32 %95, ptr %23, align 4
  br label %110

96:                                               ; preds = %86
  %97 = landingpad { ptr, i32 }
          cleanup
  %98 = extractvalue { ptr, i32 } %97, 0
  store ptr %98, ptr %22, align 8
  %99 = extractvalue { ptr, i32 } %97, 1
  store i32 %99, ptr %23, align 4
  br label %109

100:                                              ; preds = %89, %87
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %22, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %23, align 4
  br label %108

104:                                              ; preds = %90
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %22, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %23, align 4
  call void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %25) #8
  br label %108

108:                                              ; preds = %104, %100
  call void @_ZN7testing8internal6StringD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %26) #8
  br label %109

109:                                              ; preds = %108, %96
  call void @llvm.lifetime.end.p0(i64 16, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @_ZN7testing7MessageD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %24) #8
  br label %110

110:                                              ; preds = %109, %92
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  br label %115

111:                                              ; preds = %91, %80
  call void @_ZN7testing15AssertionResultD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %18) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #8
  br label %112

112:                                              ; preds = %111
  %113 = load i32, ptr %10, align 4, !tbaa !9
  %114 = add nsw i32 %113, 1
  store i32 %114, ptr %10, align 4, !tbaa !9
  br label %48, !llvm.loop !15

115:                                              ; preds = %110, %81
  call void @_ZN7testing15AssertionResultD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %18) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  br label %125

116:                                              ; preds = %56
  br label %117

117:                                              ; preds = %116
  %118 = load i32, ptr %7, align 4, !tbaa !9
  %119 = add nsw i32 %118, 1
  store i32 %119, ptr %7, align 4, !tbaa !9
  br label %38, !llvm.loop !17

120:                                              ; preds = %46
  br label %121

121:                                              ; preds = %120
  %122 = load i32, ptr %3, align 4, !tbaa !9
  %123 = add nsw i32 %122, 1
  store i32 %123, ptr %3, align 4, !tbaa !9
  br label %28, !llvm.loop !18

124:                                              ; preds = %36
  ret void

125:                                              ; preds = %115
  %126 = load ptr, ptr %22, align 8
  %127 = load i32, ptr %23, align 4
  %128 = insertvalue { ptr, i32 } poison, ptr %126, 0
  %129 = insertvalue { ptr, i32 } %128, i32 %127, 1
  resume { ptr, i32 } %129
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4picaplIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #7

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4picamlIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #7

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN4pica7Vector3IiEC2Eiii(ptr noundef nonnull align 4 dereferenceable(12), i32 noundef, i32 noundef, i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local { i64, i32 } @_ZN4pica4GridILNS_9DimensionE3EdE12getCellIndexERKNS_7Vector3IdEE(ptr noundef nonnull align 8 dereferenceable(408), ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

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 = { "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 "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 = { 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 #6 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #7 = { 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 #8 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 0}
!12 = !{!"_ZTSN4pica7Vector3IiEE", !10, i64 0, !10, i64 4, !10, i64 8}
!13 = !{!12, !10, i64 4}
!14 = !{!12, !10, i64 8}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = distinct !{!17, !16}
!18 = distinct !{!18, !16}


; 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.testing::internal::String" = type { ptr, i64 }
%"struct.pica::Vector3" = type { double, double, double }
%"class.testing::AssertionResult" = type { i8, %"class.testing::internal::scoped_ptr" }
%"class.testing::internal::scoped_ptr" = type { ptr }
%"struct.pica::Vector3.15" = type { i32, i32, i32 }
%"class.testing::Message" = type { %"class.testing::internal::scoped_ptr.1" }
%"class.testing::internal::scoped_ptr.1" = type { ptr }
%"class.testing::internal::AssertHelper" = type { ptr }

@.str.3 = external hidden unnamed_addr constant [78 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [51 x i8], align 1

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7testing15AssertionResultC2Eb(ptr noundef nonnull align 8 dereferenceable(16), i1 noundef zeroext) unnamed_addr #1 align 2

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

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

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

declare void @_ZN7testing8internal30GetBoolAssertionFailureMessageERKNS_15AssertionResultEPKcS5_S5_(ptr dead_on_unwind writable sret(%"class.testing::internal::String") align 8, ptr noundef nonnull align 8 dereferenceable(16), ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

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

declare void @_ZN7testing8internal12AssertHelperC1ENS_14TestPartResult4TypeEPKciS5_(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef, ptr noundef, i32 noundef, ptr noundef) unnamed_addr #3

declare void @_ZNK7testing8internal12AssertHelperaSERKNS_7MessageE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3

; Function Attrs: nounwind
declare void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #4

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4pica4GridILNS_9DimensionE3EdE9getOriginEv(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(408)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4pica4GridILNS_9DimensionE3EdE7getStepEv(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(408)) local_unnamed_addr #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN31YeeGridTest3d_GetCellIndex_Test8TestBodyEv(ptr noundef nonnull align 8 dereferenceable(84) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"struct.pica::Vector3", align 8
  %3 = alloca %"struct.pica::Vector3", align 8
  %4 = alloca %"struct.pica::Vector3", align 8
  %5 = alloca %"struct.pica::Vector3", align 8
  %6 = alloca %"struct.pica::Vector3", align 8
  %7 = alloca %"class.testing::AssertionResult", align 8
  %8 = alloca %"struct.pica::Vector3.15", align 4
  %9 = alloca %"struct.pica::Vector3.15", align 8
  %10 = alloca %"class.testing::Message", align 8
  %11 = alloca %"class.testing::internal::AssertHelper", align 8
  %12 = alloca %"class.testing::internal::String", align 8
  %13 = getelementptr inbounds i8, ptr %0, i64 16
  %14 = tail call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %15 = tail call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %14)
  %.fca.0.extract1947 = extractvalue { i64, i32 } %15, 0
  %.sroa.023.0.extract.trunc48 = trunc i64 %.fca.0.extract1947 to i32
  %16 = icmp sgt i32 %.sroa.023.0.extract.trunc48, 0
  br i1 %16, label %.preheader39.lr.ph, label %._crit_edge50

.preheader39.lr.ph:                               ; preds = %1
  %.sroa.2.0..sroa_idx = getelementptr inbounds i8, ptr %9, i64 8
  br label %.preheader39

.preheader39:                                     ; preds = %.preheader39.lr.ph, %._crit_edge46
  %.03349 = phi i32 [ 0, %.preheader39.lr.ph ], [ %27, %._crit_edge46 ]
  %17 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %18 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %17)
  %.fca.0.extract1042 = extractvalue { i64, i32 } %18, 0
  %.sroa.014.4.extract.shift43 = lshr i64 %.fca.0.extract1042, 32
  %.sroa.014.4.extract.trunc44 = trunc nuw i64 %.sroa.014.4.extract.shift43 to i32
  %19 = icmp sgt i32 %.sroa.014.4.extract.trunc44, 0
  br i1 %19, label %.preheader.lr.ph, label %._crit_edge46

.preheader.lr.ph:                                 ; preds = %.preheader39
  %20 = uitofp nneg i32 %.03349 to double
  %21 = fadd double %20, 5.000000e-01
  br label %.preheader

._crit_edge50:                                    ; preds = %._crit_edge46, %1
  ret void

.preheader:                                       ; preds = %.preheader.lr.ph, %._crit_edge
  %.03445 = phi i32 [ 0, %.preheader.lr.ph ], [ %31, %._crit_edge ]
  %22 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %23 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %22)
  %.fca.1.extract240 = extractvalue { i64, i32 } %23, 1
  %24 = icmp sgt i32 %.fca.1.extract240, 0
  br i1 %24, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %.preheader
  %25 = uitofp nneg i32 %.03445 to double
  %26 = fadd double %25, 5.000000e-01
  br label %35

._crit_edge46:                                    ; preds = %._crit_edge, %.preheader39
  %27 = add nuw nsw i32 %.03349, 1
  %28 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %29 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %28)
  %.fca.0.extract19 = extractvalue { i64, i32 } %29, 0
  %.sroa.023.0.extract.trunc = trunc i64 %.fca.0.extract19 to i32
  %30 = icmp slt i32 %27, %.sroa.023.0.extract.trunc
  br i1 %30, label %.preheader39, label %._crit_edge50, !llvm.loop !5

._crit_edge:                                      ; preds = %61, %.preheader
  %31 = add nuw nsw i32 %.03445, 1
  %32 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %33 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %32)
  %.fca.0.extract10 = extractvalue { i64, i32 } %33, 0
  %.sroa.014.4.extract.shift = lshr i64 %.fca.0.extract10, 32
  %.sroa.014.4.extract.trunc = trunc nuw i64 %.sroa.014.4.extract.shift to i32
  %34 = icmp slt i32 %31, %.sroa.014.4.extract.trunc
  br i1 %34, label %.preheader, label %._crit_edge46, !llvm.loop !7

35:                                               ; preds = %.lr.ph, %61
  %.03541 = phi i32 [ 0, %.lr.ph ], [ %62, %61 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %2) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3) #7
  %36 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  call void @_ZNK4pica4GridILNS_9DimensionE3EdE9getOriginEv(ptr dead_on_unwind nonnull writable sret(%"struct.pica::Vector3") align 8 %3, ptr noundef nonnull align 8 dereferenceable(408) %36)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #7
  %37 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  call void @_ZNK4pica4GridILNS_9DimensionE3EdE7getStepEv(ptr dead_on_unwind nonnull writable sret(%"struct.pica::Vector3") align 8 %5, ptr noundef nonnull align 8 dereferenceable(408) %37)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #7
  %38 = uitofp nneg i32 %.03541 to double
  %39 = fadd double %38, 5.000000e-01
  call void @_ZN4pica7Vector3IdEC2Eddd(ptr noundef nonnull align 8 dereferenceable(24) %6, double noundef %21, double noundef %26, double noundef %39)
  call void @_ZN4picamlIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind nonnull writable sret(%"struct.pica::Vector3") align 8 %4, ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %6)
  call void @_ZN4picaplIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind nonnull writable sret(%"struct.pica::Vector3") align 8 %2, ptr noundef nonnull align 8 dereferenceable(24) %3, ptr noundef nonnull align 8 dereferenceable(24) %4)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %8) #7
  call void @_ZN4pica7Vector3IiEC2Eiii(ptr noundef nonnull align 4 dereferenceable(12) %8, i32 noundef %.03349, i32 noundef %.03445, i32 noundef %.03541)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %9) #7
  %40 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %41 = call { i64, i32 } @_ZN4pica4GridILNS_9DimensionE3EdE12getCellIndexERKNS_7Vector3IdEE(ptr noundef nonnull align 8 dereferenceable(408) %40, ptr noundef nonnull align 8 dereferenceable(24) %2)
  %.fca.0.extract = extractvalue { i64, i32 } %41, 0
  %.fca.1.extract = extractvalue { i64, i32 } %41, 1
  store i64 %.fca.0.extract, ptr %9, align 8
  store i32 %.fca.1.extract, ptr %.sroa.2.0..sroa_idx, align 8
  %42 = call noundef zeroext i1 @_ZN4picaeqIiEEbRKNS_7Vector3IT_EES5_(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %9)
  call void @_ZN7testing15AssertionResultC2Eb(ptr noundef nonnull align 8 dereferenceable(16) %7, i1 noundef zeroext %42)
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %8) #7
  %43 = call noundef zeroext i1 @_ZNK7testing15AssertionResultcvbEv(ptr noundef nonnull align 8 dereferenceable(16) %7)
  br i1 %43, label %61, label %44

44:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #7
  invoke void @_ZN7testing7MessageC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %45 unwind label %50

45:                                               ; preds = %44
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %12) #7
  invoke void @_ZN7testing8internal30GetBoolAssertionFailureMessageERKNS_15AssertionResultEPKcS5_S5_(ptr dead_on_unwind nonnull writable sret(%"class.testing::internal::String") align 8 %12, ptr noundef nonnull align 8 dereferenceable(16) %7, ptr noundef nonnull @.str.27, ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.6)
          to label %46 unwind label %52

46:                                               ; preds = %45
  %47 = call noundef ptr @_ZNK7testing8internal6String5c_strEv(ptr noundef nonnull align 8 dereferenceable(16) %12)
  invoke void @_ZN7testing8internal12AssertHelperC1ENS_14TestPartResult4TypeEPKciS5_(ptr noundef nonnull align 8 dereferenceable(8) %11, i32 noundef 1, ptr noundef nonnull @.str.3, i32 noundef 132, ptr noundef %47)
          to label %48 unwind label %54

48:                                               ; preds = %46
  invoke void @_ZNK7testing8internal12AssertHelperaSERKNS_7MessageE(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %49 unwind label %56

49:                                               ; preds = %48
  call void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %11) #7
  call void @_ZN7testing8internal6StringD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  call void @_ZN7testing7MessageD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  br label %61

50:                                               ; preds = %44
  %51 = landingpad { ptr, i32 }
          cleanup
  br label %60

52:                                               ; preds = %45
  %53 = landingpad { ptr, i32 }
          cleanup
  br label %59

54:                                               ; preds = %46
  %55 = landingpad { ptr, i32 }
          cleanup
  br label %58

56:                                               ; preds = %48
  %57 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7testing8internal12AssertHelperD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %11) #7
  br label %58

58:                                               ; preds = %56, %54
  %.pn = phi { ptr, i32 } [ %57, %56 ], [ %55, %54 ]
  call void @_ZN7testing8internal6StringD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #7
  br label %59

59:                                               ; preds = %58, %52
  %.pn.pn = phi { ptr, i32 } [ %.pn, %58 ], [ %53, %52 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  call void @_ZN7testing7MessageD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %10) #7
  br label %60

60:                                               ; preds = %59, %50
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %59 ], [ %51, %50 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  call void @_ZN7testing15AssertionResultD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #7
  resume { ptr, i32 } %.pn.pn.pn

61:                                               ; preds = %35, %49
  call void @_ZN7testing15AssertionResultD2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %2) #7
  %62 = add nuw nsw i32 %.03541, 1
  %63 = call noundef ptr @_ZNKSt8auto_ptrIN4pica7YeeGridILNS0_9DimensionE3EdEEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #7
  %64 = call { i64, i32 } @_ZNK4pica4GridILNS_9DimensionE3EdE7getSizeEv(ptr noundef nonnull align 8 dereferenceable(408) %63)
  %.fca.1.extract2 = extractvalue { i64, i32 } %64, 1
  %65 = icmp slt i32 %62, %.fca.1.extract2
  br i1 %65, label %35, label %._crit_edge, !llvm.loop !8
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4picaplIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #6

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN4picamlIdEEKNS_7Vector3IT_EERS4_S5_(ptr dead_on_unwind noalias writable sret(%"struct.pica::Vector3") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #6

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN4pica7Vector3IiEC2Eiii(ptr noundef nonnull align 4 dereferenceable(12), i32 noundef, i32 noundef, i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local { i64, i32 } @_ZN4pica4GridILNS_9DimensionE3EdE12getCellIndexERKNS_7Vector3IdEE(ptr noundef nonnull align 8 dereferenceable(408), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

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 = { "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 "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 = { 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 #6 = { 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 #7 = { 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 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}
!7 = distinct !{!7, !6}
!8 = distinct !{!8, !6}


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