; LLVM IR from ArefMq/SoccerBallDetection :: src/modules/edgeimage.ll (ZN7MVision9EdgeImage13calculateEdgeERKNS_8Vector2DES3_S3_i)

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

%"class.MVision::Image::Pixel" = type { i8, i8, i8 }
%"class.MVision::EdgeImage" = type { %class.Debugable, %"class.MVision::Image", i32, %"class.std::vector", ptr, %"class.std::vector.0", %"class.std::vector.5" }
%class.Debugable = type { ptr, ptr }
%"class.MVision::Image" = type { i32, i32, i32, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<std::vector<MVision::Vector2D>, std::allocator<std::vector<MVision::Vector2D>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<MVision::Vector2D>, std::allocator<std::vector<MVision::Vector2D>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<MVision::Vector2D>, std::allocator<std::vector<MVision::Vector2D>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<MVision::Vector2D>, std::allocator<std::vector<MVision::Vector2D>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<MVision::Vector2D, std::allocator<MVision::Vector2D>>::_Vector_impl" }
%"struct.std::_Vector_base<MVision::Vector2D, std::allocator<MVision::Vector2D>>::_Vector_impl" = type { %"struct.std::_Vector_base<MVision::Vector2D, std::allocator<MVision::Vector2D>>::_Vector_impl_data" }
%"struct.std::_Vector_base<MVision::Vector2D, std::allocator<MVision::Vector2D>>::_Vector_impl_data" = type { ptr, ptr, ptr }

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

; 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 dso_local noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8)) #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8)) #2 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local i24 @_ZN7MVision9EdgeImage13calculateEdgeERKNS_8Vector2DES3_S3_i(ptr noundef nonnull align 8 dereferenceable(128) %0, ptr noundef nonnull align 4 dereferenceable(8) %1, ptr noundef nonnull align 4 dereferenceable(8) %2, ptr noundef nonnull align 4 dereferenceable(8) %3, i32 noundef %4) #4 align 2 {
  %6 = alloca %"class.MVision::Image::Pixel", align 1
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"class.MVision::Image::Pixel", align 1
  %13 = alloca %"class.MVision::Image::Pixel", align 1
  %14 = alloca %"class.MVision::Image::Pixel", align 1
  %15 = alloca %"class.MVision::Image::Pixel", align 1
  %16 = alloca %"class.MVision::Image::Pixel", align 1
  %17 = alloca %"class.MVision::Image::Pixel", align 1
  %18 = alloca %"class.MVision::Image::Pixel", align 1
  %19 = alloca %"class.MVision::Image::Pixel", align 1
  %20 = alloca %"class.MVision::Image::Pixel", align 1
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca i24, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !5
  store ptr %2, ptr %9, align 8, !tbaa !5
  store ptr %3, ptr %10, align 8, !tbaa !5
  store i32 %4, ptr %11, align 4, !tbaa !9
  %29 = load ptr, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 3, ptr %12) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %12)
  %30 = load ptr, ptr %8, align 8, !tbaa !5
  %31 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %30)
  %32 = fptosi float %31 to i32
  %33 = load ptr, ptr %8, align 8, !tbaa !5
  %34 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %33)
  %35 = fptosi float %34 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %32, i32 noundef %35, ptr noundef nonnull align 1 dereferenceable(3) %12)
  call void @llvm.lifetime.start.p0(i64 3, ptr %13) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %13)
  %36 = load ptr, ptr %9, align 8, !tbaa !5
  %37 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %36)
  %38 = fptosi float %37 to i32
  %39 = load ptr, ptr %8, align 8, !tbaa !5
  %40 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %39)
  %41 = fptosi float %40 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %38, i32 noundef %41, ptr noundef nonnull align 1 dereferenceable(3) %13)
  call void @llvm.lifetime.start.p0(i64 3, ptr %14) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %14)
  %42 = load ptr, ptr %10, align 8, !tbaa !5
  %43 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %42)
  %44 = fptosi float %43 to i32
  %45 = load ptr, ptr %8, align 8, !tbaa !5
  %46 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %45)
  %47 = fptosi float %46 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %44, i32 noundef %47, ptr noundef nonnull align 1 dereferenceable(3) %14)
  call void @llvm.lifetime.start.p0(i64 3, ptr %15) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %15)
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  %49 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %48)
  %50 = fptosi float %49 to i32
  %51 = load ptr, ptr %9, align 8, !tbaa !5
  %52 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %51)
  %53 = fptosi float %52 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %50, i32 noundef %53, ptr noundef nonnull align 1 dereferenceable(3) %15)
  call void @llvm.lifetime.start.p0(i64 3, ptr %16) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %16)
  %54 = load ptr, ptr %9, align 8, !tbaa !5
  %55 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %54)
  %56 = fptosi float %55 to i32
  %57 = load ptr, ptr %9, align 8, !tbaa !5
  %58 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %57)
  %59 = fptosi float %58 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %56, i32 noundef %59, ptr noundef nonnull align 1 dereferenceable(3) %16)
  call void @llvm.lifetime.start.p0(i64 3, ptr %17) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %17)
  %60 = load ptr, ptr %10, align 8, !tbaa !5
  %61 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %60)
  %62 = fptosi float %61 to i32
  %63 = load ptr, ptr %9, align 8, !tbaa !5
  %64 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %63)
  %65 = fptosi float %64 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %62, i32 noundef %65, ptr noundef nonnull align 1 dereferenceable(3) %17)
  call void @llvm.lifetime.start.p0(i64 3, ptr %18) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %18)
  %66 = load ptr, ptr %8, align 8, !tbaa !5
  %67 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %66)
  %68 = fptosi float %67 to i32
  %69 = load ptr, ptr %10, align 8, !tbaa !5
  %70 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %69)
  %71 = fptosi float %70 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %68, i32 noundef %71, ptr noundef nonnull align 1 dereferenceable(3) %18)
  call void @llvm.lifetime.start.p0(i64 3, ptr %19) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %19)
  %72 = load ptr, ptr %9, align 8, !tbaa !5
  %73 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %72)
  %74 = fptosi float %73 to i32
  %75 = load ptr, ptr %10, align 8, !tbaa !5
  %76 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %75)
  %77 = fptosi float %76 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %74, i32 noundef %77, ptr noundef nonnull align 1 dereferenceable(3) %19)
  call void @llvm.lifetime.start.p0(i64 3, ptr %20) #7
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %20)
  %78 = load ptr, ptr %10, align 8, !tbaa !5
  %79 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %78)
  %80 = fptosi float %79 to i32
  %81 = load ptr, ptr %10, align 8, !tbaa !5
  %82 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %81)
  %83 = fptosi float %82 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %29, i32 noundef %80, i32 noundef %83, ptr noundef nonnull align 1 dereferenceable(3) %20)
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #7
  %84 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 0
  %85 = load i8, ptr %84, align 1, !tbaa !11
  %86 = zext i8 %85 to i32
  %87 = sub nsw i32 0, %86
  %88 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %13, i32 0, i32 0
  %89 = load i8, ptr %88, align 1, !tbaa !11
  %90 = zext i8 %89 to i32
  %91 = mul nsw i32 2, %90
  %92 = sub nsw i32 %87, %91
  %93 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 0
  %94 = load i8, ptr %93, align 1, !tbaa !11
  %95 = zext i8 %94 to i32
  %96 = sub nsw i32 %92, %95
  %97 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 0
  %98 = load i8, ptr %97, align 1, !tbaa !11
  %99 = zext i8 %98 to i32
  %100 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %19, i32 0, i32 0
  %101 = load i8, ptr %100, align 1, !tbaa !11
  %102 = zext i8 %101 to i32
  %103 = mul nsw i32 2, %102
  %104 = add nsw i32 %99, %103
  %105 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 0
  %106 = load i8, ptr %105, align 1, !tbaa !11
  %107 = zext i8 %106 to i32
  %108 = add nsw i32 %104, %107
  %109 = add nsw i32 %96, %108
  %110 = sdiv i32 %109, 4
  store i32 %110, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #7
  %111 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 1
  %112 = load i8, ptr %111, align 1, !tbaa !13
  %113 = zext i8 %112 to i32
  %114 = sub nsw i32 0, %113
  %115 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %13, i32 0, i32 1
  %116 = load i8, ptr %115, align 1, !tbaa !13
  %117 = zext i8 %116 to i32
  %118 = mul nsw i32 2, %117
  %119 = sub nsw i32 %114, %118
  %120 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 1
  %121 = load i8, ptr %120, align 1, !tbaa !13
  %122 = zext i8 %121 to i32
  %123 = sub nsw i32 %119, %122
  %124 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 1
  %125 = load i8, ptr %124, align 1, !tbaa !13
  %126 = zext i8 %125 to i32
  %127 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %19, i32 0, i32 1
  %128 = load i8, ptr %127, align 1, !tbaa !13
  %129 = zext i8 %128 to i32
  %130 = mul nsw i32 2, %129
  %131 = add nsw i32 %126, %130
  %132 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 1
  %133 = load i8, ptr %132, align 1, !tbaa !13
  %134 = zext i8 %133 to i32
  %135 = add nsw i32 %131, %134
  %136 = add nsw i32 %123, %135
  %137 = sdiv i32 %136, 4
  store i32 %137, ptr %22, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #7
  %138 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 2
  %139 = load i8, ptr %138, align 1, !tbaa !14
  %140 = zext i8 %139 to i32
  %141 = sub nsw i32 0, %140
  %142 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %13, i32 0, i32 2
  %143 = load i8, ptr %142, align 1, !tbaa !14
  %144 = zext i8 %143 to i32
  %145 = mul nsw i32 2, %144
  %146 = sub nsw i32 %141, %145
  %147 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 2
  %148 = load i8, ptr %147, align 1, !tbaa !14
  %149 = zext i8 %148 to i32
  %150 = sub nsw i32 %146, %149
  %151 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 2
  %152 = load i8, ptr %151, align 1, !tbaa !14
  %153 = zext i8 %152 to i32
  %154 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %19, i32 0, i32 2
  %155 = load i8, ptr %154, align 1, !tbaa !14
  %156 = zext i8 %155 to i32
  %157 = mul nsw i32 2, %156
  %158 = add nsw i32 %153, %157
  %159 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 2
  %160 = load i8, ptr %159, align 1, !tbaa !14
  %161 = zext i8 %160 to i32
  %162 = add nsw i32 %158, %161
  %163 = add nsw i32 %150, %162
  %164 = sdiv i32 %163, 4
  store i32 %164, ptr %23, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #7
  %165 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 0
  %166 = load i8, ptr %165, align 1, !tbaa !11
  %167 = zext i8 %166 to i32
  %168 = sub nsw i32 0, %167
  %169 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %15, i32 0, i32 0
  %170 = load i8, ptr %169, align 1, !tbaa !11
  %171 = zext i8 %170 to i32
  %172 = mul nsw i32 2, %171
  %173 = sub nsw i32 %168, %172
  %174 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 0
  %175 = load i8, ptr %174, align 1, !tbaa !11
  %176 = zext i8 %175 to i32
  %177 = sub nsw i32 %173, %176
  %178 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 0
  %179 = load i8, ptr %178, align 1, !tbaa !11
  %180 = zext i8 %179 to i32
  %181 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %17, i32 0, i32 0
  %182 = load i8, ptr %181, align 1, !tbaa !11
  %183 = zext i8 %182 to i32
  %184 = mul nsw i32 2, %183
  %185 = add nsw i32 %180, %184
  %186 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 0
  %187 = load i8, ptr %186, align 1, !tbaa !11
  %188 = zext i8 %187 to i32
  %189 = add nsw i32 %185, %188
  %190 = add nsw i32 %177, %189
  %191 = sdiv i32 %190, 4
  store i32 %191, ptr %24, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #7
  %192 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 1
  %193 = load i8, ptr %192, align 1, !tbaa !13
  %194 = zext i8 %193 to i32
  %195 = sub nsw i32 0, %194
  %196 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %15, i32 0, i32 1
  %197 = load i8, ptr %196, align 1, !tbaa !13
  %198 = zext i8 %197 to i32
  %199 = mul nsw i32 2, %198
  %200 = sub nsw i32 %195, %199
  %201 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 1
  %202 = load i8, ptr %201, align 1, !tbaa !13
  %203 = zext i8 %202 to i32
  %204 = sub nsw i32 %200, %203
  %205 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 1
  %206 = load i8, ptr %205, align 1, !tbaa !13
  %207 = zext i8 %206 to i32
  %208 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %17, i32 0, i32 1
  %209 = load i8, ptr %208, align 1, !tbaa !13
  %210 = zext i8 %209 to i32
  %211 = mul nsw i32 2, %210
  %212 = add nsw i32 %207, %211
  %213 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 1
  %214 = load i8, ptr %213, align 1, !tbaa !13
  %215 = zext i8 %214 to i32
  %216 = add nsw i32 %212, %215
  %217 = add nsw i32 %204, %216
  %218 = sdiv i32 %217, 4
  store i32 %218, ptr %25, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #7
  %219 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %12, i32 0, i32 2
  %220 = load i8, ptr %219, align 1, !tbaa !14
  %221 = zext i8 %220 to i32
  %222 = sub nsw i32 0, %221
  %223 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %15, i32 0, i32 2
  %224 = load i8, ptr %223, align 1, !tbaa !14
  %225 = zext i8 %224 to i32
  %226 = mul nsw i32 2, %225
  %227 = sub nsw i32 %222, %226
  %228 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %18, i32 0, i32 2
  %229 = load i8, ptr %228, align 1, !tbaa !14
  %230 = zext i8 %229 to i32
  %231 = sub nsw i32 %227, %230
  %232 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %14, i32 0, i32 2
  %233 = load i8, ptr %232, align 1, !tbaa !14
  %234 = zext i8 %233 to i32
  %235 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %17, i32 0, i32 2
  %236 = load i8, ptr %235, align 1, !tbaa !14
  %237 = zext i8 %236 to i32
  %238 = mul nsw i32 2, %237
  %239 = add nsw i32 %234, %238
  %240 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %20, i32 0, i32 2
  %241 = load i8, ptr %240, align 1, !tbaa !14
  %242 = zext i8 %241 to i32
  %243 = add nsw i32 %239, %242
  %244 = add nsw i32 %231, %243
  %245 = sdiv i32 %244, 4
  store i32 %245, ptr %26, align 4, !tbaa !9
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %6)
  %246 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %6, i32 0, i32 2
  store i8 127, ptr %246, align 1, !tbaa !14
  %247 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %6, i32 0, i32 1
  store i8 127, ptr %247, align 1, !tbaa !13
  %248 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %6, i32 0, i32 0
  store i8 1, ptr %248, align 1, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #7
  %249 = load i32, ptr %21, align 4, !tbaa !9
  %250 = load i32, ptr %21, align 4, !tbaa !9
  %251 = mul nsw i32 %249, %250
  %252 = load i32, ptr %22, align 4, !tbaa !9
  %253 = load i32, ptr %22, align 4, !tbaa !9
  %254 = mul nsw i32 %252, %253
  %255 = add nsw i32 %251, %254
  %256 = load i32, ptr %23, align 4, !tbaa !9
  %257 = load i32, ptr %23, align 4, !tbaa !9
  %258 = mul nsw i32 %256, %257
  %259 = add nsw i32 %255, %258
  %260 = load i32, ptr %24, align 4, !tbaa !9
  %261 = load i32, ptr %24, align 4, !tbaa !9
  %262 = mul nsw i32 %260, %261
  %263 = add nsw i32 %259, %262
  %264 = load i32, ptr %25, align 4, !tbaa !9
  %265 = load i32, ptr %25, align 4, !tbaa !9
  %266 = mul nsw i32 %264, %265
  %267 = add nsw i32 %263, %266
  %268 = load i32, ptr %26, align 4, !tbaa !9
  %269 = load i32, ptr %26, align 4, !tbaa !9
  %270 = mul nsw i32 %268, %269
  %271 = add nsw i32 %267, %270
  %272 = sitofp i32 %271 to double
  %273 = call double @sqrt(double noundef %272) #7
  %274 = fptosi double %273 to i32
  store i32 %274, ptr %27, align 4, !tbaa !9
  %275 = load i32, ptr %27, align 4, !tbaa !9
  %276 = load i32, ptr %11, align 4, !tbaa !9
  %277 = icmp sgt i32 %275, %276
  br i1 %277, label %278, label %282

278:                                              ; preds = %5
  %279 = getelementptr inbounds %"class.MVision::Image::Pixel", ptr %6, i32 0, i32 0
  store i8 -1, ptr %279, align 1, !tbaa !11
  %280 = getelementptr inbounds %"class.MVision::EdgeImage", ptr %29, i32 0, i32 6
  %281 = load ptr, ptr %9, align 8, !tbaa !5
  call void @_ZNSt6vectorIN7MVision8Vector2DESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %280, ptr noundef nonnull align 4 dereferenceable(8) %281)
  br label %282

282:                                              ; preds = %278, %5
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %19) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 3, ptr %12) #7
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %28, ptr align 1 %6, i64 3, i1 false)
  %283 = load i24, ptr %28, align 4
  ret i24 %283
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128), i32 noundef, i32 noundef, ptr noundef nonnull align 1 dereferenceable(3)) #5 align 2

; Function Attrs: nounwind
declare double @sqrt(double noundef) #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN7MVision8Vector2DESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(8)) #4 align 2

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

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

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


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

%"class.MVision::Image::Pixel" = type { i8, i8, i8 }

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

; 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 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 dso_local noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local i24 @_ZN7MVision9EdgeImage13calculateEdgeERKNS_8Vector2DES3_S3_i(ptr noundef nonnull align 8 dereferenceable(128) %0, ptr noundef nonnull align 4 dereferenceable(8) %1, ptr noundef nonnull align 4 dereferenceable(8) %2, ptr noundef nonnull align 4 dereferenceable(8) %3, i32 noundef %4) local_unnamed_addr #3 align 2 {
  %6 = alloca %"class.MVision::Image::Pixel", align 4
  %7 = alloca %"class.MVision::Image::Pixel", align 1
  %8 = alloca %"class.MVision::Image::Pixel", align 1
  %9 = alloca %"class.MVision::Image::Pixel", align 1
  %10 = alloca %"class.MVision::Image::Pixel", align 1
  %11 = alloca %"class.MVision::Image::Pixel", align 1
  %12 = alloca %"class.MVision::Image::Pixel", align 1
  %13 = alloca %"class.MVision::Image::Pixel", align 1
  %14 = alloca %"class.MVision::Image::Pixel", align 1
  %15 = alloca %"class.MVision::Image::Pixel", align 1
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %7) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %7)
  %16 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %17 = fptosi float %16 to i32
  %18 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %19 = fptosi float %18 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %17, i32 noundef %19, ptr noundef nonnull align 1 dereferenceable(3) %7)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %8) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %8)
  %20 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %21 = fptosi float %20 to i32
  %22 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %23 = fptosi float %22 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %21, i32 noundef %23, ptr noundef nonnull align 1 dereferenceable(3) %8)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %9) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %9)
  %24 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %25 = fptosi float %24 to i32
  %26 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %27 = fptosi float %26 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %25, i32 noundef %27, ptr noundef nonnull align 1 dereferenceable(3) %9)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %10) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %10)
  %28 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %29 = fptosi float %28 to i32
  %30 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %31 = fptosi float %30 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %29, i32 noundef %31, ptr noundef nonnull align 1 dereferenceable(3) %10)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %11) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %11)
  %32 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %33 = fptosi float %32 to i32
  %34 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %35 = fptosi float %34 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %33, i32 noundef %35, ptr noundef nonnull align 1 dereferenceable(3) %11)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %12) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %12)
  %36 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %37 = fptosi float %36 to i32
  %38 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %39 = fptosi float %38 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %37, i32 noundef %39, ptr noundef nonnull align 1 dereferenceable(3) %12)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %13) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %13)
  %40 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %1)
  %41 = fptosi float %40 to i32
  %42 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %43 = fptosi float %42 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %41, i32 noundef %43, ptr noundef nonnull align 1 dereferenceable(3) %13)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %14) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %14)
  %44 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %2)
  %45 = fptosi float %44 to i32
  %46 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %47 = fptosi float %46 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %45, i32 noundef %47, ptr noundef nonnull align 1 dereferenceable(3) %14)
  call void @llvm.lifetime.start.p0(i64 3, ptr nonnull %15) #6
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %15)
  %48 = call noundef float @_ZNK7MVision8Vector2D1xEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %49 = fptosi float %48 to i32
  %50 = call noundef float @_ZNK7MVision8Vector2D1yEv(ptr noundef nonnull align 4 dereferenceable(8) %3)
  %51 = fptosi float %50 to i32
  call void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128) %0, i32 noundef %49, i32 noundef %51, ptr noundef nonnull align 1 dereferenceable(3) %15)
  %52 = load i8, ptr %7, align 1, !tbaa !5
  %53 = zext i8 %52 to i32
  %54 = load i8, ptr %8, align 1, !tbaa !5
  %55 = zext i8 %54 to i32
  %56 = load i8, ptr %9, align 1, !tbaa !5
  %57 = zext i8 %56 to i32
  %58 = load i8, ptr %13, align 1, !tbaa !5
  %59 = zext i8 %58 to i32
  %60 = load i8, ptr %14, align 1, !tbaa !5
  %61 = zext i8 %60 to i32
  %62 = load i8, ptr %15, align 1, !tbaa !5
  %63 = zext i8 %62 to i32
  %reass.add = sub nsw i32 %61, %55
  %reass.mul = shl nsw i32 %reass.add, 1
  %64 = add nuw nsw i32 %57, %53
  %.neg45 = sub nsw i32 %59, %64
  %65 = add nsw i32 %.neg45, %63
  %66 = add nsw i32 %65, %reass.mul
  %.lhs.trunc = trunc nsw i32 %66 to i16
  %67 = sdiv i16 %.lhs.trunc, 4
  %.sext = sext i16 %67 to i32
  %68 = getelementptr inbounds i8, ptr %7, i64 1
  %69 = load i8, ptr %68, align 1, !tbaa !9
  %70 = zext i8 %69 to i32
  %71 = getelementptr inbounds i8, ptr %8, i64 1
  %72 = load i8, ptr %71, align 1, !tbaa !9
  %73 = zext i8 %72 to i32
  %74 = getelementptr inbounds i8, ptr %9, i64 1
  %75 = load i8, ptr %74, align 1, !tbaa !9
  %76 = zext i8 %75 to i32
  %77 = getelementptr inbounds i8, ptr %13, i64 1
  %78 = load i8, ptr %77, align 1, !tbaa !9
  %79 = zext i8 %78 to i32
  %80 = getelementptr inbounds i8, ptr %14, i64 1
  %81 = load i8, ptr %80, align 1, !tbaa !9
  %82 = zext i8 %81 to i32
  %83 = getelementptr inbounds i8, ptr %15, i64 1
  %84 = load i8, ptr %83, align 1, !tbaa !9
  %85 = zext i8 %84 to i32
  %reass.add62 = sub nsw i32 %82, %73
  %reass.mul63 = shl nsw i32 %reass.add62, 1
  %86 = add nuw nsw i32 %76, %70
  %.neg48 = sub nsw i32 %79, %86
  %87 = add nsw i32 %.neg48, %85
  %88 = add nsw i32 %87, %reass.mul63
  %.lhs.trunc34 = trunc nsw i32 %88 to i16
  %89 = sdiv i16 %.lhs.trunc34, 4
  %.sext35 = sext i16 %89 to i32
  %90 = getelementptr inbounds i8, ptr %7, i64 2
  %91 = load i8, ptr %90, align 1, !tbaa !10
  %92 = zext i8 %91 to i32
  %93 = getelementptr inbounds i8, ptr %8, i64 2
  %94 = load i8, ptr %93, align 1, !tbaa !10
  %95 = zext i8 %94 to i32
  %96 = getelementptr inbounds i8, ptr %9, i64 2
  %97 = load i8, ptr %96, align 1, !tbaa !10
  %98 = zext i8 %97 to i32
  %99 = getelementptr inbounds i8, ptr %13, i64 2
  %100 = load i8, ptr %99, align 1, !tbaa !10
  %101 = zext i8 %100 to i32
  %102 = getelementptr inbounds i8, ptr %14, i64 2
  %103 = load i8, ptr %102, align 1, !tbaa !10
  %104 = zext i8 %103 to i32
  %105 = getelementptr inbounds i8, ptr %15, i64 2
  %106 = load i8, ptr %105, align 1, !tbaa !10
  %107 = zext i8 %106 to i32
  %reass.add65 = sub nsw i32 %104, %95
  %reass.mul66 = shl nsw i32 %reass.add65, 1
  %108 = add nuw nsw i32 %98, %92
  %.neg51 = sub nsw i32 %101, %108
  %109 = add nsw i32 %.neg51, %107
  %110 = add nsw i32 %109, %reass.mul66
  %.lhs.trunc36 = trunc nsw i32 %110 to i16
  %111 = sdiv i16 %.lhs.trunc36, 4
  %.sext37 = sext i16 %111 to i32
  %112 = load i8, ptr %10, align 1, !tbaa !5
  %113 = zext i8 %112 to i32
  %114 = load i8, ptr %12, align 1, !tbaa !5
  %115 = zext i8 %114 to i32
  %reass.add68 = sub nsw i32 %115, %113
  %reass.mul69 = shl nsw i32 %reass.add68, 1
  %116 = add nuw nsw i32 %53, %59
  %.neg54 = sub nsw i32 %57, %116
  %117 = add nsw i32 %.neg54, %63
  %118 = add nsw i32 %117, %reass.mul69
  %.lhs.trunc38 = trunc nsw i32 %118 to i16
  %119 = sdiv i16 %.lhs.trunc38, 4
  %.sext39 = sext i16 %119 to i32
  %120 = getelementptr inbounds i8, ptr %10, i64 1
  %121 = load i8, ptr %120, align 1, !tbaa !9
  %122 = zext i8 %121 to i32
  %123 = getelementptr inbounds i8, ptr %12, i64 1
  %124 = load i8, ptr %123, align 1, !tbaa !9
  %125 = zext i8 %124 to i32
  %reass.add71 = sub nsw i32 %125, %122
  %reass.mul72 = shl nsw i32 %reass.add71, 1
  %126 = add nuw nsw i32 %70, %79
  %.neg57 = sub nsw i32 %76, %126
  %127 = add nsw i32 %.neg57, %85
  %128 = add nsw i32 %127, %reass.mul72
  %.lhs.trunc40 = trunc nsw i32 %128 to i16
  %129 = sdiv i16 %.lhs.trunc40, 4
  %.sext41 = sext i16 %129 to i32
  %130 = getelementptr inbounds i8, ptr %10, i64 2
  %131 = load i8, ptr %130, align 1, !tbaa !10
  %132 = zext i8 %131 to i32
  %133 = getelementptr inbounds i8, ptr %12, i64 2
  %134 = load i8, ptr %133, align 1, !tbaa !10
  %135 = zext i8 %134 to i32
  %reass.add74 = sub nsw i32 %135, %132
  %reass.mul75 = shl nsw i32 %reass.add74, 1
  %136 = add nuw nsw i32 %92, %101
  %.neg60 = sub nsw i32 %98, %136
  %137 = add nsw i32 %.neg60, %107
  %138 = add nsw i32 %137, %reass.mul75
  %.lhs.trunc42 = trunc nsw i32 %138 to i16
  %139 = sdiv i16 %.lhs.trunc42, 4
  %.sext43 = sext i16 %139 to i32
  call void @_ZN7MVision5Image5PixelC2Ev(ptr noundef nonnull align 1 dereferenceable(3) %6)
  %140 = getelementptr inbounds i8, ptr %6, i64 2
  store i8 127, ptr %140, align 2, !tbaa !10
  %141 = getelementptr inbounds i8, ptr %6, i64 1
  store i8 127, ptr %141, align 1, !tbaa !9
  store i8 1, ptr %6, align 4, !tbaa !5
  %142 = mul nsw i32 %.sext, %.sext
  %143 = mul nsw i32 %.sext35, %.sext35
  %144 = add nuw nsw i32 %143, %142
  %145 = mul nsw i32 %.sext37, %.sext37
  %146 = add nuw nsw i32 %144, %145
  %147 = mul nsw i32 %.sext39, %.sext39
  %148 = add nuw nsw i32 %146, %147
  %149 = mul nsw i32 %.sext41, %.sext41
  %150 = add nuw nsw i32 %148, %149
  %151 = mul nsw i32 %.sext43, %.sext43
  %152 = add nuw nsw i32 %150, %151
  %153 = uitofp nneg i32 %152 to double
  %sqrt = call double @llvm.sqrt.f64(double %153)
  %154 = fptosi double %sqrt to i32
  %155 = icmp sgt i32 %154, %4
  br i1 %155, label %156, label %158

156:                                              ; preds = %5
  store i8 -1, ptr %6, align 4, !tbaa !5
  %157 = getelementptr inbounds i8, ptr %0, i64 104
  call void @_ZNSt6vectorIN7MVision8Vector2DESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %157, ptr noundef nonnull align 4 dereferenceable(8) %2)
  br label %158

158:                                              ; preds = %156, %5
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %15) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %14) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %13) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %12) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %11) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %8) #6
  call void @llvm.lifetime.end.p0(i64 3, ptr nonnull %7) #6
  %.0.copyload = load i24, ptr %6, align 4
  ret i24 %.0.copyload
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN7MVision9EdgeImage19getSafeOrginalPixelEiiRNS_5Image5PixelE(ptr noundef nonnull align 8 dereferenceable(128), i32 noundef, i32 noundef, ptr noundef nonnull align 1 dereferenceable(3)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN7MVision8Vector2DESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.sqrt.f64(double) #5

attributes #0 = { 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 #1 = { mustprogress 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 = { 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 #4 = { inlinehint 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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 0}
!6 = !{!"_ZTSN7MVision5Image5PixelE", !7, i64 0, !7, i64 1, !7, i64 2}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!6, !7, i64 1}
!10 = !{!6, !7, i64 2}


; Effective O3 passes: AggressiveInstCombinePass,CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,ReassociatePass,SROAPass