; LLVM IR from albertobsd/keyhunt :: keyhunt_legacy.ll (Z16bsgs_secondcheckP3IntjjS0_)

; 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::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl" }
%"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl" = type { %"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Int = type { [1 x %struct.__mpz_struct] }
%struct.__mpz_struct = type { i32, i32, ptr }
%class.Point = type { %class.Int, %class.Int, %class.Int }
%struct.bloom = type { i64, i64, i64, i8, x86_fp80, i8, i8, i8, double, ptr }

@OriginalPointsBSGS = external dso_local global %"class.std::vector", align 8
@bloom_bPx2nd = external dso_local global ptr, align 8
@BSGS_M_double = external dso_local global %class.Int, align 8
@BSGS_AMP2 = external dso_local global %"class.std::vector", align 8
@secp = external dso_local global ptr, align 8

declare void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #1

declare void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #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) #2

declare void @_ZN3Int3SetEPKS_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #0

declare void @_ZN3Int4MultEm(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef) #0

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

declare void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef) #0

declare noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #0

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

declare void @_ZN9Secp256K18NegationER5Point(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef nonnull align 8 dereferenceable(48)) #0

declare void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #0

declare void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #0

declare void @_ZN3Int3AddEPKS_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #0

declare i32 @bloom_check(ptr noundef, ptr noundef, i32 noundef) #0

declare void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #0

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z16bsgs_secondcheckP3IntjjS0_(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef %3) #4 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca %class.Int, align 8
  %13 = alloca %class.Point, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca %class.Point, align 8
  %17 = alloca %class.Point, align 8
  %18 = alloca %class.Point, align 8
  %19 = alloca %class.Point, align 8
  %20 = alloca [32 x i8], align 16
  %21 = alloca %class.Point, align 8
  %22 = alloca %class.Point, align 8
  %23 = alloca %class.Point, align 8
  %24 = alloca %class.Point, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store i32 0, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  store i32 0, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #5
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(16) %12)
  call void @llvm.lifetime.start.p0(i64 48, ptr %13) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %25 unwind label %80

25:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 48, ptr %16) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %16)
          to label %26 unwind label %84

26:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 48, ptr %17) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %17)
          to label %27 unwind label %88

27:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 48, ptr %18) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18)
          to label %28 unwind label %92

28:                                               ; preds = %27
  call void @llvm.lifetime.start.p0(i64 48, ptr %19) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %19)
          to label %29 unwind label %96

29:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 32, ptr %20) #5
  invoke void @_ZN3Int3SetEPKS_(ptr noundef nonnull align 8 dereferenceable(16) %12, ptr noundef @BSGS_M_double)
          to label %30 unwind label %100

30:                                               ; preds = %29
  %31 = load i32, ptr %6, align 4, !tbaa !9
  %32 = zext i32 %31 to i64
  invoke void @_ZN3Int4MultEm(ptr noundef nonnull align 8 dereferenceable(16) %12, i64 noundef %32)
          to label %33 unwind label %100

33:                                               ; preds = %30
  %34 = load ptr, ptr %5, align 8, !tbaa !5
  invoke void @_ZN3Int3AddEPKS_(ptr noundef nonnull align 8 dereferenceable(16) %12, ptr noundef %34)
          to label %35 unwind label %100

35:                                               ; preds = %33
  call void @llvm.lifetime.start.p0(i64 48, ptr %21) #5
  %36 = load ptr, ptr @secp, align 8, !tbaa !5
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind writable sret(%class.Point) align 8 %21, ptr noundef nonnull align 8 dereferenceable(393296) %36, ptr noundef %12)
          to label %37 unwind label %104

37:                                               ; preds = %35
  %38 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %13, ptr noundef nonnull align 8 dereferenceable(48) %21)
          to label %39 unwind label %108

39:                                               ; preds = %37
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %21) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %21) #5
  call void @llvm.lifetime.start.p0(i64 48, ptr %22) #5
  %40 = load ptr, ptr @secp, align 8, !tbaa !5
  invoke void @_ZN9Secp256K18NegationER5Point(ptr dead_on_unwind writable sret(%class.Point) align 8 %22, ptr noundef nonnull align 8 dereferenceable(393296) %40, ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %41 unwind label %113

41:                                               ; preds = %39
  %42 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %16, ptr noundef nonnull align 8 dereferenceable(48) %22)
          to label %43 unwind label %117

43:                                               ; preds = %41
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #5
  call void @llvm.lifetime.start.p0(i64 48, ptr %23) #5
  %44 = load ptr, ptr @secp, align 8, !tbaa !5
  %45 = load i32, ptr %7, align 4, !tbaa !9
  %46 = zext i32 %45 to i64
  %47 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @OriginalPointsBSGS, i64 noundef %46) #5
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8 %23, ptr noundef nonnull align 8 dereferenceable(393296) %44, ptr noundef nonnull align 8 dereferenceable(48) %47, ptr noundef nonnull align 8 dereferenceable(48) %16)
          to label %48 unwind label %122

48:                                               ; preds = %43
  %49 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %18, ptr noundef nonnull align 8 dereferenceable(48) %23)
          to label %50 unwind label %126

50:                                               ; preds = %48
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %23) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %23) #5
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48) %17, ptr noundef nonnull align 8 dereferenceable(48) %18)
          to label %51 unwind label %100

51:                                               ; preds = %50
  br label %52

52:                                               ; preds = %150, %51
  call void @llvm.lifetime.start.p0(i64 48, ptr %24) #5
  %53 = load ptr, ptr @secp, align 8, !tbaa !5
  %54 = load i32, ptr %9, align 4, !tbaa !9
  %55 = sext i32 %54 to i64
  %56 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP2, i64 noundef %55) #5
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8 %24, ptr noundef nonnull align 8 dereferenceable(393296) %53, ptr noundef nonnull align 8 dereferenceable(48) %17, ptr noundef nonnull align 8 dereferenceable(48) %56)
          to label %57 unwind label %131

57:                                               ; preds = %52
  %58 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef nonnull align 8 dereferenceable(48) %24)
          to label %59 unwind label %135

59:                                               ; preds = %57
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %24) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %24) #5
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48) %18, ptr noundef nonnull align 8 dereferenceable(48) %19)
          to label %60 unwind label %100

60:                                               ; preds = %59
  %61 = getelementptr inbounds %class.Point, ptr %18, i32 0, i32 0
  %62 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  invoke void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(16) %61, ptr noundef %62)
          to label %63 unwind label %100

63:                                               ; preds = %60
  %64 = load ptr, ptr @bloom_bPx2nd, align 8, !tbaa !5
  %65 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  %66 = load i8, ptr %65, align 16, !tbaa !11
  %67 = zext i8 %66 to i64
  %68 = getelementptr inbounds %struct.bloom, ptr %64, i64 %67
  %69 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  %70 = invoke i32 @bloom_check(ptr noundef %68, ptr noundef %69, i32 noundef 32)
          to label %71 unwind label %100

71:                                               ; preds = %63
  store i32 %70, ptr %11, align 4, !tbaa !9
  %72 = load i32, ptr %11, align 4, !tbaa !9
  %73 = icmp ne i32 %72, 0
  br i1 %73, label %74, label %140

74:                                               ; preds = %71
  %75 = load i32, ptr %9, align 4, !tbaa !9
  %76 = load i32, ptr %7, align 4, !tbaa !9
  %77 = load ptr, ptr %8, align 8, !tbaa !5
  %78 = invoke noundef i32 @_Z15bsgs_thirdcheckP3IntjjS0_(ptr noundef %12, i32 noundef %75, i32 noundef %76, ptr noundef %77)
          to label %79 unwind label %100

79:                                               ; preds = %74
  store i32 %78, ptr %10, align 4, !tbaa !9
  br label %140

80:                                               ; preds = %4
  %81 = landingpad { ptr, i32 }
          cleanup
  %82 = extractvalue { ptr, i32 } %81, 0
  store ptr %82, ptr %14, align 8
  %83 = extractvalue { ptr, i32 } %81, 1
  store i32 %83, ptr %15, align 4
  br label %159

84:                                               ; preds = %25
  %85 = landingpad { ptr, i32 }
          cleanup
  %86 = extractvalue { ptr, i32 } %85, 0
  store ptr %86, ptr %14, align 8
  %87 = extractvalue { ptr, i32 } %85, 1
  store i32 %87, ptr %15, align 4
  br label %158

88:                                               ; preds = %26
  %89 = landingpad { ptr, i32 }
          cleanup
  %90 = extractvalue { ptr, i32 } %89, 0
  store ptr %90, ptr %14, align 8
  %91 = extractvalue { ptr, i32 } %89, 1
  store i32 %91, ptr %15, align 4
  br label %157

92:                                               ; preds = %27
  %93 = landingpad { ptr, i32 }
          cleanup
  %94 = extractvalue { ptr, i32 } %93, 0
  store ptr %94, ptr %14, align 8
  %95 = extractvalue { ptr, i32 } %93, 1
  store i32 %95, ptr %15, align 4
  br label %156

96:                                               ; preds = %28
  %97 = landingpad { ptr, i32 }
          cleanup
  %98 = extractvalue { ptr, i32 } %97, 0
  store ptr %98, ptr %14, align 8
  %99 = extractvalue { ptr, i32 } %97, 1
  store i32 %99, ptr %15, align 4
  br label %155

100:                                              ; preds = %74, %63, %60, %59, %50, %33, %30, %29
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %14, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %15, align 4
  br label %154

104:                                              ; preds = %35
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %14, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %15, align 4
  br label %112

108:                                              ; preds = %37
  %109 = landingpad { ptr, i32 }
          cleanup
  %110 = extractvalue { ptr, i32 } %109, 0
  store ptr %110, ptr %14, align 8
  %111 = extractvalue { ptr, i32 } %109, 1
  store i32 %111, ptr %15, align 4
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %21) #5
  br label %112

112:                                              ; preds = %108, %104
  call void @llvm.lifetime.end.p0(i64 48, ptr %21) #5
  br label %154

113:                                              ; preds = %39
  %114 = landingpad { ptr, i32 }
          cleanup
  %115 = extractvalue { ptr, i32 } %114, 0
  store ptr %115, ptr %14, align 8
  %116 = extractvalue { ptr, i32 } %114, 1
  store i32 %116, ptr %15, align 4
  br label %121

117:                                              ; preds = %41
  %118 = landingpad { ptr, i32 }
          cleanup
  %119 = extractvalue { ptr, i32 } %118, 0
  store ptr %119, ptr %14, align 8
  %120 = extractvalue { ptr, i32 } %118, 1
  store i32 %120, ptr %15, align 4
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #5
  br label %121

121:                                              ; preds = %117, %113
  call void @llvm.lifetime.end.p0(i64 48, ptr %22) #5
  br label %154

122:                                              ; preds = %43
  %123 = landingpad { ptr, i32 }
          cleanup
  %124 = extractvalue { ptr, i32 } %123, 0
  store ptr %124, ptr %14, align 8
  %125 = extractvalue { ptr, i32 } %123, 1
  store i32 %125, ptr %15, align 4
  br label %130

126:                                              ; preds = %48
  %127 = landingpad { ptr, i32 }
          cleanup
  %128 = extractvalue { ptr, i32 } %127, 0
  store ptr %128, ptr %14, align 8
  %129 = extractvalue { ptr, i32 } %127, 1
  store i32 %129, ptr %15, align 4
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %23) #5
  br label %130

130:                                              ; preds = %126, %122
  call void @llvm.lifetime.end.p0(i64 48, ptr %23) #5
  br label %154

131:                                              ; preds = %52
  %132 = landingpad { ptr, i32 }
          cleanup
  %133 = extractvalue { ptr, i32 } %132, 0
  store ptr %133, ptr %14, align 8
  %134 = extractvalue { ptr, i32 } %132, 1
  store i32 %134, ptr %15, align 4
  br label %139

135:                                              ; preds = %57
  %136 = landingpad { ptr, i32 }
          cleanup
  %137 = extractvalue { ptr, i32 } %136, 0
  store ptr %137, ptr %14, align 8
  %138 = extractvalue { ptr, i32 } %136, 1
  store i32 %138, ptr %15, align 4
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %24) #5
  br label %139

139:                                              ; preds = %135, %131
  call void @llvm.lifetime.end.p0(i64 48, ptr %24) #5
  br label %154

140:                                              ; preds = %79, %71
  %141 = load i32, ptr %9, align 4, !tbaa !9
  %142 = add nsw i32 %141, 1
  store i32 %142, ptr %9, align 4, !tbaa !9
  br label %143

143:                                              ; preds = %140
  %144 = load i32, ptr %9, align 4, !tbaa !9
  %145 = icmp slt i32 %144, 32
  br i1 %145, label %146, label %150

146:                                              ; preds = %143
  %147 = load i32, ptr %10, align 4, !tbaa !9
  %148 = icmp ne i32 %147, 0
  %149 = xor i1 %148, true
  br label %150

150:                                              ; preds = %146, %143
  %151 = phi i1 [ false, %143 ], [ %149, %146 ]
  br i1 %151, label %52, label %152, !llvm.loop !12

152:                                              ; preds = %150
  %153 = load i32, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %18) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %17) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %17) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %16) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #5
  call void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  ret i32 %153

154:                                              ; preds = %139, %130, %121, %112, %100
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #5
  br label %155

155:                                              ; preds = %154, %96
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %18) #5
  br label %156

156:                                              ; preds = %155, %92
  call void @llvm.lifetime.end.p0(i64 48, ptr %18) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %17) #5
  br label %157

157:                                              ; preds = %156, %88
  call void @llvm.lifetime.end.p0(i64 48, ptr %17) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #5
  br label %158

158:                                              ; preds = %157, %84
  call void @llvm.lifetime.end.p0(i64 48, ptr %16) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  br label %159

159:                                              ; preds = %158, %80
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #5
  call void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %160

160:                                              ; preds = %159
  %161 = load ptr, ptr %14, align 8
  %162 = load i32, ptr %15, align 4
  %163 = insertvalue { ptr, i32 } poison, ptr %161, 0
  %164 = insertvalue { ptr, i32 } %163, i32 %162, 1
  resume { ptr, i32 } %164
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_Z15bsgs_thirdcheckP3IntjjS0_(ptr noundef, i32 noundef, i32 noundef, ptr noundef) #4

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl" }
%"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl" = type { %"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl_data" }
%"struct.std::_Vector_base<Point, std::allocator<Point>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Int = type { [1 x %struct.__mpz_struct] }
%struct.__mpz_struct = type { i32, i32, ptr }
%class.Point = type { %class.Int, %class.Int, %class.Int }
%struct.bloom = type { i64, i64, i64, i8, x86_fp80, i8, i8, i8, double, ptr }

@OriginalPointsBSGS = external dso_local global %"class.std::vector", align 8
@bloom_bPx2nd = external dso_local local_unnamed_addr global ptr, align 8
@BSGS_M_double = external dso_local global %class.Int, align 8
@BSGS_AMP2 = external dso_local global %"class.std::vector", align 8
@secp = external dso_local local_unnamed_addr global ptr, align 8

declare void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #1

declare void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #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) #2

declare void @_ZN3Int3SetEPKS_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) local_unnamed_addr #0

declare void @_ZN3Int4MultEm(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef) local_unnamed_addr #0

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

declare void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef) local_unnamed_addr #0

declare noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #0

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

declare void @_ZN9Secp256K18NegationER5Point(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #0

declare void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8, ptr noundef nonnull align 8 dereferenceable(393296), ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #0

declare void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #0

declare void @_ZN3Int3AddEPKS_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) local_unnamed_addr #0

declare i32 @bloom_check(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

declare void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z16bsgs_secondcheckP3IntjjS0_(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef %3) local_unnamed_addr #4 personality ptr @__gxx_personality_v0 {
  %5 = alloca %class.Int, align 8
  %6 = alloca %class.Point, align 8
  %7 = alloca %class.Point, align 8
  %8 = alloca %class.Point, align 8
  %9 = alloca %class.Point, align 8
  %10 = alloca %class.Point, align 8
  %11 = alloca [32 x i8], align 16
  %12 = alloca %class.Point, align 8
  %13 = alloca %class.Point, align 8
  %14 = alloca %class.Point, align 8
  %15 = alloca %class.Point, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #5
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(16) %5)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %6) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %6)
          to label %16 unwind label %55

16:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %7) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %7)
          to label %17 unwind label %57

17:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %8) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %8)
          to label %18 unwind label %59

18:                                               ; preds = %17
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %9) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %9)
          to label %19 unwind label %61

19:                                               ; preds = %18
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %10) #5
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(48) %10)
          to label %20 unwind label %63

20:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #5
  invoke void @_ZN3Int3SetEPKS_(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull @BSGS_M_double)
          to label %21 unwind label %.loopexit.split-lp

21:                                               ; preds = %20
  %22 = zext i32 %1 to i64
  invoke void @_ZN3Int4MultEm(ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %22)
          to label %23 unwind label %.loopexit.split-lp

23:                                               ; preds = %21
  invoke void @_ZN3Int3AddEPKS_(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef %0)
          to label %24 unwind label %.loopexit.split-lp

24:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %12) #5
  %25 = load ptr, ptr @secp, align 8, !tbaa !5
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %12, ptr noundef nonnull align 8 dereferenceable(393296) %25, ptr noundef nonnull %5)
          to label %26 unwind label %65

26:                                               ; preds = %24
  %27 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %6, ptr noundef nonnull align 8 dereferenceable(48) %12)
          to label %28 unwind label %67

28:                                               ; preds = %26
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %12) #5
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %13) #5
  %29 = load ptr, ptr @secp, align 8, !tbaa !5
  invoke void @_ZN9Secp256K18NegationER5Point(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %13, ptr noundef nonnull align 8 dereferenceable(393296) %29, ptr noundef nonnull align 8 dereferenceable(48) %6)
          to label %30 unwind label %70

30:                                               ; preds = %28
  %31 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %7, ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %32 unwind label %72

32:                                               ; preds = %30
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %13) #5
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %14) #5
  %33 = load ptr, ptr @secp, align 8, !tbaa !5
  %34 = zext i32 %2 to i64
  %35 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @OriginalPointsBSGS, i64 noundef %34) #5
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %14, ptr noundef nonnull align 8 dereferenceable(393296) %33, ptr noundef nonnull align 8 dereferenceable(48) %35, ptr noundef nonnull align 8 dereferenceable(48) %7)
          to label %36 unwind label %75

36:                                               ; preds = %32
  %37 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %9, ptr noundef nonnull align 8 dereferenceable(48) %14)
          to label %38 unwind label %77

38:                                               ; preds = %36
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %14) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %14) #5
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(48) %9)
          to label %.preheader unwind label %.loopexit.split-lp

.preheader:                                       ; preds = %38, %85
  %indvars.iv = phi i64 [ %indvars.iv.next, %85 ], [ 0, %38 ]
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %15) #5
  %39 = load ptr, ptr @secp, align 8, !tbaa !5
  %40 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP2, i64 noundef %indvars.iv) #5
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %15, ptr noundef nonnull align 8 dereferenceable(393296) %39, ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(48) %40)
          to label %41 unwind label %80

41:                                               ; preds = %.preheader
  %42 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZN5PointaSERKS_(ptr noundef nonnull align 8 dereferenceable(48) %10, ptr noundef nonnull align 8 dereferenceable(48) %15)
          to label %43 unwind label %82

43:                                               ; preds = %41
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %15) #5
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(48) %9, ptr noundef nonnull align 8 dereferenceable(48) %10)
          to label %44 unwind label %.loopexit

44:                                               ; preds = %43
  invoke void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull %11)
          to label %45 unwind label %.loopexit

45:                                               ; preds = %44
  %46 = load ptr, ptr @bloom_bPx2nd, align 8, !tbaa !5
  %47 = load i8, ptr %11, align 16, !tbaa !9
  %48 = zext i8 %47 to i64
  %49 = getelementptr inbounds %struct.bloom, ptr %46, i64 %48
  %50 = invoke i32 @bloom_check(ptr noundef %49, ptr noundef nonnull %11, i32 noundef 32)
          to label %51 unwind label %.loopexit

51:                                               ; preds = %45
  %.not = icmp eq i32 %50, 0
  br i1 %.not, label %85, label %52

52:                                               ; preds = %51
  %53 = trunc nuw nsw i64 %indvars.iv to i32
  %54 = invoke noundef i32 @_Z15bsgs_thirdcheckP3IntjjS0_(ptr noundef nonnull %5, i32 noundef %53, i32 noundef %2, ptr noundef %3)
          to label %85 unwind label %.loopexit

55:                                               ; preds = %4
  %56 = landingpad { ptr, i32 }
          cleanup
  br label %94

57:                                               ; preds = %16
  %58 = landingpad { ptr, i32 }
          cleanup
  br label %93

59:                                               ; preds = %17
  %60 = landingpad { ptr, i32 }
          cleanup
  br label %92

61:                                               ; preds = %18
  %62 = landingpad { ptr, i32 }
          cleanup
  br label %91

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

.loopexit:                                        ; preds = %43, %44, %45, %52
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %89

.loopexit.split-lp:                               ; preds = %20, %21, %23, %38
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %89

65:                                               ; preds = %24
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %69

67:                                               ; preds = %26
  %68 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #5
  br label %69

69:                                               ; preds = %67, %65
  %.pn = phi { ptr, i32 } [ %68, %67 ], [ %66, %65 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %12) #5
  br label %89

70:                                               ; preds = %28
  %71 = landingpad { ptr, i32 }
          cleanup
  br label %74

72:                                               ; preds = %30
  %73 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #5
  br label %74

74:                                               ; preds = %72, %70
  %.pn28 = phi { ptr, i32 } [ %73, %72 ], [ %71, %70 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %13) #5
  br label %89

75:                                               ; preds = %32
  %76 = landingpad { ptr, i32 }
          cleanup
  br label %79

77:                                               ; preds = %36
  %78 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %14) #5
  br label %79

79:                                               ; preds = %77, %75
  %.pn30 = phi { ptr, i32 } [ %78, %77 ], [ %76, %75 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %14) #5
  br label %89

80:                                               ; preds = %.preheader
  %81 = landingpad { ptr, i32 }
          cleanup
  br label %84

82:                                               ; preds = %41
  %83 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %15) #5
  br label %84

84:                                               ; preds = %82, %80
  %.pn32 = phi { ptr, i32 } [ %83, %82 ], [ %81, %80 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %15) #5
  br label %89

85:                                               ; preds = %52, %51
  %.124 = phi i32 [ 0, %51 ], [ %54, %52 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %86 = icmp ult i64 %indvars.iv, 31
  %.not41 = icmp eq i32 %.124, 0
  %87 = and i1 %86, %.not41
  br i1 %87, label %.preheader, label %88, !llvm.loop !10

88:                                               ; preds = %85
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %10) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %8) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %6) #5
  call void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #5
  ret i32 %.124

89:                                               ; preds = %.loopexit, %.loopexit.split-lp, %84, %79, %74, %69
  %.pn34 = phi { ptr, i32 } [ %.pn32, %84 ], [ %.pn30, %79 ], [ %.pn28, %74 ], [ %.pn, %69 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %10) #5
  br label %90

90:                                               ; preds = %89, %63
  %.pn34.pn = phi { ptr, i32 } [ %.pn34, %89 ], [ %64, %63 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %9) #5
  br label %91

91:                                               ; preds = %90, %61
  %.pn34.pn.pn = phi { ptr, i32 } [ %.pn34.pn, %90 ], [ %62, %61 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %9) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  br label %92

92:                                               ; preds = %91, %59
  %.pn34.pn.pn.pn = phi { ptr, i32 } [ %.pn34.pn.pn, %91 ], [ %60, %59 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %8) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #5
  br label %93

93:                                               ; preds = %92, %57
  %.pn34.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn34.pn.pn.pn, %92 ], [ %58, %57 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #5
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(48) %6) #5
  br label %94

94:                                               ; preds = %93, %55
  %.pn34.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn34.pn.pn.pn.pn, %93 ], [ %56, %55 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %6) #5
  call void @_ZN3IntD1Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #5
  resume { ptr, i32 } %.pn34.pn.pn.pn.pn.pn
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_Z15bsgs_thirdcheckP3IntjjS0_(ptr noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

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

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

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


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,LCSSAPass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass