; LLVM IR from intel/cryptography-primitives :: sources/ippcp (pcpdlpsetkeypair)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct._cpDLP = type { i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct._cpBigNum = type { i32, i32, i32, i32, ptr, ptr }
%struct._gsModEngine = type { ptr, i32, i32, i32, i32, i32, ptr, ptr, ptr, i64, ptr, ptr, ptr, ptr, i32, i32, ptr }

; Function Attrs: nounwind uwtable
define dso_local i32 @ippsDLPSetKeyPair(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %19 = load ptr, ptr %7, align 8, !tbaa !5
  %20 = icmp eq ptr null, %19
  br i1 %20, label %21, label %22

21:                                               ; preds = %3
  store i32 -8, ptr %4, align 4
  br label %158

22:                                               ; preds = %3
  %23 = load ptr, ptr %7, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct._cpDLP, ptr %23, i32 0, i32 0
  %25 = load i32, ptr %24, align 8, !tbaa !9
  %26 = load ptr, ptr %7, align 8, !tbaa !5
  %27 = call i64 @IPP_UINT_PTR(ptr noundef %26)
  %28 = trunc i64 %27 to i32
  %29 = xor i32 %25, %28
  %30 = icmp eq i32 %29, 541346896
  br i1 %30, label %32, label %31

31:                                               ; preds = %22
  store i32 -13, ptr %4, align 4
  br label %158

32:                                               ; preds = %22
  %33 = load ptr, ptr %7, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct._cpDLP, ptr %33, i32 0, i32 1
  %35 = load i32, ptr %34, align 4, !tbaa !12
  %36 = icmp eq i32 %35, 7
  br i1 %36, label %38, label %37

37:                                               ; preds = %32
  store i32 -1013, ptr %4, align 4
  br label %158

38:                                               ; preds = %32
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  %40 = icmp ne ptr %39, null
  br i1 %40, label %41, label %99

41:                                               ; preds = %38
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct._cpBigNum, ptr %42, i32 0, i32 0
  %44 = load i32, ptr %43, align 8, !tbaa !13
  %45 = load ptr, ptr %5, align 8, !tbaa !5
  %46 = call i64 @IPP_UINT_PTR(ptr noundef %45)
  %47 = trunc i64 %46 to i32
  %48 = xor i32 %44, %47
  %49 = icmp eq i32 %48, 1112098638
  br i1 %49, label %51, label %50

50:                                               ; preds = %41
  store i32 -13, ptr %4, align 4
  br label %158

51:                                               ; preds = %41
  %52 = load ptr, ptr %5, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct._cpBigNum, ptr %52, i32 0, i32 1
  %54 = load i32, ptr %53, align 4, !tbaa !15
  %55 = icmp eq i32 %54, 0
  br i1 %55, label %56, label %57

56:                                               ; preds = %51
  store i32 -1008, ptr %4, align 4
  br label %158

57:                                               ; preds = %51
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #3
  %58 = load ptr, ptr %7, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct._cpDLP, ptr %58, i32 0, i32 7
  %60 = load ptr, ptr %59, align 8, !tbaa !16
  store ptr %60, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #3
  %61 = load ptr, ptr %8, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct._gsModEngine, ptr %61, i32 0, i32 8
  %63 = load ptr, ptr %62, align 8, !tbaa !17
  store ptr %63, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  %64 = load ptr, ptr %8, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct._gsModEngine, ptr %64, i32 0, i32 3
  %66 = load i32, ptr %65, align 8, !tbaa !20
  store i32 %66, ptr %10, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #3
  %67 = load ptr, ptr %5, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct._cpBigNum, ptr %67, i32 0, i32 4
  %69 = load ptr, ptr %68, align 8, !tbaa !22
  store ptr %69, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  %70 = load ptr, ptr %5, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct._cpBigNum, ptr %70, i32 0, i32 2
  %72 = load i32, ptr %71, align 8, !tbaa !23
  store i32 %72, ptr %12, align 4, !tbaa !21
  %73 = load ptr, ptr %11, align 8, !tbaa !5
  %74 = load i32, ptr %12, align 4, !tbaa !21
  %75 = call i32 @cpEqu_BNU_CHUNK(ptr noundef %73, i32 noundef %74, i64 noundef 0)
  %76 = icmp ne i32 %75, 0
  br i1 %76, label %84, label %77

77:                                               ; preds = %57
  %78 = load ptr, ptr %11, align 8, !tbaa !5
  %79 = load i32, ptr %12, align 4, !tbaa !21
  %80 = load ptr, ptr %9, align 8, !tbaa !5
  %81 = load i32, ptr %10, align 4, !tbaa !21
  %82 = call i32 @cpCmp_BNU(ptr noundef %78, i32 noundef %79, ptr noundef %80, i32 noundef %81)
  %83 = icmp sle i32 0, %82
  br i1 %83, label %84, label %85

84:                                               ; preds = %77, %57
  store i32 -1008, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %96

85:                                               ; preds = %77
  %86 = load ptr, ptr %7, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct._cpDLP, ptr %86, i32 0, i32 9
  %88 = load ptr, ptr %87, align 8, !tbaa !24
  %89 = load ptr, ptr %5, align 8, !tbaa !5
  %90 = call ptr @cpBN_copy(ptr noundef %88, ptr noundef %89)
  %91 = load i32, ptr %10, align 4, !tbaa !21
  %92 = load ptr, ptr %7, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct._cpDLP, ptr %92, i32 0, i32 9
  %94 = load ptr, ptr %93, align 8, !tbaa !24
  %95 = getelementptr inbounds %struct._cpBigNum, ptr %94, i32 0, i32 2
  store i32 %91, ptr %95, align 8, !tbaa !23
  store i32 0, ptr %13, align 4
  br label %96

96:                                               ; preds = %85, %84
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  %97 = load i32, ptr %13, align 4
  switch i32 %97, label %160 [
    i32 0, label %98
    i32 1, label %158
  ]

98:                                               ; preds = %96
  br label %99

99:                                               ; preds = %98, %38
  %100 = load ptr, ptr %6, align 8, !tbaa !5
  %101 = icmp ne ptr %100, null
  br i1 %101, label %102, label %157

102:                                              ; preds = %99
  %103 = load ptr, ptr %6, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct._cpBigNum, ptr %103, i32 0, i32 0
  %105 = load i32, ptr %104, align 8, !tbaa !13
  %106 = load ptr, ptr %6, align 8, !tbaa !5
  %107 = call i64 @IPP_UINT_PTR(ptr noundef %106)
  %108 = trunc i64 %107 to i32
  %109 = xor i32 %105, %108
  %110 = icmp eq i32 %109, 1112098638
  br i1 %110, label %112, label %111

111:                                              ; preds = %102
  store i32 -13, ptr %4, align 4
  br label %158

112:                                              ; preds = %102
  %113 = load ptr, ptr %6, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct._cpBigNum, ptr %113, i32 0, i32 1
  %115 = load i32, ptr %114, align 4, !tbaa !15
  %116 = icmp eq i32 %115, 0
  br i1 %116, label %117, label %118

117:                                              ; preds = %112
  store i32 -7, ptr %4, align 4
  br label %158

118:                                              ; preds = %112
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  %119 = load ptr, ptr %7, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct._cpDLP, ptr %119, i32 0, i32 5
  %121 = load ptr, ptr %120, align 8, !tbaa !25
  store ptr %121, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  %122 = load ptr, ptr %14, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct._gsModEngine, ptr %122, i32 0, i32 8
  %124 = load ptr, ptr %123, align 8, !tbaa !17
  store ptr %124, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #3
  %125 = load ptr, ptr %14, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct._gsModEngine, ptr %125, i32 0, i32 3
  %127 = load i32, ptr %126, align 8, !tbaa !20
  store i32 %127, ptr %16, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  %128 = load ptr, ptr %6, align 8, !tbaa !5
  %129 = getelementptr inbounds %struct._cpBigNum, ptr %128, i32 0, i32 4
  %130 = load ptr, ptr %129, align 8, !tbaa !22
  store ptr %130, ptr %17, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #3
  %131 = load ptr, ptr %6, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct._cpBigNum, ptr %131, i32 0, i32 2
  %133 = load i32, ptr %132, align 8, !tbaa !23
  store i32 %133, ptr %18, align 4, !tbaa !21
  %134 = load ptr, ptr %17, align 8, !tbaa !5
  %135 = load i32, ptr %18, align 4, !tbaa !21
  %136 = call i32 @cpEqu_BNU_CHUNK(ptr noundef %134, i32 noundef %135, i64 noundef 0)
  %137 = icmp ne i32 %136, 0
  br i1 %137, label %145, label %138

138:                                              ; preds = %118
  %139 = load ptr, ptr %17, align 8, !tbaa !5
  %140 = load i32, ptr %18, align 4, !tbaa !21
  %141 = load ptr, ptr %15, align 8, !tbaa !5
  %142 = load i32, ptr %16, align 4, !tbaa !21
  %143 = call i32 @cpCmp_BNU(ptr noundef %139, i32 noundef %140, ptr noundef %141, i32 noundef %142)
  %144 = icmp sle i32 0, %143
  br i1 %144, label %145, label %146

145:                                              ; preds = %138, %118
  store i32 -7, ptr %4, align 4
  store i32 1, ptr %13, align 4
  br label %154

146:                                              ; preds = %138
  %147 = load ptr, ptr %7, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct._cpDLP, ptr %147, i32 0, i32 10
  %149 = load ptr, ptr %148, align 8, !tbaa !26
  %150 = load ptr, ptr %6, align 8, !tbaa !5
  %151 = load ptr, ptr %7, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct._cpDLP, ptr %151, i32 0, i32 5
  %153 = load ptr, ptr %152, align 8, !tbaa !25
  call void @cpMontEnc_BN(ptr noundef %149, ptr noundef %150, ptr noundef %153)
  store i32 0, ptr %13, align 4
  br label %154

154:                                              ; preds = %146, %145
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  %155 = load i32, ptr %13, align 4
  switch i32 %155, label %160 [
    i32 0, label %156
    i32 1, label %158
  ]

156:                                              ; preds = %154
  br label %157

157:                                              ; preds = %156, %99
  store i32 0, ptr %4, align 4
  br label %158

158:                                              ; preds = %157, %154, %117, %111, %96, %56, %50, %37, %31, %21
  %159 = load i32, ptr %4, align 4
  ret i32 %159

160:                                              ; preds = %154, %96
  unreachable
}

; Function Attrs: inlinehint nounwind uwtable
declare hidden i64 @IPP_UINT_PTR(ptr noundef) #1

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

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @cpEqu_BNU_CHUNK(ptr noundef, i32 noundef, i64 noundef) #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @cpCmp_BNU(ptr noundef, i32 noundef, ptr noundef, i32 noundef) #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @cpBN_copy(ptr noundef, ptr noundef) #1

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

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @cpMontEnc_BN(ptr noundef, ptr noundef, ptr noundef) #1

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"_cpDLP", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !11, i64 4}
!13 = !{!14, !11, i64 0}
!14 = !{!"_cpBigNum", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !6, i64 16, !6, i64 24}
!15 = !{!14, !11, i64 4}
!16 = !{!10, !6, i64 40}
!17 = !{!18, !6, i64 48}
!18 = !{!"_gsModEngine", !6, i64 0, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !11, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !19, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !11, i64 96, !11, i64 100, !6, i64 104}
!19 = !{!"long long", !7, i64 0}
!20 = !{!18, !11, i64 16}
!21 = !{!11, !11, i64 0}
!22 = !{!14, !6, i64 16}
!23 = !{!14, !11, i64 8}
!24 = !{!10, !6, i64 56}
!25 = !{!10, !6, i64 24}
!26 = !{!10, !6, i64 64}


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

; Function Attrs: nounwind uwtable
define dso_local range(i32 -1013, 1) i32 @ippsDLPSetKeyPair(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #0 {
  %4 = icmp eq ptr %2, null
  br i1 %4, label %.thread, label %5

5:                                                ; preds = %3
  %6 = load i32, ptr %2, align 8, !tbaa !5
  %7 = tail call i64 @IPP_UINT_PTR(ptr noundef nonnull %2)
  %8 = trunc i64 %7 to i32
  %9 = xor i32 %6, %8
  %10 = icmp eq i32 %9, 541346896
  br i1 %10, label %11, label %.thread

11:                                               ; preds = %5
  %12 = getelementptr inbounds i8, ptr %2, i64 4
  %13 = load i32, ptr %12, align 4, !tbaa !11
  %14 = icmp eq i32 %13, 7
  br i1 %14, label %15, label %.thread

15:                                               ; preds = %11
  %.not = icmp eq ptr %0, null
  br i1 %.not, label %47, label %16

16:                                               ; preds = %15
  %17 = load i32, ptr %0, align 8, !tbaa !12
  %18 = tail call i64 @IPP_UINT_PTR(ptr noundef nonnull %0)
  %19 = trunc i64 %18 to i32
  %20 = xor i32 %17, %19
  %21 = icmp eq i32 %20, 1112098638
  br i1 %21, label %22, label %.thread

22:                                               ; preds = %16
  %23 = getelementptr inbounds i8, ptr %0, i64 4
  %24 = load i32, ptr %23, align 4, !tbaa !14
  %25 = icmp eq i32 %24, 0
  br i1 %25, label %.thread, label %26

26:                                               ; preds = %22
  %27 = getelementptr inbounds i8, ptr %2, i64 40
  %28 = load ptr, ptr %27, align 8, !tbaa !15
  %29 = getelementptr inbounds i8, ptr %28, i64 48
  %30 = load ptr, ptr %29, align 8, !tbaa !16
  %31 = getelementptr inbounds i8, ptr %28, i64 16
  %32 = load i32, ptr %31, align 8, !tbaa !19
  %33 = getelementptr inbounds i8, ptr %0, i64 16
  %34 = load ptr, ptr %33, align 8, !tbaa !20
  %35 = getelementptr inbounds i8, ptr %0, i64 8
  %36 = load i32, ptr %35, align 8, !tbaa !21
  %37 = tail call i32 @cpEqu_BNU_CHUNK(ptr noundef %34, i32 noundef %36, i64 noundef 0)
  %.not47 = icmp eq i32 %37, 0
  br i1 %.not47, label %38, label %.thread

38:                                               ; preds = %26
  %39 = tail call i32 @cpCmp_BNU(ptr noundef %34, i32 noundef %36, ptr noundef %30, i32 noundef %32)
  %40 = icmp sgt i32 %39, -1
  br i1 %40, label %.thread, label %41

41:                                               ; preds = %38
  %42 = getelementptr inbounds i8, ptr %2, i64 56
  %43 = load ptr, ptr %42, align 8, !tbaa !22
  %44 = tail call ptr @cpBN_copy(ptr noundef %43, ptr noundef nonnull %0)
  %45 = load ptr, ptr %42, align 8, !tbaa !22
  %46 = getelementptr inbounds i8, ptr %45, i64 8
  store i32 %32, ptr %46, align 8, !tbaa !21
  br label %47

47:                                               ; preds = %41, %15
  %.not48 = icmp eq ptr %1, null
  br i1 %.not48, label %.thread, label %48

48:                                               ; preds = %47
  %49 = load i32, ptr %1, align 8, !tbaa !12
  %50 = tail call i64 @IPP_UINT_PTR(ptr noundef nonnull %1)
  %51 = trunc i64 %50 to i32
  %52 = xor i32 %49, %51
  %53 = icmp eq i32 %52, 1112098638
  br i1 %53, label %54, label %.thread

54:                                               ; preds = %48
  %55 = getelementptr inbounds i8, ptr %1, i64 4
  %56 = load i32, ptr %55, align 4, !tbaa !14
  %57 = icmp eq i32 %56, 0
  br i1 %57, label %.thread, label %58

58:                                               ; preds = %54
  %59 = getelementptr inbounds i8, ptr %2, i64 24
  %60 = load ptr, ptr %59, align 8, !tbaa !23
  %61 = getelementptr inbounds i8, ptr %60, i64 48
  %62 = load ptr, ptr %61, align 8, !tbaa !16
  %63 = getelementptr inbounds i8, ptr %60, i64 16
  %64 = load i32, ptr %63, align 8, !tbaa !19
  %65 = getelementptr inbounds i8, ptr %1, i64 16
  %66 = load ptr, ptr %65, align 8, !tbaa !20
  %67 = getelementptr inbounds i8, ptr %1, i64 8
  %68 = load i32, ptr %67, align 8, !tbaa !21
  %69 = tail call i32 @cpEqu_BNU_CHUNK(ptr noundef %66, i32 noundef %68, i64 noundef 0)
  %.not49 = icmp eq i32 %69, 0
  br i1 %.not49, label %70, label %.thread

70:                                               ; preds = %58
  %71 = tail call i32 @cpCmp_BNU(ptr noundef %66, i32 noundef %68, ptr noundef %62, i32 noundef %64)
  %72 = icmp sgt i32 %71, -1
  br i1 %72, label %.thread, label %73

73:                                               ; preds = %70
  %74 = getelementptr inbounds i8, ptr %2, i64 64
  %75 = load ptr, ptr %74, align 8, !tbaa !24
  %76 = load ptr, ptr %59, align 8, !tbaa !23
  tail call void @cpMontEnc_BN(ptr noundef %75, ptr noundef nonnull %1, ptr noundef %76)
  br label %.thread

.thread:                                          ; preds = %58, %70, %26, %38, %47, %73, %54, %48, %22, %16, %11, %5, %3
  %.3 = phi i32 [ -8, %3 ], [ -13, %5 ], [ -1013, %11 ], [ -13, %16 ], [ -1008, %22 ], [ -13, %48 ], [ -7, %54 ], [ 0, %73 ], [ 0, %47 ], [ -1008, %38 ], [ -1008, %26 ], [ -7, %70 ], [ -7, %58 ]
  ret i32 %.3
}

; Function Attrs: inlinehint nounwind uwtable
declare hidden i64 @IPP_UINT_PTR(ptr noundef) local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @cpEqu_BNU_CHUNK(ptr noundef, i32 noundef, i64 noundef) local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @cpCmp_BNU(ptr noundef, i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden ptr @cpBN_copy(ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @cpMontEnc_BN(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { inlinehint 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" }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 0}
!6 = !{!"_cpDLP", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!6, !7, i64 4}
!12 = !{!13, !7, i64 0}
!13 = !{!"_cpBigNum", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !10, i64 16, !10, i64 24}
!14 = !{!13, !7, i64 4}
!15 = !{!6, !10, i64 40}
!16 = !{!17, !10, i64 48}
!17 = !{!"_gsModEngine", !10, i64 0, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !18, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !7, i64 96, !7, i64 100, !10, i64 104}
!18 = !{!"long long", !8, i64 0}
!19 = !{!17, !7, i64 16}
!20 = !{!13, !10, i64 16}
!21 = !{!13, !7, i64 8}
!22 = !{!6, !10, i64 56}
!23 = !{!6, !10, i64 24}
!24 = !{!6, !10, i64 64}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass