; LLVM IR from intel/qpl :: sources/c_api/legacy_hw_path (qpl_hw_check_job)

; 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.qpl_hw_state = type { %struct.hw_decompress_analytics_descriptor, %struct.hw_iaa_completion_record, [2 x %struct.hw_iaa_aecs_analytic], [2 x %struct.hw_iaa_aecs_compress], %struct.qpl_buffer, %struct.qpl_execution_history, i32, i32, i32, %struct.hw_huffman_code, i32, %struct.hw_accelerator_context, i32, i32, i8, i8, i32, i32, %struct.qpl_execution_record }
%struct.hw_decompress_analytics_descriptor = type { i32, i32, ptr, ptr, ptr, i32, i16, i16, ptr, i32, i32, i32, i32 }
%struct.hw_iaa_completion_record = type { i8, i8, i8, i8, i32, i64, i64, i32, i8, i8, i16, i32, i32, i32, i32, i64, i64 }
%struct.hw_iaa_aecs_analytic = type { %struct.hw_iaa_aecs_filter, [36 x i32], %struct.hw_iaa_aecs_decompress }
%struct.hw_iaa_aecs_filter = type { i32, i32, i32, i32, i32, i32 }
%struct.hw_iaa_aecs_decompress = type { [2 x i32], i32, i32, [32 x i64], [32 x i8], i32, i8, i8, i16, [5 x i32], [5 x i32], [5 x i32], [5 x i32], [62 x i32], %union.anon, i16, i16, %union.anon.0, %struct.anon.2, i16, [4096 x i8], [6 x i32] }
%union.anon = type { %struct.anon }
%struct.anon = type { [6 x i32], [224 x i8], [5 x i32] }
%union.anon.0 = type { %struct.anon.1 }
%struct.anon.1 = type { [2 x i32], [144 x i8], [5 x i32] }
%struct.anon.2 = type { i16 }
%struct.hw_iaa_aecs_compress = type { i32, i32, [5 x i32], i32, [256 x i8], %struct.hw_iaa_histogram, [12288 x i8] }
%struct.hw_iaa_histogram = type { [286 x i32], [2 x i32], [30 x i32], [2 x i32] }
%struct.qpl_buffer = type { [1024 x i8], i32, i32 }
%struct.qpl_execution_history = type { i8, i32, i32, i32, ptr }
%struct.hw_huffman_code = type { i16, i8, i8 }
%struct.hw_accelerator_context = type { %struct.hw_device_properties, ptr }
%struct.hw_device_properties = type { i32, i32, i32, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8 }
%struct.qpl_execution_record = type { double, i32, i32 }
%struct.qpl_job = type { ptr, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, ptr, i32, ptr, i32, i32, i8, i8, i8, i64, i64, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, %struct.qpl_aux_data }
%struct.qpl_aux_data = type { ptr, ptr, ptr, ptr, ptr, i32 }
%struct.qpl_dictionary = type { i8, i8, i64, i32, i32, i32, i32, i32 }

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN3qpl3jobL11get_adler32EPK7qpl_job(ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN3qpl2ml33write_stored_block_and_update_jobEP7qpl_job(ptr noundef) #0

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef ptr @_ZN3qpl3jobL9get_stateEPK7qpl_job(ptr noundef) #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef ptr @_ZL33hw_iaa_aecs_compress_get_aecs_ptrP20hw_iaa_aecs_compressjj(ptr noundef, i32 noundef, i32 noundef) #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden void @_ZN3qpl3jobL16update_checksumsEP7qpl_jobjj(ptr noundef, i32 noundef, i32 noundef) #2

; Function Attrs: nounwind
declare noundef i32 @_ZN3qpl2ml4util7adler32EPKhjj(ptr noundef, i32 noundef, i32 noundef) #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden void @_ZN3qpl3jobL14update_adler32EP7qpl_jobj(ptr noundef, i32 noundef) #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden void @_ZN3qpl3jobL20update_output_streamEP7qpl_jobjj(ptr noundef, i32 noundef, i32 noundef) #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden void @_ZN3qpl3jobL19update_input_streamEP7qpl_jobj(ptr noundef, i32 noundef) #2

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN3qpl2ml21hw_check_compress_jobEP7qpl_job(ptr noundef %0) #0 {
  %2 = alloca i32, align 4
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i8, align 1
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i8, align 1
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca ptr, align 8
  %20 = alloca i32, align 4
  %21 = alloca ptr, align 8
  %22 = alloca i8, align 1
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  store ptr %0, ptr %3, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #5
  %26 = load ptr, ptr %3, align 8, !tbaa !5
  %27 = call noundef ptr @_ZN3qpl3jobL9get_stateEPK7qpl_job(ptr noundef %26) #5
  store ptr %27, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  %28 = load ptr, ptr %4, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.qpl_hw_state, ptr %28, i32 0, i32 0
  store ptr %29, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %30 = load ptr, ptr %4, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.qpl_hw_state, ptr %30, i32 0, i32 1
  store ptr %31, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %7) #5
  %32 = load ptr, ptr %3, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.qpl_job, ptr %32, i32 0, i32 7
  %34 = load i32, ptr %33, align 4, !tbaa !9
  %35 = and i32 2, %34
  %36 = icmp ne i32 %35, 0
  %37 = zext i1 %36 to i8
  store i8 %37, ptr %7, align 1, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %38 = load ptr, ptr %4, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.qpl_hw_state, ptr %38, i32 0, i32 3
  %40 = getelementptr inbounds [2 x %struct.hw_iaa_aecs_compress], ptr %39, i64 0, i64 0
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.qpl_hw_state, ptr %41, i32 0, i32 7
  %43 = load i32, ptr %42, align 4, !tbaa !23
  %44 = load ptr, ptr %4, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.qpl_hw_state, ptr %44, i32 0, i32 8
  %46 = load i32, ptr %45, align 8, !tbaa !39
  %47 = call noundef ptr @_ZL33hw_iaa_aecs_compress_get_aecs_ptrP20hw_iaa_aecs_compressjj(ptr noundef %40, i32 noundef %43, i32 noundef %46)
  store ptr %47, ptr %8, align 8, !tbaa !5
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  %49 = icmp ne ptr %48, null
  br i1 %49, label %51, label %50

50:                                               ; preds = %1
  store i32 6, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %478

51:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %52 = load ptr, ptr %4, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.qpl_hw_state, ptr %52, i32 0, i32 3
  %54 = getelementptr inbounds [2 x %struct.hw_iaa_aecs_compress], ptr %53, i64 0, i64 0
  %55 = load ptr, ptr %4, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.qpl_hw_state, ptr %55, i32 0, i32 7
  %57 = load i32, ptr %56, align 4, !tbaa !23
  %58 = xor i32 %57, 1
  %59 = load ptr, ptr %4, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.qpl_hw_state, ptr %59, i32 0, i32 8
  %61 = load i32, ptr %60, align 8, !tbaa !39
  %62 = call noundef ptr @_ZL33hw_iaa_aecs_compress_get_aecs_ptrP20hw_iaa_aecs_compressjj(ptr noundef %54, i32 noundef %58, i32 noundef %61)
  store ptr %62, ptr %10, align 8, !tbaa !5
  %63 = load ptr, ptr %10, align 8, !tbaa !5
  %64 = icmp ne ptr %63, null
  br i1 %64, label %66, label %65

65:                                               ; preds = %51
  store i32 6, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %477

66:                                               ; preds = %51
  %67 = load ptr, ptr %5, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %67, i32 0, i32 1
  %69 = load i32, ptr %68, align 1, !tbaa !40
  %70 = lshr i32 %69, 24
  %71 = and i32 %70, 255
  %72 = icmp eq i32 66, %71
  br i1 %72, label %73, label %118

73:                                               ; preds = %66
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  %74 = load ptr, ptr %6, align 8, !tbaa !5
  %75 = call noundef i32 @_ZN3qpl2ml4utilL25convert_status_iaa_to_qplEPVK20hw_completion_record(ptr noundef %74)
  store i32 %75, ptr %11, align 4, !tbaa !41
  %76 = load i32, ptr %11, align 4, !tbaa !41
  %77 = icmp ne i32 %76, 0
  br i1 %77, label %78, label %80

78:                                               ; preds = %73
  %79 = load i32, ptr %11, align 4, !tbaa !41
  store i32 %79, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %81

80:                                               ; preds = %73
  store i32 0, ptr %9, align 4
  br label %81

81:                                               ; preds = %80, %78
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  %82 = load i32, ptr %9, align 4
  switch i32 %82, label %477 [
    i32 0, label %83
  ]

83:                                               ; preds = %81
  %84 = load ptr, ptr %6, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %84, i32 0, i32 7
  %86 = load i32, ptr %85, align 1, !tbaa !42
  %87 = zext i32 %86 to i64
  %88 = udiv i64 %87, 8
  %89 = load ptr, ptr %3, align 8, !tbaa !5
  %90 = getelementptr inbounds %struct.qpl_job, ptr %89, i32 0, i32 18
  %91 = load i32, ptr %90, align 4, !tbaa !43
  %92 = zext i32 %91 to i64
  %93 = add i64 %92, %88
  %94 = trunc i64 %93 to i32
  store i32 %94, ptr %90, align 4, !tbaa !43
  %95 = load ptr, ptr %4, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.qpl_hw_state, ptr %95, i32 0, i32 7
  %97 = load i32, ptr %96, align 4, !tbaa !23
  %98 = xor i32 %97, 1
  store i32 %98, ptr %96, align 4, !tbaa !23
  %99 = load ptr, ptr %4, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.qpl_hw_state, ptr %99, i32 0, i32 13
  %101 = load i32, ptr %100, align 4, !tbaa !44
  %102 = xor i32 %101, 1
  store i32 %102, ptr %100, align 4, !tbaa !44
  %103 = load i8, ptr %7, align 1, !tbaa !21, !range !45, !noundef !46
  %104 = trunc i8 %103 to i1
  br i1 %104, label %105, label %114

105:                                              ; preds = %83
  %106 = load ptr, ptr %6, align 8, !tbaa !5
  %107 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %106, i32 0, i32 11
  %108 = load i32, ptr %107, align 1, !tbaa !47
  %109 = load ptr, ptr %4, align 8, !tbaa !5
  %110 = getelementptr inbounds %struct.qpl_hw_state, ptr %109, i32 0, i32 5
  %111 = getelementptr inbounds %struct.qpl_execution_history, ptr %110, i32 0, i32 3
  %112 = load i32, ptr %111, align 4, !tbaa !48
  %113 = icmp ne i32 %108, %112
  br label %114

114:                                              ; preds = %105, %83
  %115 = phi i1 [ false, %83 ], [ %113, %105 ]
  %116 = zext i1 %115 to i64
  %117 = select i1 %115, i32 229, i32 0
  store i32 %117, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %477

118:                                              ; preds = %66
  %119 = load ptr, ptr %6, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %119, i32 0, i32 1
  %121 = load i8, ptr %120, align 1, !tbaa !49
  %122 = zext i8 %121 to i32
  %123 = icmp eq i32 %122, 25
  br i1 %123, label %124, label %146

124:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  %125 = load ptr, ptr %3, align 8, !tbaa !5
  %126 = call noundef i32 @_ZN3qpl2ml33write_stored_block_and_update_jobEP7qpl_job(ptr noundef %125)
  store i32 %126, ptr %12, align 4, !tbaa !50
  %127 = load i32, ptr %12, align 4, !tbaa !50
  %128 = icmp ne i32 %127, 0
  br i1 %128, label %129, label %131

129:                                              ; preds = %124
  %130 = load i32, ptr %12, align 4, !tbaa !50
  store i32 %130, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %145

131:                                              ; preds = %124
  %132 = load ptr, ptr %3, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.qpl_job, ptr %132, i32 0, i32 7
  %134 = load i32, ptr %133, align 4, !tbaa !9
  %135 = and i32 16384, %134
  %136 = icmp ne i32 %135, 0
  br i1 %136, label %140, label %137

137:                                              ; preds = %131
  %138 = load ptr, ptr %3, align 8, !tbaa !5
  %139 = call i32 @hw_submit_verify_job(ptr noundef %138)
  store i32 %139, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %145

140:                                              ; preds = %131
  %141 = load ptr, ptr %4, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.qpl_hw_state, ptr %141, i32 0, i32 7
  %143 = load i32, ptr %142, align 4, !tbaa !23
  %144 = xor i32 %143, 1
  store i32 %144, ptr %142, align 4, !tbaa !23
  store i32 0, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %145

145:                                              ; preds = %140, %137, %129
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %477

146:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  %147 = load ptr, ptr %6, align 8, !tbaa !5
  %148 = call noundef i32 @_ZN3qpl2ml4utilL25convert_status_iaa_to_qplEPVK20hw_completion_record(ptr noundef %147)
  store i32 %148, ptr %13, align 4, !tbaa !41
  %149 = load ptr, ptr %3, align 8, !tbaa !5
  %150 = getelementptr inbounds %struct.qpl_job, ptr %149, i32 0, i32 7
  %151 = load i32, ptr %150, align 4, !tbaa !9
  %152 = and i32 %151, 1
  %153 = icmp ne i32 %152, 0
  br i1 %153, label %154, label %190

154:                                              ; preds = %146
  %155 = load i32, ptr %13, align 4, !tbaa !41
  %156 = icmp ne i32 %155, 0
  br i1 %156, label %157, label %190

157:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !41
  %158 = load ptr, ptr %3, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.qpl_job, ptr %158, i32 0, i32 7
  %160 = load i32, ptr %159, align 4, !tbaa !9
  %161 = and i32 8, %160
  %162 = icmp ne i32 %161, 0
  br i1 %162, label %163, label %164

163:                                              ; preds = %157
  store i32 10, ptr %14, align 4, !tbaa !41
  br label %172

164:                                              ; preds = %157
  %165 = load ptr, ptr %3, align 8, !tbaa !5
  %166 = getelementptr inbounds %struct.qpl_job, ptr %165, i32 0, i32 7
  %167 = load i32, ptr %166, align 4, !tbaa !9
  %168 = and i32 524288, %167
  %169 = icmp ne i32 %168, 0
  br i1 %169, label %170, label %171

170:                                              ; preds = %164
  store i32 2, ptr %14, align 4, !tbaa !41
  br label %171

171:                                              ; preds = %170, %164
  br label %172

172:                                              ; preds = %171, %163
  %173 = load i32, ptr %14, align 4, !tbaa !41
  %174 = load ptr, ptr %3, align 8, !tbaa !5
  %175 = getelementptr inbounds %struct.qpl_job, ptr %174, i32 0, i32 3
  %176 = load ptr, ptr %175, align 8, !tbaa !51
  %177 = zext i32 %173 to i64
  %178 = sub i64 0, %177
  %179 = getelementptr inbounds i8, ptr %176, i64 %178
  store ptr %179, ptr %175, align 8, !tbaa !51
  %180 = load i32, ptr %14, align 4, !tbaa !41
  %181 = load ptr, ptr %3, align 8, !tbaa !5
  %182 = getelementptr inbounds %struct.qpl_job, ptr %181, i32 0, i32 4
  %183 = load i32, ptr %182, align 8, !tbaa !52
  %184 = add i32 %183, %180
  store i32 %184, ptr %182, align 8, !tbaa !52
  %185 = load i32, ptr %14, align 4, !tbaa !41
  %186 = load ptr, ptr %3, align 8, !tbaa !5
  %187 = getelementptr inbounds %struct.qpl_job, ptr %186, i32 0, i32 5
  %188 = load i32, ptr %187, align 4, !tbaa !53
  %189 = sub i32 %188, %185
  store i32 %189, ptr %187, align 4, !tbaa !53
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %190

190:                                              ; preds = %172, %154, %146
  %191 = load ptr, ptr %4, align 8, !tbaa !5
  %192 = getelementptr inbounds %struct.qpl_hw_state, ptr %191, i32 0, i32 12
  %193 = load i32, ptr %192, align 8, !tbaa !54
  %194 = icmp ne i32 %193, 0
  br i1 %194, label %205, label %195

195:                                              ; preds = %190
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %196 = load i32, ptr %13, align 4, !tbaa !41
  store i32 %196, ptr %15, align 4, !tbaa !41
  %197 = load i32, ptr %15, align 4, !tbaa !41
  %198 = icmp ne i32 %197, 0
  br i1 %198, label %199, label %201

199:                                              ; preds = %195
  %200 = load i32, ptr %15, align 4, !tbaa !41
  store i32 %200, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %202

201:                                              ; preds = %195
  store i32 0, ptr %9, align 4
  br label %202

202:                                              ; preds = %201, %199
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  %203 = load i32, ptr %9, align 4
  switch i32 %203, label %476 [
    i32 0, label %204
  ]

204:                                              ; preds = %202
  br label %205

205:                                              ; preds = %204, %190
  %206 = load ptr, ptr %3, align 8, !tbaa !5
  %207 = getelementptr inbounds %struct.qpl_job, ptr %206, i32 0, i32 7
  %208 = load i32, ptr %207, align 4, !tbaa !9
  %209 = and i32 %208, 18
  %210 = icmp eq i32 %209, 18
  br i1 %210, label %211, label %252

211:                                              ; preds = %205
  %212 = call noundef zeroext i1 @_ZN3qpl2ml4util38are_iaa_gen_2_min_capabilities_presentEv()
  br i1 %212, label %252, label %213

213:                                              ; preds = %211
  %214 = load ptr, ptr %6, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %214, i32 0, i32 7
  %216 = load i32, ptr %215, align 1, !tbaa !42
  %217 = urem i32 %216, 2
  %218 = icmp eq i32 %217, 1
  br i1 %218, label %219, label %237

219:                                              ; preds = %213
  %220 = load ptr, ptr %6, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %220, i32 0, i32 8
  %222 = load i8, ptr %221, align 1, !tbaa !55
  %223 = zext i8 %222 to i32
  %224 = icmp ne i32 %223, 0
  br i1 %224, label %225, label %232

225:                                              ; preds = %219
  %226 = load ptr, ptr %6, align 8, !tbaa !5
  %227 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %226, i32 0, i32 8
  %228 = load i8, ptr %227, align 1, !tbaa !55
  %229 = zext i8 %228 to i32
  %230 = add nsw i32 %229, 8
  %231 = trunc i32 %230 to i8
  store i8 %231, ptr %227, align 1, !tbaa !55
  br label %232

232:                                              ; preds = %225, %219
  %233 = load ptr, ptr %6, align 8, !tbaa !5
  %234 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %233, i32 0, i32 7
  %235 = load i32, ptr %234, align 1, !tbaa !42
  %236 = and i32 %235, -2
  store i32 %236, ptr %234, align 1, !tbaa !42
  br label %251

237:                                              ; preds = %213
  %238 = load ptr, ptr %6, align 8, !tbaa !5
  %239 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %238, i32 0, i32 8
  %240 = load i8, ptr %239, align 1, !tbaa !55
  %241 = zext i8 %240 to i32
  %242 = icmp eq i32 %241, 0
  br i1 %242, label %243, label %250

243:                                              ; preds = %237
  %244 = load ptr, ptr %6, align 8, !tbaa !5
  %245 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %244, i32 0, i32 8
  %246 = load i8, ptr %245, align 1, !tbaa !55
  %247 = zext i8 %246 to i32
  %248 = add nsw i32 %247, 8
  %249 = trunc i32 %248 to i8
  store i8 %249, ptr %245, align 1, !tbaa !55
  br label %250

250:                                              ; preds = %243, %237
  br label %251

251:                                              ; preds = %250, %232
  br label %252

252:                                              ; preds = %251, %211, %205
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #5
  %253 = load ptr, ptr %5, align 8, !tbaa !5
  %254 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %253, i32 0, i32 7
  %255 = load i16, ptr %254, align 1, !tbaa !56
  %256 = zext i16 %255 to i32
  %257 = and i32 20480, %256
  %258 = icmp eq i32 20480, %257
  br i1 %258, label %273, label %259

259:                                              ; preds = %252
  %260 = load ptr, ptr %5, align 8, !tbaa !5
  %261 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %260, i32 0, i32 7
  %262 = load i16, ptr %261, align 1, !tbaa !56
  %263 = zext i16 %262 to i32
  %264 = and i32 24576, %263
  %265 = icmp eq i32 24576, %264
  br i1 %265, label %273, label %266

266:                                              ; preds = %259
  %267 = load ptr, ptr %5, align 8, !tbaa !5
  %268 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %267, i32 0, i32 7
  %269 = load i16, ptr %268, align 1, !tbaa !56
  %270 = zext i16 %269 to i32
  %271 = and i32 28672, %270
  %272 = icmp eq i32 28672, %271
  br label %273

273:                                              ; preds = %266, %259, %252
  %274 = phi i1 [ true, %259 ], [ true, %252 ], [ %272, %266 ]
  %275 = zext i1 %274 to i8
  store i8 %275, ptr %16, align 1, !tbaa !21
  %276 = load ptr, ptr %5, align 8, !tbaa !5
  %277 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %276, i32 0, i32 7
  %278 = load i16, ptr %277, align 1, !tbaa !56
  %279 = zext i16 %278 to i32
  %280 = and i32 1, %279
  %281 = icmp ne i32 %280, 0
  br i1 %281, label %295, label %282

282:                                              ; preds = %273
  %283 = load i8, ptr %16, align 1, !tbaa !21, !range !45, !noundef !46
  %284 = trunc i8 %283 to i1
  br i1 %284, label %295, label %285

285:                                              ; preds = %282
  %286 = load ptr, ptr %4, align 8, !tbaa !5
  %287 = getelementptr inbounds %struct.qpl_hw_state, ptr %286, i32 0, i32 16
  %288 = load i32, ptr %287, align 4, !tbaa !57
  %289 = icmp eq i32 %288, 1
  br i1 %289, label %290, label %386

290:                                              ; preds = %285
  %291 = load ptr, ptr %4, align 8, !tbaa !5
  %292 = getelementptr inbounds %struct.qpl_hw_state, ptr %291, i32 0, i32 12
  %293 = load i32, ptr %292, align 8, !tbaa !54
  %294 = icmp ne i32 %293, 0
  br i1 %294, label %295, label %386

295:                                              ; preds = %290, %282, %273
  %296 = load ptr, ptr %4, align 8, !tbaa !5
  %297 = getelementptr inbounds %struct.qpl_hw_state, ptr %296, i32 0, i32 16
  %298 = load i32, ptr %297, align 4, !tbaa !57
  %299 = icmp eq i32 %298, 0
  br i1 %299, label %300, label %362

300:                                              ; preds = %295
  %301 = load ptr, ptr %6, align 8, !tbaa !5
  %302 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %301, i32 0, i32 11
  %303 = load i32, ptr %302, align 1, !tbaa !47
  %304 = load ptr, ptr %3, align 8, !tbaa !5
  %305 = getelementptr inbounds %struct.qpl_job, ptr %304, i32 0, i32 8
  store i32 %303, ptr %305, align 8, !tbaa !58
  %306 = load ptr, ptr %6, align 8, !tbaa !5
  %307 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %306, i32 0, i32 10
  %308 = load i16, ptr %307, align 1, !tbaa !59
  %309 = zext i16 %308 to i32
  %310 = load ptr, ptr %3, align 8, !tbaa !5
  %311 = getelementptr inbounds %struct.qpl_job, ptr %310, i32 0, i32 9
  store i32 %309, ptr %311, align 4, !tbaa !60
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %312 = load ptr, ptr %5, align 8, !tbaa !5
  %313 = load ptr, ptr %4, align 8, !tbaa !5
  %314 = load ptr, ptr %3, align 8, !tbaa !5
  %315 = load ptr, ptr %8, align 8, !tbaa !5
  %316 = load ptr, ptr %6, align 8, !tbaa !5
  %317 = call i32 @hw_descriptor_compress_init_deflate_dynamic(ptr noundef %312, ptr noundef %313, ptr noundef %314, ptr noundef %315, ptr noundef %316)
  store i32 %317, ptr %17, align 4, !tbaa !50
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %318 = load i32, ptr %17, align 4, !tbaa !50
  store i32 %318, ptr %18, align 4, !tbaa !50
  %319 = load i32, ptr %18, align 4, !tbaa !50
  %320 = icmp ne i32 %319, 0
  br i1 %320, label %321, label %323

321:                                              ; preds = %300
  %322 = load i32, ptr %18, align 4, !tbaa !50
  store i32 %322, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %324

323:                                              ; preds = %300
  store i32 0, ptr %9, align 4
  br label %324

324:                                              ; preds = %323, %321
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  %325 = load i32, ptr %9, align 4
  switch i32 %325, label %359 [
    i32 0, label %326
  ]

326:                                              ; preds = %324
  %327 = load ptr, ptr %3, align 8, !tbaa !5
  %328 = getelementptr inbounds %struct.qpl_job, ptr %327, i32 0, i32 14
  %329 = load ptr, ptr %328, align 8, !tbaa !61
  %330 = icmp ne ptr %329, null
  br i1 %330, label %331, label %358

331:                                              ; preds = %326
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  %332 = load ptr, ptr %3, align 8, !tbaa !5
  %333 = getelementptr inbounds %struct.qpl_job, ptr %332, i32 0, i32 14
  %334 = load ptr, ptr %333, align 8, !tbaa !61
  store ptr %334, ptr %19, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  %335 = load ptr, ptr %19, align 8, !tbaa !5
  %336 = call noundef i32 @_ZN3qpl2ml11compression27get_dictionary_size_in_aecsER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %335) #5
  store i32 %336, ptr %20, align 4, !tbaa !41
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  %337 = load ptr, ptr %19, align 8, !tbaa !5
  %338 = call noundef ptr @_ZN3qpl2ml11compression19get_dictionary_dataER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %337) #5
  store ptr %338, ptr %21, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %22) #5
  %339 = load ptr, ptr %19, align 8, !tbaa !5
  %340 = call noundef zeroext i8 @_ZN3qpl2ml11compression24get_load_dictionary_flagER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %339) #5
  store i8 %340, ptr %22, align 1, !tbaa !62
  %341 = load ptr, ptr %5, align 8, !tbaa !5
  %342 = load i32, ptr %20, align 4, !tbaa !41
  %343 = load ptr, ptr %21, align 8, !tbaa !5
  %344 = load ptr, ptr %19, align 8, !tbaa !5
  %345 = getelementptr inbounds %struct.qpl_dictionary, ptr %344, i32 0, i32 3
  %346 = load i32, ptr %345, align 8, !tbaa !63
  %347 = load ptr, ptr %4, align 8, !tbaa !5
  %348 = getelementptr inbounds %struct.qpl_hw_state, ptr %347, i32 0, i32 3
  %349 = getelementptr inbounds [2 x %struct.hw_iaa_aecs_compress], ptr %348, i64 0, i64 0
  %350 = load ptr, ptr %4, align 8, !tbaa !5
  %351 = getelementptr inbounds %struct.qpl_hw_state, ptr %350, i32 0, i32 7
  %352 = load i32, ptr %351, align 4, !tbaa !23
  %353 = load ptr, ptr %4, align 8, !tbaa !5
  %354 = getelementptr inbounds %struct.qpl_hw_state, ptr %353, i32 0, i32 8
  %355 = load i32, ptr %354, align 8, !tbaa !39
  %356 = load i8, ptr %22, align 1, !tbaa !62
  %357 = zext i8 %356 to i32
  call void @hw_iaa_descriptor_compress_setup_dictionary(ptr noundef %341, i32 noundef %342, ptr noundef %343, i32 noundef %346, ptr noundef %349, i32 noundef %352, i32 noundef %355, i32 noundef %357)
  call void @llvm.lifetime.end.p0(i64 1, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  br label %358

358:                                              ; preds = %331, %326
  store i32 0, ptr %9, align 4
  br label %359

359:                                              ; preds = %358, %324
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  %360 = load i32, ptr %9, align 4
  switch i32 %360, label %475 [
    i32 0, label %361
  ]

361:                                              ; preds = %359
  br label %362

362:                                              ; preds = %361, %295
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #5
  %363 = load ptr, ptr %5, align 8, !tbaa !5
  %364 = load ptr, ptr %4, align 8, !tbaa !5
  %365 = getelementptr inbounds %struct.qpl_hw_state, ptr %364, i32 0, i32 1
  %366 = load ptr, ptr %3, align 8, !tbaa !5
  %367 = getelementptr inbounds %struct.qpl_job, ptr %366, i32 0, i32 38
  %368 = load i32, ptr %367, align 4, !tbaa !67
  %369 = call noundef i32 @_ZN3qpl2ml4util18process_descriptorI10qpl_statusLNS1_16execution_mode_tE1EEET_P13hw_descriptorPV20hw_completion_recordi(ptr noundef %363, ptr noundef %365, i32 noundef %368) #5
  store i32 %369, ptr %23, align 4, !tbaa !50
  %370 = load i32, ptr %23, align 4, !tbaa !50
  %371 = icmp ne i32 0, %370
  br i1 %371, label %372, label %377

372:                                              ; preds = %362
  %373 = load ptr, ptr %4, align 8, !tbaa !5
  %374 = getelementptr inbounds %struct.qpl_hw_state, ptr %373, i32 0, i32 12
  store i32 1, ptr %374, align 8, !tbaa !54
  %375 = load ptr, ptr %4, align 8, !tbaa !5
  %376 = getelementptr inbounds %struct.qpl_hw_state, ptr %375, i32 0, i32 16
  store i32 1, ptr %376, align 4, !tbaa !57
  br label %380

377:                                              ; preds = %362
  %378 = load ptr, ptr %4, align 8, !tbaa !5
  %379 = getelementptr inbounds %struct.qpl_hw_state, ptr %378, i32 0, i32 12
  store i32 0, ptr %379, align 8, !tbaa !54
  br label %380

380:                                              ; preds = %377, %372
  %381 = load i32, ptr %23, align 4, !tbaa !50
  %382 = icmp ne i32 0, %381
  br i1 %382, label %383, label %384

383:                                              ; preds = %380
  store i32 5, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %385

384:                                              ; preds = %380
  store i32 1, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %385

385:                                              ; preds = %384, %383
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #5
  br label %475

386:                                              ; preds = %290, %285
  %387 = load ptr, ptr %5, align 8, !tbaa !5
  %388 = getelementptr inbounds %struct.hw_decompress_analytics_descriptor, ptr %387, i32 0, i32 1
  %389 = load i32, ptr %388, align 1, !tbaa !40
  %390 = lshr i32 %389, 18
  %391 = and i32 %390, 3
  %392 = icmp eq i32 %391, 1
  %393 = zext i1 %392 to i32
  %394 = load ptr, ptr %4, align 8, !tbaa !5
  %395 = getelementptr inbounds %struct.qpl_hw_state, ptr %394, i32 0, i32 6
  store i32 %393, ptr %395, align 8, !tbaa !68
  %396 = load ptr, ptr %6, align 8, !tbaa !5
  %397 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %396, i32 0, i32 11
  %398 = load i32, ptr %397, align 1, !tbaa !47
  %399 = load ptr, ptr %4, align 8, !tbaa !5
  %400 = getelementptr inbounds %struct.qpl_hw_state, ptr %399, i32 0, i32 5
  %401 = getelementptr inbounds %struct.qpl_execution_history, ptr %400, i32 0, i32 3
  store i32 %398, ptr %401, align 4, !tbaa !48
  %402 = load ptr, ptr %3, align 8, !tbaa !5
  %403 = load ptr, ptr %6, align 8, !tbaa !5
  %404 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %403, i32 0, i32 11
  %405 = load i32, ptr %404, align 1, !tbaa !47
  %406 = load ptr, ptr %6, align 8, !tbaa !5
  %407 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %406, i32 0, i32 10
  %408 = load i16, ptr %407, align 1, !tbaa !59
  %409 = zext i16 %408 to i32
  call void @_ZN3qpl3jobL16update_checksumsEP7qpl_jobjj(ptr noundef %402, i32 noundef %405, i32 noundef %409) #5
  %410 = load ptr, ptr %3, align 8, !tbaa !5
  %411 = getelementptr inbounds %struct.qpl_job, ptr %410, i32 0, i32 7
  %412 = load i32, ptr %411, align 4, !tbaa !9
  %413 = and i32 524288, %412
  %414 = icmp ne i32 %413, 0
  br i1 %414, label %415, label %428

415:                                              ; preds = %386
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #5
  %416 = load ptr, ptr %3, align 8, !tbaa !5
  %417 = call noundef i32 @_ZN3qpl3jobL11get_adler32EPK7qpl_job(ptr noundef %416) #5
  store i32 %417, ptr %24, align 4, !tbaa !41
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #5
  %418 = load ptr, ptr %3, align 8, !tbaa !5
  %419 = getelementptr inbounds %struct.qpl_job, ptr %418, i32 0, i32 0
  %420 = load ptr, ptr %419, align 8, !tbaa !69
  %421 = load ptr, ptr %3, align 8, !tbaa !5
  %422 = getelementptr inbounds %struct.qpl_job, ptr %421, i32 0, i32 1
  %423 = load i32, ptr %422, align 8, !tbaa !70
  %424 = load i32, ptr %24, align 4, !tbaa !41
  %425 = call noundef i32 @_ZN3qpl2ml4util7adler32EPKhjj(ptr noundef %420, i32 noundef %423, i32 noundef %424) #5
  store i32 %425, ptr %25, align 4, !tbaa !41
  %426 = load ptr, ptr %3, align 8, !tbaa !5
  %427 = load i32, ptr %25, align 4, !tbaa !41
  call void @_ZN3qpl3jobL14update_adler32EP7qpl_jobj(ptr noundef %426, i32 noundef %427) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  br label %428

428:                                              ; preds = %415, %386
  %429 = load ptr, ptr %3, align 8, !tbaa !5
  %430 = load ptr, ptr %6, align 8, !tbaa !5
  %431 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %430, i32 0, i32 7
  %432 = load i32, ptr %431, align 1, !tbaa !42
  %433 = load ptr, ptr %6, align 8, !tbaa !5
  %434 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %433, i32 0, i32 8
  %435 = load i8, ptr %434, align 1, !tbaa !55
  %436 = zext i8 %435 to i32
  call void @_ZN3qpl3jobL20update_output_streamEP7qpl_jobjj(ptr noundef %429, i32 noundef %432, i32 noundef %436) #5
  %437 = load i8, ptr %7, align 1, !tbaa !21, !range !45, !noundef !46
  %438 = trunc i8 %437 to i1
  br i1 %438, label %439, label %446

439:                                              ; preds = %428
  %440 = load ptr, ptr %3, align 8, !tbaa !5
  %441 = load ptr, ptr %4, align 8, !tbaa !5
  %442 = load ptr, ptr %6, align 8, !tbaa !5
  %443 = getelementptr inbounds %struct.hw_iaa_completion_record, ptr %442, i32 0, i32 11
  %444 = load i32, ptr %443, align 1, !tbaa !47
  %445 = call noundef i32 @_ZN3qpl2ml30set_state_to_complete_and_wrapEP7qpl_jobP12qpl_hw_statej(ptr noundef %440, ptr noundef %441, i32 noundef %444)
  br label %457

446:                                              ; preds = %428
  %447 = load ptr, ptr %3, align 8, !tbaa !5
  %448 = getelementptr inbounds %struct.qpl_job, ptr %447, i32 0, i32 7
  %449 = load i32, ptr %448, align 4, !tbaa !9
  %450 = and i32 8192, %449
  %451 = icmp ne i32 %450, 0
  br i1 %451, label %456, label %452

452:                                              ; preds = %446
  %453 = load ptr, ptr %4, align 8, !tbaa !5
  %454 = getelementptr inbounds %struct.qpl_hw_state, ptr %453, i32 0, i32 5
  %455 = getelementptr inbounds %struct.qpl_execution_history, ptr %454, i32 0, i32 1
  store i32 2, ptr %455, align 4, !tbaa !71
  br label %456

456:                                              ; preds = %452, %446
  br label %457

457:                                              ; preds = %456, %439
  %458 = load ptr, ptr %3, align 8, !tbaa !5
  %459 = load ptr, ptr %3, align 8, !tbaa !5
  %460 = getelementptr inbounds %struct.qpl_job, ptr %459, i32 0, i32 1
  %461 = load i32, ptr %460, align 8, !tbaa !70
  call void @_ZN3qpl3jobL19update_input_streamEP7qpl_jobj(ptr noundef %458, i32 noundef %461) #5
  %462 = load ptr, ptr %3, align 8, !tbaa !5
  %463 = getelementptr inbounds %struct.qpl_job, ptr %462, i32 0, i32 7
  %464 = load i32, ptr %463, align 4, !tbaa !9
  %465 = and i32 16384, %464
  %466 = icmp ne i32 %465, 0
  br i1 %466, label %470, label %467

467:                                              ; preds = %457
  %468 = load ptr, ptr %3, align 8, !tbaa !5
  %469 = call i32 @hw_submit_verify_job(ptr noundef %468)
  store i32 %469, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %475

470:                                              ; preds = %457
  %471 = load ptr, ptr %4, align 8, !tbaa !5
  %472 = getelementptr inbounds %struct.qpl_hw_state, ptr %471, i32 0, i32 7
  %473 = load i32, ptr %472, align 4, !tbaa !23
  %474 = xor i32 %473, 1
  store i32 %474, ptr %472, align 4, !tbaa !23
  store i32 0, ptr %2, align 4
  store i32 1, ptr %9, align 4
  br label %475

475:                                              ; preds = %470, %467, %385, %359
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #5
  br label %476

476:                                              ; preds = %475, %202
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  br label %477

477:                                              ; preds = %476, %145, %114, %81, %65
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  br label %478

478:                                              ; preds = %477, %50
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #5
  %479 = load i32, ptr %2, align 4
  ret i32 %479
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN3qpl2ml4utilL25convert_status_iaa_to_qplEPVK20hw_completion_record(ptr noundef) #2

declare i32 @hw_submit_verify_job(ptr noundef) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3qpl2ml4util38are_iaa_gen_2_min_capabilities_presentEv() #2

declare i32 @hw_descriptor_compress_init_deflate_dynamic(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #4

; Function Attrs: nounwind
declare noundef i32 @_ZN3qpl2ml11compression27get_dictionary_size_in_aecsER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) #3

; Function Attrs: nounwind
declare noundef ptr @_ZN3qpl2ml11compression19get_dictionary_dataER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) #3

; Function Attrs: nounwind
declare noundef zeroext i8 @_ZN3qpl2ml11compression24get_load_dictionary_flagER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) #3

declare void @hw_iaa_descriptor_compress_setup_dictionary(ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN3qpl2ml4util18process_descriptorI10qpl_statusLNS1_16execution_mode_tE1EEET_P13hw_descriptorPV20hw_completion_recordi(ptr noundef, ptr noundef, i32 noundef) #2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !11, i64 36}
!10 = !{!"_ZTS7qpl_job", !6, i64 0, !11, i64 8, !11, i64 12, !6, i64 16, !11, i64 24, !11, i64 28, !12, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !13, i64 52, !14, i64 56, !6, i64 64, !6, i64 72, !15, i64 80, !6, i64 88, !11, i64 96, !11, i64 100, !7, i64 104, !7, i64 105, !7, i64 106, !16, i64 112, !16, i64 120, !6, i64 128, !11, i64 136, !11, i64 140, !11, i64 144, !11, i64 148, !17, i64 152, !11, i64 156, !11, i64 160, !11, i64 164, !11, i64 168, !18, i64 172, !11, i64 176, !11, i64 180, !11, i64 184, !11, i64 188, !19, i64 192}
!11 = !{!"int", !7, i64 0}
!12 = !{!"_ZTS13qpl_operation", !7, i64 0}
!13 = !{!"_ZTS22qpl_compression_levels", !7, i64 0}
!14 = !{!"_ZTS19qpl_statistics_mode", !7, i64 0}
!15 = !{!"_ZTS19qpl_mini_block_size", !7, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = !{!"_ZTS14qpl_out_format", !7, i64 0}
!18 = !{!"_ZTS10qpl_parser", !7, i64 0}
!19 = !{!"_ZTS12qpl_aux_data", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !20, i64 40}
!20 = !{!"_ZTS10qpl_path_t", !7, i64 0}
!21 = !{!22, !22, i64 0}
!22 = !{!"bool", !7, i64 0}
!23 = !{!24, !11, i64 39652}
!24 = !{!"_ZTS12qpl_hw_state", !25, i64 0, !27, i64 64, !7, i64 128, !7, i64 10880, !28, i64 38592, !29, i64 39624, !11, i64 39648, !11, i64 39652, !11, i64 39656, !32, i64 39660, !11, i64 39664, !33, i64 39672, !11, i64 39704, !11, i64 39708, !22, i64 39712, !22, i64 39713, !35, i64 39716, !36, i64 39720, !37, i64 39728}
!25 = !{!"_ZTS34hw_decompress_analytics_descriptor", !11, i64 0, !11, i64 4, !6, i64 8, !6, i64 16, !6, i64 24, !11, i64 32, !26, i64 36, !26, i64 38, !6, i64 40, !11, i64 48, !11, i64 52, !11, i64 56, !11, i64 60}
!26 = !{!"short", !7, i64 0}
!27 = !{!"_ZTS24hw_iaa_completion_record", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3, !11, i64 4, !16, i64 8, !16, i64 16, !11, i64 24, !7, i64 28, !7, i64 29, !26, i64 30, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !16, i64 48, !16, i64 56}
!28 = !{!"_ZTS10qpl_buffer", !7, i64 0, !11, i64 1024, !11, i64 1028}
!29 = !{!"_ZTS21qpl_execution_history", !22, i64 0, !30, i64 4, !31, i64 8, !11, i64 12, !6, i64 16}
!30 = !{!"_ZTS23qpl_task_execution_step", !7, i64 0}
!31 = !{!"_ZTS14qpl_comp_style", !7, i64 0}
!32 = !{!"_ZTS15hw_huffman_code", !26, i64 0, !7, i64 2, !7, i64 3}
!33 = !{!"_ZTS22hw_accelerator_context", !34, i64 0, !6, i64 24}
!34 = !{!"_ZTS20hw_device_properties", !11, i64 0, !11, i64 4, !11, i64 8, !22, i64 12, !22, i64 13, !22, i64 14, !22, i64 15, !22, i64 16, !22, i64 17, !22, i64 18, !22, i64 19, !22, i64 20, !22, i64 21, !22, i64 22}
!35 = !{!"_ZTS25hw_multidescriptor_status", !7, i64 0}
!36 = !{!"_ZTS10qpl_status", !7, i64 0}
!37 = !{!"_ZTS20qpl_execution_record", !38, i64 0, !11, i64 8, !11, i64 12}
!38 = !{!"double", !7, i64 0}
!39 = !{!24, !11, i64 39656}
!40 = !{!25, !11, i64 4}
!41 = !{!11, !11, i64 0}
!42 = !{!27, !11, i64 24}
!43 = !{!10, !11, i64 100}
!44 = !{!24, !11, i64 39708}
!45 = !{i8 0, i8 2}
!46 = !{}
!47 = !{!27, !11, i64 32}
!48 = !{!24, !11, i64 39636}
!49 = !{!27, !7, i64 1}
!50 = !{!36, !36, i64 0}
!51 = !{!10, !6, i64 16}
!52 = !{!10, !11, i64 24}
!53 = !{!10, !11, i64 28}
!54 = !{!24, !11, i64 39704}
!55 = !{!27, !7, i64 28}
!56 = !{!25, !26, i64 38}
!57 = !{!24, !35, i64 39716}
!58 = !{!10, !11, i64 40}
!59 = !{!27, !26, i64 30}
!60 = !{!10, !11, i64 44}
!61 = !{!10, !6, i64 72}
!62 = !{!7, !7, i64 0}
!63 = !{!64, !11, i64 16}
!64 = !{!"_ZTS14qpl_dictionary", !65, i64 0, !66, i64 1, !16, i64 8, !11, i64 16, !11, i64 20, !11, i64 24, !11, i64 28, !11, i64 32}
!65 = !{!"_ZTS26software_compression_level", !7, i64 0}
!66 = !{!"_ZTS25hardware_dictionary_level", !7, i64 0}
!67 = !{!10, !11, i64 188}
!68 = !{!24, !11, i64 39648}
!69 = !{!10, !6, i64 0}
!70 = !{!10, !11, i64 8}
!71 = !{!24, !30, i64 39628}


; 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: mustprogress uwtable
declare dso_local noundef i32 @_ZN3qpl2ml30set_state_to_complete_and_wrapEP7qpl_jobP12qpl_hw_statej(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN3qpl2ml33write_stored_block_and_update_jobEP7qpl_job(ptr noundef) local_unnamed_addr #0

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

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

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

; Function Attrs: nounwind
declare noundef i32 @_ZN3qpl2ml4util7adler32EPKhjj(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN3qpl2ml21hw_check_compress_jobEP7qpl_job(ptr noundef %0) local_unnamed_addr #0 {
  %2 = tail call noundef ptr @_ZN3qpl3jobL9get_stateEPK7qpl_job(ptr noundef %0) #4
  %3 = getelementptr inbounds i8, ptr %2, i64 64
  %4 = getelementptr inbounds i8, ptr %0, i64 36
  %5 = load i32, ptr %4, align 4, !tbaa !5
  %6 = and i32 %5, 2
  %.not = icmp eq i32 %6, 0
  %7 = getelementptr inbounds i8, ptr %2, i64 10880
  %8 = getelementptr inbounds i8, ptr %2, i64 39652
  %9 = load i32, ptr %8, align 4, !tbaa !20
  %10 = getelementptr inbounds i8, ptr %2, i64 39656
  %11 = load i32, ptr %10, align 8, !tbaa !37
  %12 = tail call noundef ptr @_ZL33hw_iaa_aecs_compress_get_aecs_ptrP20hw_iaa_aecs_compressjj(ptr noundef nonnull %7, i32 noundef %9, i32 noundef %11)
  %.not139 = icmp eq ptr %12, null
  br i1 %.not139, label %.critedge, label %13

13:                                               ; preds = %1
  %14 = load i32, ptr %8, align 4, !tbaa !20
  %15 = xor i32 %14, 1
  %16 = load i32, ptr %10, align 8, !tbaa !37
  %17 = tail call noundef ptr @_ZL33hw_iaa_aecs_compress_get_aecs_ptrP20hw_iaa_aecs_compressjj(ptr noundef nonnull %7, i32 noundef %15, i32 noundef %16)
  %.not140 = icmp eq ptr %17, null
  br i1 %.not140, label %.critedge, label %18

18:                                               ; preds = %13
  %19 = getelementptr inbounds i8, ptr %2, i64 4
  %20 = load i32, ptr %19, align 1, !tbaa !38
  %.mask = and i32 %20, -16777216
  %21 = icmp eq i32 %.mask, 1107296256
  br i1 %21, label %22, label %42

22:                                               ; preds = %18
  %23 = tail call noundef i32 @_ZN3qpl2ml4utilL25convert_status_iaa_to_qplEPVK20hw_completion_record(ptr noundef nonnull %3)
  %.not156 = icmp eq i32 %23, 0
  br i1 %.not156, label %24, label %.critedge

24:                                               ; preds = %22
  %25 = getelementptr inbounds i8, ptr %2, i64 88
  %26 = load i32, ptr %25, align 1, !tbaa !39
  %27 = lshr i32 %26, 3
  %28 = getelementptr inbounds i8, ptr %0, i64 100
  %29 = load i32, ptr %28, align 4, !tbaa !40
  %30 = add i32 %29, %27
  store i32 %30, ptr %28, align 4, !tbaa !40
  %31 = load i32, ptr %8, align 4, !tbaa !20
  %32 = xor i32 %31, 1
  store i32 %32, ptr %8, align 4, !tbaa !20
  %33 = getelementptr inbounds i8, ptr %2, i64 39708
  %34 = load i32, ptr %33, align 4, !tbaa !41
  %35 = xor i32 %34, 1
  store i32 %35, ptr %33, align 4, !tbaa !41
  br i1 %.not, label %.critedge, label %36

36:                                               ; preds = %24
  %37 = getelementptr inbounds i8, ptr %2, i64 96
  %38 = load i32, ptr %37, align 1, !tbaa !42
  %39 = getelementptr inbounds i8, ptr %2, i64 39636
  %40 = load i32, ptr %39, align 4, !tbaa !43
  %.not157 = icmp eq i32 %38, %40
  %41 = select i1 %.not157, i32 0, i32 229
  br label %.critedge

42:                                               ; preds = %18
  %43 = getelementptr inbounds i8, ptr %2, i64 65
  %44 = load i8, ptr %43, align 1, !tbaa !44
  %45 = icmp eq i8 %44, 25
  br i1 %45, label %46, label %56

46:                                               ; preds = %42
  %47 = tail call noundef i32 @_ZN3qpl2ml33write_stored_block_and_update_jobEP7qpl_job(ptr noundef nonnull %0)
  %.not154 = icmp eq i32 %47, 0
  br i1 %.not154, label %48, label %.critedge

48:                                               ; preds = %46
  %49 = load i32, ptr %4, align 4, !tbaa !5
  %50 = and i32 %49, 16384
  %.not155 = icmp eq i32 %50, 0
  br i1 %.not155, label %51, label %53

51:                                               ; preds = %48
  %52 = tail call i32 @hw_submit_verify_job(ptr noundef nonnull %0)
  br label %.critedge

53:                                               ; preds = %48
  %54 = load i32, ptr %8, align 4, !tbaa !20
  %55 = xor i32 %54, 1
  store i32 %55, ptr %8, align 4, !tbaa !20
  br label %.critedge

56:                                               ; preds = %42
  %57 = tail call noundef i32 @_ZN3qpl2ml4utilL25convert_status_iaa_to_qplEPVK20hw_completion_record(ptr noundef nonnull %3)
  %58 = load i32, ptr %4, align 4, !tbaa !5
  %59 = and i32 %58, 1
  %60 = icmp ne i32 %59, 0
  %61 = icmp ne i32 %57, 0
  %or.cond = and i1 %61, %60
  br i1 %or.cond, label %62, label %76

62:                                               ; preds = %56
  %63 = and i32 %58, 8
  %.not141 = icmp eq i32 %63, 0
  %64 = lshr i32 %58, 18
  %spec.select = and i32 %64, 2
  %.0133 = select i1 %.not141, i32 %spec.select, i32 10
  %65 = getelementptr inbounds i8, ptr %0, i64 16
  %66 = load ptr, ptr %65, align 8, !tbaa !45
  %67 = zext nneg i32 %.0133 to i64
  %68 = sub nsw i64 0, %67
  %69 = getelementptr inbounds i8, ptr %66, i64 %68
  store ptr %69, ptr %65, align 8, !tbaa !45
  %70 = getelementptr inbounds i8, ptr %0, i64 24
  %71 = load i32, ptr %70, align 8, !tbaa !46
  %72 = add i32 %71, %.0133
  store i32 %72, ptr %70, align 8, !tbaa !46
  %73 = getelementptr inbounds i8, ptr %0, i64 28
  %74 = load i32, ptr %73, align 4, !tbaa !47
  %75 = sub i32 %74, %.0133
  store i32 %75, ptr %73, align 4, !tbaa !47
  br label %76

76:                                               ; preds = %62, %56
  %77 = getelementptr inbounds i8, ptr %2, i64 39704
  %78 = load i32, ptr %77, align 8, !tbaa !48
  %.not143 = icmp eq i32 %78, 0
  %brmerge.not = and i1 %61, %.not143
  br i1 %brmerge.not, label %.critedge, label %79

79:                                               ; preds = %76
  %80 = and i32 %58, 18
  %81 = icmp eq i32 %80, 18
  br i1 %81, label %82, label %98

82:                                               ; preds = %79
  %83 = tail call noundef zeroext i1 @_ZN3qpl2ml4util38are_iaa_gen_2_min_capabilities_presentEv()
  br i1 %83, label %98, label %84

84:                                               ; preds = %82
  %85 = getelementptr inbounds i8, ptr %2, i64 88
  %86 = load i32, ptr %85, align 1, !tbaa !39
  %87 = and i32 %86, 1
  %.not144 = icmp eq i32 %87, 0
  %88 = getelementptr inbounds i8, ptr %2, i64 92
  %89 = load i8, ptr %88, align 1, !tbaa !49
  %90 = icmp eq i8 %89, 0
  br i1 %.not144, label %96, label %91

91:                                               ; preds = %84
  br i1 %90, label %94, label %92

92:                                               ; preds = %91
  %93 = add i8 %89, 8
  store i8 %93, ptr %88, align 1, !tbaa !49
  br label %94

94:                                               ; preds = %92, %91
  %95 = and i32 %86, -2
  store i32 %95, ptr %85, align 1, !tbaa !39
  br label %98

96:                                               ; preds = %84
  br i1 %90, label %97, label %98

97:                                               ; preds = %96
  store i8 8, ptr %88, align 1, !tbaa !49
  br label %98

98:                                               ; preds = %94, %97, %96, %82, %79
  %99 = getelementptr inbounds i8, ptr %2, i64 38
  %100 = load i16, ptr %99, align 1, !tbaa !50
  %101 = zext i16 %100 to i32
  %102 = and i32 %101, 20480
  %103 = icmp eq i32 %102, 20480
  %104 = and i32 %101, 24576
  %105 = icmp eq i32 %104, 24576
  %or.cond160 = or i1 %103, %105
  br i1 %or.cond160, label %.thread, label %106

106:                                              ; preds = %98
  %107 = and i32 %101, 28672
  %108 = icmp eq i32 %107, 28672
  %109 = and i16 %100, 1
  %.not146 = icmp ne i16 %109, 0
  %brmerge161 = or i1 %.not146, %108
  br i1 %brmerge161, label %.thread, label %110

110:                                              ; preds = %106
  %111 = getelementptr inbounds i8, ptr %2, i64 39716
  %112 = load i32, ptr %111, align 4, !tbaa !51
  %113 = icmp eq i32 %112, 1
  br i1 %113, label %114, label %146

114:                                              ; preds = %110
  %115 = load i32, ptr %77, align 8, !tbaa !48
  %.not147 = icmp eq i32 %115, 0
  br i1 %.not147, label %146, label %.thread

.thread:                                          ; preds = %98, %106, %114
  %116 = getelementptr inbounds i8, ptr %2, i64 39716
  %117 = load i32, ptr %116, align 4, !tbaa !51
  %118 = icmp eq i32 %117, 0
  br i1 %118, label %119, label %140

119:                                              ; preds = %.thread
  %120 = getelementptr inbounds i8, ptr %2, i64 96
  %121 = load i32, ptr %120, align 1, !tbaa !42
  %122 = getelementptr inbounds i8, ptr %0, i64 40
  store i32 %121, ptr %122, align 8, !tbaa !52
  %123 = getelementptr inbounds i8, ptr %2, i64 94
  %124 = load i16, ptr %123, align 1, !tbaa !53
  %125 = zext i16 %124 to i32
  %126 = getelementptr inbounds i8, ptr %0, i64 44
  store i32 %125, ptr %126, align 4, !tbaa !54
  %127 = tail call i32 @hw_descriptor_compress_init_deflate_dynamic(ptr noundef nonnull %2, ptr noundef nonnull %2, ptr noundef nonnull %0, ptr noundef nonnull %12, ptr noundef nonnull %3)
  %.not151 = icmp eq i32 %127, 0
  br i1 %.not151, label %128, label %.critedge

128:                                              ; preds = %119
  %129 = getelementptr inbounds i8, ptr %0, i64 72
  %130 = load ptr, ptr %129, align 8, !tbaa !55
  %.not152 = icmp eq ptr %130, null
  br i1 %.not152, label %140, label %131

131:                                              ; preds = %128
  %132 = tail call noundef i32 @_ZN3qpl2ml11compression27get_dictionary_size_in_aecsER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %130) #4
  %133 = tail call noundef ptr @_ZN3qpl2ml11compression19get_dictionary_dataER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %130) #4
  %134 = tail call noundef zeroext i8 @_ZN3qpl2ml11compression24get_load_dictionary_flagER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40) %130) #4
  %135 = getelementptr inbounds i8, ptr %130, i64 16
  %136 = load i32, ptr %135, align 8, !tbaa !56
  %137 = load i32, ptr %8, align 4, !tbaa !20
  %138 = load i32, ptr %10, align 8, !tbaa !37
  %139 = zext i8 %134 to i32
  tail call void @hw_iaa_descriptor_compress_setup_dictionary(ptr noundef nonnull %2, i32 noundef %132, ptr noundef %133, i32 noundef %136, ptr noundef nonnull %7, i32 noundef %137, i32 noundef %138, i32 noundef %139)
  br label %140

140:                                              ; preds = %131, %128, %.thread
  %141 = getelementptr inbounds i8, ptr %0, i64 188
  %142 = load i32, ptr %141, align 4, !tbaa !60
  %143 = tail call noundef i32 @_ZN3qpl2ml4util18process_descriptorI10qpl_statusLNS1_16execution_mode_tE1EEET_P13hw_descriptorPV20hw_completion_recordi(ptr noundef nonnull %2, ptr noundef nonnull %3, i32 noundef %142) #4
  %.not153 = icmp eq i32 %143, 0
  br i1 %.not153, label %145, label %144

144:                                              ; preds = %140
  store i32 1, ptr %77, align 8, !tbaa !48
  store i32 1, ptr %116, align 4, !tbaa !51
  br label %.critedge

145:                                              ; preds = %140
  store i32 0, ptr %77, align 8, !tbaa !48
  br label %.critedge

146:                                              ; preds = %114, %110
  %147 = load i32, ptr %19, align 1, !tbaa !38
  %148 = and i32 %147, 786432
  %149 = icmp eq i32 %148, 262144
  %150 = zext i1 %149 to i32
  %151 = getelementptr inbounds i8, ptr %2, i64 39648
  store i32 %150, ptr %151, align 8, !tbaa !61
  %152 = getelementptr inbounds i8, ptr %2, i64 96
  %153 = load i32, ptr %152, align 1, !tbaa !42
  %154 = getelementptr inbounds i8, ptr %2, i64 39636
  store i32 %153, ptr %154, align 4, !tbaa !43
  %155 = getelementptr inbounds i8, ptr %2, i64 94
  %156 = load i16, ptr %155, align 1, !tbaa !53
  %157 = zext i16 %156 to i32
  tail call void @_ZN3qpl3jobL16update_checksumsEP7qpl_jobjj(ptr noundef nonnull %0, i32 noundef %153, i32 noundef %157) #4
  %158 = load i32, ptr %4, align 4, !tbaa !5
  %159 = and i32 %158, 524288
  %.not148 = icmp eq i32 %159, 0
  br i1 %.not148, label %166, label %160

160:                                              ; preds = %146
  %161 = tail call noundef i32 @_ZN3qpl3jobL11get_adler32EPK7qpl_job(ptr noundef nonnull %0) #4
  %162 = load ptr, ptr %0, align 8, !tbaa !62
  %163 = getelementptr inbounds i8, ptr %0, i64 8
  %164 = load i32, ptr %163, align 8, !tbaa !63
  %165 = tail call noundef i32 @_ZN3qpl2ml4util7adler32EPKhjj(ptr noundef %162, i32 noundef %164, i32 noundef %161) #4
  tail call void @_ZN3qpl3jobL14update_adler32EP7qpl_jobj(ptr noundef nonnull %0, i32 noundef %165) #4
  br label %166

166:                                              ; preds = %160, %146
  %167 = getelementptr inbounds i8, ptr %2, i64 88
  %168 = load i32, ptr %167, align 1, !tbaa !39
  %169 = getelementptr inbounds i8, ptr %2, i64 92
  %170 = load i8, ptr %169, align 1, !tbaa !49
  %171 = zext i8 %170 to i32
  tail call void @_ZN3qpl3jobL20update_output_streamEP7qpl_jobjj(ptr noundef nonnull %0, i32 noundef %168, i32 noundef %171) #4
  br i1 %.not, label %175, label %172

172:                                              ; preds = %166
  %173 = load i32, ptr %152, align 1, !tbaa !42
  %174 = tail call noundef i32 @_ZN3qpl2ml30set_state_to_complete_and_wrapEP7qpl_jobP12qpl_hw_statej(ptr noundef nonnull %0, ptr noundef nonnull %2, i32 noundef %173)
  br label %180

175:                                              ; preds = %166
  %176 = load i32, ptr %4, align 4, !tbaa !5
  %177 = and i32 %176, 8192
  %.not149 = icmp eq i32 %177, 0
  br i1 %.not149, label %178, label %180

178:                                              ; preds = %175
  %179 = getelementptr inbounds i8, ptr %2, i64 39628
  store i32 2, ptr %179, align 4, !tbaa !64
  br label %180

180:                                              ; preds = %175, %178, %172
  %181 = getelementptr inbounds i8, ptr %0, i64 8
  %182 = load i32, ptr %181, align 8, !tbaa !63
  tail call void @_ZN3qpl3jobL19update_input_streamEP7qpl_jobj(ptr noundef nonnull %0, i32 noundef %182) #4
  %183 = load i32, ptr %4, align 4, !tbaa !5
  %184 = and i32 %183, 16384
  %.not150 = icmp eq i32 %184, 0
  br i1 %.not150, label %185, label %187

185:                                              ; preds = %180
  %186 = tail call i32 @hw_submit_verify_job(ptr noundef nonnull %0)
  br label %.critedge

187:                                              ; preds = %180
  %188 = load i32, ptr %8, align 4, !tbaa !20
  %189 = xor i32 %188, 1
  store i32 %189, ptr %8, align 4, !tbaa !20
  br label %.critedge

.critedge:                                        ; preds = %144, %145, %22, %13, %36, %24, %46, %53, %51, %185, %187, %119, %76, %1
  %.9 = phi i32 [ 6, %1 ], [ %23, %22 ], [ 6, %13 ], [ 0, %24 ], [ %41, %36 ], [ 0, %53 ], [ %52, %51 ], [ %47, %46 ], [ %57, %76 ], [ 0, %187 ], [ %186, %185 ], [ %127, %119 ], [ 1, %145 ], [ 5, %144 ]
  ret i32 %.9
}

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

declare i32 @hw_submit_verify_job(ptr noundef) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3qpl2ml4util38are_iaa_gen_2_min_capabilities_presentEv() local_unnamed_addr #1

declare i32 @hw_descriptor_compress_init_deflate_dynamic(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

; Function Attrs: nounwind
declare noundef i32 @_ZN3qpl2ml11compression27get_dictionary_size_in_aecsER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #2

; Function Attrs: nounwind
declare noundef ptr @_ZN3qpl2ml11compression19get_dictionary_dataER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #2

; Function Attrs: nounwind
declare noundef zeroext i8 @_ZN3qpl2ml11compression24get_load_dictionary_flagER14qpl_dictionary(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #2

declare void @hw_iaa_descriptor_compress_setup_dictionary(ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN3qpl2ml4util18process_descriptorI10qpl_statusLNS1_16execution_mode_tE1EEET_P13hw_descriptorPV20hw_completion_recordi(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

attributes #0 = { 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 #1 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 #3 = { "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, !10, i64 36}
!6 = !{!"_ZTS7qpl_job", !7, i64 0, !10, i64 8, !10, i64 12, !7, i64 16, !10, i64 24, !10, i64 28, !11, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !10, i64 48, !12, i64 52, !13, i64 56, !7, i64 64, !7, i64 72, !14, i64 80, !7, i64 88, !10, i64 96, !10, i64 100, !8, i64 104, !8, i64 105, !8, i64 106, !15, i64 112, !15, i64 120, !7, i64 128, !10, i64 136, !10, i64 140, !10, i64 144, !10, i64 148, !16, i64 152, !10, i64 156, !10, i64 160, !10, i64 164, !10, i64 168, !17, i64 172, !10, i64 176, !10, i64 180, !10, i64 184, !10, i64 188, !18, i64 192}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"_ZTS13qpl_operation", !8, i64 0}
!12 = !{!"_ZTS22qpl_compression_levels", !8, i64 0}
!13 = !{!"_ZTS19qpl_statistics_mode", !8, i64 0}
!14 = !{!"_ZTS19qpl_mini_block_size", !8, i64 0}
!15 = !{!"long", !8, i64 0}
!16 = !{!"_ZTS14qpl_out_format", !8, i64 0}
!17 = !{!"_ZTS10qpl_parser", !8, i64 0}
!18 = !{!"_ZTS12qpl_aux_data", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !19, i64 40}
!19 = !{!"_ZTS10qpl_path_t", !8, i64 0}
!20 = !{!21, !10, i64 39652}
!21 = !{!"_ZTS12qpl_hw_state", !22, i64 0, !24, i64 64, !8, i64 128, !8, i64 10880, !25, i64 38592, !26, i64 39624, !10, i64 39648, !10, i64 39652, !10, i64 39656, !30, i64 39660, !10, i64 39664, !31, i64 39672, !10, i64 39704, !10, i64 39708, !27, i64 39712, !27, i64 39713, !33, i64 39716, !34, i64 39720, !35, i64 39728}
!22 = !{!"_ZTS34hw_decompress_analytics_descriptor", !10, i64 0, !10, i64 4, !7, i64 8, !7, i64 16, !7, i64 24, !10, i64 32, !23, i64 36, !23, i64 38, !7, i64 40, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60}
!23 = !{!"short", !8, i64 0}
!24 = !{!"_ZTS24hw_iaa_completion_record", !8, i64 0, !8, i64 1, !8, i64 2, !8, i64 3, !10, i64 4, !15, i64 8, !15, i64 16, !10, i64 24, !8, i64 28, !8, i64 29, !23, i64 30, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !15, i64 48, !15, i64 56}
!25 = !{!"_ZTS10qpl_buffer", !8, i64 0, !10, i64 1024, !10, i64 1028}
!26 = !{!"_ZTS21qpl_execution_history", !27, i64 0, !28, i64 4, !29, i64 8, !10, i64 12, !7, i64 16}
!27 = !{!"bool", !8, i64 0}
!28 = !{!"_ZTS23qpl_task_execution_step", !8, i64 0}
!29 = !{!"_ZTS14qpl_comp_style", !8, i64 0}
!30 = !{!"_ZTS15hw_huffman_code", !23, i64 0, !8, i64 2, !8, i64 3}
!31 = !{!"_ZTS22hw_accelerator_context", !32, i64 0, !7, i64 24}
!32 = !{!"_ZTS20hw_device_properties", !10, i64 0, !10, i64 4, !10, i64 8, !27, i64 12, !27, i64 13, !27, i64 14, !27, i64 15, !27, i64 16, !27, i64 17, !27, i64 18, !27, i64 19, !27, i64 20, !27, i64 21, !27, i64 22}
!33 = !{!"_ZTS25hw_multidescriptor_status", !8, i64 0}
!34 = !{!"_ZTS10qpl_status", !8, i64 0}
!35 = !{!"_ZTS20qpl_execution_record", !36, i64 0, !10, i64 8, !10, i64 12}
!36 = !{!"double", !8, i64 0}
!37 = !{!21, !10, i64 39656}
!38 = !{!22, !10, i64 4}
!39 = !{!24, !10, i64 24}
!40 = !{!6, !10, i64 100}
!41 = !{!21, !10, i64 39708}
!42 = !{!24, !10, i64 32}
!43 = !{!21, !10, i64 39636}
!44 = !{!24, !8, i64 1}
!45 = !{!6, !7, i64 16}
!46 = !{!6, !10, i64 24}
!47 = !{!6, !10, i64 28}
!48 = !{!21, !10, i64 39704}
!49 = !{!24, !8, i64 28}
!50 = !{!22, !23, i64 38}
!51 = !{!21, !33, i64 39716}
!52 = !{!6, !10, i64 40}
!53 = !{!24, !23, i64 30}
!54 = !{!6, !10, i64 44}
!55 = !{!6, !7, i64 72}
!56 = !{!57, !10, i64 16}
!57 = !{!"_ZTS14qpl_dictionary", !58, i64 0, !59, i64 1, !15, i64 8, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32}
!58 = !{!"_ZTS26software_compression_level", !8, i64 0}
!59 = !{!"_ZTS25hardware_dictionary_level", !8, i64 0}
!60 = !{!6, !10, i64 188}
!61 = !{!21, !10, i64 39648}
!62 = !{!6, !7, i64 0}
!63 = !{!6, !10, i64 8}
!64 = !{!21, !28, i64 39628}


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