; LLVM IR from openssl/openssl :: crypto/modes (ocb128)

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

%union.OCB_BLOCK = type { [2 x i64] }
%struct.ocb128_context = type { ptr, ptr, ptr, ptr, ptr, i64, i64, %union.OCB_BLOCK, %union.OCB_BLOCK, ptr, %struct.anon }
%struct.anon = type { i64, i64, %union.OCB_BLOCK, %union.OCB_BLOCK, %union.OCB_BLOCK, %union.OCB_BLOCK }

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

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

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

; 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) #2

; Function Attrs: nounwind uwtable
declare hidden void @ocb_block_xor(ptr noundef, ptr noundef, i64 noundef, ptr noundef) #3

; Function Attrs: nounwind uwtable
declare hidden ptr @ocb_lookup_l(ptr noundef, i64 noundef) #3

; Function Attrs: nounwind uwtable
declare hidden i32 @ocb_ntz(i64 noundef) #3

; Function Attrs: nounwind uwtable
define dso_local i32 @CRYPTO_ocb128_encrypt(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3) #3 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca i64, align 8
  %11 = alloca i64, align 8
  %12 = alloca i64, align 8
  %13 = alloca i64, align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i32, align 4
  %17 = alloca ptr, align 8
  %18 = alloca %union.OCB_BLOCK, align 8
  %19 = alloca %union.OCB_BLOCK, align 8
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store i64 %3, ptr %9, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  %20 = load i64, ptr %9, align 8, !tbaa !9
  %21 = udiv i64 %20, 16
  store i64 %21, ptr %12, align 8, !tbaa !9
  %22 = load i64, ptr %12, align 8, !tbaa !9
  %23 = load ptr, ptr %6, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.ocb128_context, ptr %23, i32 0, i32 10
  %25 = getelementptr inbounds %struct.anon, ptr %24, i32 0, i32 1
  %26 = load i64, ptr %25, align 8, !tbaa !11
  %27 = add i64 %22, %26
  store i64 %27, ptr %11, align 8, !tbaa !15
  %28 = load i64, ptr %12, align 8, !tbaa !9
  %29 = icmp ne i64 %28, 0
  br i1 %29, label %30, label %83

30:                                               ; preds = %4
  %31 = load i64, ptr %11, align 8, !tbaa !15
  %32 = load i64, ptr %11, align 8, !tbaa !15
  %33 = icmp eq i64 %31, %32
  br i1 %33, label %34, label %83

34:                                               ; preds = %30
  %35 = load ptr, ptr %6, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.ocb128_context, ptr %35, i32 0, i32 4
  %37 = load ptr, ptr %36, align 8, !tbaa !16
  %38 = icmp ne ptr %37, null
  br i1 %38, label %39, label %83

39:                                               ; preds = %34
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  store i64 0, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %40 = load i64, ptr %11, align 8, !tbaa !15
  store i64 %40, ptr %15, align 8, !tbaa !9
  br label %41

41:                                               ; preds = %45, %39
  %42 = load i64, ptr %15, align 8, !tbaa !9
  %43 = lshr i64 %42, 1
  store i64 %43, ptr %15, align 8, !tbaa !9
  %44 = icmp ne i64 %43, 0
  br i1 %44, label %45, label %48

45:                                               ; preds = %41
  %46 = load i64, ptr %14, align 8, !tbaa !9
  %47 = add i64 %46, 1
  store i64 %47, ptr %14, align 8, !tbaa !9
  br label %41, !llvm.loop !17

48:                                               ; preds = %41
  %49 = load ptr, ptr %6, align 8, !tbaa !5
  %50 = load i64, ptr %14, align 8, !tbaa !9
  %51 = call ptr @ocb_lookup_l(ptr noundef %49, i64 noundef %50)
  %52 = icmp eq ptr %51, null
  br i1 %52, label %53, label %54

53:                                               ; preds = %48
  store i32 0, ptr %5, align 4
  store i32 1, ptr %16, align 4
  br label %80

54:                                               ; preds = %48
  %55 = load ptr, ptr %6, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.ocb128_context, ptr %55, i32 0, i32 4
  %57 = load ptr, ptr %56, align 8, !tbaa !16
  %58 = load ptr, ptr %7, align 8, !tbaa !5
  %59 = load ptr, ptr %8, align 8, !tbaa !5
  %60 = load i64, ptr %12, align 8, !tbaa !9
  %61 = load ptr, ptr %6, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.ocb128_context, ptr %61, i32 0, i32 2
  %63 = load ptr, ptr %62, align 8, !tbaa !19
  %64 = load ptr, ptr %6, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct.ocb128_context, ptr %64, i32 0, i32 10
  %66 = getelementptr inbounds %struct.anon, ptr %65, i32 0, i32 1
  %67 = load i64, ptr %66, align 8, !tbaa !11
  %68 = add i64 %67, 1
  %69 = load ptr, ptr %6, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.ocb128_context, ptr %69, i32 0, i32 10
  %71 = getelementptr inbounds %struct.anon, ptr %70, i32 0, i32 4
  %72 = getelementptr inbounds [16 x i8], ptr %71, i64 0, i64 0
  %73 = load ptr, ptr %6, align 8, !tbaa !5
  %74 = getelementptr inbounds %struct.ocb128_context, ptr %73, i32 0, i32 9
  %75 = load ptr, ptr %74, align 8, !tbaa !20
  %76 = load ptr, ptr %6, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.ocb128_context, ptr %76, i32 0, i32 10
  %78 = getelementptr inbounds %struct.anon, ptr %77, i32 0, i32 5
  %79 = getelementptr inbounds [16 x i8], ptr %78, i64 0, i64 0
  call void %57(ptr noundef %58, ptr noundef %59, i64 noundef %60, ptr noundef %63, i64 noundef %68, ptr noundef %72, ptr noundef %75, ptr noundef %79)
  store i32 0, ptr %16, align 4
  br label %80

80:                                               ; preds = %54, %53
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  %81 = load i32, ptr %16, align 4
  switch i32 %81, label %296 [
    i32 0, label %82
  ]

82:                                               ; preds = %80
  br label %212

83:                                               ; preds = %34, %30, %4
  %84 = load ptr, ptr %6, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.ocb128_context, ptr %84, i32 0, i32 10
  %86 = getelementptr inbounds %struct.anon, ptr %85, i32 0, i32 1
  %87 = load i64, ptr %86, align 8, !tbaa !11
  %88 = add i64 %87, 1
  store i64 %88, ptr %10, align 8, !tbaa !15
  br label %89

89:                                               ; preds = %208, %83
  %90 = load i64, ptr %10, align 8, !tbaa !15
  %91 = load i64, ptr %11, align 8, !tbaa !15
  %92 = icmp ule i64 %90, %91
  br i1 %92, label %93, label %211

93:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #4
  %94 = load ptr, ptr %6, align 8, !tbaa !5
  %95 = load i64, ptr %10, align 8, !tbaa !15
  %96 = call i32 @ocb_ntz(i64 noundef %95)
  %97 = zext i32 %96 to i64
  %98 = call ptr @ocb_lookup_l(ptr noundef %94, i64 noundef %97)
  store ptr %98, ptr %17, align 8, !tbaa !5
  %99 = load ptr, ptr %17, align 8, !tbaa !5
  %100 = icmp eq ptr %99, null
  br i1 %100, label %101, label %102

101:                                              ; preds = %93
  store i32 0, ptr %5, align 4
  store i32 1, ptr %16, align 4
  br label %205

102:                                              ; preds = %93
  %103 = load ptr, ptr %6, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.ocb128_context, ptr %103, i32 0, i32 10
  %105 = getelementptr inbounds %struct.anon, ptr %104, i32 0, i32 4
  %106 = getelementptr inbounds [2 x i64], ptr %105, i64 0, i64 0
  %107 = load i64, ptr %106, align 8, !tbaa !21
  %108 = load ptr, ptr %17, align 8, !tbaa !5
  %109 = getelementptr inbounds [2 x i64], ptr %108, i64 0, i64 0
  %110 = load i64, ptr %109, align 8, !tbaa !21
  %111 = xor i64 %107, %110
  %112 = load ptr, ptr %6, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.ocb128_context, ptr %112, i32 0, i32 10
  %114 = getelementptr inbounds %struct.anon, ptr %113, i32 0, i32 4
  %115 = getelementptr inbounds [2 x i64], ptr %114, i64 0, i64 0
  store i64 %111, ptr %115, align 8, !tbaa !21
  %116 = load ptr, ptr %6, align 8, !tbaa !5
  %117 = getelementptr inbounds %struct.ocb128_context, ptr %116, i32 0, i32 10
  %118 = getelementptr inbounds %struct.anon, ptr %117, i32 0, i32 4
  %119 = getelementptr inbounds [2 x i64], ptr %118, i64 0, i64 1
  %120 = load i64, ptr %119, align 8, !tbaa !21
  %121 = load ptr, ptr %17, align 8, !tbaa !5
  %122 = getelementptr inbounds [2 x i64], ptr %121, i64 0, i64 1
  %123 = load i64, ptr %122, align 8, !tbaa !21
  %124 = xor i64 %120, %123
  %125 = load ptr, ptr %6, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.ocb128_context, ptr %125, i32 0, i32 10
  %127 = getelementptr inbounds %struct.anon, ptr %126, i32 0, i32 4
  %128 = getelementptr inbounds [2 x i64], ptr %127, i64 0, i64 1
  store i64 %124, ptr %128, align 8, !tbaa !21
  %129 = getelementptr inbounds [16 x i8], ptr %18, i64 0, i64 0
  %130 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %129, ptr align 1 %130, i64 16, i1 false)
  %131 = load ptr, ptr %7, align 8, !tbaa !5
  %132 = getelementptr inbounds i8, ptr %131, i64 16
  store ptr %132, ptr %7, align 8, !tbaa !5
  %133 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 0
  %134 = load i64, ptr %133, align 8, !tbaa !21
  %135 = load ptr, ptr %6, align 8, !tbaa !5
  %136 = getelementptr inbounds %struct.ocb128_context, ptr %135, i32 0, i32 10
  %137 = getelementptr inbounds %struct.anon, ptr %136, i32 0, i32 5
  %138 = getelementptr inbounds [2 x i64], ptr %137, i64 0, i64 0
  %139 = load i64, ptr %138, align 8, !tbaa !21
  %140 = xor i64 %134, %139
  %141 = load ptr, ptr %6, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.ocb128_context, ptr %141, i32 0, i32 10
  %143 = getelementptr inbounds %struct.anon, ptr %142, i32 0, i32 5
  %144 = getelementptr inbounds [2 x i64], ptr %143, i64 0, i64 0
  store i64 %140, ptr %144, align 8, !tbaa !21
  %145 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 1
  %146 = load i64, ptr %145, align 8, !tbaa !21
  %147 = load ptr, ptr %6, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.ocb128_context, ptr %147, i32 0, i32 10
  %149 = getelementptr inbounds %struct.anon, ptr %148, i32 0, i32 5
  %150 = getelementptr inbounds [2 x i64], ptr %149, i64 0, i64 1
  %151 = load i64, ptr %150, align 8, !tbaa !21
  %152 = xor i64 %146, %151
  %153 = load ptr, ptr %6, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct.ocb128_context, ptr %153, i32 0, i32 10
  %155 = getelementptr inbounds %struct.anon, ptr %154, i32 0, i32 5
  %156 = getelementptr inbounds [2 x i64], ptr %155, i64 0, i64 1
  store i64 %152, ptr %156, align 8, !tbaa !21
  %157 = load ptr, ptr %6, align 8, !tbaa !5
  %158 = getelementptr inbounds %struct.ocb128_context, ptr %157, i32 0, i32 10
  %159 = getelementptr inbounds %struct.anon, ptr %158, i32 0, i32 4
  %160 = getelementptr inbounds [2 x i64], ptr %159, i64 0, i64 0
  %161 = load i64, ptr %160, align 8, !tbaa !21
  %162 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 0
  %163 = load i64, ptr %162, align 8, !tbaa !21
  %164 = xor i64 %161, %163
  %165 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 0
  store i64 %164, ptr %165, align 8, !tbaa !21
  %166 = load ptr, ptr %6, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.ocb128_context, ptr %166, i32 0, i32 10
  %168 = getelementptr inbounds %struct.anon, ptr %167, i32 0, i32 4
  %169 = getelementptr inbounds [2 x i64], ptr %168, i64 0, i64 1
  %170 = load i64, ptr %169, align 8, !tbaa !21
  %171 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 1
  %172 = load i64, ptr %171, align 8, !tbaa !21
  %173 = xor i64 %170, %172
  %174 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 1
  store i64 %173, ptr %174, align 8, !tbaa !21
  %175 = load ptr, ptr %6, align 8, !tbaa !5
  %176 = getelementptr inbounds %struct.ocb128_context, ptr %175, i32 0, i32 0
  %177 = load ptr, ptr %176, align 8, !tbaa !22
  %178 = getelementptr inbounds [16 x i8], ptr %18, i64 0, i64 0
  %179 = getelementptr inbounds [16 x i8], ptr %18, i64 0, i64 0
  %180 = load ptr, ptr %6, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.ocb128_context, ptr %180, i32 0, i32 2
  %182 = load ptr, ptr %181, align 8, !tbaa !19
  call void %177(ptr noundef %178, ptr noundef %179, ptr noundef %182)
  %183 = load ptr, ptr %6, align 8, !tbaa !5
  %184 = getelementptr inbounds %struct.ocb128_context, ptr %183, i32 0, i32 10
  %185 = getelementptr inbounds %struct.anon, ptr %184, i32 0, i32 4
  %186 = getelementptr inbounds [2 x i64], ptr %185, i64 0, i64 0
  %187 = load i64, ptr %186, align 8, !tbaa !21
  %188 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 0
  %189 = load i64, ptr %188, align 8, !tbaa !21
  %190 = xor i64 %187, %189
  %191 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 0
  store i64 %190, ptr %191, align 8, !tbaa !21
  %192 = load ptr, ptr %6, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.ocb128_context, ptr %192, i32 0, i32 10
  %194 = getelementptr inbounds %struct.anon, ptr %193, i32 0, i32 4
  %195 = getelementptr inbounds [2 x i64], ptr %194, i64 0, i64 1
  %196 = load i64, ptr %195, align 8, !tbaa !21
  %197 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 1
  %198 = load i64, ptr %197, align 8, !tbaa !21
  %199 = xor i64 %196, %198
  %200 = getelementptr inbounds [2 x i64], ptr %18, i64 0, i64 1
  store i64 %199, ptr %200, align 8, !tbaa !21
  %201 = load ptr, ptr %8, align 8, !tbaa !5
  %202 = getelementptr inbounds [16 x i8], ptr %18, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %201, ptr align 8 %202, i64 16, i1 false)
  %203 = load ptr, ptr %8, align 8, !tbaa !5
  %204 = getelementptr inbounds i8, ptr %203, i64 16
  store ptr %204, ptr %8, align 8, !tbaa !5
  store i32 0, ptr %16, align 4
  br label %205

205:                                              ; preds = %102, %101
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  %206 = load i32, ptr %16, align 4
  switch i32 %206, label %296 [
    i32 0, label %207
  ]

207:                                              ; preds = %205
  br label %208

208:                                              ; preds = %207
  %209 = load i64, ptr %10, align 8, !tbaa !15
  %210 = add i64 %209, 1
  store i64 %210, ptr %10, align 8, !tbaa !15
  br label %89, !llvm.loop !23

211:                                              ; preds = %89
  br label %212

212:                                              ; preds = %211, %82
  %213 = load i64, ptr %9, align 8, !tbaa !9
  %214 = urem i64 %213, 16
  store i64 %214, ptr %13, align 8, !tbaa !9
  %215 = load i64, ptr %13, align 8, !tbaa !9
  %216 = icmp ugt i64 %215, 0
  br i1 %216, label %217, label %291

217:                                              ; preds = %212
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #4
  %218 = load ptr, ptr %6, align 8, !tbaa !5
  %219 = getelementptr inbounds %struct.ocb128_context, ptr %218, i32 0, i32 10
  %220 = getelementptr inbounds %struct.anon, ptr %219, i32 0, i32 4
  %221 = getelementptr inbounds [2 x i64], ptr %220, i64 0, i64 0
  %222 = load i64, ptr %221, align 8, !tbaa !21
  %223 = load ptr, ptr %6, align 8, !tbaa !5
  %224 = getelementptr inbounds %struct.ocb128_context, ptr %223, i32 0, i32 7
  %225 = getelementptr inbounds [2 x i64], ptr %224, i64 0, i64 0
  %226 = load i64, ptr %225, align 8, !tbaa !21
  %227 = xor i64 %222, %226
  %228 = load ptr, ptr %6, align 8, !tbaa !5
  %229 = getelementptr inbounds %struct.ocb128_context, ptr %228, i32 0, i32 10
  %230 = getelementptr inbounds %struct.anon, ptr %229, i32 0, i32 4
  %231 = getelementptr inbounds [2 x i64], ptr %230, i64 0, i64 0
  store i64 %227, ptr %231, align 8, !tbaa !21
  %232 = load ptr, ptr %6, align 8, !tbaa !5
  %233 = getelementptr inbounds %struct.ocb128_context, ptr %232, i32 0, i32 10
  %234 = getelementptr inbounds %struct.anon, ptr %233, i32 0, i32 4
  %235 = getelementptr inbounds [2 x i64], ptr %234, i64 0, i64 1
  %236 = load i64, ptr %235, align 8, !tbaa !21
  %237 = load ptr, ptr %6, align 8, !tbaa !5
  %238 = getelementptr inbounds %struct.ocb128_context, ptr %237, i32 0, i32 7
  %239 = getelementptr inbounds [2 x i64], ptr %238, i64 0, i64 1
  %240 = load i64, ptr %239, align 8, !tbaa !21
  %241 = xor i64 %236, %240
  %242 = load ptr, ptr %6, align 8, !tbaa !5
  %243 = getelementptr inbounds %struct.ocb128_context, ptr %242, i32 0, i32 10
  %244 = getelementptr inbounds %struct.anon, ptr %243, i32 0, i32 4
  %245 = getelementptr inbounds [2 x i64], ptr %244, i64 0, i64 1
  store i64 %241, ptr %245, align 8, !tbaa !21
  %246 = load ptr, ptr %6, align 8, !tbaa !5
  %247 = getelementptr inbounds %struct.ocb128_context, ptr %246, i32 0, i32 0
  %248 = load ptr, ptr %247, align 8, !tbaa !22
  %249 = load ptr, ptr %6, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct.ocb128_context, ptr %249, i32 0, i32 10
  %251 = getelementptr inbounds %struct.anon, ptr %250, i32 0, i32 4
  %252 = getelementptr inbounds [16 x i8], ptr %251, i64 0, i64 0
  %253 = getelementptr inbounds [16 x i8], ptr %19, i64 0, i64 0
  %254 = load ptr, ptr %6, align 8, !tbaa !5
  %255 = getelementptr inbounds %struct.ocb128_context, ptr %254, i32 0, i32 2
  %256 = load ptr, ptr %255, align 8, !tbaa !19
  call void %248(ptr noundef %252, ptr noundef %253, ptr noundef %256)
  %257 = load ptr, ptr %7, align 8, !tbaa !5
  %258 = getelementptr inbounds [16 x i8], ptr %19, i64 0, i64 0
  %259 = load i64, ptr %13, align 8, !tbaa !9
  %260 = load ptr, ptr %8, align 8, !tbaa !5
  call void @ocb_block_xor(ptr noundef %257, ptr noundef %258, i64 noundef %259, ptr noundef %260)
  %261 = getelementptr inbounds [16 x i8], ptr %19, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 8 %261, i8 0, i64 16, i1 false)
  %262 = getelementptr inbounds [16 x i8], ptr %19, i64 0, i64 0
  %263 = load ptr, ptr %7, align 8, !tbaa !5
  %264 = load i64, ptr %13, align 8, !tbaa !9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %262, ptr align 1 %263, i64 %264, i1 false)
  %265 = load i64, ptr %13, align 8, !tbaa !9
  %266 = getelementptr inbounds [16 x i8], ptr %19, i64 0, i64 %265
  store i8 -128, ptr %266, align 1, !tbaa !21
  %267 = getelementptr inbounds [2 x i64], ptr %19, i64 0, i64 0
  %268 = load i64, ptr %267, align 8, !tbaa !21
  %269 = load ptr, ptr %6, align 8, !tbaa !5
  %270 = getelementptr inbounds %struct.ocb128_context, ptr %269, i32 0, i32 10
  %271 = getelementptr inbounds %struct.anon, ptr %270, i32 0, i32 5
  %272 = getelementptr inbounds [2 x i64], ptr %271, i64 0, i64 0
  %273 = load i64, ptr %272, align 8, !tbaa !21
  %274 = xor i64 %268, %273
  %275 = load ptr, ptr %6, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.ocb128_context, ptr %275, i32 0, i32 10
  %277 = getelementptr inbounds %struct.anon, ptr %276, i32 0, i32 5
  %278 = getelementptr inbounds [2 x i64], ptr %277, i64 0, i64 0
  store i64 %274, ptr %278, align 8, !tbaa !21
  %279 = getelementptr inbounds [2 x i64], ptr %19, i64 0, i64 1
  %280 = load i64, ptr %279, align 8, !tbaa !21
  %281 = load ptr, ptr %6, align 8, !tbaa !5
  %282 = getelementptr inbounds %struct.ocb128_context, ptr %281, i32 0, i32 10
  %283 = getelementptr inbounds %struct.anon, ptr %282, i32 0, i32 5
  %284 = getelementptr inbounds [2 x i64], ptr %283, i64 0, i64 1
  %285 = load i64, ptr %284, align 8, !tbaa !21
  %286 = xor i64 %280, %285
  %287 = load ptr, ptr %6, align 8, !tbaa !5
  %288 = getelementptr inbounds %struct.ocb128_context, ptr %287, i32 0, i32 10
  %289 = getelementptr inbounds %struct.anon, ptr %288, i32 0, i32 5
  %290 = getelementptr inbounds [2 x i64], ptr %289, i64 0, i64 1
  store i64 %286, ptr %290, align 8, !tbaa !21
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #4
  br label %291

291:                                              ; preds = %217, %212
  %292 = load i64, ptr %11, align 8, !tbaa !15
  %293 = load ptr, ptr %6, align 8, !tbaa !5
  %294 = getelementptr inbounds %struct.ocb128_context, ptr %293, i32 0, i32 10
  %295 = getelementptr inbounds %struct.anon, ptr %294, i32 0, i32 1
  store i64 %292, ptr %295, align 8, !tbaa !11
  store i32 1, ptr %5, align 4
  store i32 1, ptr %16, align 4
  br label %296

296:                                              ; preds = %291, %205, %80
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  %297 = load i32, ptr %5, align 4
  ret i32 %297
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #2 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 = { 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, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !14, i64 104}
!12 = !{!"ocb128_context", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !10, i64 40, !10, i64 48, !7, i64 56, !7, i64 72, !6, i64 88, !13, i64 96}
!13 = !{!"", !14, i64 0, !14, i64 8, !7, i64 16, !7, i64 32, !7, i64 48, !7, i64 64}
!14 = !{!"long long", !7, i64 0}
!15 = !{!14, !14, i64 0}
!16 = !{!12, !6, i64 32}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = !{!12, !6, i64 16}
!20 = !{!12, !6, i64 88}
!21 = !{!7, !7, i64 0}
!22 = !{!12, !6, i64 0}
!23 = distinct !{!23, !18}


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

%union.OCB_BLOCK = type { [2 x i64] }

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

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

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

; 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) #2

; Function Attrs: nounwind uwtable
declare hidden void @ocb_block_xor(ptr noundef, ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
declare hidden ptr @ocb_lookup_l(ptr noundef, i64 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
declare hidden i32 @ocb_ntz(i64 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @CRYPTO_ocb128_encrypt(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3) local_unnamed_addr #3 {
  %5 = alloca %union.OCB_BLOCK, align 16
  %6 = alloca %union.OCB_BLOCK, align 16
  %7 = lshr i64 %3, 4
  %8 = getelementptr inbounds i8, ptr %0, i64 104
  %9 = load i64, ptr %8, align 8, !tbaa !5
  %10 = add i64 %9, %7
  %.not = icmp ult i64 %3, 16
  br i1 %.not, label %27, label %11

11:                                               ; preds = %4
  %12 = getelementptr inbounds i8, ptr %0, i64 32
  %13 = load ptr, ptr %12, align 8, !tbaa !13
  %.not88 = icmp eq ptr %13, null
  br i1 %.not88, label %27, label %.preheader

.preheader:                                       ; preds = %11
  %.not9198 = icmp ult i64 %10, 2
  %14 = tail call range(i64 0, 65) i64 @llvm.ctlz.i64(i64 %10, i1 true)
  %15 = xor i64 %14, 63
  %.077.lcssa = select i1 %.not9198, i64 0, i64 %15
  %16 = tail call ptr @ocb_lookup_l(ptr noundef nonnull %0, i64 noundef %.077.lcssa)
  %.not92 = icmp eq ptr %16, null
  br i1 %.not92, label %.critedge, label %17

17:                                               ; preds = %.preheader
  %18 = load ptr, ptr %12, align 8, !tbaa !13
  %19 = getelementptr inbounds i8, ptr %0, i64 16
  %20 = load ptr, ptr %19, align 8, !tbaa !14
  %21 = load i64, ptr %8, align 8, !tbaa !5
  %22 = add i64 %21, 1
  %23 = getelementptr inbounds i8, ptr %0, i64 144
  %24 = getelementptr inbounds i8, ptr %0, i64 88
  %25 = load ptr, ptr %24, align 8, !tbaa !15
  %26 = getelementptr inbounds i8, ptr %0, i64 160
  tail call void %18(ptr noundef %1, ptr noundef %2, i64 noundef %7, ptr noundef %20, i64 noundef %22, ptr noundef nonnull %23, ptr noundef %25, ptr noundef nonnull %26) #5
  br label %.loopexit

27:                                               ; preds = %11, %4
  %.084101 = add i64 %9, 1
  %.not89102 = icmp ugt i64 %.084101, %10
  br i1 %.not89102, label %.loopexit, label %.lr.ph107

.lr.ph107:                                        ; preds = %27
  %28 = getelementptr inbounds i8, ptr %0, i64 144
  %29 = getelementptr inbounds i8, ptr %0, i64 152
  %30 = getelementptr inbounds i8, ptr %0, i64 160
  %31 = getelementptr inbounds i8, ptr %0, i64 16
  br label %32

32:                                               ; preds = %.lr.ph107, %36
  %.084105 = phi i64 [ %.084101, %.lr.ph107 ], [ %.084, %36 ]
  %.078104 = phi ptr [ %1, %.lr.ph107 ], [ %41, %36 ]
  %.081103 = phi ptr [ %2, %.lr.ph107 ], [ %56, %36 ]
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #5
  %33 = call i32 @ocb_ntz(i64 noundef %.084105)
  %34 = zext i32 %33 to i64
  %35 = call ptr @ocb_lookup_l(ptr noundef nonnull %0, i64 noundef %34)
  %.not90 = icmp eq ptr %35, null
  br i1 %.not90, label %.thread, label %36

.thread:                                          ; preds = %32
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #5
  br label %.critedge

36:                                               ; preds = %32
  %37 = load i64, ptr %28, align 8, !tbaa !16
  %38 = load i64, ptr %35, align 8, !tbaa !16
  %39 = load i64, ptr %29, align 8, !tbaa !16
  %40 = getelementptr inbounds i8, ptr %35, i64 8
  %41 = getelementptr inbounds i8, ptr %.078104, i64 16
  %42 = xor i64 %38, %37
  store i64 %42, ptr %28, align 8, !tbaa !16
  %43 = load i64, ptr %40, align 8, !tbaa !16
  %44 = xor i64 %43, %39
  store i64 %44, ptr %29, align 8, !tbaa !16
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %5, ptr noundef nonnull align 1 dereferenceable(16) %.078104, i64 16, i1 false)
  %45 = load <2 x i64>, ptr %5, align 16, !tbaa !16
  %46 = load <2 x i64>, ptr %30, align 8, !tbaa !16
  %47 = xor <2 x i64> %46, %45
  store <2 x i64> %47, ptr %30, align 8, !tbaa !16
  %48 = insertelement <2 x i64> poison, i64 %42, i64 0
  %49 = insertelement <2 x i64> %48, i64 %44, i64 1
  %50 = xor <2 x i64> %45, %49
  store <2 x i64> %50, ptr %5, align 16, !tbaa !16
  %51 = load ptr, ptr %0, align 8, !tbaa !17
  %52 = load ptr, ptr %31, align 8, !tbaa !14
  call void %51(ptr noundef nonnull %5, ptr noundef nonnull %5, ptr noundef %52) #5
  %53 = load <2 x i64>, ptr %28, align 8, !tbaa !16
  %54 = load <2 x i64>, ptr %5, align 16, !tbaa !16
  %55 = xor <2 x i64> %54, %53
  store <2 x i64> %55, ptr %5, align 16, !tbaa !16
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(16) %.081103, ptr noundef nonnull align 16 dereferenceable(16) %5, i64 16, i1 false)
  %56 = getelementptr inbounds i8, ptr %.081103, i64 16
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #5
  %.084 = add i64 %.084105, 1
  %.not89 = icmp ugt i64 %.084, %10
  br i1 %.not89, label %.loopexit, label %32, !llvm.loop !18

.loopexit:                                        ; preds = %36, %27, %17
  %.283 = phi ptr [ %2, %17 ], [ %2, %27 ], [ %56, %36 ]
  %.280 = phi ptr [ %1, %17 ], [ %1, %27 ], [ %41, %36 ]
  %57 = and i64 %3, 15
  %.not93 = icmp eq i64 %57, 0
  br i1 %.not93, label %72, label %58

58:                                               ; preds = %.loopexit
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #5
  %59 = getelementptr inbounds i8, ptr %0, i64 144
  %60 = getelementptr inbounds i8, ptr %0, i64 56
  %61 = load <2 x i64>, ptr %59, align 8, !tbaa !16
  %62 = load <2 x i64>, ptr %60, align 8, !tbaa !16
  %63 = xor <2 x i64> %62, %61
  store <2 x i64> %63, ptr %59, align 8, !tbaa !16
  %64 = load ptr, ptr %0, align 8, !tbaa !17
  %65 = getelementptr inbounds i8, ptr %0, i64 16
  %66 = load ptr, ptr %65, align 8, !tbaa !14
  call void %64(ptr noundef nonnull %59, ptr noundef nonnull %6, ptr noundef %66) #5
  call void @ocb_block_xor(ptr noundef %.280, ptr noundef nonnull %6, i64 noundef %57, ptr noundef %.283)
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %6, i8 0, i64 16, i1 false)
  call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 16 %6, ptr align 1 %.280, i64 %57, i1 false)
  %67 = getelementptr inbounds [16 x i8], ptr %6, i64 0, i64 %57
  store i8 -128, ptr %67, align 1, !tbaa !16
  %68 = getelementptr inbounds i8, ptr %0, i64 160
  %69 = load <2 x i64>, ptr %6, align 16, !tbaa !16
  %70 = load <2 x i64>, ptr %68, align 8, !tbaa !16
  %71 = xor <2 x i64> %70, %69
  store <2 x i64> %71, ptr %68, align 8, !tbaa !16
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #5
  br label %72

72:                                               ; preds = %58, %.loopexit
  store i64 %10, ptr %8, align 8, !tbaa !5
  br label %.critedge

.critedge:                                        ; preds = %.thread, %.preheader, %72
  %.3 = phi i32 [ 1, %72 ], [ 0, %.preheader ], [ 0, %.thread ]
  ret i32 %.3
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.ctlz.i64(i64, i1 immarg) #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !12, i64 104}
!6 = !{!"ocb128_context", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !10, i64 40, !10, i64 48, !8, i64 56, !8, i64 72, !7, i64 88, !11, i64 96}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"long", !8, i64 0}
!11 = !{!"", !12, i64 0, !12, i64 8, !8, i64 16, !8, i64 32, !8, i64 48, !8, i64 64}
!12 = !{!"long long", !8, i64 0}
!13 = !{!6, !7, i64 32}
!14 = !{!6, !7, i64 16}
!15 = !{!6, !7, i64 88}
!16 = !{!8, !8, i64 0}
!17 = !{!6, !7, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass