; LLVM IR from facebook/hermes :: API/hermes_sandbox/external (hermes_sandbox_impl_compiled_4)

; 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.w2c_hermes = type { ptr, ptr, ptr, i32, i32, i32, %struct.wasm_rt_memory_t, %struct.wasm_rt_funcref_table_t }
%struct.wasm_rt_memory_t = type { ptr, i64, i64, i64, i8 }
%struct.wasm_rt_funcref_table_t = type { ptr, i32, i32 }

; 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: noreturn
declare void @wasm_rt_trap(i32 noundef) #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @i32_store(ptr noundef, i64 noundef, i32 noundef) #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @i32_load8_u(ptr noundef, i64 noundef) #2

declare void @w2c_hermes_0x5F_assert_fail(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #3

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @i32_store8(ptr noundef, i64 noundef, i32 noundef) #2

; Function Attrs: nounwind uwtable
define dso_local void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x3A0x3Acreate0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20unsigned0x20int0x29(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3) #4 {
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !9
  store i32 %3, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  %16 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %16, ptr %9, align 4, !tbaa !9
  store i32 521668609, ptr %10, align 4, !tbaa !9
  %17 = load i32, ptr %9, align 4, !tbaa !9
  %18 = load i32, ptr %10, align 4, !tbaa !9
  %19 = icmp uge i32 %17, %18
  %20 = zext i1 %19 to i32
  store i32 %20, ptr %9, align 4, !tbaa !9
  %21 = load i32, ptr %9, align 4, !tbaa !9
  %22 = icmp ne i32 %21, 0
  br i1 %22, label %23, label %70

23:                                               ; preds = %4
  %24 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %24, ptr %9, align 4, !tbaa !9
  %25 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %25, ptr %10, align 4, !tbaa !9
  %26 = load ptr, ptr %5, align 8, !tbaa !5
  %27 = load i32, ptr %9, align 4, !tbaa !9
  %28 = load i32, ptr %10, align 4, !tbaa !9
  %29 = call i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x3A0x3AthrowExcessiveCapacityError0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20unsigned0x20int0x29(ptr noundef %26, i32 noundef %27, i32 noundef %28)
  store i32 %29, ptr %9, align 4, !tbaa !9
  %30 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %30, ptr %8, align 4, !tbaa !9
  %31 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %31, ptr %9, align 4, !tbaa !9
  store i32 1, ptr %10, align 4, !tbaa !9
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.w2c_hermes, ptr %32, i32 0, i32 6
  %34 = load i32, ptr %9, align 4, !tbaa !9
  %35 = zext i32 %34 to i64
  %36 = add i64 %35, 4
  %37 = load i32, ptr %10, align 4, !tbaa !9
  call void @i32_store8(ptr noundef %33, i64 noundef %36, i32 noundef %37)
  %38 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %38, ptr %9, align 4, !tbaa !9
  store i32 -1, ptr %10, align 4, !tbaa !9
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.w2c_hermes, ptr %39, i32 0, i32 6
  %41 = load i32, ptr %9, align 4, !tbaa !9
  %42 = zext i32 %41 to i64
  %43 = load i32, ptr %10, align 4, !tbaa !9
  call void @i32_store(ptr noundef %40, i64 noundef %42, i32 noundef %43)
  %44 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %44, ptr %9, align 4, !tbaa !9
  store i32 1, ptr %10, align 4, !tbaa !9
  %45 = load i32, ptr %9, align 4, !tbaa !9
  %46 = load i32, ptr %10, align 4, !tbaa !9
  %47 = icmp ne i32 %45, %46
  %48 = zext i1 %47 to i32
  store i32 %48, ptr %9, align 4, !tbaa !9
  %49 = load i32, ptr %9, align 4, !tbaa !9
  %50 = icmp ne i32 %49, 0
  br i1 %50, label %51, label %52

51:                                               ; preds = %23
  br label %147

52:                                               ; preds = %23
  store i32 0, ptr %9, align 4, !tbaa !9
  %53 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %53, ptr %8, align 4, !tbaa !9
  store i32 109717, ptr %10, align 4, !tbaa !9
  %54 = load i32, ptr %10, align 4, !tbaa !9
  %55 = load i32, ptr %9, align 4, !tbaa !9
  %56 = add i32 %55, %54
  store i32 %56, ptr %9, align 4, !tbaa !9
  %57 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %57, ptr %10, align 4, !tbaa !9
  store i32 77564, ptr %11, align 4, !tbaa !9
  %58 = load i32, ptr %11, align 4, !tbaa !9
  %59 = load i32, ptr %10, align 4, !tbaa !9
  %60 = add i32 %59, %58
  store i32 %60, ptr %10, align 4, !tbaa !9
  store i32 389, ptr %11, align 4, !tbaa !9
  %61 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %61, ptr %12, align 4, !tbaa !9
  store i32 28083, ptr %13, align 4, !tbaa !9
  %62 = load i32, ptr %13, align 4, !tbaa !9
  %63 = load i32, ptr %12, align 4, !tbaa !9
  %64 = add i32 %63, %62
  store i32 %64, ptr %12, align 4, !tbaa !9
  %65 = load ptr, ptr %5, align 8, !tbaa !5
  %66 = load i32, ptr %9, align 4, !tbaa !9
  %67 = load i32, ptr %10, align 4, !tbaa !9
  %68 = load i32, ptr %11, align 4, !tbaa !9
  %69 = load i32, ptr %12, align 4, !tbaa !9
  call void @w2c_hermes_0x5F_assert_fail(ptr noundef %65, i32 noundef %66, i32 noundef %67, i32 noundef %68, i32 noundef %69)
  call void @wasm_rt_trap(i32 noundef 5) #6
  unreachable

70:                                               ; preds = %4
  %71 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %71, ptr %9, align 4, !tbaa !9
  store i32 4097, ptr %10, align 4, !tbaa !9
  %72 = load i32, ptr %9, align 4, !tbaa !9
  %73 = load i32, ptr %10, align 4, !tbaa !9
  %74 = icmp uge i32 %72, %73
  %75 = zext i1 %74 to i32
  store i32 %75, ptr %9, align 4, !tbaa !9
  %76 = load i32, ptr %9, align 4, !tbaa !9
  %77 = icmp ne i32 %76, 0
  br i1 %77, label %78, label %98

78:                                               ; preds = %70
  %79 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %79, ptr %9, align 4, !tbaa !9
  store i32 4096, ptr %10, align 4, !tbaa !9
  %80 = load i32, ptr %10, align 4, !tbaa !9
  %81 = load i32, ptr %9, align 4, !tbaa !9
  %82 = sub i32 %81, %80
  store i32 %82, ptr %9, align 4, !tbaa !9
  %83 = load i32, ptr %9, align 4, !tbaa !9
  %84 = zext i32 %83 to i64
  store i64 %84, ptr %14, align 8, !tbaa !11
  store i64 1023, ptr %15, align 8, !tbaa !11
  %85 = load i64, ptr %15, align 8, !tbaa !11
  %86 = load i64, ptr %14, align 8, !tbaa !11
  %87 = add i64 %86, %85
  store i64 %87, ptr %14, align 8, !tbaa !11
  store i64 10, ptr %15, align 8, !tbaa !11
  %88 = load i64, ptr %15, align 8, !tbaa !11
  %89 = and i64 %88, 63
  %90 = load i64, ptr %14, align 8, !tbaa !11
  %91 = lshr i64 %90, %89
  store i64 %91, ptr %14, align 8, !tbaa !11
  %92 = load i64, ptr %14, align 8, !tbaa !11
  %93 = trunc i64 %92 to i32
  store i32 %93, ptr %9, align 4, !tbaa !9
  store i32 4096, ptr %10, align 4, !tbaa !9
  %94 = load i32, ptr %10, align 4, !tbaa !9
  %95 = load i32, ptr %9, align 4, !tbaa !9
  %96 = add i32 %95, %94
  store i32 %96, ptr %9, align 4, !tbaa !9
  %97 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %97, ptr %8, align 4, !tbaa !9
  br label %98

98:                                               ; preds = %78, %70
  %99 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %99, ptr %9, align 4, !tbaa !9
  store i32 5860, ptr %10, align 4, !tbaa !9
  %100 = load i32, ptr %10, align 4, !tbaa !9
  %101 = load i32, ptr %9, align 4, !tbaa !9
  %102 = add i32 %101, %100
  store i32 %102, ptr %9, align 4, !tbaa !9
  %103 = load ptr, ptr %5, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.w2c_hermes, ptr %103, i32 0, i32 6
  %105 = load i32, ptr %9, align 4, !tbaa !9
  %106 = zext i32 %105 to i64
  %107 = call i32 @i32_load8_u(ptr noundef %104, i64 noundef %106)
  store i32 %107, ptr %9, align 4, !tbaa !9
  %108 = load i32, ptr %9, align 4, !tbaa !9
  %109 = icmp ne i32 %108, 0
  %110 = xor i1 %109, true
  %111 = zext i1 %110 to i32
  store i32 %111, ptr %9, align 4, !tbaa !9
  %112 = load i32, ptr %9, align 4, !tbaa !9
  %113 = icmp ne i32 %112, 0
  br i1 %113, label %114, label %115

114:                                              ; preds = %98
  br label %148

115:                                              ; preds = %98
  %116 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %116, ptr %9, align 4, !tbaa !9
  store i32 808, ptr %10, align 4, !tbaa !9
  %117 = load i32, ptr %10, align 4, !tbaa !9
  %118 = load i32, ptr %9, align 4, !tbaa !9
  %119 = add i32 %118, %117
  store i32 %119, ptr %9, align 4, !tbaa !9
  %120 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %120, ptr %10, align 4, !tbaa !9
  store i32 3, ptr %11, align 4, !tbaa !9
  %121 = load i32, ptr %11, align 4, !tbaa !9
  %122 = and i32 %121, 31
  %123 = load i32, ptr %10, align 4, !tbaa !9
  %124 = shl i32 %123, %122
  store i32 %124, ptr %10, align 4, !tbaa !9
  store i32 16, ptr %11, align 4, !tbaa !9
  %125 = load i32, ptr %11, align 4, !tbaa !9
  %126 = load i32, ptr %10, align 4, !tbaa !9
  %127 = add i32 %126, %125
  store i32 %127, ptr %10, align 4, !tbaa !9
  %128 = load ptr, ptr %5, align 8, !tbaa !5
  %129 = load i32, ptr %9, align 4, !tbaa !9
  %130 = load i32, ptr %10, align 4, !tbaa !9
  %131 = call i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2A0x20hermes0x3A0x3Avm0x3A0x3AGCBase0x3A0x3AmakeAVariable0x3Chermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2C0x200x28hermes0x3A0x3Avm0x3A0x3AHasFinalizer0x2900x2C0x200x28hermes0x3A0x3Avm0x3A0x3ALongLived0x2900x3E0x28unsigned0x20int0x29(ptr noundef %128, i32 noundef %129, i32 noundef %130)
  store i32 %131, ptr %9, align 4, !tbaa !9
  %132 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %132, ptr %8, align 4, !tbaa !9
  %133 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %133, ptr %9, align 4, !tbaa !9
  store i32 1, ptr %10, align 4, !tbaa !9
  %134 = load ptr, ptr %5, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.w2c_hermes, ptr %134, i32 0, i32 6
  %136 = load i32, ptr %9, align 4, !tbaa !9
  %137 = zext i32 %136 to i64
  %138 = add i64 %137, 4
  %139 = load i32, ptr %10, align 4, !tbaa !9
  call void @i32_store8(ptr noundef %135, i64 noundef %138, i32 noundef %139)
  %140 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %140, ptr %9, align 4, !tbaa !9
  %141 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %141, ptr %10, align 4, !tbaa !9
  %142 = load ptr, ptr %5, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct.w2c_hermes, ptr %142, i32 0, i32 6
  %144 = load i32, ptr %9, align 4, !tbaa !9
  %145 = zext i32 %144 to i64
  %146 = load i32, ptr %10, align 4, !tbaa !9
  call void @i32_store(ptr noundef %143, i64 noundef %145, i32 noundef %146)
  br label %147

147:                                              ; preds = %115, %51
  br label %166

148:                                              ; preds = %114
  store i32 0, ptr %9, align 4, !tbaa !9
  %149 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %149, ptr %8, align 4, !tbaa !9
  store i32 193151, ptr %10, align 4, !tbaa !9
  %150 = load i32, ptr %10, align 4, !tbaa !9
  %151 = load i32, ptr %9, align 4, !tbaa !9
  %152 = add i32 %151, %150
  store i32 %152, ptr %9, align 4, !tbaa !9
  %153 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %153, ptr %10, align 4, !tbaa !9
  store i32 84373, ptr %11, align 4, !tbaa !9
  %154 = load i32, ptr %11, align 4, !tbaa !9
  %155 = load i32, ptr %10, align 4, !tbaa !9
  %156 = add i32 %155, %154
  store i32 %156, ptr %10, align 4, !tbaa !9
  store i32 1447, ptr %11, align 4, !tbaa !9
  %157 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %157, ptr %12, align 4, !tbaa !9
  store i32 109070, ptr %13, align 4, !tbaa !9
  %158 = load i32, ptr %13, align 4, !tbaa !9
  %159 = load i32, ptr %12, align 4, !tbaa !9
  %160 = add i32 %159, %158
  store i32 %160, ptr %12, align 4, !tbaa !9
  %161 = load ptr, ptr %5, align 8, !tbaa !5
  %162 = load i32, ptr %9, align 4, !tbaa !9
  %163 = load i32, ptr %10, align 4, !tbaa !9
  %164 = load i32, ptr %11, align 4, !tbaa !9
  %165 = load i32, ptr %12, align 4, !tbaa !9
  call void @w2c_hermes_0x5F_assert_fail(ptr noundef %161, i32 noundef %162, i32 noundef %163, i32 noundef %164, i32 noundef %165)
  call void @wasm_rt_trap(i32 noundef 5) #6
  unreachable

166:                                              ; preds = %147
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  ret void
}

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

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

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

!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 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}


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

; Function Attrs: noreturn
declare void @wasm_rt_trap(i32 noundef) local_unnamed_addr #0

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @i32_store(ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @i32_load8_u(ptr noundef, i64 noundef) local_unnamed_addr #1

declare void @w2c_hermes_0x5F_assert_fail(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden void @i32_store8(ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x3A0x3Acreate0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20unsigned0x20int0x29(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3) local_unnamed_addr #3 {
  %5 = icmp ugt i32 %3, 521668608
  %6 = getelementptr inbounds i8, ptr %0, i64 40
  br i1 %5, label %7, label %12

7:                                                ; preds = %4
  %8 = tail call i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x3A0x3AthrowExcessiveCapacityError0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20unsigned0x20int0x29(ptr noundef %0, i32 noundef %2, i32 noundef %3)
  %9 = zext i32 %1 to i64
  %10 = add nuw nsw i64 %9, 4
  tail call void @i32_store8(ptr noundef nonnull %6, i64 noundef %10, i32 noundef 1)
  tail call void @i32_store(ptr noundef nonnull %6, i64 noundef %9, i32 noundef -1)
  %.not94 = icmp eq i32 %8, 1
  br i1 %.not94, label %11, label %30

11:                                               ; preds = %7
  tail call void @w2c_hermes_0x5F_assert_fail(ptr noundef %0, i32 noundef 109717, i32 noundef 77564, i32 noundef 389, i32 noundef 28083) #4
  tail call void @wasm_rt_trap(i32 noundef 5) #5
  unreachable

12:                                               ; preds = %4
  %13 = add i32 %2, 5860
  %14 = zext i32 %13 to i64
  %15 = tail call i32 @i32_load8_u(ptr noundef nonnull %6, i64 noundef %14)
  %.not = icmp eq i32 %15, 0
  br i1 %.not, label %29, label %16

16:                                               ; preds = %12
  %17 = icmp ugt i32 %3, 4096
  %18 = zext nneg i32 %3 to i64
  %19 = add nuw nsw i64 %18, 4398046508031
  %20 = lshr i64 %19, 10
  %21 = trunc i64 %20 to i32
  %22 = add nuw nsw i32 %21, 4096
  %.0 = select i1 %17, i32 %22, i32 %3
  %23 = add i32 %2, 808
  %24 = shl nuw nsw i32 %.0, 3
  %25 = add nuw nsw i32 %24, 16
  %26 = tail call i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2A0x20hermes0x3A0x3Avm0x3A0x3AGCBase0x3A0x3AmakeAVariable0x3Chermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2C0x200x28hermes0x3A0x3Avm0x3A0x3AHasFinalizer0x2900x2C0x200x28hermes0x3A0x3Avm0x3A0x3ALongLived0x2900x3E0x28unsigned0x20int0x29(ptr noundef %0, i32 noundef %23, i32 noundef %25)
  %27 = zext i32 %1 to i64
  %28 = add nuw nsw i64 %27, 4
  tail call void @i32_store8(ptr noundef nonnull %6, i64 noundef %28, i32 noundef 1)
  tail call void @i32_store(ptr noundef nonnull %6, i64 noundef %27, i32 noundef %26)
  br label %30

29:                                               ; preds = %12
  tail call void @w2c_hermes_0x5F_assert_fail(ptr noundef %0, i32 noundef 193151, i32 noundef 84373, i32 noundef 1447, i32 noundef 109070) #4
  tail call void @wasm_rt_trap(i32 noundef 5) #5
  unreachable

30:                                               ; preds = %16, %7
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x3A0x3AthrowExcessiveCapacityError0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20unsigned0x20int0x29(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: nounwind uwtable
declare dso_local i32 @w2c_hermes_hermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2A0x20hermes0x3A0x3Avm0x3A0x3AGCBase0x3A0x3AmakeAVariable0x3Chermes0x3A0x3Avm0x3A0x3ASegmentedArrayBase0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x2C0x200x28hermes0x3A0x3Avm0x3A0x3AHasFinalizer0x2900x2C0x200x28hermes0x3A0x3Avm0x3A0x3ALongLived0x2900x3E0x28unsigned0x20int0x29(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

attributes #0 = { noreturn "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 = { inlinehint 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 = { "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 = { 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 = { nounwind }
attributes #5 = { 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)"}


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