; LLVM IR from ClementineAccount/Albuquerque :: src/HelloSDL (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.nk_rect = type { float, float, float, float }
%struct.nk_color = type { i8, i8, i8, i8 }
%struct.nk_user_font_glyph = type { [2 x %struct.nk_vec2], %struct.nk_vec2, float, float, float }
%struct.nk_vec2 = type { float, float }
%union.nk_handle = type { ptr }
%struct.nk_draw_list = type { %struct.nk_rect, [12 x %struct.nk_vec2], %struct.nk_convert_config, ptr, ptr, ptr, i32, i32, i32, i64, i32, i32, i32, i32 }
%struct.nk_convert_config = type { float, i32, i32, i32, i32, i32, %struct.nk_draw_null_texture, ptr, i64, i64 }
%struct.nk_draw_null_texture = type { %union.nk_handle, %struct.nk_vec2 }
%struct.nk_user_font = type { %union.nk_handle, float, ptr, ptr, %union.nk_handle }

@.str.1 = external hidden unnamed_addr constant [86 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [5 x i8], align 1
@__PRETTY_FUNCTION__.nk_draw_list_add_text = external hidden unnamed_addr constant [138 x i8], align 1

; 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) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local <2 x float> @nk_vec2(float noundef, float noundef) #1

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

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

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

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

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL23nk_draw_list_push_imageP12nk_draw_list9nk_handle(ptr noundef, ptr) #5

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL25nk_draw_list_push_rect_uvP12nk_draw_list7nk_vec2S1_S1_S1_8nk_color(ptr noundef, <2 x float>, <2 x float>, <2 x float>, <2 x float>, i32) #5

; Function Attrs: mustprogress uwtable
define dso_local void @nk_draw_list_add_text(ptr noundef %0, ptr noundef %1, <2 x float> %2, <2 x float> %3, ptr noundef %4, i32 noundef %5, float noundef %6, i32 %7) #5 {
  %9 = alloca %struct.nk_rect, align 4
  %10 = alloca %struct.nk_color, align 1
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca float, align 4
  %16 = alloca float, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca %struct.nk_user_font_glyph, align 4
  %23 = alloca i32, align 4
  %24 = alloca %union.nk_handle, align 8
  %25 = alloca float, align 4
  %26 = alloca float, align 4
  %27 = alloca float, align 4
  %28 = alloca float, align 4
  %29 = alloca float, align 4
  %30 = alloca %union.nk_handle, align 8
  %31 = alloca %struct.nk_vec2, align 4
  %32 = alloca %struct.nk_vec2, align 4
  %33 = alloca %struct.nk_vec2, align 4
  %34 = alloca %struct.nk_vec2, align 4
  %35 = alloca %struct.nk_color, align 1
  %36 = getelementptr inbounds { <2 x float>, <2 x float> }, ptr %9, i32 0, i32 0
  store <2 x float> %2, ptr %36, align 4
  %37 = getelementptr inbounds { <2 x float>, <2 x float> }, ptr %9, i32 0, i32 1
  store <2 x float> %3, ptr %37, align 4
  store i32 %7, ptr %10, align 1
  store ptr %0, ptr %11, align 8, !tbaa !5
  store ptr %1, ptr %12, align 8, !tbaa !5
  store ptr %4, ptr %13, align 8, !tbaa !5
  store i32 %5, ptr %14, align 4, !tbaa !9
  store float %6, ptr %15, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  store float 0.000000e+00, ptr %16, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  store i32 0, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #6
  store i32 0, ptr %18, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #6
  store i32 0, ptr %19, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #6
  store i32 0, ptr %20, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #6
  store i32 0, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 36, ptr %22) #6
  %38 = load ptr, ptr %11, align 8, !tbaa !5
  %39 = icmp ne ptr %38, null
  br i1 %39, label %40, label %41

40:                                               ; preds = %8
  br label %43

41:                                               ; preds = %8
  call void @__assert_fail(ptr noundef @.str.25, ptr noundef @.str.1, i32 noundef 10540, ptr noundef @__PRETTY_FUNCTION__.nk_draw_list_add_text) #7
  unreachable

42:                                               ; No predecessors!
  br label %43

43:                                               ; preds = %42, %40
  %44 = load ptr, ptr %11, align 8, !tbaa !5
  %45 = icmp ne ptr %44, null
  br i1 %45, label %46, label %52

46:                                               ; preds = %43
  %47 = load i32, ptr %14, align 4, !tbaa !9
  %48 = icmp ne i32 %47, 0
  br i1 %48, label %49, label %52

49:                                               ; preds = %46
  %50 = load ptr, ptr %13, align 8, !tbaa !5
  %51 = icmp ne ptr %50, null
  br i1 %51, label %53, label %52

52:                                               ; preds = %49, %46, %43
  store i32 1, ptr %23, align 4
  br label %217

53:                                               ; preds = %49
  %54 = load ptr, ptr %11, align 8, !tbaa !5
  %55 = getelementptr inbounds %struct.nk_draw_list, ptr %54, i32 0, i32 0
  %56 = getelementptr inbounds %struct.nk_rect, ptr %55, i32 0, i32 0
  %57 = load float, ptr %56, align 8, !tbaa !13
  %58 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 0
  %59 = load float, ptr %58, align 4, !tbaa !21
  %60 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 2
  %61 = load float, ptr %60, align 4, !tbaa !22
  %62 = fadd float %59, %61
  %63 = fcmp olt float %57, %62
  br i1 %63, label %64, label %101

64:                                               ; preds = %53
  %65 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 0
  %66 = load float, ptr %65, align 4, !tbaa !21
  %67 = load ptr, ptr %11, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.nk_draw_list, ptr %67, i32 0, i32 0
  %69 = getelementptr inbounds %struct.nk_rect, ptr %68, i32 0, i32 0
  %70 = load float, ptr %69, align 8, !tbaa !13
  %71 = load ptr, ptr %11, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.nk_draw_list, ptr %71, i32 0, i32 0
  %73 = getelementptr inbounds %struct.nk_rect, ptr %72, i32 0, i32 2
  %74 = load float, ptr %73, align 8, !tbaa !23
  %75 = fadd float %70, %74
  %76 = fcmp olt float %66, %75
  br i1 %76, label %77, label %101

77:                                               ; preds = %64
  %78 = load ptr, ptr %11, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.nk_draw_list, ptr %78, i32 0, i32 0
  %80 = getelementptr inbounds %struct.nk_rect, ptr %79, i32 0, i32 1
  %81 = load float, ptr %80, align 4, !tbaa !24
  %82 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 1
  %83 = load float, ptr %82, align 4, !tbaa !25
  %84 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 3
  %85 = load float, ptr %84, align 4, !tbaa !26
  %86 = fadd float %83, %85
  %87 = fcmp olt float %81, %86
  br i1 %87, label %88, label %101

88:                                               ; preds = %77
  %89 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 1
  %90 = load float, ptr %89, align 4, !tbaa !25
  %91 = load ptr, ptr %11, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.nk_draw_list, ptr %91, i32 0, i32 0
  %93 = getelementptr inbounds %struct.nk_rect, ptr %92, i32 0, i32 1
  %94 = load float, ptr %93, align 4, !tbaa !24
  %95 = load ptr, ptr %11, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.nk_draw_list, ptr %95, i32 0, i32 0
  %97 = getelementptr inbounds %struct.nk_rect, ptr %96, i32 0, i32 3
  %98 = load float, ptr %97, align 4, !tbaa !27
  %99 = fadd float %94, %98
  %100 = fcmp olt float %90, %99
  br i1 %100, label %102, label %101

101:                                              ; preds = %88, %77, %64, %53
  store i32 1, ptr %23, align 4
  br label %217

102:                                              ; preds = %88
  %103 = load ptr, ptr %11, align 8, !tbaa !5
  %104 = load ptr, ptr %12, align 8, !tbaa !5
  %105 = getelementptr inbounds %struct.nk_user_font, ptr %104, i32 0, i32 4
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %24, ptr align 8 %105, i64 8, i1 false), !tbaa.struct !28
  %106 = getelementptr inbounds %union.nk_handle, ptr %24, i32 0, i32 0
  %107 = load ptr, ptr %106, align 8
  call void @_ZL23nk_draw_list_push_imageP12nk_draw_list9nk_handle(ptr noundef %103, ptr %107)
  %108 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 0
  %109 = load float, ptr %108, align 4, !tbaa !21
  store float %109, ptr %16, align 4, !tbaa !11
  %110 = load ptr, ptr %13, align 8, !tbaa !5
  %111 = load i32, ptr %14, align 4, !tbaa !9
  %112 = call i32 @nk_utf_decode(ptr noundef %110, ptr noundef %18, i32 noundef %111)
  store i32 %112, ptr %20, align 4, !tbaa !9
  %113 = load i32, ptr %20, align 4, !tbaa !9
  %114 = icmp ne i32 %113, 0
  br i1 %114, label %116, label %115

115:                                              ; preds = %102
  store i32 1, ptr %23, align 4
  br label %217

116:                                              ; preds = %102
  %117 = getelementptr inbounds %struct.nk_color, ptr %10, i32 0, i32 3
  %118 = load i8, ptr %117, align 1, !tbaa !30
  %119 = uitofp i8 %118 to float
  %120 = load ptr, ptr %11, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct.nk_draw_list, ptr %120, i32 0, i32 2
  %122 = getelementptr inbounds %struct.nk_convert_config, ptr %121, i32 0, i32 0
  %123 = load float, ptr %122, align 8, !tbaa !32
  %124 = fmul float %119, %123
  %125 = fptoui float %124 to i8
  %126 = getelementptr inbounds %struct.nk_color, ptr %10, i32 0, i32 3
  store i8 %125, ptr %126, align 1, !tbaa !30
  br label %127

127:                                              ; preds = %215, %116
  %128 = load i32, ptr %17, align 4, !tbaa !9
  %129 = load i32, ptr %14, align 4, !tbaa !9
  %130 = icmp slt i32 %128, %129
  br i1 %130, label %131, label %134

131:                                              ; preds = %127
  %132 = load i32, ptr %20, align 4, !tbaa !9
  %133 = icmp ne i32 %132, 0
  br label %134

134:                                              ; preds = %131, %127
  %135 = phi i1 [ false, %127 ], [ %133, %131 ]
  br i1 %135, label %136, label %216

136:                                              ; preds = %134
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #6
  store float 0.000000e+00, ptr %29, align 4, !tbaa !11
  %137 = load i32, ptr %18, align 4, !tbaa !9
  %138 = icmp eq i32 %137, 65533
  br i1 %138, label %139, label %140

139:                                              ; preds = %136
  store i32 3, ptr %23, align 4
  br label %213

140:                                              ; preds = %136
  %141 = load ptr, ptr %13, align 8, !tbaa !5
  %142 = load i32, ptr %17, align 4, !tbaa !9
  %143 = sext i32 %142 to i64
  %144 = getelementptr inbounds i8, ptr %141, i64 %143
  %145 = load i32, ptr %20, align 4, !tbaa !9
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds i8, ptr %144, i64 %146
  %148 = load i32, ptr %14, align 4, !tbaa !9
  %149 = load i32, ptr %17, align 4, !tbaa !9
  %150 = sub nsw i32 %148, %149
  %151 = call i32 @nk_utf_decode(ptr noundef %147, ptr noundef %19, i32 noundef %150)
  store i32 %151, ptr %21, align 4, !tbaa !9
  %152 = load ptr, ptr %12, align 8, !tbaa !5
  %153 = getelementptr inbounds %struct.nk_user_font, ptr %152, i32 0, i32 3
  %154 = load ptr, ptr %153, align 8, !tbaa !33
  %155 = load ptr, ptr %12, align 8, !tbaa !5
  %156 = getelementptr inbounds %struct.nk_user_font, ptr %155, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %30, ptr align 8 %156, i64 8, i1 false), !tbaa.struct !28
  %157 = load float, ptr %15, align 4, !tbaa !11
  %158 = load i32, ptr %18, align 4, !tbaa !9
  %159 = load i32, ptr %19, align 4, !tbaa !9
  %160 = icmp eq i32 %159, 65533
  br i1 %160, label %161, label %162

161:                                              ; preds = %140
  br label %164

162:                                              ; preds = %140
  %163 = load i32, ptr %19, align 4, !tbaa !9
  br label %164

164:                                              ; preds = %162, %161
  %165 = phi i32 [ 0, %161 ], [ %163, %162 ]
  %166 = getelementptr inbounds %union.nk_handle, ptr %30, i32 0, i32 0
  %167 = load ptr, ptr %166, align 8
  call void %154(ptr %167, float noundef %157, ptr noundef %22, i32 noundef %158, i32 noundef %165)
  %168 = load float, ptr %16, align 4, !tbaa !11
  %169 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 1
  %170 = getelementptr inbounds %struct.nk_vec2, ptr %169, i32 0, i32 0
  %171 = load float, ptr %170, align 4, !tbaa !35
  %172 = fadd float %168, %171
  store float %172, ptr %25, align 4, !tbaa !11
  %173 = getelementptr inbounds %struct.nk_rect, ptr %9, i32 0, i32 1
  %174 = load float, ptr %173, align 4, !tbaa !25
  %175 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 1
  %176 = getelementptr inbounds %struct.nk_vec2, ptr %175, i32 0, i32 1
  %177 = load float, ptr %176, align 4, !tbaa !37
  %178 = fadd float %174, %177
  store float %178, ptr %26, align 4, !tbaa !11
  %179 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 2
  %180 = load float, ptr %179, align 4, !tbaa !38
  store float %180, ptr %28, align 4, !tbaa !11
  %181 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 3
  %182 = load float, ptr %181, align 4, !tbaa !39
  store float %182, ptr %27, align 4, !tbaa !11
  %183 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 4
  %184 = load float, ptr %183, align 4, !tbaa !40
  store float %184, ptr %29, align 4, !tbaa !11
  %185 = load ptr, ptr %11, align 8, !tbaa !5
  %186 = load float, ptr %25, align 4, !tbaa !11
  %187 = load float, ptr %26, align 4, !tbaa !11
  %188 = call <2 x float> @nk_vec2(float noundef %186, float noundef %187)
  store <2 x float> %188, ptr %31, align 4
  %189 = load float, ptr %25, align 4, !tbaa !11
  %190 = load float, ptr %28, align 4, !tbaa !11
  %191 = fadd float %189, %190
  %192 = load float, ptr %26, align 4, !tbaa !11
  %193 = load float, ptr %27, align 4, !tbaa !11
  %194 = fadd float %192, %193
  %195 = call <2 x float> @nk_vec2(float noundef %191, float noundef %194)
  store <2 x float> %195, ptr %32, align 4
  %196 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 0
  %197 = getelementptr inbounds [2 x %struct.nk_vec2], ptr %196, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %33, ptr align 4 %197, i64 8, i1 false), !tbaa.struct !41
  %198 = getelementptr inbounds %struct.nk_user_font_glyph, ptr %22, i32 0, i32 0
  %199 = getelementptr inbounds [2 x %struct.nk_vec2], ptr %198, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %34, ptr align 4 %199, i64 8, i1 false), !tbaa.struct !41
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %35, ptr align 1 %10, i64 4, i1 false), !tbaa.struct !42
  %200 = load <2 x float>, ptr %31, align 4
  %201 = load <2 x float>, ptr %32, align 4
  %202 = load <2 x float>, ptr %33, align 4
  %203 = load <2 x float>, ptr %34, align 4
  %204 = load i32, ptr %35, align 1
  call void @_ZL25nk_draw_list_push_rect_uvP12nk_draw_list7nk_vec2S1_S1_S1_8nk_color(ptr noundef %185, <2 x float> %200, <2 x float> %201, <2 x float> %202, <2 x float> %203, i32 %204)
  %205 = load i32, ptr %20, align 4, !tbaa !9
  %206 = load i32, ptr %17, align 4, !tbaa !9
  %207 = add nsw i32 %206, %205
  store i32 %207, ptr %17, align 4, !tbaa !9
  %208 = load float, ptr %29, align 4, !tbaa !11
  %209 = load float, ptr %16, align 4, !tbaa !11
  %210 = fadd float %209, %208
  store float %210, ptr %16, align 4, !tbaa !11
  %211 = load i32, ptr %21, align 4, !tbaa !9
  store i32 %211, ptr %20, align 4, !tbaa !9
  %212 = load i32, ptr %19, align 4, !tbaa !9
  store i32 %212, ptr %18, align 4, !tbaa !9
  store i32 0, ptr %23, align 4
  br label %213

213:                                              ; preds = %164, %139
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #6
  %214 = load i32, ptr %23, align 4
  switch i32 %214, label %220 [
    i32 0, label %215
    i32 3, label %216
  ]

215:                                              ; preds = %213
  br label %127, !llvm.loop !43

216:                                              ; preds = %213, %134
  store i32 0, ptr %23, align 4
  br label %217

217:                                              ; preds = %216, %115, %101, %52
  call void @llvm.lifetime.end.p0(i64 36, ptr %22) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #6
  %218 = load i32, ptr %23, align 4
  switch i32 %218, label %220 [
    i32 0, label %219
    i32 1, label %219
  ]

219:                                              ; preds = %217, %217
  ret void

220:                                              ; preds = %217, %213
  unreachable
}

attributes #0 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="64" "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 willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #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 = { mustprogress uwtable "min-legal-vector-width"="64" "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 }
attributes #7 = { noreturn 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, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{!14, !12, i64 0}
!14 = !{!"_ZTS12nk_draw_list", !15, i64 0, !7, i64 16, !16, i64 112, !6, i64 176, !6, i64 184, !6, i64 192, !10, i64 200, !10, i64 204, !10, i64 208, !20, i64 216, !10, i64 224, !10, i64 228, !17, i64 232, !17, i64 236}
!15 = !{!"_ZTS7nk_rect", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12}
!16 = !{!"_ZTS17nk_convert_config", !12, i64 0, !17, i64 4, !17, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !18, i64 24, !6, i64 40, !20, i64 48, !20, i64 56}
!17 = !{!"_ZTS16nk_anti_aliasing", !7, i64 0}
!18 = !{!"_ZTS20nk_draw_null_texture", !7, i64 0, !19, i64 8}
!19 = !{!"_ZTS7nk_vec2", !12, i64 0, !12, i64 4}
!20 = !{!"long", !7, i64 0}
!21 = !{!15, !12, i64 0}
!22 = !{!15, !12, i64 8}
!23 = !{!14, !12, i64 8}
!24 = !{!14, !12, i64 4}
!25 = !{!15, !12, i64 4}
!26 = !{!15, !12, i64 12}
!27 = !{!14, !12, i64 12}
!28 = !{i64 0, i64 8, !29}
!29 = !{!7, !7, i64 0}
!30 = !{!31, !7, i64 3}
!31 = !{!"_ZTS8nk_color", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3}
!32 = !{!14, !12, i64 112}
!33 = !{!34, !6, i64 24}
!34 = !{!"_ZTS12nk_user_font", !7, i64 0, !12, i64 8, !6, i64 16, !6, i64 24, !7, i64 32}
!35 = !{!36, !12, i64 16}
!36 = !{!"_ZTS18nk_user_font_glyph", !7, i64 0, !19, i64 16, !12, i64 24, !12, i64 28, !12, i64 32}
!37 = !{!36, !12, i64 20}
!38 = !{!36, !12, i64 24}
!39 = !{!36, !12, i64 28}
!40 = !{!36, !12, i64 32}
!41 = !{i64 0, i64 4, !11, i64 4, i64 4, !11}
!42 = !{i64 0, i64 1, !29, i64 1, i64 1, !29, i64 2, i64 1, !29, i64 3, i64 1, !29}
!43 = distinct !{!43, !44}
!44 = !{!"llvm.loop.mustprogress"}


; 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.nk_user_font_glyph = type { [2 x %struct.nk_vec2], %struct.nk_vec2, float, float, float }
%struct.nk_vec2 = type { float, float }

@.str.1 = external hidden unnamed_addr constant [86 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [5 x i8], align 1
@__PRETTY_FUNCTION__.nk_draw_list_add_text = external hidden unnamed_addr constant [138 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local <2 x float> @nk_vec2(float noundef, float noundef) local_unnamed_addr #0

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

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

; 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 i32 @nk_utf_decode(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL23nk_draw_list_push_imageP12nk_draw_list9nk_handle(ptr noundef, ptr) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare hidden void @_ZL25nk_draw_list_push_rect_uvP12nk_draw_list7nk_vec2S1_S1_S1_8nk_color(ptr noundef, <2 x float>, <2 x float>, <2 x float>, <2 x float>, i32) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
define dso_local void @nk_draw_list_add_text(ptr noundef %0, ptr nocapture noundef readonly %1, <2 x float> %2, <2 x float> %3, ptr noundef %4, i32 noundef %5, float noundef %6, i32 %7) local_unnamed_addr #4 {
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca %struct.nk_user_font_glyph, align 8
  %.sroa.2.0.extract.shift = lshr i32 %7, 24
  %.sroa.2.0.extract.trunc = trunc nuw i32 %.sroa.2.0.extract.shift to i8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #5
  store i32 0, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #5
  store i32 0, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %11) #5
  %.not = icmp eq ptr %0, null
  br i1 %.not, label %12, label %13

12:                                               ; preds = %8
  tail call void @__assert_fail(ptr noundef nonnull @.str.25, ptr noundef nonnull @.str.1, i32 noundef 10540, ptr noundef nonnull @__PRETTY_FUNCTION__.nk_draw_list_add_text) #6
  unreachable

13:                                               ; preds = %8
  %14 = icmp ne i32 %5, 0
  %15 = icmp ne ptr %4, null
  %or.cond3 = and i1 %15, %14
  br i1 %or.cond3, label %16, label %.thread

16:                                               ; preds = %13
  %17 = load float, ptr %0, align 8, !tbaa !9
  %.sroa.050.0.vec.extract = extractelement <2 x float> %2, i64 0
  %18 = fadd <2 x float> %2, %3
  %19 = extractelement <2 x float> %18, i64 0
  %20 = fcmp olt float %17, %19
  br i1 %20, label %21, label %.thread

21:                                               ; preds = %16
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  %23 = load float, ptr %22, align 8, !tbaa !19
  %24 = fadd float %17, %23
  %25 = fcmp olt float %.sroa.050.0.vec.extract, %24
  br i1 %25, label %26, label %.thread

26:                                               ; preds = %21
  %27 = getelementptr inbounds i8, ptr %0, i64 4
  %28 = load float, ptr %27, align 4, !tbaa !20
  %.sroa.050.4.vec.extract = extractelement <2 x float> %2, i64 1
  %29 = fadd <2 x float> %2, %3
  %30 = extractelement <2 x float> %29, i64 1
  %31 = fcmp olt float %28, %30
  br i1 %31, label %32, label %.thread

32:                                               ; preds = %26
  %33 = getelementptr inbounds i8, ptr %0, i64 12
  %34 = load float, ptr %33, align 4, !tbaa !21
  %35 = fadd float %28, %34
  %36 = fcmp olt float %.sroa.050.4.vec.extract, %35
  br i1 %36, label %37, label %.thread

37:                                               ; preds = %32
  %38 = getelementptr inbounds i8, ptr %1, i64 32
  %.sroa.015.0.copyload = load ptr, ptr %38, align 8, !tbaa !22
  tail call void @_ZL23nk_draw_list_push_imageP12nk_draw_list9nk_handle(ptr noundef nonnull %0, ptr %.sroa.015.0.copyload)
  %39 = call i32 @nk_utf_decode(ptr noundef nonnull %4, ptr noundef nonnull %9, i32 noundef %5)
  %.not70 = icmp eq i32 %39, 0
  br i1 %.not70, label %.thread, label %40

40:                                               ; preds = %37
  %41 = icmp slt i32 %5, 1
  %42 = load i32, ptr %9, align 4
  %43 = icmp eq i32 %42, 65533
  %or.cond81 = select i1 %41, i1 true, i1 %43
  br i1 %or.cond81, label %.thread, label %.lr.ph

.lr.ph:                                           ; preds = %40
  %44 = getelementptr inbounds i8, ptr %0, i64 112
  %45 = load float, ptr %44, align 8, !tbaa !23
  %46 = uitofp i8 %.sroa.2.0.extract.trunc to float
  %47 = fmul float %45, %46
  %48 = fptoui float %47 to i8
  %49 = getelementptr inbounds i8, ptr %1, i64 24
  %50 = getelementptr inbounds i8, ptr %11, i64 16
  %51 = getelementptr inbounds i8, ptr %11, i64 20
  %52 = getelementptr inbounds i8, ptr %11, i64 24
  %53 = getelementptr inbounds i8, ptr %11, i64 28
  %54 = getelementptr inbounds i8, ptr %11, i64 32
  %55 = getelementptr inbounds i8, ptr %11, i64 8
  %.sroa.2.0.insert.ext = zext i8 %48 to i32
  %.sroa.2.0.insert.shift = shl nuw i32 %.sroa.2.0.insert.ext, 24
  %.sroa.049.0.insert.ext = and i32 %7, 16777215
  %.sroa.049.0.insert.insert = or disjoint i32 %.sroa.2.0.insert.shift, %.sroa.049.0.insert.ext
  br label %56

56:                                               ; preds = %.lr.ph, %56
  %.084 = phi float [ %.sroa.050.0.vec.extract, %.lr.ph ], [ %80, %56 ]
  %.05983 = phi i32 [ 0, %.lr.ph ], [ %79, %56 ]
  %.06182 = phi i32 [ %39, %.lr.ph ], [ %62, %56 ]
  %57 = sext i32 %.05983 to i64
  %58 = getelementptr inbounds i8, ptr %4, i64 %57
  %59 = sext i32 %.06182 to i64
  %60 = getelementptr inbounds i8, ptr %58, i64 %59
  %61 = sub nsw i32 %5, %.05983
  %62 = call i32 @nk_utf_decode(ptr noundef nonnull %60, ptr noundef nonnull %10, i32 noundef %61)
  %63 = load ptr, ptr %49, align 8, !tbaa !24
  %.sroa.08.0.copyload = load ptr, ptr %1, align 8, !tbaa !22
  %64 = load i32, ptr %9, align 4, !tbaa !5
  %65 = load i32, ptr %10, align 4
  %66 = icmp eq i32 %65, 65533
  %67 = select i1 %66, i32 0, i32 %65
  call void %63(ptr %.sroa.08.0.copyload, float noundef %6, ptr noundef nonnull %11, i32 noundef %64, i32 noundef %67)
  %68 = load float, ptr %50, align 8, !tbaa !26
  %69 = fadd float %.084, %68
  %70 = load float, ptr %51, align 4, !tbaa !28
  %71 = fadd float %.sroa.050.4.vec.extract, %70
  %72 = load float, ptr %52, align 8, !tbaa !29
  %73 = load float, ptr %53, align 4, !tbaa !30
  %74 = load float, ptr %54, align 8, !tbaa !31
  %75 = call <2 x float> @nk_vec2(float noundef %69, float noundef %71)
  %76 = fadd float %69, %72
  %77 = fadd float %71, %73
  %78 = call <2 x float> @nk_vec2(float noundef %76, float noundef %77)
  %.sroa.05.0.copyload = load <2 x float>, ptr %11, align 8
  %.sroa.04.0.copyload = load <2 x float>, ptr %55, align 8
  call void @_ZL25nk_draw_list_push_rect_uvP12nk_draw_list7nk_vec2S1_S1_S1_8nk_color(ptr noundef nonnull %0, <2 x float> %75, <2 x float> %78, <2 x float> %.sroa.05.0.copyload, <2 x float> %.sroa.04.0.copyload, i32 %.sroa.049.0.insert.insert)
  %79 = add nsw i32 %.05983, %.06182
  %80 = fadd float %.084, %74
  %81 = load i32, ptr %10, align 4, !tbaa !5
  store i32 %81, ptr %9, align 4, !tbaa !5
  %82 = icmp sge i32 %79, %5
  %83 = icmp eq i32 %62, 0
  %.not80 = select i1 %82, i1 true, i1 %83
  %84 = icmp eq i32 %81, 65533
  %or.cond = select i1 %.not80, i1 true, i1 %84
  br i1 %or.cond, label %.thread, label %56

.thread:                                          ; preds = %56, %40, %37, %16, %21, %26, %32, %13
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #5
  ret void
}

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="64" "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 = { 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 #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 = { mustprogress uwtable "min-legal-vector-width"="64" "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 }
attributes #6 = { noreturn 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !12, i64 0}
!10 = !{!"_ZTS12nk_draw_list", !11, i64 0, !7, i64 16, !13, i64 112, !17, i64 176, !17, i64 184, !17, i64 192, !6, i64 200, !6, i64 204, !6, i64 208, !18, i64 216, !6, i64 224, !6, i64 228, !14, i64 232, !14, i64 236}
!11 = !{!"_ZTS7nk_rect", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12}
!12 = !{!"float", !7, i64 0}
!13 = !{!"_ZTS17nk_convert_config", !12, i64 0, !14, i64 4, !14, i64 8, !6, i64 12, !6, i64 16, !6, i64 20, !15, i64 24, !17, i64 40, !18, i64 48, !18, i64 56}
!14 = !{!"_ZTS16nk_anti_aliasing", !7, i64 0}
!15 = !{!"_ZTS20nk_draw_null_texture", !7, i64 0, !16, i64 8}
!16 = !{!"_ZTS7nk_vec2", !12, i64 0, !12, i64 4}
!17 = !{!"any pointer", !7, i64 0}
!18 = !{!"long", !7, i64 0}
!19 = !{!10, !12, i64 8}
!20 = !{!10, !12, i64 4}
!21 = !{!10, !12, i64 12}
!22 = !{!7, !7, i64 0}
!23 = !{!10, !12, i64 112}
!24 = !{!25, !17, i64 24}
!25 = !{!"_ZTS12nk_user_font", !7, i64 0, !12, i64 8, !17, i64 16, !17, i64 24, !7, i64 32}
!26 = !{!27, !12, i64 16}
!27 = !{!"_ZTS18nk_user_font_glyph", !7, i64 0, !16, i64 16, !12, i64 24, !12, i64 28, !12, i64 32}
!28 = !{!27, !12, i64 20}
!29 = !{!27, !12, i64 24}
!30 = !{!27, !12, i64 28}
!31 = !{!27, !12, i64 32}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass,VectorCombinePass