; LLVM IR from kimwalisch/primesieve :: src/ParallelSieve.ll (ZN10primesieve13ParallelSieve5sieveEv)

; 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.std::chrono::time_point" = type { %"class.std::chrono::duration" }
%"class.std::chrono::duration" = type { i64 }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i64 }
%class.anon = type { ptr, ptr, ptr, ptr }
%"class.primesieve::Vector" = type { ptr, ptr, ptr }
%"class.std::future" = type { %"class.std::__basic_future" }
%"class.std::__basic_future" = type { %"class.std::shared_ptr" }
%"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 }
%"class.primesieve::Array" = type { [6 x i64] }
%"class.std::chrono::duration.0" = type { double }
%"class.primesieve::PrimeSieve" = type { ptr, i64, i64, double, double, %"class.primesieve::Array", i64, i64, i32, i32, ptr }

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

declare i32 @__gxx_personality_v0(...)

; 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
declare dso_local noundef i32 @_ZNK10primesieve13ParallelSieve15idealNumThreadsEv(ptr noundef nonnull align 8 dereferenceable(164)) #1 align 2

declare noundef i64 @_ZNK10primesieve10PrimeSieve11getDistanceEv(ptr noundef nonnull align 8 dereferenceable(120)) #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK10primesieve13ParallelSieve17getThreadDistanceEi(ptr noundef nonnull align 8 dereferenceable(164), i32 noundef) #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN10primesieve13ParallelSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(164) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca %"class.std::chrono::time_point", align 8
  %5 = alloca i64, align 8
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca %"struct.std::atomic", align 8
  %9 = alloca %class.anon, align 8
  %10 = alloca %"class.primesieve::Vector", align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca %"class.std::future", align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca %"class.primesieve::Array", align 8
  %20 = alloca %"class.std::chrono::time_point", align 8
  %21 = alloca %"class.std::chrono::duration.0", align 8
  %22 = alloca %"class.std::chrono::duration", align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %23 = load ptr, ptr %2, align 8
  call void @_ZN10primesieve10PrimeSieve5resetEv(ptr noundef nonnull align 8 dereferenceable(120) %23)
  %24 = getelementptr inbounds %"class.primesieve::PrimeSieve", ptr %23, i32 0, i32 1
  %25 = load i64, ptr %24, align 8, !tbaa !9
  %26 = getelementptr inbounds %"class.primesieve::PrimeSieve", ptr %23, i32 0, i32 2
  %27 = load i64, ptr %26, align 8, !tbaa !15
  %28 = icmp ugt i64 %25, %27
  br i1 %28, label %29, label %30

29:                                               ; preds = %1
  br label %128

30:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #8
  %31 = call noundef i32 @_ZNK10primesieve13ParallelSieve15idealNumThreadsEv(ptr noundef nonnull align 8 dereferenceable(164) %23)
  store i32 %31, ptr %3, align 4, !tbaa !16
  %32 = load i32, ptr %3, align 4, !tbaa !16
  %33 = icmp eq i32 %32, 1
  br i1 %33, label %34, label %35

34:                                               ; preds = %30
  call void @_ZN10primesieve10PrimeSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(120) %23)
  br label %127

35:                                               ; preds = %30
  call void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120) %23, double noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #8
  %36 = call i64 @_ZNSt6chrono3_V212system_clock3nowEv() #8
  %37 = getelementptr inbounds %"class.std::chrono::time_point", ptr %4, i32 0, i32 0
  %38 = getelementptr inbounds %"class.std::chrono::duration", ptr %37, i32 0, i32 0
  store i64 %36, ptr %38, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #8
  %39 = call noundef i64 @_ZNK10primesieve10PrimeSieve11getDistanceEv(ptr noundef nonnull align 8 dereferenceable(120) %23)
  store i64 %39, ptr %5, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #8
  %40 = load i32, ptr %3, align 4, !tbaa !16
  %41 = call noundef i64 @_ZNK10primesieve13ParallelSieve17getThreadDistanceEi(ptr noundef nonnull align 8 dereferenceable(164) %23, i32 noundef %40)
  store i64 %41, ptr %6, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #8
  %42 = load i64, ptr %5, align 8, !tbaa !17
  %43 = sub i64 %42, 1
  %44 = load i64, ptr %6, align 8, !tbaa !17
  %45 = udiv i64 %43, %44
  %46 = add i64 %45, 1
  store i64 %46, ptr %7, align 8, !tbaa !17
  %47 = load i32, ptr %3, align 4, !tbaa !16
  %48 = load i64, ptr %7, align 8, !tbaa !17
  %49 = call noundef i32 @_ZN12_GLOBAL__N_19inBetweenIiimEET0_T_S1_T1_(i32 noundef 1, i32 noundef %47, i64 noundef %48)
  store i32 %49, ptr %3, align 4, !tbaa !16
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #8
  call void @llvm.memset.p0.i64(ptr align 8 %8, i8 0, i64 8, i1 false)
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #8
  %50 = getelementptr inbounds %class.anon, ptr %9, i32 0, i32 0
  store ptr %23, ptr %50, align 8, !tbaa !18
  %51 = getelementptr inbounds %class.anon, ptr %9, i32 0, i32 1
  store ptr %8, ptr %51, align 8, !tbaa !5
  %52 = getelementptr inbounds %class.anon, ptr %9, i32 0, i32 2
  store ptr %7, ptr %52, align 8, !tbaa !5
  %53 = getelementptr inbounds %class.anon, ptr %9, i32 0, i32 3
  store ptr %6, ptr %53, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %10) #8
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  %54 = load i32, ptr %3, align 4, !tbaa !16
  %55 = sext i32 %54 to i64
  invoke void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE7reserveEm(ptr noundef nonnull align 8 dereferenceable(24) %10, i64 noundef %55)
          to label %56 unwind label %62

56:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #8
  store i32 0, ptr %13, align 4, !tbaa !16
  br label %57

57:                                               ; preds = %69, %56
  %58 = load i32, ptr %13, align 4, !tbaa !16
  %59 = load i32, ptr %3, align 4, !tbaa !16
  %60 = icmp slt i32 %58, %59
  br i1 %60, label %66, label %61

61:                                               ; preds = %57
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  br label %81

62:                                               ; preds = %35
  %63 = landingpad { ptr, i32 }
          cleanup
  %64 = extractvalue { ptr, i32 } %63, 0
  store ptr %64, ptr %11, align 8
  %65 = extractvalue { ptr, i32 } %63, 1
  store i32 %65, ptr %12, align 4
  br label %126

66:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #8
  invoke void @"_ZSt5asyncIRZN10primesieve13ParallelSieve5sieveEvE3$_0JEESt6futureINSt15__invoke_resultINSt5decayIT_E4typeEJDpNS6_IT0_E4typeEEE4typeEESt6launchOS7_DpOSA_"(ptr dead_on_unwind writable sret(%"class.std::future") align 8 %14, i32 noundef 1, ptr noundef nonnull align 8 dereferenceable(32) %9)
          to label %67 unwind label %72

67:                                               ; preds = %66
  invoke void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE12emplace_backIJS4_EEEvDpOT_(ptr noundef nonnull align 8 dereferenceable(24) %10, ptr noundef nonnull align 8 dereferenceable(16) %14)
          to label %68 unwind label %76

68:                                               ; preds = %67
  call void @_ZNSt14__basic_futureIN10primesieve5ArrayImLm6EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #8
  br label %69

69:                                               ; preds = %68
  %70 = load i32, ptr %13, align 4, !tbaa !16
  %71 = add nsw i32 %70, 1
  store i32 %71, ptr %13, align 4, !tbaa !16
  br label %57, !llvm.loop !20

72:                                               ; preds = %66
  %73 = landingpad { ptr, i32 }
          cleanup
  %74 = extractvalue { ptr, i32 } %73, 0
  store ptr %74, ptr %11, align 8
  %75 = extractvalue { ptr, i32 } %73, 1
  store i32 %75, ptr %12, align 4
  br label %80

76:                                               ; preds = %67
  %77 = landingpad { ptr, i32 }
          cleanup
  %78 = extractvalue { ptr, i32 } %77, 0
  store ptr %78, ptr %11, align 8
  %79 = extractvalue { ptr, i32 } %77, 1
  store i32 %79, ptr %12, align 4
  call void @_ZNSt14__basic_futureIN10primesieve5ArrayImLm6EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #8
  br label %80

80:                                               ; preds = %76, %72
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  br label %126

81:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #8
  store ptr %10, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #8
  %82 = load ptr, ptr %15, align 8, !tbaa !5
  %83 = call noundef ptr @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %82) #8
  store ptr %83, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #8
  %84 = load ptr, ptr %15, align 8, !tbaa !5
  %85 = call noundef ptr @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %84) #8
  store ptr %85, ptr %17, align 8, !tbaa !5
  br label %86

86:                                               ; preds = %98, %81
  %87 = load ptr, ptr %16, align 8, !tbaa !5
  %88 = load ptr, ptr %17, align 8, !tbaa !5
  %89 = icmp ne ptr %87, %88
  br i1 %89, label %91, label %90

90:                                               ; preds = %86
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  br label %105

91:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #8
  %92 = load ptr, ptr %16, align 8, !tbaa !5
  store ptr %92, ptr %18, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 48, ptr %19) #8
  %93 = load ptr, ptr %18, align 8, !tbaa !5
  invoke void @_ZNSt6futureIN10primesieve5ArrayImLm6EEEE3getEv(ptr dead_on_unwind writable sret(%"class.primesieve::Array") align 8 %19, ptr noundef nonnull align 8 dereferenceable(16) %93)
          to label %94 unwind label %101

94:                                               ; preds = %91
  %95 = getelementptr inbounds %"class.primesieve::PrimeSieve", ptr %23, i32 0, i32 5
  %96 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN12_GLOBAL__N_1pLERN10primesieve5ArrayImLm6EEERKS2_(ptr noundef nonnull align 8 dereferenceable(48) %95, ptr noundef nonnull align 8 dereferenceable(48) %19)
          to label %97 unwind label %101

97:                                               ; preds = %94
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  br label %98

98:                                               ; preds = %97
  %99 = load ptr, ptr %16, align 8, !tbaa !5
  %100 = getelementptr inbounds %"class.std::future", ptr %99, i32 1
  store ptr %100, ptr %16, align 8, !tbaa !5
  br label %86

101:                                              ; preds = %94, %91
  %102 = landingpad { ptr, i32 }
          cleanup
  %103 = extractvalue { ptr, i32 } %102, 0
  store ptr %103, ptr %11, align 8
  %104 = extractvalue { ptr, i32 } %102, 1
  store i32 %104, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #8
  br label %126

105:                                              ; preds = %90
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #8
  %106 = call i64 @_ZNSt6chrono3_V212system_clock3nowEv() #8
  %107 = getelementptr inbounds %"class.std::chrono::time_point", ptr %20, i32 0, i32 0
  %108 = getelementptr inbounds %"class.std::chrono::duration", ptr %107, i32 0, i32 0
  store i64 %106, ptr %108, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  %109 = invoke i64 @_ZNSt6chronomiINS_3_V212system_clockENS_8durationIlSt5ratioILl1ELl1000000000EEEES6_EENSt11common_typeIJT0_T1_EE4typeERKNS_10time_pointIT_S8_EERKNSC_ISD_S9_EE(ptr noundef nonnull align 8 dereferenceable(8) %20, ptr noundef nonnull align 8 dereferenceable(8) %4)
          to label %110 unwind label %117

110:                                              ; preds = %105
  %111 = getelementptr inbounds %"class.std::chrono::duration", ptr %22, i32 0, i32 0
  store i64 %109, ptr %111, align 8
  invoke void @_ZNSt6chrono8durationIdSt5ratioILl1ELl1EEEC2IlS1_ILl1ELl1000000000EEvEERKNS0_IT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8) %21, ptr noundef nonnull align 8 dereferenceable(8) %22)
          to label %112 unwind label %117

112:                                              ; preds = %110
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  %113 = invoke noundef double @_ZNKSt6chrono8durationIdSt5ratioILl1ELl1EEE5countEv(ptr noundef nonnull align 8 dereferenceable(8) %21)
          to label %114 unwind label %121

114:                                              ; preds = %112
  %115 = getelementptr inbounds %"class.primesieve::PrimeSieve", ptr %23, i32 0, i32 3
  store double %113, ptr %115, align 8, !tbaa !22
  invoke void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120) %23, double noundef 1.000000e+02)
          to label %116 unwind label %121

116:                                              ; preds = %114
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #8
  br label %127

117:                                              ; preds = %110, %105
  %118 = landingpad { ptr, i32 }
          cleanup
  %119 = extractvalue { ptr, i32 } %118, 0
  store ptr %119, ptr %11, align 8
  %120 = extractvalue { ptr, i32 } %118, 1
  store i32 %120, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %125

121:                                              ; preds = %114, %112
  %122 = landingpad { ptr, i32 }
          cleanup
  %123 = extractvalue { ptr, i32 } %122, 0
  store ptr %123, ptr %11, align 8
  %124 = extractvalue { ptr, i32 } %122, 1
  store i32 %124, ptr %12, align 4
  br label %125

125:                                              ; preds = %121, %117
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  br label %126

126:                                              ; preds = %125, %101, %80, %62
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  br label %129

127:                                              ; preds = %116, %34
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #8
  br label %128

128:                                              ; preds = %127, %29
  ret void

129:                                              ; preds = %126
  %130 = load ptr, ptr %11, align 8
  %131 = load i32, ptr %12, align 4
  %132 = insertvalue { ptr, i32 } poison, ptr %130, 0
  %133 = insertvalue { ptr, i32 } %132, i32 %131, 1
  resume { ptr, i32 } %133
}

declare void @_ZN10primesieve10PrimeSieve5resetEv(ptr noundef nonnull align 8 dereferenceable(120)) #2

declare void @_ZN10primesieve10PrimeSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #2

declare void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120), double noundef) #2

; Function Attrs: nounwind
declare i64 @_ZNSt6chrono3_V212system_clock3nowEv() #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN12_GLOBAL__N_19inBetweenIiimEET0_T_S1_T1_(i32 noundef, i32 noundef, i64 noundef) #4

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #5

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE12emplace_backIJS4_EEEvDpOT_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(16)) #7 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZSt5asyncIRZN10primesieve13ParallelSieve5sieveEvE3$_0JEESt6futureINSt15__invoke_resultINSt5decayIT_E4typeEJDpNS6_IT0_E4typeEEE4typeEESt6launchOS7_DpOSA_"(ptr dead_on_unwind noalias writable sret(%"class.std::future") align 8, i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) #1

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(48) ptr @_ZN12_GLOBAL__N_1pLERN10primesieve5ArrayImLm6EEERKS2_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6futureIN10primesieve5ArrayImLm6EEEE3getEv(ptr dead_on_unwind noalias writable sret(%"class.primesieve::Array") align 8, ptr noundef nonnull align 8 dereferenceable(16)) #1 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #6 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 = { "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 "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 = { 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 #5 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #6 = { 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 #7 = { alwaysinline 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, !11, i64 8}
!10 = !{!"_ZTSN10primesieve10PrimeSieveE", !11, i64 8, !11, i64 16, !12, i64 24, !12, i64 32, !13, i64 40, !11, i64 88, !11, i64 96, !14, i64 104, !14, i64 108, !6, i64 112}
!11 = !{!"long", !7, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!"_ZTSN10primesieve5ArrayImLm6EEE", !7, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!10, !11, i64 16}
!16 = !{!14, !14, i64 0}
!17 = !{!11, !11, i64 0}
!18 = !{!19, !6, i64 0}
!19 = !{!"_ZTSZN10primesieve13ParallelSieve5sieveEvE3$_0", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!10, !12, i64 24}


; 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.std::chrono::time_point" = type { %"class.std::chrono::duration" }
%"class.std::chrono::duration" = type { i64 }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i64 }
%class.anon = type { ptr, ptr, ptr, ptr }
%"class.primesieve::Vector" = type { ptr, ptr, ptr }
%"class.std::future" = type { %"class.std::__basic_future" }
%"class.std::__basic_future" = type { %"class.std::shared_ptr" }
%"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 }
%"class.primesieve::Array" = type { [6 x i64] }
%"class.std::chrono::duration.0" = type { double }

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

declare i32 @__gxx_personality_v0(...)

; 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
declare dso_local noundef i32 @_ZNK10primesieve13ParallelSieve15idealNumThreadsEv(ptr noundef nonnull align 8 dereferenceable(164)) local_unnamed_addr #1 align 2

declare noundef i64 @_ZNK10primesieve10PrimeSieve11getDistanceEv(ptr noundef nonnull align 8 dereferenceable(120)) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN10primesieve13ParallelSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(164) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca %"class.std::chrono::time_point", align 8
  %3 = alloca i64, align 8
  %4 = alloca i64, align 8
  %5 = alloca %"struct.std::atomic", align 8
  %6 = alloca %class.anon, align 8
  %7 = alloca %"class.primesieve::Vector", align 8
  %8 = alloca %"class.std::future", align 8
  %9 = alloca %"class.primesieve::Array", align 8
  %10 = alloca %"class.std::chrono::time_point", align 8
  %11 = alloca %"class.std::chrono::duration.0", align 8
  %12 = alloca %"class.std::chrono::duration", align 8
  tail call void @_ZN10primesieve10PrimeSieve5resetEv(ptr noundef nonnull align 8 dereferenceable(120) %0)
  %13 = getelementptr inbounds i8, ptr %0, i64 8
  %14 = load i64, ptr %13, align 8, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %0, i64 16
  %16 = load i64, ptr %15, align 8, !tbaa !14
  %17 = icmp ugt i64 %14, %16
  br i1 %17, label %67, label %18

18:                                               ; preds = %1
  %19 = tail call noundef i32 @_ZNK10primesieve13ParallelSieve15idealNumThreadsEv(ptr noundef nonnull align 8 dereferenceable(164) %0)
  %20 = icmp eq i32 %19, 1
  br i1 %20, label %21, label %22

21:                                               ; preds = %18
  tail call void @_ZN10primesieve10PrimeSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(120) %0)
  br label %67

22:                                               ; preds = %18
  tail call void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120) %0, double noundef 0.000000e+00)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  %23 = tail call i64 @_ZNSt6chrono3_V212system_clock3nowEv() #7
  store i64 %23, ptr %2, align 8
  %24 = tail call noundef i64 @_ZNK10primesieve10PrimeSieve11getDistanceEv(ptr noundef nonnull align 8 dereferenceable(120) %0)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  %25 = tail call noundef i64 @_ZNK10primesieve13ParallelSieve17getThreadDistanceEi(ptr noundef nonnull align 8 dereferenceable(164) %0, i32 noundef %19)
  store i64 %25, ptr %3, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  %26 = add i64 %24, -1
  %27 = udiv i64 %26, %25
  %28 = add i64 %27, 1
  store i64 %28, ptr %4, align 8, !tbaa !15
  %29 = tail call noundef i32 @_ZN12_GLOBAL__N_19inBetweenIiimEET0_T_S1_T1_(i32 noundef 1, i32 noundef %19, i64 noundef %28)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #7
  store i64 0, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #7
  store ptr %0, ptr %6, align 8, !tbaa !16
  %30 = getelementptr inbounds i8, ptr %6, i64 8
  store ptr %5, ptr %30, align 8, !tbaa !18
  %31 = getelementptr inbounds i8, ptr %6, i64 16
  store ptr %4, ptr %31, align 8, !tbaa !18
  %32 = getelementptr inbounds i8, ptr %6, i64 24
  store ptr %3, ptr %32, align 8, !tbaa !18
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  %33 = sext i32 %29 to i64
  invoke void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE7reserveEm(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %33)
          to label %.preheader unwind label %38

.preheader:                                       ; preds = %22
  %34 = icmp sgt i32 %29, 0
  br i1 %34, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %41, %.preheader
  %35 = call noundef ptr @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  %36 = call noundef ptr @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  %.not28 = icmp eq ptr %35, %36
  br i1 %.not28, label %._crit_edge32, label %.lr.ph31

.lr.ph31:                                         ; preds = %._crit_edge
  %37 = getelementptr inbounds i8, ptr %0, i64 40
  br label %50

38:                                               ; preds = %22
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %66

.lr.ph:                                           ; preds = %.preheader, %41
  %.02127 = phi i32 [ %42, %41 ], [ 0, %.preheader ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #7
  invoke void @"_ZSt5asyncIRZN10primesieve13ParallelSieve5sieveEvE3$_0JEESt6futureINSt15__invoke_resultINSt5decayIT_E4typeEJDpNS6_IT0_E4typeEEE4typeEESt6launchOS7_DpOSA_"(ptr dead_on_unwind nonnull writable sret(%"class.std::future") align 8 %8, i32 noundef 1, ptr noundef nonnull align 8 dereferenceable(32) %6)
          to label %40 unwind label %43

40:                                               ; preds = %.lr.ph
  invoke void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE12emplace_backIJS4_EEEvDpOT_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(16) %8)
          to label %41 unwind label %45

41:                                               ; preds = %40
  call void @_ZNSt14__basic_futureIN10primesieve5ArrayImLm6EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %8) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #7
  %42 = add nuw nsw i32 %.02127, 1
  %exitcond.not = icmp eq i32 %42, %29
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !19

43:                                               ; preds = %.lr.ph
  %44 = landingpad { ptr, i32 }
          cleanup
  br label %47

45:                                               ; preds = %40
  %46 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt14__basic_futureIN10primesieve5ArrayImLm6EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %8) #7
  br label %47

47:                                               ; preds = %45, %43
  %.pn24 = phi { ptr, i32 } [ %46, %45 ], [ %44, %43 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #7
  br label %66

._crit_edge32:                                    ; preds = %51, %._crit_edge
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #7
  %48 = call i64 @_ZNSt6chrono3_V212system_clock3nowEv() #7
  store i64 %48, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #7
  %49 = invoke i64 @_ZNSt6chronomiINS_3_V212system_clockENS_8durationIlSt5ratioILl1ELl1000000000EEEES6_EENSt11common_typeIJT0_T1_EE4typeERKNS_10time_pointIT_S8_EERKNSC_ISD_S9_EE(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef nonnull align 8 dereferenceable(8) %2)
          to label %56 unwind label %61

50:                                               ; preds = %.lr.ph31, %51
  %.01729 = phi ptr [ %35, %.lr.ph31 ], [ %53, %51 ]
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %9) #7
  invoke void @_ZNSt6futureIN10primesieve5ArrayImLm6EEEE3getEv(ptr dead_on_unwind nonnull writable sret(%"class.primesieve::Array") align 8 %9, ptr noundef nonnull align 8 dereferenceable(16) %.01729)
          to label %51 unwind label %54

51:                                               ; preds = %50
  %52 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZN12_GLOBAL__N_1pLERN10primesieve5ArrayImLm6EEERKS2_(ptr noundef nonnull align 8 dereferenceable(48) %37, ptr noundef nonnull align 8 dereferenceable(48) %9)
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #7
  %53 = getelementptr inbounds i8, ptr %.01729, i64 16
  %.not = icmp eq ptr %53, %36
  br i1 %.not, label %._crit_edge32, label %50

54:                                               ; preds = %50
  %55 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #7
  br label %66

56:                                               ; preds = %._crit_edge32
  store i64 %49, ptr %12, align 8
  invoke void @_ZNSt6chrono8durationIdSt5ratioILl1ELl1EEEC2IlS1_ILl1ELl1000000000EEvEERKNS0_IT_T0_EE(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(8) %12)
          to label %57 unwind label %61

57:                                               ; preds = %56
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  %58 = call noundef double @_ZNKSt6chrono8durationIdSt5ratioILl1ELl1EEE5countEv(ptr noundef nonnull align 8 dereferenceable(8) %11)
  %59 = getelementptr inbounds i8, ptr %0, i64 24
  store double %58, ptr %59, align 8, !tbaa !21
  invoke void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120) %0, double noundef 1.000000e+02)
          to label %60 unwind label %63

60:                                               ; preds = %57
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  br label %67

61:                                               ; preds = %56, %._crit_edge32
  %62 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #7
  br label %65

63:                                               ; preds = %57
  %64 = landingpad { ptr, i32 }
          cleanup
  br label %65

65:                                               ; preds = %63, %61
  %.pn = phi { ptr, i32 } [ %64, %63 ], [ %62, %61 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #7
  br label %66

66:                                               ; preds = %65, %54, %47, %38
  %.pn24.pn = phi { ptr, i32 } [ %.pn24, %47 ], [ %55, %54 ], [ %.pn, %65 ], [ %39, %38 ]
  call void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  resume { ptr, i32 } %.pn24.pn

67:                                               ; preds = %21, %60, %1
  ret void
}

declare void @_ZN10primesieve10PrimeSieve5resetEv(ptr noundef nonnull align 8 dereferenceable(120)) local_unnamed_addr #2

declare void @_ZN10primesieve10PrimeSieve5sieveEv(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #2

declare void @_ZN10primesieve10PrimeSieve9setStatusEd(ptr noundef nonnull align 8 dereferenceable(120), double noundef) local_unnamed_addr #2

; Function Attrs: nounwind
declare i64 @_ZNSt6chrono3_V212system_clock3nowEv() local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN12_GLOBAL__N_19inBetweenIiimEET0_T_S1_T1_(i32 noundef, i32 noundef, i64 noundef) local_unnamed_addr #4

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

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

; Function Attrs: alwaysinline mustprogress uwtable
declare dso_local void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EE12emplace_backIJS4_EEEvDpOT_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZSt5asyncIRZN10primesieve13ParallelSieve5sieveEvE3$_0JEESt6futureINSt15__invoke_resultINSt5decayIT_E4typeEJDpNS6_IT0_E4typeEEE4typeEESt6launchOS7_DpOSA_"(ptr dead_on_unwind noalias writable sret(%"class.std::future") align 8, i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #1

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(48) ptr @_ZN12_GLOBAL__N_1pLERN10primesieve5ArrayImLm6EEERKS2_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6futureIN10primesieve5ArrayImLm6EEEE3getEv(ptr dead_on_unwind noalias writable sret(%"class.primesieve::Array") align 8, ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #1 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN10primesieve6VectorISt6futureINS_5ArrayImLm6EEEESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #5 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 = { "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 "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 = { 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 #5 = { 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 = { alwaysinline 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 = !{!6, !7, i64 8}
!6 = !{!"_ZTSN10primesieve10PrimeSieveE", !7, i64 8, !7, i64 16, !10, i64 24, !10, i64 32, !11, i64 40, !7, i64 88, !7, i64 96, !12, i64 104, !12, i64 108, !13, i64 112}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"double", !8, i64 0}
!11 = !{!"_ZTSN10primesieve5ArrayImLm6EEE", !8, i64 0}
!12 = !{!"int", !8, i64 0}
!13 = !{!"any pointer", !8, i64 0}
!14 = !{!6, !7, i64 16}
!15 = !{!7, !7, i64 0}
!16 = !{!17, !13, i64 0}
!17 = !{!"_ZTSZN10primesieve13ParallelSieve5sieveEvE3$_0", !13, i64 0, !13, i64 8, !13, i64 16, !13, i64 24}
!18 = !{!13, !13, i64 0}
!19 = distinct !{!19, !20}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!6, !10, i64 24}


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