; LLVM IR from albertobsd/keyhunt :: bsgsd.ll (Z15bsgs_thirdcheckP3IntjS0_)

; 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.Point = type { %class.Int, %class.Int, %class.Int }
%class.Int = type { %union.anon }
%union.anon = type { [5 x i64] }
%"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 }
%struct.bloom = type { i64, i64, i64, i8, x86_fp80, i8, i8, i8, double, ptr }

@OriginalPointsBSGS = external dso_local global %class.Point, align 8
@bPtable = external dso_local global ptr, align 8
@bloom_bPx3rd = external dso_local global ptr, align 8
@bsgs_m3 = external dso_local global i64, align 8
@BSGS_M2_double = external dso_local global %class.Int, align 8
@BSGS_AMP3 = 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(120)) unnamed_addr #0

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

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

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

declare i32 @__gxx_personality_v0(...)

declare void @_ZN3Int8SetInt32Ej(ptr noundef nonnull align 8 dereferenceable(40), i32 noundef) #0

declare void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) #0

declare void @_ZN3Int4MultEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) #0

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

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

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

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

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

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

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

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

declare void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) #0

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_Z15bsgs_thirdcheckP3IntjS0_(ptr noundef %0, i32 noundef %1, ptr noundef %2) #5 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca %class.Int, align 8
  %12 = alloca %class.Int, align 8
  %13 = alloca %class.Point, align 8
  %14 = alloca %class.Point, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %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
  %25 = alloca %class.Point, align 8
  %26 = alloca %class.Point, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !9
  store ptr %2, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  store i64 0, ptr %7, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  store i32 0, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 40, ptr %11) #6
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(40) %11)
  call void @llvm.lifetime.start.p0(i64 40, ptr %12) #6
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(40) %12)
  call void @llvm.lifetime.start.p0(i64 120, ptr %13) #6
  call void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(120) %13)
  call void @llvm.lifetime.start.p0(i64 120, ptr %14) #6
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(120) %14)
          to label %27 unwind label %88

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

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

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

30:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 32, ptr %20) #6
  %31 = load i32, ptr %5, align 4, !tbaa !9
  invoke void @_ZN3Int8SetInt32Ej(ptr noundef nonnull align 8 dereferenceable(40) %11, i32 noundef %31)
          to label %32 unwind label %104

32:                                               ; preds = %30
  invoke void @_ZN3Int4MultEPS_(ptr noundef nonnull align 8 dereferenceable(40) %11, ptr noundef @BSGS_M2_double)
          to label %33 unwind label %104

33:                                               ; preds = %32
  %34 = load ptr, ptr %4, align 8, !tbaa !5
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %11, ptr noundef %34)
          to label %35 unwind label %104

35:                                               ; preds = %33
  call void @llvm.lifetime.start.p0(i64 120, ptr %21) #6
  %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(983240) %36, ptr noundef %11)
          to label %37 unwind label %108

37:                                               ; preds = %35
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %13, ptr align 8 %21, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %21) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %21) #6
  call void @llvm.lifetime.start.p0(i64 120, ptr %22) #6
  %38 = 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(983240) %38, ptr noundef nonnull align 8 dereferenceable(120) %13)
          to label %39 unwind label %112

39:                                               ; preds = %37
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %14, ptr align 8 %22, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %22) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 120, ptr %23) #6
  %40 = load ptr, ptr @secp, align 8, !tbaa !5
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8 %23, ptr noundef nonnull align 8 dereferenceable(983240) %40, ptr noundef nonnull align 8 dereferenceable(120) @OriginalPointsBSGS, ptr noundef nonnull align 8 dereferenceable(120) %14)
          to label %41 unwind label %116

41:                                               ; preds = %39
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %18, ptr align 8 %23, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %23) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %23) #6
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(120) %17, ptr noundef nonnull align 8 dereferenceable(120) %18)
          to label %42 unwind label %104

42:                                               ; preds = %41
  br label %43

43:                                               ; preds = %179, %42
  call void @llvm.lifetime.start.p0(i64 120, ptr %24) #6
  %44 = load ptr, ptr @secp, align 8, !tbaa !5
  %45 = load i32, ptr %8, align 4, !tbaa !9
  %46 = sext i32 %45 to i64
  %47 = call noundef nonnull align 8 dereferenceable(120) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP3, i64 noundef %46) #6
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind writable sret(%class.Point) align 8 %24, ptr noundef nonnull align 8 dereferenceable(983240) %44, ptr noundef nonnull align 8 dereferenceable(120) %17, ptr noundef nonnull align 8 dereferenceable(120) %47)
          to label %48 unwind label %120

48:                                               ; preds = %43
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %24, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %24) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %24) #6
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(120) %18, ptr noundef nonnull align 8 dereferenceable(120) %19)
          to label %49 unwind label %104

49:                                               ; preds = %48
  %50 = getelementptr inbounds %class.Point, ptr %18, i32 0, i32 0
  %51 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  invoke void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(40) %50, ptr noundef %51)
          to label %52 unwind label %104

52:                                               ; preds = %49
  %53 = load ptr, ptr @bloom_bPx3rd, align 8, !tbaa !5
  %54 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  %55 = load i8, ptr %54, align 16, !tbaa !14
  %56 = zext i8 %55 to i64
  %57 = getelementptr inbounds %struct.bloom, ptr %53, i64 %56
  %58 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  %59 = invoke i32 @bloom_check(ptr noundef %57, ptr noundef %58, i32 noundef 32)
          to label %60 unwind label %104

60:                                               ; preds = %52
  store i32 %59, ptr %10, align 4, !tbaa !9
  %61 = load i32, ptr %10, align 4, !tbaa !9
  %62 = icmp ne i32 %61, 0
  br i1 %62, label %63, label %153

63:                                               ; preds = %60
  %64 = load ptr, ptr @bPtable, align 8, !tbaa !5
  %65 = getelementptr inbounds [32 x i8], ptr %20, i64 0, i64 0
  %66 = load i64, ptr @bsgs_m3, align 8, !tbaa !11
  %67 = call noundef i32 @_Z17bsgs_searchbinaryP11bsgs_xvaluePclPm(ptr noundef %64, ptr noundef %65, i64 noundef %66, ptr noundef %7)
  store i32 %67, ptr %10, align 4, !tbaa !9
  %68 = load i32, ptr %10, align 4, !tbaa !9
  %69 = icmp ne i32 %68, 0
  br i1 %69, label %70, label %152

70:                                               ; preds = %63
  %71 = load i32, ptr %8, align 4, !tbaa !9
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %71, ptr noundef %12)
          to label %72 unwind label %104

72:                                               ; preds = %70
  %73 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %73, ptr noundef %12)
          to label %74 unwind label %104

74:                                               ; preds = %72
  %75 = load ptr, ptr %6, align 8, !tbaa !5
  %76 = load i64, ptr %7, align 8, !tbaa !11
  %77 = add i64 %76, 1
  invoke void @_ZN3Int3AddEm(ptr noundef nonnull align 8 dereferenceable(40) %75, i64 noundef %77)
          to label %78 unwind label %104

78:                                               ; preds = %74
  %79 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %79, ptr noundef %11)
          to label %80 unwind label %104

80:                                               ; preds = %78
  call void @llvm.lifetime.start.p0(i64 120, ptr %25) #6
  %81 = load ptr, ptr @secp, align 8, !tbaa !5
  %82 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind writable sret(%class.Point) align 8 %25, ptr noundef nonnull align 8 dereferenceable(983240) %81, ptr noundef %82)
          to label %83 unwind label %124

83:                                               ; preds = %80
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %14, ptr align 8 %25, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %25) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %25) #6
  %84 = getelementptr inbounds %class.Point, ptr %14, i32 0, i32 0
  %85 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %84, ptr noundef @OriginalPointsBSGS)
          to label %86 unwind label %104

86:                                               ; preds = %83
  br i1 %85, label %87, label %128

87:                                               ; preds = %86
  store i32 1, ptr %9, align 4, !tbaa !9
  br label %151

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

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

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

100:                                              ; preds = %29
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %15, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %16, align 4
  br label %184

104:                                              ; preds = %165, %163, %161, %153, %141, %136, %132, %130, %128, %83, %78, %74, %72, %70, %52, %49, %48, %41, %33, %32, %30
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %15, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %16, align 4
  br label %183

108:                                              ; preds = %35
  %109 = landingpad { ptr, i32 }
          cleanup
  %110 = extractvalue { ptr, i32 } %109, 0
  store ptr %110, ptr %15, align 8
  %111 = extractvalue { ptr, i32 } %109, 1
  store i32 %111, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %21) #6
  br label %183

112:                                              ; preds = %37
  %113 = landingpad { ptr, i32 }
          cleanup
  %114 = extractvalue { ptr, i32 } %113, 0
  store ptr %114, ptr %15, align 8
  %115 = extractvalue { ptr, i32 } %113, 1
  store i32 %115, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %22) #6
  br label %183

116:                                              ; preds = %39
  %117 = landingpad { ptr, i32 }
          cleanup
  %118 = extractvalue { ptr, i32 } %117, 0
  store ptr %118, ptr %15, align 8
  %119 = extractvalue { ptr, i32 } %117, 1
  store i32 %119, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %23) #6
  br label %183

120:                                              ; preds = %43
  %121 = landingpad { ptr, i32 }
          cleanup
  %122 = extractvalue { ptr, i32 } %121, 0
  store ptr %122, ptr %15, align 8
  %123 = extractvalue { ptr, i32 } %121, 1
  store i32 %123, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %24) #6
  br label %183

124:                                              ; preds = %80
  %125 = landingpad { ptr, i32 }
          cleanup
  %126 = extractvalue { ptr, i32 } %125, 0
  store ptr %126, ptr %15, align 8
  %127 = extractvalue { ptr, i32 } %125, 1
  store i32 %127, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %25) #6
  br label %183

128:                                              ; preds = %86
  %129 = load i32, ptr %8, align 4, !tbaa !9
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %129, ptr noundef %12)
          to label %130 unwind label %104

130:                                              ; preds = %128
  %131 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %131, ptr noundef %12)
          to label %132 unwind label %104

132:                                              ; preds = %130
  %133 = load ptr, ptr %6, align 8, !tbaa !5
  %134 = load i64, ptr %7, align 8, !tbaa !11
  %135 = add i64 %134, 1
  invoke void @_ZN3Int3SubEm(ptr noundef nonnull align 8 dereferenceable(40) %133, i64 noundef %135)
          to label %136 unwind label %104

136:                                              ; preds = %132
  %137 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %137, ptr noundef %11)
          to label %138 unwind label %104

138:                                              ; preds = %136
  call void @llvm.lifetime.start.p0(i64 120, ptr %26) #6
  %139 = load ptr, ptr @secp, align 8, !tbaa !5
  %140 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind writable sret(%class.Point) align 8 %26, ptr noundef nonnull align 8 dereferenceable(983240) %139, ptr noundef %140)
          to label %141 unwind label %146

141:                                              ; preds = %138
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %14, ptr align 8 %26, i64 120, i1 false), !tbaa.struct !13
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %26) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %26) #6
  %142 = getelementptr inbounds %class.Point, ptr %14, i32 0, i32 0
  %143 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %142, ptr noundef @OriginalPointsBSGS)
          to label %144 unwind label %104

144:                                              ; preds = %141
  br i1 %143, label %145, label %150

145:                                              ; preds = %144
  store i32 1, ptr %9, align 4, !tbaa !9
  br label %150

146:                                              ; preds = %138
  %147 = landingpad { ptr, i32 }
          cleanup
  %148 = extractvalue { ptr, i32 } %147, 0
  store ptr %148, ptr %15, align 8
  %149 = extractvalue { ptr, i32 } %147, 1
  store i32 %149, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 120, ptr %26) #6
  br label %183

150:                                              ; preds = %145, %144
  br label %151

151:                                              ; preds = %150, %87
  br label %152

152:                                              ; preds = %151, %63
  br label %169

153:                                              ; preds = %60
  %154 = getelementptr inbounds %class.Point, ptr %17, i32 0, i32 0
  %155 = load i32, ptr %8, align 4, !tbaa !9
  %156 = sext i32 %155 to i64
  %157 = call noundef nonnull align 8 dereferenceable(120) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP3, i64 noundef %156) #6
  %158 = getelementptr inbounds %class.Point, ptr %157, i32 0, i32 0
  %159 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %154, ptr noundef %158)
          to label %160 unwind label %104

160:                                              ; preds = %153
  br i1 %159, label %161, label %168

161:                                              ; preds = %160
  %162 = load i32, ptr %8, align 4, !tbaa !9
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %162, ptr noundef %12)
          to label %163 unwind label %104

163:                                              ; preds = %161
  %164 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %164, ptr noundef %12)
          to label %165 unwind label %104

165:                                              ; preds = %163
  %166 = load ptr, ptr %6, align 8, !tbaa !5
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %166, ptr noundef %11)
          to label %167 unwind label %104

167:                                              ; preds = %165
  store i32 1, ptr %9, align 4, !tbaa !9
  br label %168

168:                                              ; preds = %167, %160
  br label %169

169:                                              ; preds = %168, %152
  %170 = load i32, ptr %8, align 4, !tbaa !9
  %171 = add nsw i32 %170, 1
  store i32 %171, ptr %8, align 4, !tbaa !9
  br label %172

172:                                              ; preds = %169
  %173 = load i32, ptr %8, align 4, !tbaa !9
  %174 = icmp slt i32 %173, 32
  br i1 %174, label %175, label %179

175:                                              ; preds = %172
  %176 = load i32, ptr %9, align 4, !tbaa !9
  %177 = icmp ne i32 %176, 0
  %178 = xor i1 %177, true
  br label %179

179:                                              ; preds = %175, %172
  %180 = phi i1 [ false, %172 ], [ %178, %175 ]
  br i1 %180, label %43, label %181, !llvm.loop !15

181:                                              ; preds = %179
  %182 = load i32, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %19) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %19) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %18) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %18) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %17) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %17) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %14) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %14) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %13) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  ret i32 %182

183:                                              ; preds = %146, %124, %120, %116, %112, %108, %104
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %19) #6
  br label %184

184:                                              ; preds = %183, %100
  call void @llvm.lifetime.end.p0(i64 120, ptr %19) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %18) #6
  br label %185

185:                                              ; preds = %184, %96
  call void @llvm.lifetime.end.p0(i64 120, ptr %18) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %17) #6
  br label %186

186:                                              ; preds = %185, %92
  call void @llvm.lifetime.end.p0(i64 120, ptr %17) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %14) #6
  br label %187

187:                                              ; preds = %186, %88
  call void @llvm.lifetime.end.p0(i64 120, ptr %14) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %13) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  br label %188

188:                                              ; preds = %187
  %189 = load ptr, ptr %15, align 8
  %190 = load i32, ptr %16, align 4
  %191 = insertvalue { ptr, i32 } poison, ptr %189, 0
  %192 = insertvalue { ptr, i32 } %191, i32 %190, 1
  resume { ptr, i32 } %192
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z14calcualteindexiP3Int(i32 noundef, ptr noundef) #5

declare void @_ZN3Int3AddEm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) #0

declare noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) #0

declare void @_ZN3Int3SubEm(ptr noundef nonnull align 8 dereferenceable(40), i64 noundef) #0

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

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

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


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

%class.Point = type { %class.Int, %class.Int, %class.Int }
%class.Int = type { %union.anon }
%union.anon = type { [5 x i64] }
%"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 }
%struct.bloom = type { i64, i64, i64, i8, x86_fp80, i8, i8, i8, double, ptr }

@OriginalPointsBSGS = external dso_local global %class.Point, align 8
@bPtable = external dso_local local_unnamed_addr global ptr, align 8
@bloom_bPx3rd = external dso_local local_unnamed_addr global ptr, align 8
@bsgs_m3 = external dso_local local_unnamed_addr global i64, align 8
@BSGS_M2_double = external dso_local global %class.Int, align 8
@BSGS_AMP3 = 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(120)) unnamed_addr #0

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

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

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

declare i32 @__gxx_personality_v0(...)

declare void @_ZN3Int8SetInt32Ej(ptr noundef nonnull align 8 dereferenceable(40), i32 noundef) local_unnamed_addr #0

declare void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) local_unnamed_addr #0

declare void @_ZN3Int4MultEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) local_unnamed_addr #0

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

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

; Function Attrs: 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(983240), ptr noundef nonnull align 8 dereferenceable(120)) local_unnamed_addr #0

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

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

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

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

declare void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) local_unnamed_addr #0

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef range(i32 0, 2) i32 @_Z15bsgs_thirdcheckP3IntjS0_(ptr noundef %0, i32 noundef %1, ptr noundef %2) local_unnamed_addr #5 personality ptr @__gxx_personality_v0 {
  %4 = alloca i64, align 8
  %5 = alloca %class.Int, align 8
  %6 = alloca %class.Int, 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 %class.Point, align 8
  %12 = alloca [32 x i8], align 16
  %13 = alloca %class.Point, align 8
  %14 = alloca %class.Point, align 8
  %15 = alloca %class.Point, align 8
  %16 = alloca %class.Point, align 8
  %17 = alloca %class.Point, align 8
  %18 = alloca %class.Point, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #6
  store i64 0, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #6
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(40) %5)
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %6) #6
  call void @_ZN3IntC1Ev(ptr noundef nonnull align 8 dereferenceable(40) %6)
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %7) #6
  call void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(120) %7)
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %8) #6
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(120) %8)
          to label %19 unwind label %59

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

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

21:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %11) #6
  invoke void @_ZN5PointC1Ev(ptr noundef nonnull align 8 dereferenceable(120) %11)
          to label %22 unwind label %65

22:                                               ; preds = %21
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %12) #6
  invoke void @_ZN3Int8SetInt32Ej(ptr noundef nonnull align 8 dereferenceable(40) %5, i32 noundef %1)
          to label %23 unwind label %.loopexit.split-lp

23:                                               ; preds = %22
  invoke void @_ZN3Int4MultEPS_(ptr noundef nonnull align 8 dereferenceable(40) %5, ptr noundef nonnull @BSGS_M2_double)
          to label %24 unwind label %.loopexit.split-lp

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

25:                                               ; preds = %24
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %13) #6
  %26 = load ptr, ptr @secp, align 8, !tbaa !9
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %13, ptr noundef nonnull align 8 dereferenceable(983240) %26, ptr noundef nonnull %5)
          to label %27 unwind label %67

27:                                               ; preds = %25
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %7, ptr noundef nonnull align 8 dereferenceable(120) %13, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %13) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %13) #6
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %14) #6
  %28 = load ptr, ptr @secp, align 8, !tbaa !9
  invoke void @_ZN9Secp256K18NegationER5Point(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %14, ptr noundef nonnull align 8 dereferenceable(983240) %28, ptr noundef nonnull align 8 dereferenceable(120) %7)
          to label %29 unwind label %69

29:                                               ; preds = %27
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %8, ptr noundef nonnull align 8 dereferenceable(120) %14, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %14) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %14) #6
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %15) #6
  %30 = load ptr, ptr @secp, align 8, !tbaa !9
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %15, ptr noundef nonnull align 8 dereferenceable(983240) %30, ptr noundef nonnull align 8 dereferenceable(120) @OriginalPointsBSGS, ptr noundef nonnull align 8 dereferenceable(120) %8)
          to label %31 unwind label %71

31:                                               ; preds = %29
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %10, ptr noundef nonnull align 8 dereferenceable(120) %15, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %15) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %15) #6
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(120) %9, ptr noundef nonnull align 8 dereferenceable(120) %10)
          to label %.preheader unwind label %.loopexit.split-lp

.preheader:                                       ; preds = %31, %98
  %indvars.iv = phi i64 [ %indvars.iv.next, %98 ], [ 0, %31 ]
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %16) #6
  %32 = load ptr, ptr @secp, align 8, !tbaa !9
  %33 = call noundef nonnull align 8 dereferenceable(120) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP3, i64 noundef %indvars.iv) #6
  invoke void @_ZN9Secp256K19AddDirectER5PointS1_(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %16, ptr noundef nonnull align 8 dereferenceable(983240) %32, ptr noundef nonnull align 8 dereferenceable(120) %9, ptr noundef nonnull align 8 dereferenceable(120) %33)
          to label %34 unwind label %73

34:                                               ; preds = %.preheader
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %11, ptr noundef nonnull align 8 dereferenceable(120) %16, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %16) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %16) #6
  invoke void @_ZN5Point3SetERS_(ptr noundef nonnull align 8 dereferenceable(120) %10, ptr noundef nonnull align 8 dereferenceable(120) %11)
          to label %35 unwind label %.loopexit

35:                                               ; preds = %34
  invoke void @_ZN3Int10Get32BytesEPh(ptr noundef nonnull align 8 dereferenceable(40) %10, ptr noundef nonnull %12)
          to label %36 unwind label %.loopexit

36:                                               ; preds = %35
  %37 = load ptr, ptr @bloom_bPx3rd, align 8, !tbaa !9
  %38 = load i8, ptr %12, align 16, !tbaa !12
  %39 = zext i8 %38 to i64
  %40 = getelementptr inbounds %struct.bloom, ptr %37, i64 %39
  %41 = invoke i32 @bloom_check(ptr noundef %40, ptr noundef nonnull %12, i32 noundef 32)
          to label %42 unwind label %.loopexit

42:                                               ; preds = %36
  %.not = icmp eq i32 %41, 0
  br i1 %.not, label %90, label %43

43:                                               ; preds = %42
  %44 = load ptr, ptr @bPtable, align 8, !tbaa !9
  %45 = load i64, ptr @bsgs_m3, align 8, !tbaa !5
  %46 = call noundef i32 @_Z17bsgs_searchbinaryP11bsgs_xvaluePclPm(ptr noundef %44, ptr noundef nonnull %12, i64 noundef %45, ptr noundef nonnull %4)
  %.not33 = icmp eq i32 %46, 0
  br i1 %.not33, label %98, label %47

47:                                               ; preds = %43
  %48 = trunc nuw nsw i64 %indvars.iv to i32
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %48, ptr noundef nonnull %6)
          to label %49 unwind label %.loopexit

49:                                               ; preds = %47
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %6)
          to label %50 unwind label %.loopexit

50:                                               ; preds = %49
  %51 = load i64, ptr %4, align 8, !tbaa !5
  %52 = add i64 %51, 1
  invoke void @_ZN3Int3AddEm(ptr noundef nonnull align 8 dereferenceable(40) %2, i64 noundef %52)
          to label %53 unwind label %.loopexit

53:                                               ; preds = %50
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %5)
          to label %54 unwind label %.loopexit

54:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %17) #6
  %55 = load ptr, ptr @secp, align 8, !tbaa !9
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %17, ptr noundef nonnull align 8 dereferenceable(983240) %55, ptr noundef nonnull %2)
          to label %56 unwind label %75

56:                                               ; preds = %54
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %8, ptr noundef nonnull align 8 dereferenceable(120) %17, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %17) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %17) #6
  %57 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %8, ptr noundef nonnull @OriginalPointsBSGS)
          to label %58 unwind label %.loopexit

58:                                               ; preds = %56
  br i1 %57, label %.thread, label %77

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

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

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

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

.loopexit:                                        ; preds = %34, %35, %36, %47, %49, %50, %53, %56, %77, %78, %79, %82, %85, %90
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %101

.loopexit.split-lp:                               ; preds = %22, %23, %24, %31, %94, %96, %97
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %101

67:                                               ; preds = %25
  %68 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %13) #6
  br label %101

69:                                               ; preds = %27
  %70 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %14) #6
  br label %101

71:                                               ; preds = %29
  %72 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %15) #6
  br label %101

73:                                               ; preds = %.preheader
  %74 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %16) #6
  br label %101

75:                                               ; preds = %54
  %76 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %17) #6
  br label %101

77:                                               ; preds = %58
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %48, ptr noundef nonnull %6)
          to label %78 unwind label %.loopexit

78:                                               ; preds = %77
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %6)
          to label %79 unwind label %.loopexit

79:                                               ; preds = %78
  %80 = load i64, ptr %4, align 8, !tbaa !5
  %81 = add i64 %80, 1
  invoke void @_ZN3Int3SubEm(ptr noundef nonnull align 8 dereferenceable(40) %2, i64 noundef %81)
          to label %82 unwind label %.loopexit

82:                                               ; preds = %79
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %5)
          to label %83 unwind label %.loopexit

83:                                               ; preds = %82
  call void @llvm.lifetime.start.p0(i64 120, ptr nonnull %18) #6
  %84 = load ptr, ptr @secp, align 8, !tbaa !9
  invoke void @_ZN9Secp256K116ComputePublicKeyEP3Int(ptr dead_on_unwind nonnull writable sret(%class.Point) align 8 %18, ptr noundef nonnull align 8 dereferenceable(983240) %84, ptr noundef nonnull %2)
          to label %85 unwind label %88

85:                                               ; preds = %83
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(120) %8, ptr noundef nonnull align 8 dereferenceable(120) %18, i64 120, i1 false), !tbaa.struct !11
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %18) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %18) #6
  %86 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %8, ptr noundef nonnull @OriginalPointsBSGS)
          to label %87 unwind label %.loopexit

87:                                               ; preds = %85
  %spec.select = zext i1 %86 to i32
  br label %98

88:                                               ; preds = %83
  %89 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %18) #6
  br label %101

90:                                               ; preds = %42
  %91 = call noundef nonnull align 8 dereferenceable(120) ptr @_ZNSt6vectorI5PointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) @BSGS_AMP3, i64 noundef %indvars.iv) #6
  %92 = invoke noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40) %9, ptr noundef nonnull %91)
          to label %93 unwind label %.loopexit

93:                                               ; preds = %90
  br i1 %92, label %94, label %98

94:                                               ; preds = %93
  %95 = trunc nuw nsw i64 %indvars.iv to i32
  invoke void @_Z14calcualteindexiP3Int(i32 noundef %95, ptr noundef nonnull %6)
          to label %96 unwind label %.loopexit.split-lp

96:                                               ; preds = %94
  invoke void @_ZN3Int3SetEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %6)
          to label %97 unwind label %.loopexit.split-lp

97:                                               ; preds = %96
  invoke void @_ZN3Int3AddEPS_(ptr noundef nonnull align 8 dereferenceable(40) %2, ptr noundef nonnull %5)
          to label %.thread unwind label %.loopexit.split-lp

98:                                               ; preds = %87, %93, %43
  %.130 = phi i32 [ 0, %43 ], [ 0, %93 ], [ %spec.select, %87 ]
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %99 = icmp ult i64 %indvars.iv, 31
  %.not39 = icmp eq i32 %.130, 0
  %100 = and i1 %99, %.not39
  br i1 %100, label %.preheader, label %.thread, !llvm.loop !13

.thread:                                          ; preds = %58, %98, %97
  %.13042 = phi i32 [ 1, %97 ], [ 1, %58 ], [ %.130, %98 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %12) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %11) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %11) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %10) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %10) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %9) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %9) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %8) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %8) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %7) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  ret i32 %.13042

101:                                              ; preds = %.loopexit, %.loopexit.split-lp, %88, %75, %73, %71, %69, %67
  %.pn = phi { ptr, i32 } [ %89, %88 ], [ %76, %75 ], [ %74, %73 ], [ %72, %71 ], [ %70, %69 ], [ %68, %67 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %12) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %11) #6
  br label %102

102:                                              ; preds = %101, %65
  %.pn.pn = phi { ptr, i32 } [ %.pn, %101 ], [ %66, %65 ]
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %11) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %10) #6
  br label %103

103:                                              ; preds = %102, %63
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %102 ], [ %64, %63 ]
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %10) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %9) #6
  br label %104

104:                                              ; preds = %103, %61
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %103 ], [ %62, %61 ]
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %9) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %8) #6
  br label %105

105:                                              ; preds = %104, %59
  %.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn, %104 ], [ %60, %59 ]
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %8) #6
  call void @_ZN5PointD1Ev(ptr noundef nonnull align 8 dereferenceable(120) %7) #6
  call void @llvm.lifetime.end.p0(i64 120, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  resume { ptr, i32 } %.pn.pn.pn.pn.pn
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z14calcualteindexiP3Int(i32 noundef, ptr noundef) local_unnamed_addr #5

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

declare noundef zeroext i1 @_ZN3Int7IsEqualEPS_(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) local_unnamed_addr #0

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

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

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

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


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