; LLVM IR from tangjz/acm-icpc :: self_training/2015-09-24/I.ll (Z5checkd)

; 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"

%struct.Point = type { double, double }

@pos = external dso_local global [4 x double], align 16
@p = external dso_local global [4 x %struct.Point], align 16
@tr = external dso_local global %struct.Point, align 8
@pp = external dso_local global [4 x %struct.Point], align 16

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z5checkd(double noundef %0) #0 {
  %2 = alloca double, align 8
  %3 = alloca %struct.Point, align 8
  %4 = alloca i32, align 4
  %5 = alloca %struct.Point, align 8
  store double %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 16, ptr %3) #6
  %6 = getelementptr inbounds %struct.Point, ptr %3, i32 0, i32 0
  %7 = load double, ptr %2, align 8, !tbaa !5
  %8 = call double @cos(double noundef %7) #6
  store double %8, ptr %6, align 8, !tbaa !9
  %9 = getelementptr inbounds %struct.Point, ptr %3, i32 0, i32 1
  %10 = load double, ptr %2, align 8, !tbaa !5
  %11 = call double @sin(double noundef %10) #6
  store double %11, ptr %9, align 8, !tbaa !11
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 @tr, ptr align 8 %3, i64 16, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 16, ptr %3) #6
  store double 1.000000e+03, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 1), align 8, !tbaa !5
  store double 1.000000e+03, ptr @pos, align 16, !tbaa !5
  store double -1.000000e+03, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 3), align 8, !tbaa !5
  store double -1.000000e+03, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 2), align 16, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  store i32 0, ptr %4, align 4, !tbaa !13
  br label %12

12:                                               ; preds = %55, %1
  %13 = load i32, ptr %4, align 4, !tbaa !13
  %14 = icmp slt i32 %13, 4
  br i1 %14, label %16, label %15

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

16:                                               ; preds = %12
  call void @llvm.lifetime.start.p0(i64 16, ptr %5) #6
  %17 = getelementptr inbounds %struct.Point, ptr %5, i32 0, i32 0
  %18 = load i32, ptr %4, align 4, !tbaa !13
  %19 = sext i32 %18 to i64
  %20 = getelementptr inbounds [4 x %struct.Point], ptr @p, i64 0, i64 %19
  %21 = call noundef double @_ZNK5Point3dotERKS_(ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef nonnull align 8 dereferenceable(16) @tr)
  store double %21, ptr %17, align 8, !tbaa !9
  %22 = getelementptr inbounds %struct.Point, ptr %5, i32 0, i32 1
  %23 = load i32, ptr %4, align 4, !tbaa !13
  %24 = sext i32 %23 to i64
  %25 = getelementptr inbounds [4 x %struct.Point], ptr @p, i64 0, i64 %24
  %26 = call noundef double @_ZNK5Point3detERKS_(ptr noundef nonnull align 8 dereferenceable(16) %25, ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %27 = fneg double %26
  store double %27, ptr %22, align 8, !tbaa !11
  %28 = load i32, ptr %4, align 4, !tbaa !13
  %29 = sext i32 %28 to i64
  %30 = getelementptr inbounds [4 x %struct.Point], ptr @pp, i64 0, i64 %29
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %30, ptr align 8 %5, i64 16, i1 false), !tbaa.struct !12
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #6
  %31 = load i32, ptr %4, align 4, !tbaa !13
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds [4 x %struct.Point], ptr @pp, i64 0, i64 %32
  %34 = getelementptr inbounds %struct.Point, ptr %33, i32 0, i32 0
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) @pos, ptr noundef nonnull align 8 dereferenceable(8) %34)
  %36 = load double, ptr %35, align 8, !tbaa !5
  store double %36, ptr @pos, align 16, !tbaa !5
  %37 = load i32, ptr %4, align 4, !tbaa !13
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds [4 x %struct.Point], ptr @pp, i64 0, i64 %38
  %40 = getelementptr inbounds %struct.Point, ptr %39, i32 0, i32 1
  %41 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 1), ptr noundef nonnull align 8 dereferenceable(8) %40)
  %42 = load double, ptr %41, align 8, !tbaa !5
  store double %42, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 1), align 8, !tbaa !5
  %43 = load i32, ptr %4, align 4, !tbaa !13
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [4 x %struct.Point], ptr @pp, i64 0, i64 %44
  %46 = getelementptr inbounds %struct.Point, ptr %45, i32 0, i32 0
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 2), ptr noundef nonnull align 8 dereferenceable(8) %46)
  %48 = load double, ptr %47, align 8, !tbaa !5
  store double %48, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 2), align 16, !tbaa !5
  %49 = load i32, ptr %4, align 4, !tbaa !13
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds [4 x %struct.Point], ptr @pp, i64 0, i64 %50
  %52 = getelementptr inbounds %struct.Point, ptr %51, i32 0, i32 1
  %53 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 3), ptr noundef nonnull align 8 dereferenceable(8) %52)
  %54 = load double, ptr %53, align 8, !tbaa !5
  store double %54, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 3), align 8, !tbaa !5
  br label %55

55:                                               ; preds = %16
  %56 = load i32, ptr %4, align 4, !tbaa !13
  %57 = add nsw i32 %56, 1
  store i32 %57, ptr %4, align 4, !tbaa !13
  br label %12, !llvm.loop !15

58:                                               ; preds = %15
  %59 = load double, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 2), align 16, !tbaa !5
  %60 = load double, ptr @pos, align 16, !tbaa !5
  %61 = fsub double %59, %60
  %62 = load double, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 3), align 8, !tbaa !5
  %63 = load double, ptr getelementptr inbounds ([4 x double], ptr @pos, i64 0, i64 1), align 8, !tbaa !5
  %64 = fsub double %62, %63
  %65 = fcmp olt double %61, %64
  %66 = zext i1 %65 to i32
  ret i32 %66
}

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

; Function Attrs: nounwind
declare double @cos(double noundef) #2

; Function Attrs: nounwind
declare double @sin(double noundef) #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) #3

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #5

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #5

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 0}
!10 = !{!"_ZTS5Point", !6, i64 0, !6, i64 8}
!11 = !{!10, !6, i64 8}
!12 = !{i64 0, i64 8, !5, i64 8, i64 8, !5}
!13 = !{!14, !14, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"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"

%struct.Point = type { double, double }

@pos = external dso_local global [4 x double], align 16
@p = external dso_local global [4 x %struct.Point], align 16
@tr = external dso_local global %struct.Point, align 8
@pp = external dso_local global [4 x %struct.Point], align 16

; Function Attrs: mustprogress nounwind uwtable
define dso_local noundef range(i32 0, 2) i32 @_Z5checkd(double noundef %0) local_unnamed_addr #0 {
  %2 = tail call double @cos(double noundef %0) #3
  %3 = tail call double @sin(double noundef %0) #3
  store double %2, ptr @tr, align 8, !tbaa !5
  store double %3, ptr getelementptr inbounds (i8, ptr @tr, i64 8), align 8, !tbaa !5
  store <2 x double> <double 1.000000e+03, double 1.000000e+03>, ptr @pos, align 16, !tbaa !5
  store <2 x double> <double -1.000000e+03, double -1.000000e+03>, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16, !tbaa !5
  %4 = tail call noundef double @_ZNK5Point3dotERKS_(ptr noundef nonnull align 8 dereferenceable(16) @p, ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %5 = tail call noundef double @_ZNK5Point3detERKS_(ptr noundef nonnull align 8 dereferenceable(16) @p, ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %6 = fneg double %5
  store double %4, ptr @pp, align 16, !tbaa !5
  store double %6, ptr getelementptr inbounds (i8, ptr @pp, i64 8), align 8, !tbaa !5
  %7 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) @pos, ptr noundef nonnull align 8 dereferenceable(8) @pp)
  %8 = load double, ptr %7, align 8, !tbaa !5
  store double %8, ptr @pos, align 16, !tbaa !5
  %9 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 8), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 8))
  %10 = load double, ptr %9, align 8, !tbaa !5
  store double %10, ptr getelementptr inbounds (i8, ptr @pos, i64 8), align 8, !tbaa !5
  %11 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 16), ptr noundef nonnull align 8 dereferenceable(8) @pp)
  %12 = load double, ptr %11, align 8, !tbaa !5
  store double %12, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16, !tbaa !5
  %13 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 24), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 8))
  %14 = load double, ptr %13, align 8, !tbaa !5
  store double %14, ptr getelementptr inbounds (i8, ptr @pos, i64 24), align 8, !tbaa !5
  %15 = tail call noundef double @_ZNK5Point3dotERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 16), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %16 = tail call noundef double @_ZNK5Point3detERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 16), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %17 = fneg double %16
  store double %15, ptr getelementptr inbounds (i8, ptr @pp, i64 16), align 16, !tbaa !5
  store double %17, ptr getelementptr inbounds (i8, ptr @pp, i64 24), align 8, !tbaa !5
  %18 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) @pos, ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 16))
  %19 = load double, ptr %18, align 8, !tbaa !5
  store double %19, ptr @pos, align 16, !tbaa !5
  %20 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 8), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 24))
  %21 = load double, ptr %20, align 8, !tbaa !5
  store double %21, ptr getelementptr inbounds (i8, ptr @pos, i64 8), align 8, !tbaa !5
  %22 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 16), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 16))
  %23 = load double, ptr %22, align 8, !tbaa !5
  store double %23, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16, !tbaa !5
  %24 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 24), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 24))
  %25 = load double, ptr %24, align 8, !tbaa !5
  store double %25, ptr getelementptr inbounds (i8, ptr @pos, i64 24), align 8, !tbaa !5
  %26 = tail call noundef double @_ZNK5Point3dotERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 32), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %27 = tail call noundef double @_ZNK5Point3detERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 32), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %28 = fneg double %27
  store double %26, ptr getelementptr inbounds (i8, ptr @pp, i64 32), align 16, !tbaa !5
  store double %28, ptr getelementptr inbounds (i8, ptr @pp, i64 40), align 8, !tbaa !5
  %29 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) @pos, ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 32))
  %30 = load double, ptr %29, align 8, !tbaa !5
  store double %30, ptr @pos, align 16, !tbaa !5
  %31 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 8), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 40))
  %32 = load double, ptr %31, align 8, !tbaa !5
  store double %32, ptr getelementptr inbounds (i8, ptr @pos, i64 8), align 8, !tbaa !5
  %33 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 16), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 32))
  %34 = load double, ptr %33, align 8, !tbaa !5
  store double %34, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16, !tbaa !5
  %35 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 24), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 40))
  %36 = load double, ptr %35, align 8, !tbaa !5
  store double %36, ptr getelementptr inbounds (i8, ptr @pos, i64 24), align 8, !tbaa !5
  %37 = tail call noundef double @_ZNK5Point3dotERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 48), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %38 = tail call noundef double @_ZNK5Point3detERKS_(ptr noundef nonnull align 8 dereferenceable(16) getelementptr inbounds (i8, ptr @p, i64 48), ptr noundef nonnull align 8 dereferenceable(16) @tr)
  %39 = fneg double %38
  store double %37, ptr getelementptr inbounds (i8, ptr @pp, i64 48), align 16, !tbaa !5
  store double %39, ptr getelementptr inbounds (i8, ptr @pp, i64 56), align 8, !tbaa !5
  %40 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) @pos, ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 48))
  %41 = load double, ptr %40, align 8, !tbaa !5
  store double %41, ptr @pos, align 16, !tbaa !5
  %42 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3minIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 8), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 56))
  %43 = load double, ptr %42, align 8, !tbaa !5
  store double %43, ptr getelementptr inbounds (i8, ptr @pos, i64 8), align 8, !tbaa !5
  %44 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 16), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 48))
  %45 = load double, ptr %44, align 8, !tbaa !5
  store double %45, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16, !tbaa !5
  %46 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pos, i64 24), ptr noundef nonnull align 8 dereferenceable(8) getelementptr inbounds (i8, ptr @pp, i64 56))
  %47 = load double, ptr %46, align 8, !tbaa !5
  store double %47, ptr getelementptr inbounds (i8, ptr @pos, i64 24), align 8, !tbaa !5
  %48 = load <2 x double>, ptr getelementptr inbounds (i8, ptr @pos, i64 16), align 16
  %49 = load <2 x double>, ptr @pos, align 16, !tbaa !5
  %50 = insertelement <2 x double> %48, double %47, i64 1
  %51 = fsub <2 x double> %50, %49
  %52 = extractelement <2 x double> %51, i64 0
  %53 = extractelement <2 x double> %51, i64 1
  %54 = fcmp olt double %52, %53
  %55 = zext i1 %54 to i32
  ret i32 %55
}

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @cos(double noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sin(double noundef) local_unnamed_addr #1

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #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 = { mustprogress nofree nounwind willreturn memory(write) "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 = { 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 #3 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,LoopRotatePass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass,VectorCombinePass