; LLVM IR from robotics-upo/Heuristic_path_planners :: include/voro++-0.4.6/src/pre_container.ll (ZN4voro18pre_container_baseC2Eddddddbbbi)

; 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.voro::pre_container_base" = type { double, double, double, double, double, double, i8, i8, i8, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4voro18pre_container_baseC2Eddddddbbbi(ptr noundef nonnull align 8 dereferenceable(128) %0, double noundef %1, double noundef %2, double noundef %3, double noundef %4, double noundef %5, double noundef %6, i1 noundef zeroext %7, i1 noundef zeroext %8, i1 noundef zeroext %9, i32 noundef %10) unnamed_addr #0 align 2 {
  %12 = alloca ptr, align 8
  %13 = alloca double, align 8
  %14 = alloca double, align 8
  %15 = alloca double, align 8
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca i8, align 1
  %20 = alloca i8, align 1
  %21 = alloca i8, align 1
  %22 = alloca i32, align 4
  store ptr %0, ptr %12, align 8, !tbaa !5
  store double %1, ptr %13, align 8, !tbaa !9
  store double %2, ptr %14, align 8, !tbaa !9
  store double %3, ptr %15, align 8, !tbaa !9
  store double %4, ptr %16, align 8, !tbaa !9
  store double %5, ptr %17, align 8, !tbaa !9
  store double %6, ptr %18, align 8, !tbaa !9
  %23 = zext i1 %7 to i8
  store i8 %23, ptr %19, align 1, !tbaa !11
  %24 = zext i1 %8 to i8
  store i8 %24, ptr %20, align 1, !tbaa !11
  %25 = zext i1 %9 to i8
  store i8 %25, ptr %21, align 1, !tbaa !11
  store i32 %10, ptr %22, align 4, !tbaa !13
  %26 = load ptr, ptr %12, align 8
  %27 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 0
  %28 = load double, ptr %13, align 8, !tbaa !9
  store double %28, ptr %27, align 8, !tbaa !15
  %29 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 1
  %30 = load double, ptr %14, align 8, !tbaa !9
  store double %30, ptr %29, align 8, !tbaa !17
  %31 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 2
  %32 = load double, ptr %15, align 8, !tbaa !9
  store double %32, ptr %31, align 8, !tbaa !18
  %33 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 3
  %34 = load double, ptr %16, align 8, !tbaa !9
  store double %34, ptr %33, align 8, !tbaa !19
  %35 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 4
  %36 = load double, ptr %17, align 8, !tbaa !9
  store double %36, ptr %35, align 8, !tbaa !20
  %37 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 5
  %38 = load double, ptr %18, align 8, !tbaa !9
  store double %38, ptr %37, align 8, !tbaa !21
  %39 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 6
  %40 = load i8, ptr %19, align 1, !tbaa !11, !range !22, !noundef !23
  %41 = trunc i8 %40 to i1
  %42 = zext i1 %41 to i8
  store i8 %42, ptr %39, align 8, !tbaa !24
  %43 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 7
  %44 = load i8, ptr %20, align 1, !tbaa !11, !range !22, !noundef !23
  %45 = trunc i8 %44 to i1
  %46 = zext i1 %45 to i8
  store i8 %46, ptr %43, align 1, !tbaa !25
  %47 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 8
  %48 = load i8, ptr %21, align 1, !tbaa !11, !range !22, !noundef !23
  %49 = trunc i8 %48 to i1
  %50 = zext i1 %49 to i8
  store i8 %50, ptr %47, align 2, !tbaa !26
  %51 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 9
  %52 = load i32, ptr %22, align 4, !tbaa !13
  store i32 %52, ptr %51, align 4, !tbaa !27
  %53 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 10
  store i32 256, ptr %53, align 8, !tbaa !28
  %54 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 11
  %55 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 10
  %56 = load i32, ptr %55, align 8, !tbaa !28
  %57 = sext i32 %56 to i64
  %58 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %57, i64 8)
  %59 = extractvalue { i64, i1 } %58, 1
  %60 = extractvalue { i64, i1 } %58, 0
  %61 = select i1 %59, i64 -1, i64 %60
  %62 = call noalias noundef nonnull ptr @_Znam(i64 noundef %61) #3
  store ptr %62, ptr %54, align 8, !tbaa !29
  %63 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 12
  %64 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 11
  %65 = load ptr, ptr %64, align 8, !tbaa !29
  store ptr %65, ptr %63, align 8, !tbaa !30
  %66 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 16
  %67 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 10
  %68 = load i32, ptr %67, align 8, !tbaa !28
  %69 = sext i32 %68 to i64
  %70 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %69, i64 8)
  %71 = extractvalue { i64, i1 } %70, 1
  %72 = extractvalue { i64, i1 } %70, 0
  %73 = select i1 %71, i64 -1, i64 %72
  %74 = call noalias noundef nonnull ptr @_Znam(i64 noundef %73) #3
  store ptr %74, ptr %66, align 8, !tbaa !31
  %75 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 17
  %76 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 16
  %77 = load ptr, ptr %76, align 8, !tbaa !31
  store ptr %77, ptr %75, align 8, !tbaa !32
  %78 = call noalias noundef nonnull ptr @_Znam(i64 noundef 4096) #3
  %79 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 12
  %80 = load ptr, ptr %79, align 8, !tbaa !30
  store ptr %78, ptr %80, align 8, !tbaa !5
  %81 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 14
  store ptr %78, ptr %81, align 8, !tbaa !33
  %82 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 12
  %83 = load ptr, ptr %82, align 8, !tbaa !30
  %84 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 10
  %85 = load i32, ptr %84, align 8, !tbaa !28
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds ptr, ptr %83, i64 %86
  %88 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 13
  store ptr %87, ptr %88, align 8, !tbaa !34
  %89 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 14
  %90 = load ptr, ptr %89, align 8, !tbaa !33
  %91 = getelementptr inbounds i32, ptr %90, i64 1024
  %92 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 15
  store ptr %91, ptr %92, align 8, !tbaa !35
  %93 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 9
  %94 = load i32, ptr %93, align 4, !tbaa !27
  %95 = mul nsw i32 %94, 1024
  %96 = sext i32 %95 to i64
  %97 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %96, i64 8)
  %98 = extractvalue { i64, i1 } %97, 1
  %99 = extractvalue { i64, i1 } %97, 0
  %100 = select i1 %98, i64 -1, i64 %99
  %101 = call noalias noundef nonnull ptr @_Znam(i64 noundef %100) #3
  %102 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 17
  %103 = load ptr, ptr %102, align 8, !tbaa !32
  store ptr %101, ptr %103, align 8, !tbaa !5
  %104 = getelementptr inbounds %"class.voro::pre_container_base", ptr %26, i32 0, i32 18
  store ptr %101, ptr %104, align 8, !tbaa !36
  ret void
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #1

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #2

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 speculatable willreturn memory(none) }
attributes #2 = { nobuiltin allocsize(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 = { builtin allocsize(0) }

!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 = !{!"double", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"bool", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!16, !10, i64 0}
!16 = !{!"_ZTSN4voro18pre_container_baseE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !12, i64 48, !12, i64 49, !12, i64 50, !14, i64 52, !14, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120}
!17 = !{!16, !10, i64 8}
!18 = !{!16, !10, i64 16}
!19 = !{!16, !10, i64 24}
!20 = !{!16, !10, i64 32}
!21 = !{!16, !10, i64 40}
!22 = !{i8 0, i8 2}
!23 = !{}
!24 = !{!16, !12, i64 48}
!25 = !{!16, !12, i64 49}
!26 = !{!16, !12, i64 50}
!27 = !{!16, !14, i64 52}
!28 = !{!16, !14, i64 56}
!29 = !{!16, !6, i64 64}
!30 = !{!16, !6, i64 72}
!31 = !{!16, !6, i64 104}
!32 = !{!16, !6, i64 112}
!33 = !{!16, !6, i64 88}
!34 = !{!16, !6, i64 80}
!35 = !{!16, !6, i64 96}
!36 = !{!16, !6, i64 120}


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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4voro18pre_container_baseC2Eddddddbbbi(ptr nocapture noundef nonnull writeonly align 8 dereferenceable(128) %0, double noundef %1, double noundef %2, double noundef %3, double noundef %4, double noundef %5, double noundef %6, i1 noundef zeroext %7, i1 noundef zeroext %8, i1 noundef zeroext %9, i32 noundef %10) unnamed_addr #0 align 2 {
  %12 = zext i1 %7 to i8
  %13 = zext i1 %8 to i8
  %14 = zext i1 %9 to i8
  store double %1, ptr %0, align 8, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %0, i64 8
  store double %2, ptr %15, align 8, !tbaa !13
  %16 = getelementptr inbounds i8, ptr %0, i64 16
  store double %3, ptr %16, align 8, !tbaa !14
  %17 = getelementptr inbounds i8, ptr %0, i64 24
  store double %4, ptr %17, align 8, !tbaa !15
  %18 = getelementptr inbounds i8, ptr %0, i64 32
  store double %5, ptr %18, align 8, !tbaa !16
  %19 = getelementptr inbounds i8, ptr %0, i64 40
  store double %6, ptr %19, align 8, !tbaa !17
  %20 = getelementptr inbounds i8, ptr %0, i64 48
  store i8 %12, ptr %20, align 8, !tbaa !18
  %21 = getelementptr inbounds i8, ptr %0, i64 49
  store i8 %13, ptr %21, align 1, !tbaa !19
  %22 = getelementptr inbounds i8, ptr %0, i64 50
  store i8 %14, ptr %22, align 2, !tbaa !20
  %23 = getelementptr inbounds i8, ptr %0, i64 52
  store i32 %10, ptr %23, align 4, !tbaa !21
  %24 = getelementptr inbounds i8, ptr %0, i64 56
  store i32 256, ptr %24, align 8, !tbaa !22
  %25 = getelementptr inbounds i8, ptr %0, i64 64
  %26 = tail call noalias noundef nonnull dereferenceable(2048) ptr @_Znam(i64 noundef 2048) #2
  store ptr %26, ptr %25, align 8, !tbaa !23
  %27 = getelementptr inbounds i8, ptr %0, i64 72
  store ptr %26, ptr %27, align 8, !tbaa !24
  %28 = getelementptr inbounds i8, ptr %0, i64 104
  %29 = tail call noalias noundef nonnull dereferenceable(2048) ptr @_Znam(i64 noundef 2048) #2
  store ptr %29, ptr %28, align 8, !tbaa !25
  %30 = getelementptr inbounds i8, ptr %0, i64 112
  store ptr %29, ptr %30, align 8, !tbaa !26
  %31 = tail call noalias noundef nonnull dereferenceable(4096) ptr @_Znam(i64 noundef 4096) #2
  store ptr %31, ptr %26, align 8, !tbaa !27
  %32 = getelementptr inbounds i8, ptr %0, i64 88
  store ptr %31, ptr %32, align 8, !tbaa !28
  %33 = getelementptr inbounds i8, ptr %26, i64 2048
  %34 = getelementptr inbounds i8, ptr %0, i64 80
  store ptr %33, ptr %34, align 8, !tbaa !29
  %35 = getelementptr inbounds i8, ptr %31, i64 4096
  %36 = getelementptr inbounds i8, ptr %0, i64 96
  store ptr %35, ptr %36, align 8, !tbaa !30
  %37 = shl nsw i32 %10, 10
  %38 = sext i32 %37 to i64
  %39 = icmp slt i32 %10, 0
  %40 = shl nsw i64 %38, 3
  %41 = select i1 %39, i64 -1, i64 %40
  %42 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %41) #2
  store ptr %42, ptr %29, align 8, !tbaa !27
  %43 = getelementptr inbounds i8, ptr %0, i64 120
  store ptr %42, ptr %43, align 8, !tbaa !31
  ret void
}

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #1

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 = { nobuiltin allocsize(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 = { builtin allocsize(0) }

!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 = !{!"_ZTSN4voro18pre_container_baseE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !10, i64 48, !10, i64 49, !10, i64 50, !11, i64 52, !11, i64 56, !12, i64 64, !12, i64 72, !12, i64 80, !12, i64 88, !12, i64 96, !12, i64 104, !12, i64 112, !12, i64 120}
!7 = !{!"double", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!6, !7, i64 8}
!14 = !{!6, !7, i64 16}
!15 = !{!6, !7, i64 24}
!16 = !{!6, !7, i64 32}
!17 = !{!6, !7, i64 40}
!18 = !{!6, !10, i64 48}
!19 = !{!6, !10, i64 49}
!20 = !{!6, !10, i64 50}
!21 = !{!6, !11, i64 52}
!22 = !{!6, !11, i64 56}
!23 = !{!6, !12, i64 64}
!24 = !{!6, !12, i64 72}
!25 = !{!6, !12, i64 104}
!26 = !{!6, !12, i64 112}
!27 = !{!12, !12, i64 0}
!28 = !{!6, !12, i64 88}
!29 = !{!6, !12, i64 80}
!30 = !{!6, !12, i64 96}
!31 = !{!6, !12, i64 120}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,SROAPass,TailCallElimPass