; LLVM IR from ARM-software/Arm-2D :: Helper/Source/arm_2d_helper_pfb.ll_ (arm_2d_helper_3fb_draw_bitmap)

; 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.arm_2d_helper_3fb_t = type { %struct.anon.31 }
%struct.anon.31 = type { %struct.arm_2d_helper_3fb_cfg_t, %struct.anon.32 }
%struct.arm_2d_helper_3fb_cfg_t = type { %struct.arm_2d_size_t, i8, [3 x i64], %struct.arm_2d_helper_2d_copy_evt_t, %struct.arm_2d_helper_dma_copy_evt_t }
%struct.arm_2d_size_t = type { i16, i16 }
%struct.arm_2d_helper_2d_copy_evt_t = type { ptr, ptr }
%struct.arm_2d_helper_dma_copy_evt_t = type { ptr, ptr }
%struct.anon.32 = type { i8, [3 x i8], i64, i8 }
%struct.arm_2d_pfb_t = type { ptr, ptr, %struct.arm_2d_tile_t, i32 }
%struct.arm_2d_tile_t = type { %union.anon.8, %union.anon.19, %union.anon.20 }
%union.anon.8 = type { %struct.anon.9 }
%struct.anon.9 = type { i8, %union.arm_2d_color_info_t, %union.anon.12 }
%union.arm_2d_color_info_t = type { %struct.anon.10 }
%struct.anon.10 = type { i8 }
%union.anon.12 = type { i16 }
%union.anon.19 = type { %struct.arm_2d_region_t }
%struct.arm_2d_region_t = type { %union.anon, %union.anon.0 }
%union.anon = type { %struct.arm_2d_location_t }
%struct.arm_2d_location_t = type { i16, i16 }
%union.anon.0 = type { %struct.arm_2d_size_t }
%union.anon.20 = type { ptr }

@.str = external hidden unnamed_addr constant [15 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [87 x i8], align 1
@__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap = external hidden unnamed_addr constant [83 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [36 x i8], align 1

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #0

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

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

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

21:                                               ; preds = %2
  br label %23

22:                                               ; preds = %2
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 3386, ptr noundef @__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap) #3
  unreachable

23:                                               ; preds = %21
  %24 = load ptr, ptr %4, align 8, !tbaa !5
  %25 = icmp ne ptr null, %24
  br i1 %25, label %26, label %27

26:                                               ; preds = %23
  br label %28

27:                                               ; preds = %23
  call void @__assert_fail(ptr noundef @.str.14, ptr noundef @.str.1, i32 noundef 3387, ptr noundef @__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap) #3
  unreachable

28:                                               ; preds = %26
  %29 = load ptr, ptr %3, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %29, i32 0, i32 0
  %31 = getelementptr inbounds %struct.anon.31, ptr %30, i32 0, i32 0
  %32 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %31, i32 0, i32 1
  %33 = load i8, ptr %32, align 4, !tbaa !9
  %34 = zext i8 %33 to i32
  %35 = and i32 %34, 7
  %36 = icmp eq i32 0, %35
  br i1 %36, label %37, label %38

37:                                               ; preds = %28
  br label %39

38:                                               ; preds = %28
  call void @__assert_fail(ptr noundef @.str.15, ptr noundef @.str.1, i32 noundef 3388, ptr noundef @__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap) #3
  unreachable

39:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 2, ptr %5) #4
  %40 = load ptr, ptr %3, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %40, i32 0, i32 0
  %42 = getelementptr inbounds %struct.anon.31, ptr %41, i32 0, i32 0
  %43 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %42, i32 0, i32 0
  %44 = getelementptr inbounds %struct.arm_2d_size_t, ptr %43, i32 0, i32 0
  %45 = load i16, ptr %44, align 8, !tbaa !20
  store i16 %45, ptr %5, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 2, ptr %6) #4
  %46 = load ptr, ptr %3, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %46, i32 0, i32 0
  %48 = getelementptr inbounds %struct.anon.31, ptr %47, i32 0, i32 0
  %49 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %48, i32 0, i32 0
  %50 = getelementptr inbounds %struct.arm_2d_size_t, ptr %49, i32 0, i32 1
  %51 = load i16, ptr %50, align 2, !tbaa !22
  store i16 %51, ptr %6, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #4
  %52 = load ptr, ptr %3, align 8, !tbaa !5
  %53 = load ptr, ptr %4, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %53, i32 0, i32 3
  %55 = load i32, ptr %54, align 8
  %56 = lshr i32 %55, 31
  %57 = icmp ne i32 %56, 0
  %58 = call i64 @__arm_2d_helper_3fb_get_drawing_pointer(ptr noundef %52, i1 noundef zeroext %57)
  store i64 %58, ptr %7, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 1, ptr %8) #4
  %59 = load ptr, ptr %3, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %59, i32 0, i32 0
  %61 = getelementptr inbounds %struct.anon.31, ptr %60, i32 0, i32 0
  %62 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %61, i32 0, i32 1
  %63 = load i8, ptr %62, align 4, !tbaa !9
  %64 = zext i8 %63 to i32
  %65 = ashr i32 %64, 3
  %66 = trunc i32 %65 to i8
  store i8 %66, ptr %8, align 1, !tbaa !24
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  %67 = load i8, ptr %8, align 1, !tbaa !24
  %68 = zext i8 %67 to i32
  %69 = load i16, ptr %5, align 2, !tbaa !21
  %70 = sext i16 %69 to i32
  %71 = mul nsw i32 %68, %70
  store i32 %71, ptr %9, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 2, ptr %10) #4
  %72 = load ptr, ptr %4, align 8, !tbaa !5
  %73 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %72, i32 0, i32 2
  %74 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %73, i32 0, i32 1
  %75 = getelementptr inbounds %struct.arm_2d_region_t, ptr %74, i32 0, i32 0
  %76 = getelementptr inbounds %struct.arm_2d_location_t, ptr %75, i32 0, i32 0
  %77 = load i16, ptr %76, align 4, !tbaa !24
  store i16 %77, ptr %10, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 2, ptr %11) #4
  %78 = load ptr, ptr %4, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %78, i32 0, i32 2
  %80 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %79, i32 0, i32 1
  %81 = getelementptr inbounds %struct.arm_2d_region_t, ptr %80, i32 0, i32 0
  %82 = getelementptr inbounds %struct.arm_2d_location_t, ptr %81, i32 0, i32 1
  %83 = load i16, ptr %82, align 2, !tbaa !24
  store i16 %83, ptr %11, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 2, ptr %12) #4
  %84 = load ptr, ptr %4, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %84, i32 0, i32 2
  %86 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %85, i32 0, i32 1
  %87 = getelementptr inbounds %struct.arm_2d_region_t, ptr %86, i32 0, i32 1
  %88 = getelementptr inbounds %struct.arm_2d_size_t, ptr %87, i32 0, i32 0
  %89 = load i16, ptr %88, align 4, !tbaa !24
  store i16 %89, ptr %12, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 2, ptr %13) #4
  %90 = load ptr, ptr %4, align 8, !tbaa !5
  %91 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %90, i32 0, i32 2
  %92 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %91, i32 0, i32 1
  %93 = getelementptr inbounds %struct.arm_2d_region_t, ptr %92, i32 0, i32 1
  %94 = getelementptr inbounds %struct.arm_2d_size_t, ptr %93, i32 0, i32 1
  %95 = load i16, ptr %94, align 2, !tbaa !24
  store i16 %95, ptr %13, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  %96 = load i8, ptr %8, align 1, !tbaa !24
  %97 = zext i8 %96 to i32
  %98 = load i16, ptr %12, align 2, !tbaa !21
  %99 = sext i16 %98 to i32
  %100 = mul nsw i32 %97, %99
  store i32 %100, ptr %14, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %101 = load i64, ptr %7, align 8, !tbaa !23
  %102 = load i16, ptr %11, align 2, !tbaa !21
  %103 = sext i16 %102 to i32
  %104 = load i16, ptr %5, align 2, !tbaa !21
  %105 = sext i16 %104 to i32
  %106 = mul nsw i32 %103, %105
  %107 = load i16, ptr %10, align 2, !tbaa !21
  %108 = sext i16 %107 to i32
  %109 = add nsw i32 %106, %108
  %110 = load i8, ptr %8, align 1, !tbaa !24
  %111 = zext i8 %110 to i32
  %112 = mul nsw i32 %109, %111
  %113 = sext i32 %112 to i64
  %114 = add i64 %101, %113
  store i64 %114, ptr %15, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  %115 = load ptr, ptr %4, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.arm_2d_pfb_t, ptr %115, i32 0, i32 2
  %117 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %116, i32 0, i32 2
  %118 = load i64, ptr %117, align 8, !tbaa !24
  store i64 %118, ptr %16, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 2, ptr %17) #4
  %119 = load i16, ptr %13, align 2, !tbaa !21
  %120 = sext i16 %119 to i32
  %121 = load i16, ptr %6, align 2, !tbaa !21
  %122 = sext i16 %121 to i32
  %123 = icmp slt i32 %120, %122
  br i1 %123, label %124, label %127

124:                                              ; preds = %39
  %125 = load i16, ptr %13, align 2, !tbaa !21
  %126 = sext i16 %125 to i32
  br label %130

127:                                              ; preds = %39
  %128 = load i16, ptr %6, align 2, !tbaa !21
  %129 = sext i16 %128 to i32
  br label %130

130:                                              ; preds = %127, %124
  %131 = phi i32 [ %126, %124 ], [ %129, %127 ]
  %132 = trunc i32 %131 to i16
  store i16 %132, ptr %17, align 2, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 2, ptr %18) #4
  %133 = load i16, ptr %12, align 2, !tbaa !21
  %134 = sext i16 %133 to i32
  %135 = load i16, ptr %5, align 2, !tbaa !21
  %136 = sext i16 %135 to i32
  %137 = icmp slt i32 %134, %136
  br i1 %137, label %138, label %141

138:                                              ; preds = %130
  %139 = load i16, ptr %12, align 2, !tbaa !21
  %140 = sext i16 %139 to i32
  br label %144

141:                                              ; preds = %130
  %142 = load i16, ptr %5, align 2, !tbaa !21
  %143 = sext i16 %142 to i32
  br label %144

144:                                              ; preds = %141, %138
  %145 = phi i32 [ %140, %138 ], [ %143, %141 ]
  %146 = trunc i32 %145 to i16
  store i16 %146, ptr %18, align 2, !tbaa !21
  %147 = load ptr, ptr %3, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %147, i32 0, i32 0
  %149 = getelementptr inbounds %struct.anon.31, ptr %148, i32 0, i32 0
  %150 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %149, i32 0, i32 3
  %151 = getelementptr inbounds %struct.arm_2d_helper_2d_copy_evt_t, ptr %150, i32 0, i32 0
  %152 = load ptr, ptr %151, align 8, !tbaa !27
  %153 = load ptr, ptr %3, align 8, !tbaa !5
  %154 = load ptr, ptr %3, align 8, !tbaa !5
  %155 = getelementptr inbounds %struct.arm_2d_helper_3fb_t, ptr %154, i32 0, i32 0
  %156 = getelementptr inbounds %struct.anon.31, ptr %155, i32 0, i32 0
  %157 = getelementptr inbounds %struct.arm_2d_helper_3fb_cfg_t, ptr %156, i32 0, i32 3
  %158 = getelementptr inbounds %struct.arm_2d_helper_2d_copy_evt_t, ptr %157, i32 0, i32 1
  %159 = load ptr, ptr %158, align 8, !tbaa !28
  %160 = load i64, ptr %16, align 8, !tbaa !23
  %161 = load i32, ptr %14, align 4, !tbaa !25
  %162 = load i64, ptr %15, align 8, !tbaa !23
  %163 = load i32, ptr %9, align 4, !tbaa !25
  %164 = load i16, ptr %18, align 2, !tbaa !21
  %165 = load i16, ptr %17, align 2, !tbaa !21
  %166 = load i8, ptr %8, align 1, !tbaa !24
  %167 = call zeroext i1 %152(ptr noundef %153, ptr noundef %159, i64 noundef %160, i32 noundef %161, i64 noundef %162, i32 noundef %163, i16 noundef signext %164, i16 noundef signext %165, i8 noundef zeroext %166)
  call void @llvm.lifetime.end.p0(i64 2, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %5) #4
  ret i1 %167
}

; Function Attrs: nounwind uwtable
declare hidden i64 @__arm_2d_helper_3fb_get_drawing_pointer(ptr noundef nonnull, i1 noundef zeroext) #2

attributes #0 = { noreturn 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 = { noreturn nounwind }
attributes #4 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !7, i64 4}
!10 = !{!"arm_2d_helper_3fb_t", !11, i64 0}
!11 = !{!"", !12, i64 0, !17, i64 64}
!12 = !{!"arm_2d_helper_3fb_cfg_t", !13, i64 0, !7, i64 4, !7, i64 8, !15, i64 32, !16, i64 48}
!13 = !{!"arm_2d_size_t", !14, i64 0, !14, i64 2}
!14 = !{!"short", !7, i64 0}
!15 = !{!"arm_2d_helper_2d_copy_evt_t", !6, i64 0, !6, i64 8}
!16 = !{!"arm_2d_helper_dma_copy_evt_t", !6, i64 0, !6, i64 8}
!17 = !{!"", !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 1, !18, i64 8, !19, i64 16}
!18 = !{!"long", !7, i64 0}
!19 = !{!"_Bool", !7, i64 0}
!20 = !{!10, !14, i64 0}
!21 = !{!14, !14, i64 0}
!22 = !{!10, !14, i64 2}
!23 = !{!18, !18, i64 0}
!24 = !{!7, !7, i64 0}
!25 = !{!26, !26, i64 0}
!26 = !{!"int", !7, i64 0}
!27 = !{!10, !6, i64 32}
!28 = !{!10, !6, i64 40}


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

@.str.1 = external hidden unnamed_addr constant [87 x i8], align 1
@__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap = external hidden unnamed_addr constant [83 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [36 x i8], align 1

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local zeroext i1 @__arm_2d_helper_3fb_draw_bitmap(ptr noundef nonnull %0, ptr nocapture noundef nonnull readonly %1) local_unnamed_addr #1 {
  %3 = getelementptr inbounds i8, ptr %0, i64 4
  %4 = load i8, ptr %3, align 4, !tbaa !5
  %5 = and i8 %4, 7
  %6 = icmp eq i8 %5, 0
  br i1 %6, label %8, label %7

7:                                                ; preds = %2
  tail call void @__assert_fail(ptr noundef nonnull @.str.15, ptr noundef nonnull @.str.1, i32 noundef 3388, ptr noundef nonnull @__PRETTY_FUNCTION__.__arm_2d_helper_3fb_draw_bitmap) #3
  unreachable

8:                                                ; preds = %2
  %9 = load i16, ptr %0, align 8, !tbaa !19
  %10 = getelementptr inbounds i8, ptr %0, i64 2
  %11 = load i16, ptr %10, align 2, !tbaa !20
  %12 = getelementptr inbounds i8, ptr %1, i64 40
  %13 = load i32, ptr %12, align 8
  %14 = icmp slt i32 %13, 0
  %15 = tail call i64 @__arm_2d_helper_3fb_get_drawing_pointer(ptr noundef %0, i1 noundef zeroext %14)
  %16 = load i8, ptr %3, align 4, !tbaa !5
  %17 = lshr i8 %16, 3
  %18 = zext nneg i8 %17 to i32
  %19 = sext i16 %9 to i32
  %20 = mul nsw i32 %18, %19
  %21 = getelementptr inbounds i8, ptr %1, i64 20
  %22 = load i16, ptr %21, align 4, !tbaa !21
  %23 = getelementptr inbounds i8, ptr %1, i64 22
  %24 = load i16, ptr %23, align 2, !tbaa !21
  %25 = getelementptr inbounds i8, ptr %1, i64 24
  %26 = load i16, ptr %25, align 4, !tbaa !21
  %27 = getelementptr inbounds i8, ptr %1, i64 26
  %28 = load i16, ptr %27, align 2, !tbaa !21
  %29 = sext i16 %26 to i32
  %30 = mul nsw i32 %29, %18
  %31 = sext i16 %24 to i32
  %32 = mul nsw i32 %31, %19
  %33 = sext i16 %22 to i32
  %34 = add nsw i32 %32, %33
  %35 = mul nsw i32 %34, %18
  %36 = sext i32 %35 to i64
  %37 = add i64 %15, %36
  %38 = getelementptr inbounds i8, ptr %1, i64 32
  %39 = load i64, ptr %38, align 8, !tbaa !21
  %40 = tail call i16 @llvm.smin.i16(i16 %28, i16 %11)
  %41 = tail call i32 @llvm.smin.i32(i32 %29, i32 %19)
  %42 = trunc nsw i32 %41 to i16
  %43 = getelementptr inbounds i8, ptr %0, i64 32
  %44 = load ptr, ptr %43, align 8, !tbaa !22
  %45 = getelementptr inbounds i8, ptr %0, i64 40
  %46 = load ptr, ptr %45, align 8, !tbaa !23
  %47 = tail call zeroext i1 %44(ptr noundef nonnull %0, ptr noundef %46, i64 noundef %39, i32 noundef %30, i64 noundef %37, i32 noundef %20, i16 noundef signext %42, i16 noundef signext %40, i8 noundef zeroext %17) #4
  ret i1 %47
}

; Function Attrs: nounwind uwtable
declare hidden i64 @__arm_2d_helper_3fb_get_drawing_pointer(ptr noundef nonnull, i1 noundef zeroext) local_unnamed_addr #1

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smin.i32(i32, i32) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i16 @llvm.smin.i16(i16, i16) #2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !11, i64 4}
!6 = !{!"arm_2d_helper_3fb_t", !7, i64 0}
!7 = !{!"", !8, i64 0, !16, i64 64}
!8 = !{!"arm_2d_helper_3fb_cfg_t", !9, i64 0, !11, i64 4, !11, i64 8, !13, i64 32, !15, i64 48}
!9 = !{!"arm_2d_size_t", !10, i64 0, !10, i64 2}
!10 = !{!"short", !11, i64 0}
!11 = !{!"omnipotent char", !12, i64 0}
!12 = !{!"Simple C/C++ TBAA"}
!13 = !{!"arm_2d_helper_2d_copy_evt_t", !14, i64 0, !14, i64 8}
!14 = !{!"any pointer", !11, i64 0}
!15 = !{!"arm_2d_helper_dma_copy_evt_t", !14, i64 0, !14, i64 8}
!16 = !{!"", !11, i64 0, !11, i64 0, !11, i64 0, !11, i64 0, !11, i64 1, !17, i64 8, !18, i64 16}
!17 = !{!"long", !11, i64 0}
!18 = !{!"_Bool", !11, i64 0}
!19 = !{!6, !10, i64 0}
!20 = !{!6, !10, i64 2}
!21 = !{!11, !11, i64 0}
!22 = !{!6, !14, i64 32}
!23 = !{!6, !14, i64 40}


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