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

; 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.anon.13 = type { %struct.arm_2d_region_t, %struct.arm_2d_region_t, %struct.arm_2d_location_t, %struct.anon.14, ptr, i32, i32, i8, i8, %struct.anon.15, %struct.anon.16, %struct.anon.17, %struct.arm_2d_scratch_mem_t, %struct.arm_2d_region_t, ptr }
%struct.arm_2d_location_t = type { i16, i16 }
%struct.anon.14 = type { i16, i16 }
%struct.anon.15 = type { i8, i8 }
%struct.anon.16 = type { %struct.arm_2d_size_t, %struct.arm_2d_size_t, %struct.arm_2d_region_t }
%struct.arm_2d_size_t = type { i16, i16 }
%struct.anon.17 = type { %union.anon.18, i16, i16, [65 x i8] }
%union.anon.18 = type { i16 }
%struct.arm_2d_scratch_mem_t = type { %union.anon.19, i64 }
%union.anon.19 = type { %union.anon.20 }
%union.anon.20 = type { %struct.anon.21 }
%struct.anon.21 = type { i32 }
%struct.arm_2d_region_t = type { %union.anon.10, %union.anon.11 }
%union.anon.10 = type { %struct.arm_2d_location_t }
%union.anon.11 = type { %struct.arm_2d_size_t }
%struct.arm_2d_tile_t = type { %union.anon, %union.anon.9, %union.anon.12 }
%union.anon = type { %struct.anon }
%struct.anon = type { i8, %union.arm_2d_color_info_t, %union.anon.2 }
%union.arm_2d_color_info_t = type { %struct.anon.0 }
%struct.anon.0 = type { i8 }
%union.anon.2 = type { i16 }
%union.anon.9 = type { %struct.arm_2d_region_t }
%union.anon.12 = type { ptr }
%struct.__arm_2d_tile_param_t = type { ptr, i32, i16, %union.arm_2d_color_info_t, i8, %struct.arm_2d_region_t, %struct.arm_2d_region_t, ptr }
%union.arm_2d_color_rgb565_t = type { i16 }
%struct.arm_2d_font_t = type { %struct.arm_2d_tile_t, %struct.arm_2d_size_t, i32, ptr, ptr }

@s_tLCDTextControl = external hidden global %struct.anon.13, align 8

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

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @__arm_2d_lcd_text_default_a8_font_draw_char(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i16 noundef zeroext, i8 noundef zeroext, i32 noundef) #3

declare ptr @__arm_2d_tile_region_caculator(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext, i32 noundef, i1 noundef zeroext) #4

declare ptr @arm_2d_tile_generate_child(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext) #4

; Function Attrs: nounwind uwtable
define dso_local i32 @__arm_2d_lcd_text_default_a4_font_draw_char(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i16 noundef zeroext %4, i8 noundef zeroext %5, i32 noundef %6) #3 {
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i16, align 2
  %14 = alloca i8, align 1
  %15 = alloca i32, align 4
  %16 = alloca %struct.arm_2d_tile_t, align 8
  %17 = alloca %struct.__arm_2d_tile_param_t, align 8
  %18 = alloca i8, align 1
  %19 = alloca %struct.arm_2d_region_t, align 2
  %20 = alloca %struct.arm_2d_tile_t, align 8
  %21 = alloca %union.arm_2d_color_rgb565_t, align 2
  store ptr %0, ptr %9, align 8, !tbaa !5
  store ptr %1, ptr %10, align 8, !tbaa !5
  store ptr %2, ptr %11, align 8, !tbaa !5
  store ptr %3, ptr %12, align 8, !tbaa !5
  store i16 %4, ptr %13, align 2, !tbaa !9
  store i8 %5, ptr %14, align 1, !tbaa !11
  store i32 %6, ptr %15, align 4, !tbaa !12
  %22 = load i32, ptr %15, align 4, !tbaa !12
  %23 = icmp ne i32 %22, 0
  br i1 %23, label %24, label %91

24:                                               ; preds = %7
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #5
  %25 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %16, i32 0, i32 0
  %26 = load i8, ptr %25, align 8
  %27 = and i8 %26, -2
  %28 = or i8 %27, 1
  store i8 %28, ptr %25, align 8
  %29 = load i8, ptr %25, align 8
  %30 = and i8 %29, -3
  %31 = or i8 %30, 2
  store i8 %31, ptr %25, align 8
  %32 = load i8, ptr %25, align 8
  %33 = and i8 %32, -5
  %34 = or i8 %33, 0
  store i8 %34, ptr %25, align 8
  %35 = load i8, ptr %25, align 8
  %36 = and i8 %35, -9
  %37 = or i8 %36, 0
  store i8 %37, ptr %25, align 8
  %38 = load i8, ptr %25, align 8
  %39 = and i8 %38, -17
  %40 = or i8 %39, 0
  store i8 %40, ptr %25, align 8
  %41 = load i8, ptr %25, align 8
  %42 = and i8 %41, 31
  %43 = or i8 %42, 0
  store i8 %43, ptr %25, align 8
  %44 = getelementptr inbounds %struct.anon, ptr %25, i32 0, i32 1
  store i8 6, ptr %44, align 1, !tbaa !11
  %45 = getelementptr inbounds %struct.anon, ptr %25, i32 0, i32 2
  call void @llvm.memset.p0.i64(ptr align 2 %45, i8 0, i64 2, i1 false)
  %46 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %16, i32 0, i32 1
  %47 = getelementptr inbounds %struct.arm_2d_region_t, ptr %46, i32 0, i32 0
  call void @llvm.memset.p0.i64(ptr align 4 %47, i8 0, i64 4, i1 false)
  %48 = getelementptr inbounds %struct.arm_2d_region_t, ptr %46, i32 0, i32 1
  %49 = load ptr, ptr %11, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.arm_2d_font_t, ptr %49, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %48, ptr align 8 %50, i64 4, i1 false), !tbaa.struct !14
  %51 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %16, i32 0, i32 2
  %52 = load i64, ptr getelementptr inbounds (%struct.arm_2d_scratch_mem_t, ptr getelementptr inbounds (%struct.anon.13, ptr @s_tLCDTextControl, i32 0, i32 12), i32 0, i32 1), align 8, !tbaa !15
  store i64 %52, ptr %51, align 8, !tbaa !11
  %53 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %16, i32 0, i32 2
  %54 = load i64, ptr %53, align 8, !tbaa !11
  %55 = inttoptr i64 %54 to ptr
  %56 = load i32, ptr getelementptr inbounds (%struct.anon.13, ptr @s_tLCDTextControl, i32 0, i32 12), align 8
  %57 = and i32 %56, 16777215
  %58 = zext i32 %57 to i64
  call void @llvm.memset.p0.i64(ptr align 1 %55, i8 0, i64 %58, i1 false)
  br label %59

59:                                               ; preds = %24
  call void @llvm.lifetime.start.p0(i64 40, ptr %17) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %18) #5
  %60 = load ptr, ptr %12, align 8, !tbaa !5
  %61 = call ptr @__arm_2d_tile_region_caculator(ptr noundef %60, ptr noundef %17, ptr noundef %18, i1 noundef zeroext true, i32 noundef 0, i1 noundef zeroext false)
  %62 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %16, i32 0, i32 2
  %63 = load ptr, ptr %62, align 8, !tbaa !11
  %64 = load ptr, ptr %11, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct.arm_2d_font_t, ptr %64, i32 0, i32 1
  %66 = getelementptr inbounds %struct.arm_2d_size_t, ptr %65, i32 0, i32 0
  %67 = load i16, ptr %66, align 8, !tbaa !26
  %68 = getelementptr inbounds %struct.__arm_2d_tile_param_t, ptr %17, i32 0, i32 0
  %69 = load ptr, ptr %68, align 8, !tbaa !29
  %70 = getelementptr inbounds %struct.__arm_2d_tile_param_t, ptr %17, i32 0, i32 2
  %71 = load i16, ptr %70, align 4, !tbaa !31
  %72 = getelementptr inbounds %struct.__arm_2d_tile_param_t, ptr %17, i32 0, i32 1
  %73 = load i32, ptr %72, align 8, !tbaa !32
  %74 = getelementptr inbounds %struct.__arm_2d_tile_param_t, ptr %17, i32 0, i32 5
  %75 = getelementptr inbounds %struct.arm_2d_region_t, ptr %74, i32 0, i32 1
  call void @__arm_2d_impl_gray8_colour_filling_a4_mask(ptr noundef %63, i16 noundef signext %67, ptr noundef %69, i16 noundef signext %71, i32 noundef %73, ptr noundef %75, i8 noundef zeroext -1)
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr %17) #5
  br label %76

76:                                               ; preds = %59
  br label %77

77:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  %78 = getelementptr inbounds %struct.arm_2d_region_t, ptr %19, i32 0, i32 0
  call void @llvm.memset.p0.i64(ptr align 2 %78, i8 0, i64 4, i1 false)
  %79 = getelementptr inbounds %struct.arm_2d_region_t, ptr %19, i32 0, i32 1
  %80 = load ptr, ptr %12, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.arm_2d_tile_t, ptr %80, i32 0, i32 1
  %82 = getelementptr inbounds %struct.arm_2d_region_t, ptr %81, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 2 %79, ptr align 4 %82, i64 4, i1 false), !tbaa.struct !14
  call void @llvm.lifetime.start.p0(i64 24, ptr %20) #5
  %83 = call ptr @arm_2d_tile_generate_child(ptr noundef %16, ptr noundef %19, ptr noundef %20, i1 noundef zeroext false)
  %84 = load ptr, ptr %9, align 8, !tbaa !5
  %85 = load ptr, ptr %10, align 8, !tbaa !5
  %86 = load ptr, ptr %11, align 8, !tbaa !5
  %87 = load i16, ptr %13, align 2, !tbaa !9
  %88 = load i8, ptr %14, align 1, !tbaa !11
  %89 = load i32, ptr %15, align 4, !tbaa !12
  %90 = call i32 @__arm_2d_lcd_text_default_a8_font_draw_char(ptr noundef %84, ptr noundef %85, ptr noundef %86, ptr noundef %20, i16 noundef zeroext %87, i8 noundef zeroext %88, i32 noundef %89)
  store i32 %90, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #5
  br label %100

91:                                               ; preds = %7
  %92 = load ptr, ptr %9, align 8, !tbaa !5
  %93 = load ptr, ptr %10, align 8, !tbaa !5
  %94 = load ptr, ptr %12, align 8, !tbaa !5
  %95 = load i16, ptr %13, align 2, !tbaa !9
  store i16 %95, ptr %21, align 2, !tbaa !11
  %96 = load i8, ptr %14, align 1, !tbaa !11
  %97 = getelementptr inbounds %union.arm_2d_color_rgb565_t, ptr %21, i32 0, i32 0
  %98 = load i16, ptr %97, align 2
  %99 = call i32 @arm_2dp_rgb565_fill_colour_with_a4_mask_and_opacity(ptr noundef null, ptr noundef %92, ptr noundef %93, ptr noundef %94, i16 %98, i8 noundef zeroext %96)
  store i32 %99, ptr %8, align 4
  br label %100

100:                                              ; preds = %91, %77
  %101 = load i32, ptr %8, align 4
  ret i32 %101
}

declare void @__arm_2d_impl_gray8_colour_filling_a4_mask(ptr noundef, i16 noundef signext, ptr noundef, i16 noundef signext, i32 noundef, ptr noundef, i8 noundef zeroext) #4

declare i32 @arm_2dp_rgb565_fill_colour_with_a4_mask_and_opacity(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i16, i8 noundef zeroext) #4

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"short", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{i64 0, i64 2, !9, i64 2, i64 2, !9}
!15 = !{!16, !25, i64 144}
!16 = !{!"", !17, i64 0, !17, i64 8, !18, i64 16, !19, i64 20, !6, i64 24, !13, i64 32, !13, i64 36, !7, i64 40, !7, i64 41, !20, i64 42, !21, i64 44, !23, i64 60, !24, i64 136, !17, i64 152, !6, i64 160}
!17 = !{!"arm_2d_region_t", !7, i64 0, !7, i64 4}
!18 = !{!"arm_2d_location_t", !10, i64 0, !10, i64 2}
!19 = !{!"", !10, i64 0, !10, i64 2}
!20 = !{!"", !7, i64 0, !7, i64 1}
!21 = !{!"", !22, i64 0, !22, i64 4, !17, i64 8}
!22 = !{!"arm_2d_size_t", !10, i64 0, !10, i64 2}
!23 = !{!"", !7, i64 0, !10, i64 2, !10, i64 4, !7, i64 6}
!24 = !{!"arm_2d_scratch_mem_t", !7, i64 0, !25, i64 8}
!25 = !{!"long", !7, i64 0}
!26 = !{!27, !10, i64 24}
!27 = !{!"arm_2d_font_t", !28, i64 0, !22, i64 24, !13, i64 28, !6, i64 32, !6, i64 40}
!28 = !{!"arm_2d_tile_t", !7, i64 0, !7, i64 4, !7, i64 16}
!29 = !{!30, !6, i64 0}
!30 = !{!"__arm_2d_tile_param_t", !6, i64 0, !13, i64 8, !10, i64 12, !7, i64 14, !7, i64 15, !7, i64 15, !7, i64 15, !17, i64 16, !17, i64 24, !6, i64 32}
!31 = !{!30, !10, i64 12}
!32 = !{!30, !13, i64 8}


; 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.anon.13 = type { %struct.arm_2d_region_t, %struct.arm_2d_region_t, %struct.arm_2d_location_t, %struct.anon.14, ptr, i32, i32, i8, i8, %struct.anon.15, %struct.anon.16, %struct.anon.17, %struct.arm_2d_scratch_mem_t, %struct.arm_2d_region_t, ptr }
%struct.arm_2d_location_t = type { i16, i16 }
%struct.anon.14 = type { i16, i16 }
%struct.anon.15 = type { i8, i8 }
%struct.anon.16 = type { %struct.arm_2d_size_t, %struct.arm_2d_size_t, %struct.arm_2d_region_t }
%struct.arm_2d_size_t = type { i16, i16 }
%struct.anon.17 = type { %union.anon.18, i16, i16, [65 x i8] }
%union.anon.18 = type { i16 }
%struct.arm_2d_scratch_mem_t = type { %union.anon.19, i64 }
%union.anon.19 = type { %union.anon.20 }
%union.anon.20 = type { %struct.anon.21 }
%struct.anon.21 = type { i32 }
%struct.arm_2d_region_t = type { %union.anon.10, %union.anon.11 }
%union.anon.10 = type { %struct.arm_2d_location_t }
%union.anon.11 = type { %struct.arm_2d_size_t }
%struct.arm_2d_tile_t = type { %union.anon, %union.anon.9, %union.anon.12 }
%union.anon = type { %struct.anon }
%struct.anon = type { i8, %union.arm_2d_color_info_t, %union.anon.2 }
%union.arm_2d_color_info_t = type { %struct.anon.0 }
%struct.anon.0 = type { i8 }
%union.anon.2 = type { i16 }
%union.anon.9 = type { %struct.arm_2d_region_t }
%union.anon.12 = type { ptr }
%struct.__arm_2d_tile_param_t = type { ptr, i32, i16, %union.arm_2d_color_info_t, i8, %struct.arm_2d_region_t, %struct.arm_2d_region_t, ptr }

@s_tLCDTextControl = external hidden local_unnamed_addr global %struct.anon.13, align 8

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @__arm_2d_lcd_text_default_a8_font_draw_char(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i16 noundef zeroext, i8 noundef zeroext, i32 noundef) local_unnamed_addr #2

declare ptr @__arm_2d_tile_region_caculator(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext, i32 noundef, i1 noundef zeroext) local_unnamed_addr #3

declare ptr @arm_2d_tile_generate_child(ptr noundef, ptr noundef, ptr noundef, i1 noundef zeroext) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
define dso_local i32 @__arm_2d_lcd_text_default_a4_font_draw_char(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i16 noundef zeroext %4, i8 noundef zeroext %5, i32 noundef %6) local_unnamed_addr #2 {
  %8 = alloca %struct.arm_2d_tile_t, align 8
  %9 = alloca %struct.__arm_2d_tile_param_t, align 8
  %10 = alloca i8, align 1
  %11 = alloca %struct.arm_2d_region_t, align 4
  %12 = alloca %struct.arm_2d_tile_t, align 8
  %.not = icmp eq i32 %6, 0
  br i1 %.not, label %39, label %13

13:                                               ; preds = %7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #4
  store i8 3, ptr %8, align 8
  %14 = getelementptr inbounds i8, ptr %8, i64 1
  store i8 6, ptr %14, align 1, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %8, i64 2
  store i16 0, ptr %15, align 2
  %16 = getelementptr inbounds i8, ptr %8, i64 4
  store i32 0, ptr %16, align 4
  %17 = getelementptr inbounds i8, ptr %8, i64 8
  %18 = getelementptr inbounds i8, ptr %2, i64 24
  %19 = load i32, ptr %18, align 8
  store i32 %19, ptr %17, align 8
  %20 = getelementptr inbounds i8, ptr %8, i64 16
  %21 = load i64, ptr getelementptr inbounds (i8, ptr @s_tLCDTextControl, i64 144), align 8, !tbaa !8
  store i64 %21, ptr %20, align 8, !tbaa !5
  %22 = inttoptr i64 %21 to ptr
  %23 = load i32, ptr getelementptr inbounds (i8, ptr @s_tLCDTextControl, i64 136), align 8
  %24 = and i32 %23, 16777215
  %25 = zext nneg i32 %24 to i64
  tail call void @llvm.memset.p0.i64(ptr align 1 %22, i8 0, i64 %25, i1 false)
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #4
  %26 = call ptr @__arm_2d_tile_region_caculator(ptr noundef %3, ptr noundef nonnull %9, ptr noundef nonnull %10, i1 noundef zeroext true, i32 noundef 0, i1 noundef zeroext false) #4
  %27 = load i16, ptr %18, align 8, !tbaa !22
  %28 = load ptr, ptr %9, align 8, !tbaa !25
  %29 = getelementptr inbounds i8, ptr %9, i64 12
  %30 = load i16, ptr %29, align 4, !tbaa !27
  %31 = getelementptr inbounds i8, ptr %9, i64 8
  %32 = load i32, ptr %31, align 8, !tbaa !28
  %33 = getelementptr inbounds i8, ptr %9, i64 20
  call void @__arm_2d_impl_gray8_colour_filling_a4_mask(ptr noundef %22, i16 noundef signext %27, ptr noundef %28, i16 noundef signext %30, i32 noundef %32, ptr noundef nonnull %33, i8 noundef zeroext -1) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #4
  store i32 0, ptr %11, align 4
  %34 = getelementptr inbounds i8, ptr %11, i64 4
  %35 = getelementptr inbounds i8, ptr %3, i64 8
  %36 = load i32, ptr %35, align 4
  store i32 %36, ptr %34, align 4
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %12) #4
  %37 = call ptr @arm_2d_tile_generate_child(ptr noundef nonnull %8, ptr noundef nonnull %11, ptr noundef nonnull %12, i1 noundef zeroext false) #4
  %38 = call i32 @__arm_2d_lcd_text_default_a8_font_draw_char(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef nonnull %12, i16 noundef zeroext %4, i8 noundef zeroext %5, i32 noundef %6)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #4
  br label %41

39:                                               ; preds = %7
  %40 = tail call i32 @arm_2dp_rgb565_fill_colour_with_a4_mask_and_opacity(ptr noundef null, ptr noundef %0, ptr noundef %1, ptr noundef %3, i16 %4, i8 noundef zeroext %5) #4
  br label %41

41:                                               ; preds = %39, %13
  %.0 = phi i32 [ %38, %13 ], [ %40, %39 ]
  ret i32 %.0
}

declare void @__arm_2d_impl_gray8_colour_filling_a4_mask(ptr noundef, i16 noundef signext, ptr noundef, i16 noundef signext, i32 noundef, ptr noundef, i8 noundef zeroext) local_unnamed_addr #3

declare i32 @arm_2dp_rgb565_fill_colour_with_a4_mask_and_opacity(ptr noundef, ptr noundef, ptr noundef, ptr noundef, i16, i8 noundef zeroext) local_unnamed_addr #3

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C/C++ TBAA"}
!8 = !{!9, !21, i64 144}
!9 = !{!"", !10, i64 0, !10, i64 8, !11, i64 16, !13, i64 20, !14, i64 24, !15, i64 32, !15, i64 36, !6, i64 40, !6, i64 41, !16, i64 42, !17, i64 44, !19, i64 60, !20, i64 136, !10, i64 152, !14, i64 160}
!10 = !{!"arm_2d_region_t", !6, i64 0, !6, i64 4}
!11 = !{!"arm_2d_location_t", !12, i64 0, !12, i64 2}
!12 = !{!"short", !6, i64 0}
!13 = !{!"", !12, i64 0, !12, i64 2}
!14 = !{!"any pointer", !6, i64 0}
!15 = !{!"int", !6, i64 0}
!16 = !{!"", !6, i64 0, !6, i64 1}
!17 = !{!"", !18, i64 0, !18, i64 4, !10, i64 8}
!18 = !{!"arm_2d_size_t", !12, i64 0, !12, i64 2}
!19 = !{!"", !6, i64 0, !12, i64 2, !12, i64 4, !6, i64 6}
!20 = !{!"arm_2d_scratch_mem_t", !6, i64 0, !21, i64 8}
!21 = !{!"long", !6, i64 0}
!22 = !{!23, !12, i64 24}
!23 = !{!"arm_2d_font_t", !24, i64 0, !18, i64 24, !15, i64 28, !14, i64 32, !14, i64 40}
!24 = !{!"arm_2d_tile_t", !6, i64 0, !6, i64 4, !6, i64 16}
!25 = !{!26, !14, i64 0}
!26 = !{!"__arm_2d_tile_param_t", !14, i64 0, !15, i64 8, !12, i64 12, !6, i64 14, !6, i64 15, !6, i64 15, !6, i64 15, !10, i64 16, !10, i64 24, !14, i64 32}
!27 = !{!26, !12, i64 12}
!28 = !{!26, !15, i64 8}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass,TailCallElimPass