; LLVM IR from mobile-algorithm-optimization/guide :: OpenCLGaussian (main)

; 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.timeval = type { i64, i64 }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@.str = external hidden unnamed_addr constant [34 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca ptr, align 8
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca %struct.timeval, align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.std::__cxx11::basic_string", align 8
  %14 = alloca %"class.std::allocator", align 1
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca %"class.std::__cxx11::basic_string", align 8
  %18 = alloca ptr, align 8
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  %26 = alloca ptr, align 8
  %27 = alloca i32, align 4
  %28 = alloca [3 x i64], align 16
  %29 = alloca i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  %32 = alloca [2 x i64], align 16
  %33 = alloca i32, align 4
  %34 = alloca ptr, align 8
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #8
  store i32 0, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #8
  call void @llvm.lifetime.start.p0(i64 16, ptr %11) #8
  %35 = call noundef ptr @_Z13CreateContextPP13_cl_device_id(ptr noundef %2)
  store ptr %35, ptr %3, align 8, !tbaa !9
  %36 = load ptr, ptr %3, align 8, !tbaa !9
  %37 = icmp eq ptr null, %36
  br i1 %37, label %38, label %40

38:                                               ; preds = %0
  %39 = call i32 (ptr, ...) @printf(ptr noundef @.str)
  store i32 -1, ptr %1, align 4
  store i32 1, ptr %12, align 4
  br label %293

40:                                               ; preds = %0
  %41 = load ptr, ptr %3, align 8, !tbaa !9
  %42 = load ptr, ptr %2, align 8, !tbaa !9
  %43 = call noundef ptr @_Z18CreateCommandQueueP11_cl_contextP13_cl_device_id(ptr noundef %41, ptr noundef %42)
  store ptr %43, ptr %4, align 8, !tbaa !9
  %44 = load ptr, ptr %4, align 8, !tbaa !9
  %45 = icmp eq ptr null, %44
  br i1 %45, label %46, label %48

46:                                               ; preds = %40
  %47 = call i32 (ptr, ...) @printf(ptr noundef @.str.1)
  store i32 -1, ptr %1, align 4
  store i32 1, ptr %12, align 4
  br label %293

48:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 32, ptr %13) #8
  call void @llvm.lifetime.start.p0(i64 1, ptr %14) #8
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #8
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %13, ptr noundef @.str.2, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %49 unwind label %62

49:                                               ; preds = %48
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #8
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #8
  invoke void @_Z12ClReadStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %17, ptr noundef nonnull align 8 dereferenceable(32) %13)
          to label %50 unwind label %66

50:                                               ; preds = %49
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #8
  %51 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %17) #8
  store ptr %51, ptr %18, align 8, !tbaa !9
  %52 = load ptr, ptr %3, align 8, !tbaa !9
  %53 = load ptr, ptr %2, align 8, !tbaa !9
  %54 = load ptr, ptr %18, align 8, !tbaa !9
  %55 = invoke noundef ptr @_Z13CreateProgramP11_cl_contextP13_cl_device_idPc(ptr noundef %52, ptr noundef %53, ptr noundef %54)
          to label %56 unwind label %70

56:                                               ; preds = %50
  store ptr %55, ptr %5, align 8, !tbaa !9
  %57 = load ptr, ptr %5, align 8, !tbaa !9
  %58 = icmp eq ptr null, %57
  br i1 %58, label %59, label %74

59:                                               ; preds = %56
  %60 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.1)
          to label %61 unwind label %70

61:                                               ; preds = %59
  store i32 -1, ptr %1, align 4
  store i32 1, ptr %12, align 4
  br label %289

62:                                               ; preds = %48
  %63 = landingpad { ptr, i32 }
          cleanup
  %64 = extractvalue { ptr, i32 } %63, 0
  store ptr %64, ptr %15, align 8
  %65 = extractvalue { ptr, i32 } %63, 1
  store i32 %65, ptr %16, align 4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #8
  call void @llvm.lifetime.end.p0(i64 1, ptr %14) #8
  br label %292

66:                                               ; preds = %49
  %67 = landingpad { ptr, i32 }
          cleanup
  %68 = extractvalue { ptr, i32 } %67, 0
  store ptr %68, ptr %15, align 8
  %69 = extractvalue { ptr, i32 } %67, 1
  store i32 %69, ptr %16, align 4
  br label %291

70:                                               ; preds = %81, %74, %59, %50
  %71 = landingpad { ptr, i32 }
          cleanup
  %72 = extractvalue { ptr, i32 } %71, 0
  store ptr %72, ptr %15, align 8
  %73 = extractvalue { ptr, i32 } %71, 1
  store i32 %73, ptr %16, align 4
  br label %290

74:                                               ; preds = %56
  %75 = load ptr, ptr %5, align 8, !tbaa !9
  %76 = load ptr, ptr %2, align 8, !tbaa !9
  %77 = invoke noundef ptr @_Z12CreateKernelP11_cl_programPKcP13_cl_device_id(ptr noundef %75, ptr noundef @.str.3, ptr noundef %76)
          to label %78 unwind label %70

78:                                               ; preds = %74
  store ptr %77, ptr %6, align 8, !tbaa !9
  %79 = load ptr, ptr %6, align 8, !tbaa !9
  %80 = icmp eq ptr null, %79
  br i1 %80, label %81, label %84

81:                                               ; preds = %78
  %82 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.4)
          to label %83 unwind label %70

83:                                               ; preds = %81
  store i32 -1, ptr %1, align 4
  store i32 1, ptr %12, align 4
  br label %289

84:                                               ; preds = %78
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #8
  store i32 30, ptr %19, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #8
  store i32 4096, ptr %20, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #8
  store i32 4096, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #8
  %85 = load i32, ptr %20, align 4, !tbaa !5
  store i32 %85, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #8
  %86 = load i32, ptr %20, align 4, !tbaa !5
  store i32 %86, ptr %23, align 4, !tbaa !5
  %87 = load i32, ptr %20, align 4, !tbaa !5
  %88 = load i32, ptr %21, align 4, !tbaa !5
  %89 = mul nsw i32 %87, %88
  %90 = sext i32 %89 to i64
  %91 = mul i64 %90, 1
  %92 = trunc i64 %91 to i32
  store i32 %92, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #8
  %93 = load i32, ptr %10, align 4, !tbaa !5
  %94 = zext i32 %93 to i64
  %95 = call noalias ptr @malloc(i64 noundef %94) #9
  store ptr %95, ptr %24, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #8
  %96 = load i32, ptr %10, align 4, !tbaa !5
  %97 = zext i32 %96 to i64
  %98 = call noalias ptr @malloc(i64 noundef %97) #9
  store ptr %98, ptr %25, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #8
  %99 = load i32, ptr %10, align 4, !tbaa !5
  %100 = zext i32 %99 to i64
  %101 = call noalias ptr @malloc(i64 noundef %100) #9
  store ptr %101, ptr %26, align 8, !tbaa !9
  %102 = load ptr, ptr %26, align 8, !tbaa !9
  %103 = load i32, ptr %10, align 4, !tbaa !5
  %104 = zext i32 %103 to i64
  call void @llvm.memset.p0.i64(ptr align 1 %102, i8 0, i64 %104, i1 false)
  %105 = load ptr, ptr %24, align 8, !tbaa !9
  %106 = load i32, ptr %20, align 4, !tbaa !5
  %107 = load i32, ptr %21, align 4, !tbaa !5
  invoke void @_Z8DataInitPhii(ptr noundef %105, i32 noundef %106, i32 noundef %107)
          to label %108 unwind label %118

108:                                              ; preds = %84
  %109 = load i32, ptr %20, align 4, !tbaa !5
  %110 = load i32, ptr %21, align 4, !tbaa !5
  %111 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %109, i32 noundef %110)
          to label %112 unwind label %118

112:                                              ; preds = %108
  %113 = call i32 @gettimeofday(ptr noundef %11, ptr noundef null) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #8
  store i32 0, ptr %27, align 4, !tbaa !5
  br label %114

114:                                              ; preds = %131, %112
  %115 = load i32, ptr %27, align 4, !tbaa !5
  %116 = icmp slt i32 %115, 30
  br i1 %116, label %122, label %117

117:                                              ; preds = %114
  store i32 2, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #8
  br label %138

118:                                              ; preds = %180, %175, %170, %165, %160, %157, %154, %152, %147, %145, %139, %138, %108, %84
  %119 = landingpad { ptr, i32 }
          cleanup
  %120 = extractvalue { ptr, i32 } %119, 0
  store ptr %120, ptr %15, align 8
  %121 = extractvalue { ptr, i32 } %119, 1
  store i32 %121, ptr %16, align 4
  br label %288

122:                                              ; preds = %114
  %123 = load ptr, ptr %24, align 8, !tbaa !9
  %124 = load i32, ptr %20, align 4, !tbaa !5
  %125 = load i32, ptr %21, align 4, !tbaa !5
  %126 = load i32, ptr %20, align 4, !tbaa !5
  %127 = load ptr, ptr %25, align 8, !tbaa !9
  %128 = load i32, ptr %20, align 4, !tbaa !5
  %129 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %123, i32 noundef %124, i32 noundef %125, i32 noundef %126, ptr noundef %127, i32 noundef %128)
          to label %130 unwind label %134

130:                                              ; preds = %122
  br label %131

131:                                              ; preds = %130
  %132 = load i32, ptr %27, align 4, !tbaa !5
  %133 = add nsw i32 %132, 1
  store i32 %133, ptr %27, align 4, !tbaa !5
  br label %114, !llvm.loop !11

134:                                              ; preds = %122
  %135 = landingpad { ptr, i32 }
          cleanup
  %136 = extractvalue { ptr, i32 } %135, 0
  store ptr %136, ptr %15, align 8
  %137 = extractvalue { ptr, i32 } %135, 1
  store i32 %137, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #8
  br label %288

138:                                              ; preds = %117
  invoke void @_Z13PrintDurationP7timevalPKci(ptr noundef %11, ptr noundef @.str.6, i32 noundef 30)
          to label %139 unwind label %118

139:                                              ; preds = %138
  %140 = load ptr, ptr %3, align 8, !tbaa !9
  %141 = load i32, ptr %10, align 4, !tbaa !5
  %142 = zext i32 %141 to i64
  %143 = load ptr, ptr %24, align 8, !tbaa !9
  %144 = invoke ptr @clCreateBuffer(ptr noundef %140, i64 noundef 36, i64 noundef %142, ptr noundef %143, ptr noundef %9)
          to label %145 unwind label %118

145:                                              ; preds = %139
  store ptr %144, ptr %7, align 8, !tbaa !9
  %146 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %146, ptr noundef @.str.7)
          to label %147 unwind label %118

147:                                              ; preds = %145
  %148 = load ptr, ptr %3, align 8, !tbaa !9
  %149 = load i32, ptr %10, align 4, !tbaa !5
  %150 = zext i32 %149 to i64
  %151 = invoke ptr @clCreateBuffer(ptr noundef %148, i64 noundef 2, i64 noundef %150, ptr noundef null, ptr noundef %9)
          to label %152 unwind label %118

152:                                              ; preds = %147
  store ptr %151, ptr %8, align 8, !tbaa !9
  %153 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %153, ptr noundef @.str.8)
          to label %154 unwind label %118

154:                                              ; preds = %152
  %155 = load ptr, ptr %6, align 8, !tbaa !9
  %156 = invoke i32 @clSetKernelArg(ptr noundef %155, i32 noundef 0, i64 noundef 8, ptr noundef %7)
          to label %157 unwind label %118

157:                                              ; preds = %154
  store i32 %156, ptr %9, align 4, !tbaa !5
  %158 = load ptr, ptr %6, align 8, !tbaa !9
  %159 = invoke i32 @clSetKernelArg(ptr noundef %158, i32 noundef 1, i64 noundef 4, ptr noundef %21)
          to label %160 unwind label %118

160:                                              ; preds = %157
  %161 = load i32, ptr %9, align 4, !tbaa !5
  %162 = or i32 %161, %159
  store i32 %162, ptr %9, align 4, !tbaa !5
  %163 = load ptr, ptr %6, align 8, !tbaa !9
  %164 = invoke i32 @clSetKernelArg(ptr noundef %163, i32 noundef 2, i64 noundef 4, ptr noundef %20)
          to label %165 unwind label %118

165:                                              ; preds = %160
  %166 = load i32, ptr %9, align 4, !tbaa !5
  %167 = or i32 %166, %164
  store i32 %167, ptr %9, align 4, !tbaa !5
  %168 = load ptr, ptr %6, align 8, !tbaa !9
  %169 = invoke i32 @clSetKernelArg(ptr noundef %168, i32 noundef 3, i64 noundef 4, ptr noundef %22)
          to label %170 unwind label %118

170:                                              ; preds = %165
  %171 = load i32, ptr %9, align 4, !tbaa !5
  %172 = or i32 %171, %169
  store i32 %172, ptr %9, align 4, !tbaa !5
  %173 = load ptr, ptr %6, align 8, !tbaa !9
  %174 = invoke i32 @clSetKernelArg(ptr noundef %173, i32 noundef 4, i64 noundef 4, ptr noundef %23)
          to label %175 unwind label %118

175:                                              ; preds = %170
  %176 = load i32, ptr %9, align 4, !tbaa !5
  %177 = or i32 %176, %174
  store i32 %177, ptr %9, align 4, !tbaa !5
  %178 = load ptr, ptr %6, align 8, !tbaa !9
  %179 = invoke i32 @clSetKernelArg(ptr noundef %178, i32 noundef 5, i64 noundef 8, ptr noundef %8)
          to label %180 unwind label %118

180:                                              ; preds = %175
  %181 = load i32, ptr %9, align 4, !tbaa !5
  %182 = or i32 %181, %179
  store i32 %182, ptr %9, align 4, !tbaa !5
  %183 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %183, ptr noundef @.str.9)
          to label %184 unwind label %118

184:                                              ; preds = %180
  call void @llvm.lifetime.start.p0(i64 24, ptr %28) #8
  %185 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 0
  store i64 16, ptr %185, align 16, !tbaa !13
  %186 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 1
  store i64 16, ptr %186, align 8, !tbaa !13
  %187 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 2
  store i64 0, ptr %187, align 16, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #8
  %188 = load i32, ptr %20, align 4, !tbaa !5
  %189 = sub nsw i32 %188, 2
  %190 = ashr i32 %189, 2
  %191 = sub nsw i32 %190, 1
  store i32 %191, ptr %29, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #8
  %192 = load i32, ptr %21, align 4, !tbaa !5
  store i32 %192, ptr %30, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #8
  %193 = load i32, ptr %29, align 4, !tbaa !5
  %194 = shl i32 %193, 2
  store i32 %194, ptr %31, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 16, ptr %32) #8
  %195 = load i32, ptr %29, align 4, !tbaa !5
  %196 = sext i32 %195 to i64
  store i64 %196, ptr %32, align 8, !tbaa !13
  %197 = getelementptr inbounds i64, ptr %32, i64 1
  %198 = load i32, ptr %30, align 4, !tbaa !5
  %199 = sext i32 %198 to i64
  store i64 %199, ptr %197, align 8, !tbaa !13
  %200 = getelementptr inbounds [2 x i64], ptr %32, i64 0, i64 0
  %201 = load i64, ptr %200, align 16, !tbaa !13
  %202 = getelementptr inbounds [2 x i64], ptr %32, i64 0, i64 1
  %203 = load i64, ptr %202, align 8, !tbaa !13
  %204 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.10, i64 noundef %201, i64 noundef %203)
          to label %205 unwind label %217

205:                                              ; preds = %184
  %206 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 0
  %207 = load i64, ptr %206, align 16, !tbaa !13
  %208 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 1
  %209 = load i64, ptr %208, align 8, !tbaa !13
  %210 = invoke i32 (ptr, ...) @printf(ptr noundef @.str.11, i64 noundef %207, i64 noundef %209)
          to label %211 unwind label %217

211:                                              ; preds = %205
  %212 = call i32 @gettimeofday(ptr noundef %11, ptr noundef null) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %33) #8
  store i32 0, ptr %33, align 4, !tbaa !5
  br label %213

213:                                              ; preds = %239, %211
  %214 = load i32, ptr %33, align 4, !tbaa !5
  %215 = icmp slt i32 %214, 30
  br i1 %215, label %221, label %216

216:                                              ; preds = %213
  store i32 5, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #8
  br label %246

217:                                              ; preds = %281, %278, %272, %267, %265, %256, %254, %247, %246, %205, %184
  %218 = landingpad { ptr, i32 }
          cleanup
  %219 = extractvalue { ptr, i32 } %218, 0
  store ptr %219, ptr %15, align 8
  %220 = extractvalue { ptr, i32 } %218, 1
  store i32 %220, ptr %16, align 4
  br label %287

221:                                              ; preds = %213
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #8
  store ptr null, ptr %34, align 8, !tbaa !9
  %222 = load ptr, ptr %4, align 8, !tbaa !9
  %223 = load ptr, ptr %6, align 8, !tbaa !9
  %224 = getelementptr inbounds [2 x i64], ptr %32, i64 0, i64 0
  %225 = getelementptr inbounds [3 x i64], ptr %28, i64 0, i64 0
  %226 = invoke i32 @clEnqueueNDRangeKernel(ptr noundef %222, ptr noundef %223, i32 noundef 2, ptr noundef null, ptr noundef %224, ptr noundef %225, i32 noundef 0, ptr noundef null, ptr noundef %34)
          to label %227 unwind label %242

227:                                              ; preds = %221
  store i32 %226, ptr %9, align 4, !tbaa !5
  %228 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %228, ptr noundef @.str.12)
          to label %229 unwind label %242

229:                                              ; preds = %227
  %230 = invoke i32 @clWaitForEvents(i32 noundef 1, ptr noundef %34)
          to label %231 unwind label %242

231:                                              ; preds = %229
  store i32 %230, ptr %9, align 4, !tbaa !5
  %232 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %232, ptr noundef @.str.13)
          to label %233 unwind label %242

233:                                              ; preds = %231
  %234 = load ptr, ptr %34, align 8, !tbaa !9
  invoke void @_Z18PrintProfilingInfoP9_cl_event(ptr noundef %234)
          to label %235 unwind label %242

235:                                              ; preds = %233
  %236 = load ptr, ptr %34, align 8, !tbaa !9
  %237 = invoke i32 @clReleaseEvent(ptr noundef %236)
          to label %238 unwind label %242

238:                                              ; preds = %235
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #8
  br label %239

239:                                              ; preds = %238
  %240 = load i32, ptr %33, align 4, !tbaa !5
  %241 = add nsw i32 %240, 1
  store i32 %241, ptr %33, align 4, !tbaa !5
  br label %213, !llvm.loop !15

242:                                              ; preds = %235, %233, %231, %229, %227, %221
  %243 = landingpad { ptr, i32 }
          cleanup
  %244 = extractvalue { ptr, i32 } %243, 0
  store ptr %244, ptr %15, align 8
  %245 = extractvalue { ptr, i32 } %243, 1
  store i32 %245, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #8
  br label %287

246:                                              ; preds = %216
  invoke void @_Z13PrintDurationP7timevalPKci(ptr noundef %11, ptr noundef @.str.14, i32 noundef 30)
          to label %247 unwind label %217

247:                                              ; preds = %246
  %248 = load ptr, ptr %4, align 8, !tbaa !9
  %249 = load ptr, ptr %8, align 8, !tbaa !9
  %250 = load i32, ptr %10, align 4, !tbaa !5
  %251 = zext i32 %250 to i64
  %252 = load ptr, ptr %26, align 8, !tbaa !9
  %253 = invoke i32 @clEnqueueReadBuffer(ptr noundef %248, ptr noundef %249, i32 noundef 1, i64 noundef 0, i64 noundef %251, ptr noundef %252, i32 noundef 0, ptr noundef null, ptr noundef null)
          to label %254 unwind label %217

254:                                              ; preds = %247
  store i32 %253, ptr %9, align 4, !tbaa !5
  %255 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %255, ptr noundef @.str.15)
          to label %256 unwind label %217

256:                                              ; preds = %254
  %257 = load ptr, ptr %24, align 8, !tbaa !9
  %258 = load i32, ptr %31, align 4, !tbaa !5
  %259 = load i32, ptr %21, align 4, !tbaa !5
  %260 = load i32, ptr %20, align 4, !tbaa !5
  %261 = load i32, ptr %22, align 4, !tbaa !5
  %262 = load i32, ptr %23, align 4, !tbaa !5
  %263 = load ptr, ptr %26, align 8, !tbaa !9
  %264 = invoke noundef i32 @_Z28Gauss3x3Sigma0U8C1RemainDataPhiiiiiS_(ptr noundef %257, i32 noundef %258, i32 noundef %259, i32 noundef %260, i32 noundef %261, i32 noundef %262, ptr noundef %263)
          to label %265 unwind label %217

265:                                              ; preds = %256
  store i32 %264, ptr %9, align 4, !tbaa !5
  %266 = load i32, ptr %9, align 4, !tbaa !5
  invoke void @_Z13CheckClStatusiPKc(i32 noundef %266, ptr noundef @.str.16)
          to label %267 unwind label %217

267:                                              ; preds = %265
  %268 = load ptr, ptr %25, align 8, !tbaa !9
  %269 = load ptr, ptr %26, align 8, !tbaa !9
  %270 = load i32, ptr %20, align 4, !tbaa !5
  %271 = load i32, ptr %21, align 4, !tbaa !5
  invoke void @_Z11DataComparePhS_ii(ptr noundef %268, ptr noundef %269, i32 noundef %270, i32 noundef %271)
          to label %272 unwind label %217

272:                                              ; preds = %267
  %273 = load ptr, ptr %24, align 8, !tbaa !9
  call void @free(ptr noundef %273) #8
  %274 = load ptr, ptr %25, align 8, !tbaa !9
  call void @free(ptr noundef %274) #8
  %275 = load ptr, ptr %26, align 8, !tbaa !9
  call void @free(ptr noundef %275) #8
  %276 = load ptr, ptr %7, align 8, !tbaa !9
  %277 = invoke i32 @clReleaseMemObject(ptr noundef %276)
          to label %278 unwind label %217

278:                                              ; preds = %272
  %279 = load ptr, ptr %8, align 8, !tbaa !9
  %280 = invoke i32 @clReleaseMemObject(ptr noundef %279)
          to label %281 unwind label %217

281:                                              ; preds = %278
  %282 = load ptr, ptr %3, align 8, !tbaa !9
  %283 = load ptr, ptr %4, align 8, !tbaa !9
  %284 = load ptr, ptr %5, align 8, !tbaa !9
  %285 = load ptr, ptr %6, align 8, !tbaa !9
  invoke void @_Z7CleanUpP11_cl_contextP17_cl_command_queueP11_cl_programP10_cl_kernel(ptr noundef %282, ptr noundef %283, ptr noundef %284, ptr noundef %285)
          to label %286 unwind label %217

286:                                              ; preds = %281
  store i32 0, ptr %1, align 4
  store i32 1, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %28) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #8
  br label %289

287:                                              ; preds = %242, %217
  call void @llvm.lifetime.end.p0(i64 16, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %28) #8
  br label %288

288:                                              ; preds = %287, %134, %118
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #8
  br label %290

289:                                              ; preds = %286, %83, %61
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #8
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %13) #8
  call void @llvm.lifetime.end.p0(i64 32, ptr %13) #8
  br label %293

290:                                              ; preds = %288, %70
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #8
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #8
  br label %291

291:                                              ; preds = %290, %66
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #8
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %13) #8
  br label %292

292:                                              ; preds = %291, %62
  call void @llvm.lifetime.end.p0(i64 32, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #8
  br label %295

293:                                              ; preds = %289, %46, %38
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #8
  %294 = load i32, ptr %1, align 4
  ret i32 %294

295:                                              ; preds = %292
  %296 = load ptr, ptr %15, align 8
  %297 = load i32, ptr %16, align 4
  %298 = insertvalue { ptr, i32 } poison, ptr %296, 0
  %299 = insertvalue { ptr, i32 } %298, i32 %297, 1
  resume { ptr, i32 } %299
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z13CreateContextPP13_cl_device_id(ptr noundef) #2

declare i32 @printf(ptr noundef, ...) #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z18CreateCommandQueueP11_cl_contextP13_cl_device_id(ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z12ClReadStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32)) #2

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32)) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z13CreateProgramP11_cl_contextP13_cl_device_idPc(ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z12CreateKernelP11_cl_programPKcP13_cl_device_id(ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #5

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

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

; Function Attrs: nounwind
declare i32 @gettimeofday(ptr noundef, ptr noundef) #7

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

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

declare ptr @clCreateBuffer(ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef) #3

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

declare i32 @clSetKernelArg(ptr noundef, i32 noundef, i64 noundef, ptr noundef) #3

declare i32 @clEnqueueNDRangeKernel(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) #3

declare i32 @clWaitForEvents(i32 noundef, ptr noundef) #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z18PrintProfilingInfoP9_cl_event(ptr noundef) #2

declare i32 @clReleaseEvent(ptr noundef) #3

declare i32 @clEnqueueReadBuffer(ptr noundef, ptr noundef, i32 noundef, i64 noundef, i64 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) #3

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

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

; Function Attrs: nounwind
declare void @free(ptr noundef) #7

declare i32 @clReleaseMemObject(ptr noundef) #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z7CleanUpP11_cl_contextP17_cl_command_queueP11_cl_programP10_cl_kernel(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

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

!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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = distinct !{!15, !12}


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

%struct.timeval = type { i64, i64 }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@.str = external hidden unnamed_addr constant [34 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [12 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef range(i32 -1, 1) i32 @main() local_unnamed_addr #0 personality ptr @__gxx_personality_v0 {
  %1 = alloca ptr, align 8
  %2 = alloca ptr, align 8
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca %struct.timeval, align 8
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  %7 = alloca %"class.std::allocator", align 1
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca [3 x i64], align 16
  %14 = alloca [2 x i64], align 16
  %15 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %1) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #9
  store i32 0, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #9
  %16 = call noundef ptr @_Z13CreateContextPP13_cl_device_id(ptr noundef nonnull %1)
  %17 = icmp eq ptr %16, null
  br i1 %17, label %18, label %20

18:                                               ; preds = %0
  %19 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str)
  br label %203

20:                                               ; preds = %0
  %21 = load ptr, ptr %1, align 8, !tbaa !9
  %22 = call noundef ptr @_Z18CreateCommandQueueP11_cl_contextP13_cl_device_id(ptr noundef nonnull %16, ptr noundef %21)
  %23 = icmp eq ptr %22, null
  br i1 %23, label %24, label %26

24:                                               ; preds = %20
  %25 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1)
  br label %203

26:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %7) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull @.str.2, ptr noundef nonnull align 1 dereferenceable(1) %7)
          to label %27 unwind label %36

27:                                               ; preds = %26
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #9
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #9
  invoke void @_Z12ClReadStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %8, ptr noundef nonnull align 8 dereferenceable(32) %6)
          to label %28 unwind label %38

28:                                               ; preds = %27
  %29 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  %30 = load ptr, ptr %1, align 8, !tbaa !9
  %31 = invoke noundef ptr @_Z13CreateProgramP11_cl_contextP13_cl_device_idPc(ptr noundef nonnull %16, ptr noundef %30, ptr noundef %29)
          to label %32 unwind label %40

32:                                               ; preds = %28
  %33 = icmp eq ptr %31, null
  br i1 %33, label %34, label %42

34:                                               ; preds = %32
  %35 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1)
  br label %199

36:                                               ; preds = %26
  %37 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %7) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %7) #9
  br label %202

38:                                               ; preds = %27
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %201

40:                                               ; preds = %42, %28
  %41 = landingpad { ptr, i32 }
          cleanup
  br label %200

42:                                               ; preds = %32
  %43 = load ptr, ptr %1, align 8, !tbaa !9
  %44 = invoke noundef ptr @_Z12CreateKernelP11_cl_programPKcP13_cl_device_id(ptr noundef nonnull %31, ptr noundef nonnull @.str.3, ptr noundef %43)
          to label %45 unwind label %40

45:                                               ; preds = %42
  %46 = icmp eq ptr %44, null
  br i1 %46, label %47, label %49

47:                                               ; preds = %45
  %48 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4)
  br label %199

49:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #9
  store i32 4096, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #9
  store i32 4096, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #9
  store i32 4096, ptr %11, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #9
  store i32 4096, ptr %12, align 4, !tbaa !5
  %50 = call noalias dereferenceable_or_null(16777216) ptr @malloc(i64 noundef 16777216) #10
  %51 = call noalias dereferenceable_or_null(16777216) ptr @malloc(i64 noundef 16777216) #10
  %calloc = call dereferenceable_or_null(16777216) ptr @calloc(i64 1, i64 16777216)
  call void @_Z8DataInitPhii(ptr noundef %50, i32 noundef 4096, i32 noundef 4096)
  %52 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef 4096, i32 noundef 4096)
  %53 = call i32 @gettimeofday(ptr noundef nonnull %5, ptr noundef null) #9
  %54 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %57 unwind label %116

55:                                               ; preds = %140, %136, %132, %128, %126, %123, %120, %118, %115
  %56 = landingpad { ptr, i32 }
          cleanup
  br label %198

57:                                               ; preds = %49
  %58 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %59 unwind label %116

59:                                               ; preds = %57
  %60 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %61 unwind label %116

61:                                               ; preds = %59
  %62 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %63 unwind label %116

63:                                               ; preds = %61
  %64 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %65 unwind label %116

65:                                               ; preds = %63
  %66 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %67 unwind label %116

67:                                               ; preds = %65
  %68 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %69 unwind label %116

69:                                               ; preds = %67
  %70 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %71 unwind label %116

71:                                               ; preds = %69
  %72 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %73 unwind label %116

73:                                               ; preds = %71
  %74 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %75 unwind label %116

75:                                               ; preds = %73
  %76 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %77 unwind label %116

77:                                               ; preds = %75
  %78 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %79 unwind label %116

79:                                               ; preds = %77
  %80 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %81 unwind label %116

81:                                               ; preds = %79
  %82 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %83 unwind label %116

83:                                               ; preds = %81
  %84 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %85 unwind label %116

85:                                               ; preds = %83
  %86 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %87 unwind label %116

87:                                               ; preds = %85
  %88 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %89 unwind label %116

89:                                               ; preds = %87
  %90 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %91 unwind label %116

91:                                               ; preds = %89
  %92 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %93 unwind label %116

93:                                               ; preds = %91
  %94 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %95 unwind label %116

95:                                               ; preds = %93
  %96 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %97 unwind label %116

97:                                               ; preds = %95
  %98 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %99 unwind label %116

99:                                               ; preds = %97
  %100 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %101 unwind label %116

101:                                              ; preds = %99
  %102 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %103 unwind label %116

103:                                              ; preds = %101
  %104 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %105 unwind label %116

105:                                              ; preds = %103
  %106 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %107 unwind label %116

107:                                              ; preds = %105
  %108 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %109 unwind label %116

109:                                              ; preds = %107
  %110 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %111 unwind label %116

111:                                              ; preds = %109
  %112 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %113 unwind label %116

113:                                              ; preds = %111
  %114 = invoke noundef i32 @_Z21Gaussian3x3Sigma0U8C1PhiiiS_i(ptr noundef %50, i32 noundef 4096, i32 noundef 4096, i32 noundef 4096, ptr noundef %51, i32 noundef 4096)
          to label %115 unwind label %116

115:                                              ; preds = %113
  invoke void @_Z13PrintDurationP7timevalPKci(ptr noundef nonnull %5, ptr noundef nonnull @.str.6, i32 noundef 30)
          to label %118 unwind label %55

116:                                              ; preds = %113, %111, %109, %107, %105, %103, %101, %99, %97, %95, %93, %91, %89, %87, %85, %83, %81, %79, %77, %75, %73, %71, %69, %67, %65, %63, %61, %59, %57, %49
  %117 = landingpad { ptr, i32 }
          cleanup
  br label %198

118:                                              ; preds = %115
  %119 = invoke ptr @clCreateBuffer(ptr noundef nonnull %16, i64 noundef 36, i64 noundef 16777216, ptr noundef %50, ptr noundef nonnull %4)
          to label %120 unwind label %55

120:                                              ; preds = %118
  store ptr %119, ptr %2, align 8, !tbaa !9
  %121 = load i32, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %121, ptr noundef nonnull @.str.7)
  %122 = invoke ptr @clCreateBuffer(ptr noundef nonnull %16, i64 noundef 2, i64 noundef 16777216, ptr noundef null, ptr noundef nonnull %4)
          to label %123 unwind label %55

123:                                              ; preds = %120
  store ptr %122, ptr %3, align 8, !tbaa !9
  %124 = load i32, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %124, ptr noundef nonnull @.str.8)
  %125 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 0, i64 noundef 8, ptr noundef nonnull %2)
          to label %126 unwind label %55

126:                                              ; preds = %123
  store i32 %125, ptr %4, align 4, !tbaa !5
  %127 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 1, i64 noundef 4, ptr noundef nonnull %10)
          to label %128 unwind label %55

128:                                              ; preds = %126
  %129 = load i32, ptr %4, align 4, !tbaa !5
  %130 = or i32 %129, %127
  store i32 %130, ptr %4, align 4, !tbaa !5
  %131 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 2, i64 noundef 4, ptr noundef nonnull %9)
          to label %132 unwind label %55

132:                                              ; preds = %128
  %133 = load i32, ptr %4, align 4, !tbaa !5
  %134 = or i32 %133, %131
  store i32 %134, ptr %4, align 4, !tbaa !5
  %135 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 3, i64 noundef 4, ptr noundef nonnull %11)
          to label %136 unwind label %55

136:                                              ; preds = %132
  %137 = load i32, ptr %4, align 4, !tbaa !5
  %138 = or i32 %137, %135
  store i32 %138, ptr %4, align 4, !tbaa !5
  %139 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 4, i64 noundef 4, ptr noundef nonnull %12)
          to label %140 unwind label %55

140:                                              ; preds = %136
  %141 = load i32, ptr %4, align 4, !tbaa !5
  %142 = or i32 %141, %139
  store i32 %142, ptr %4, align 4, !tbaa !5
  %143 = invoke i32 @clSetKernelArg(ptr noundef nonnull %44, i32 noundef 5, i64 noundef 8, ptr noundef nonnull %3)
          to label %144 unwind label %55

144:                                              ; preds = %140
  %145 = load i32, ptr %4, align 4, !tbaa !5
  %146 = or i32 %145, %143
  store i32 %146, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %146, ptr noundef nonnull @.str.9)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %13) #9
  store i64 16, ptr %13, align 16, !tbaa !11
  %147 = getelementptr inbounds i8, ptr %13, i64 8
  store i64 16, ptr %147, align 8, !tbaa !11
  %148 = getelementptr inbounds i8, ptr %13, i64 16
  store i64 0, ptr %148, align 16, !tbaa !11
  %149 = load i32, ptr %9, align 4, !tbaa !5
  %150 = add nsw i32 %149, -2
  %151 = ashr i32 %150, 2
  %152 = add nsw i32 %151, -1
  %153 = load i32, ptr %10, align 4, !tbaa !5
  %154 = shl i32 %152, 2
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #9
  %155 = sext i32 %152 to i64
  store i64 %155, ptr %14, align 16, !tbaa !11
  %156 = getelementptr inbounds i8, ptr %14, i64 8
  %157 = sext i32 %153 to i64
  store i64 %157, ptr %156, align 8, !tbaa !11
  %158 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.10, i64 noundef %155, i64 noundef %157)
  %159 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.11, i64 noundef 16, i64 noundef 16)
  %160 = call i32 @gettimeofday(ptr noundef nonnull %5, ptr noundef null) #9
  br label %164

161:                                              ; preds = %173
  invoke void @_Z13PrintDurationP7timevalPKci(ptr noundef nonnull %5, ptr noundef nonnull @.str.14, i32 noundef 30)
          to label %177 unwind label %162

162:                                              ; preds = %195, %192, %189, %186, %180, %177, %161
  %163 = landingpad { ptr, i32 }
          cleanup
  br label %197

164:                                              ; preds = %144, %173
  %.073 = phi i32 [ 0, %144 ], [ %174, %173 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #9
  store ptr null, ptr %15, align 8, !tbaa !9
  %165 = invoke i32 @clEnqueueNDRangeKernel(ptr noundef nonnull %22, ptr noundef nonnull %44, i32 noundef 2, ptr noundef null, ptr noundef nonnull %14, ptr noundef nonnull %13, i32 noundef 0, ptr noundef null, ptr noundef nonnull %15)
          to label %166 unwind label %175

166:                                              ; preds = %164
  store i32 %165, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %165, ptr noundef nonnull @.str.12)
  %167 = invoke i32 @clWaitForEvents(i32 noundef 1, ptr noundef nonnull %15)
          to label %168 unwind label %175

168:                                              ; preds = %166
  store i32 %167, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %167, ptr noundef nonnull @.str.13)
  %169 = load ptr, ptr %15, align 8, !tbaa !9
  invoke void @_Z18PrintProfilingInfoP9_cl_event(ptr noundef %169)
          to label %170 unwind label %175

170:                                              ; preds = %168
  %171 = load ptr, ptr %15, align 8, !tbaa !9
  %172 = invoke i32 @clReleaseEvent(ptr noundef %171)
          to label %173 unwind label %175

173:                                              ; preds = %170
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #9
  %174 = add nuw nsw i32 %.073, 1
  %exitcond74.not = icmp eq i32 %174, 30
  br i1 %exitcond74.not, label %161, label %164, !llvm.loop !13

175:                                              ; preds = %170, %168, %166, %164
  %176 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #9
  br label %197

177:                                              ; preds = %161
  %178 = load ptr, ptr %3, align 8, !tbaa !9
  %179 = invoke i32 @clEnqueueReadBuffer(ptr noundef nonnull %22, ptr noundef %178, i32 noundef 1, i64 noundef 0, i64 noundef 16777216, ptr noundef %calloc, i32 noundef 0, ptr noundef null, ptr noundef null)
          to label %180 unwind label %162

180:                                              ; preds = %177
  store i32 %179, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %179, ptr noundef nonnull @.str.15)
  %181 = load i32, ptr %10, align 4, !tbaa !5
  %182 = load i32, ptr %9, align 4, !tbaa !5
  %183 = load i32, ptr %11, align 4, !tbaa !5
  %184 = load i32, ptr %12, align 4, !tbaa !5
  %185 = invoke noundef i32 @_Z28Gauss3x3Sigma0U8C1RemainDataPhiiiiiS_(ptr noundef %50, i32 noundef %154, i32 noundef %181, i32 noundef %182, i32 noundef %183, i32 noundef %184, ptr noundef %calloc)
          to label %186 unwind label %162

186:                                              ; preds = %180
  store i32 %185, ptr %4, align 4, !tbaa !5
  call void @_Z13CheckClStatusiPKc(i32 noundef %185, ptr noundef nonnull @.str.16)
  %187 = load i32, ptr %9, align 4, !tbaa !5
  %188 = load i32, ptr %10, align 4, !tbaa !5
  invoke void @_Z11DataComparePhS_ii(ptr noundef %51, ptr noundef %calloc, i32 noundef %187, i32 noundef %188)
          to label %189 unwind label %162

189:                                              ; preds = %186
  call void @free(ptr noundef %50) #9
  call void @free(ptr noundef %51) #9
  call void @free(ptr noundef %calloc) #9
  %190 = load ptr, ptr %2, align 8, !tbaa !9
  %191 = invoke i32 @clReleaseMemObject(ptr noundef %190)
          to label %192 unwind label %162

192:                                              ; preds = %189
  %193 = load ptr, ptr %3, align 8, !tbaa !9
  %194 = invoke i32 @clReleaseMemObject(ptr noundef %193)
          to label %195 unwind label %162

195:                                              ; preds = %192
  invoke void @_Z7CleanUpP11_cl_contextP17_cl_command_queueP11_cl_programP10_cl_kernel(ptr noundef nonnull %16, ptr noundef nonnull %22, ptr noundef nonnull %31, ptr noundef nonnull %44)
          to label %196 unwind label %162

196:                                              ; preds = %195
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #9
  br label %199

197:                                              ; preds = %175, %162
  %.pn = phi { ptr, i32 } [ %176, %175 ], [ %163, %162 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %13) #9
  br label %198

198:                                              ; preds = %197, %116, %55
  %.pn67 = phi { ptr, i32 } [ %117, %116 ], [ %.pn, %197 ], [ %56, %55 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #9
  br label %200

199:                                              ; preds = %196, %47, %34
  %.053 = phi i32 [ -1, %34 ], [ -1, %47 ], [ 0, %196 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #9
  br label %203

200:                                              ; preds = %198, %40
  %.pn67.pn = phi { ptr, i32 } [ %.pn67, %198 ], [ %41, %40 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  br label %201

201:                                              ; preds = %200, %38
  %.pn67.pn.pn = phi { ptr, i32 } [ %.pn67.pn, %200 ], [ %39, %38 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #9
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #9
  br label %202

202:                                              ; preds = %201, %36
  %.pn67.pn.pn.pn = phi { ptr, i32 } [ %.pn67.pn.pn, %201 ], [ %37, %36 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #9
  resume { ptr, i32 } %.pn67.pn.pn.pn

203:                                              ; preds = %199, %24, %18
  %.1 = phi i32 [ -1, %18 ], [ -1, %24 ], [ %.053, %199 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %1) #9
  ret i32 %.1
}

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z13CreateContextPP13_cl_device_id(ptr noundef) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z18CreateCommandQueueP11_cl_contextP13_cl_device_id(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z12ClReadStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z13CreateProgramP11_cl_contextP13_cl_device_idPc(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_Z12CreateKernelP11_cl_programPKcP13_cl_device_id(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #5

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

; Function Attrs: nofree nounwind
declare noundef i32 @gettimeofday(ptr nocapture noundef, ptr nocapture noundef) local_unnamed_addr #3

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

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

declare ptr @clCreateBuffer(ptr noundef, i64 noundef, i64 noundef, ptr noundef, ptr noundef) local_unnamed_addr #6

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

declare i32 @clSetKernelArg(ptr noundef, i32 noundef, i64 noundef, ptr noundef) local_unnamed_addr #6

declare i32 @clEnqueueNDRangeKernel(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #6

declare i32 @clWaitForEvents(i32 noundef, ptr noundef) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z18PrintProfilingInfoP9_cl_event(ptr noundef) local_unnamed_addr #2

declare i32 @clReleaseEvent(ptr noundef) local_unnamed_addr #6

declare i32 @clEnqueueReadBuffer(ptr noundef, ptr noundef, i32 noundef, i64 noundef, i64 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #6

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

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

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #7

declare i32 @clReleaseMemObject(ptr noundef) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_Z7CleanUpP11_cl_contextP17_cl_command_queueP11_cl_programP10_cl_kernel(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr #8

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

!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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LoopRotatePass,LoopUnrollPass,SROAPass,SimplifyCFGPass