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

; 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: inlinehint nounwind uwtable
declare hidden void @i32_store(ptr noundef, i64 noundef, i32 noundef) #1

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

; 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 nosync nounwind willreturn memory(none)
declare i64 @llvm.expect.i64(i64, i64) #2

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

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

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

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

; Function Attrs: inlinehint nounwind uwtable
declare hidden double @f64_reinterpret_i64(i64 noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoLengthU640x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3) #5 {
  %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 i64, align 8
  %11 = alloca double, align 8
  %12 = alloca double, align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca double, align 8
  %23 = alloca double, 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) #6
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  store i64 0, ptr %10, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  store double 0.000000e+00, ptr %11, align 8, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  store double 0.000000e+00, ptr %12, align 8, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #6
  %24 = load ptr, ptr %5, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct.w2c_hermes, ptr %24, i32 0, i32 3
  %26 = load i32, ptr %25, align 8, !tbaa !15
  store i32 %26, ptr %13, align 4, !tbaa !9
  store i32 32, ptr %14, align 4, !tbaa !9
  %27 = load i32, ptr %14, align 4, !tbaa !9
  %28 = load i32, ptr %13, align 4, !tbaa !9
  %29 = sub i32 %28, %27
  store i32 %29, ptr %13, align 4, !tbaa !9
  %30 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %30, ptr %9, align 4, !tbaa !9
  %31 = load i32, ptr %13, align 4, !tbaa !9
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.w2c_hermes, ptr %32, i32 0, i32 3
  store i32 %31, ptr %33, align 8, !tbaa !15
  %34 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %34, ptr %13, align 4, !tbaa !9
  %35 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %35, ptr %14, align 4, !tbaa !9
  %36 = load ptr, ptr %5, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.w2c_hermes, ptr %36, i32 0, i32 6
  %38 = load i32, ptr %14, align 4, !tbaa !9
  %39 = zext i32 %38 to i64
  %40 = add i64 %39, 4
  %41 = call i32 @i32_load(ptr noundef %37, i64 noundef %40)
  store i32 %41, ptr %14, align 4, !tbaa !9
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.w2c_hermes, ptr %42, i32 0, i32 6
  %44 = load i32, ptr %13, align 4, !tbaa !9
  %45 = zext i32 %44 to i64
  %46 = add i64 %45, 12
  %47 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %43, i64 noundef %46, i32 noundef %47)
  %48 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %48, ptr %13, align 4, !tbaa !9
  %49 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %49, ptr %14, align 4, !tbaa !9
  %50 = load ptr, ptr %5, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.w2c_hermes, ptr %50, i32 0, i32 6
  %52 = load i32, ptr %14, align 4, !tbaa !9
  %53 = zext i32 %52 to i64
  %54 = call i32 @i32_load(ptr noundef %51, i64 noundef %53)
  store i32 %54, ptr %14, align 4, !tbaa !9
  %55 = load i32, ptr %14, align 4, !tbaa !9
  store i32 %55, ptr %8, align 4, !tbaa !9
  %56 = load ptr, ptr %5, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.w2c_hermes, ptr %56, i32 0, i32 6
  %58 = load i32, ptr %13, align 4, !tbaa !9
  %59 = zext i32 %58 to i64
  %60 = add i64 %59, 8
  %61 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %57, i64 noundef %60, i32 noundef %61)
  %62 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %62, ptr %13, align 4, !tbaa !9
  %63 = load i32, ptr %13, align 4, !tbaa !9
  %64 = icmp ne i32 %63, 0
  %65 = xor i1 %64, true
  %66 = zext i1 %65 to i32
  store i32 %66, ptr %13, align 4, !tbaa !9
  %67 = load i32, ptr %13, align 4, !tbaa !9
  %68 = icmp ne i32 %67, 0
  br i1 %68, label %69, label %83

69:                                               ; preds = %4
  %70 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %70, ptr %13, align 4, !tbaa !9
  store i32 16, ptr %14, align 4, !tbaa !9
  %71 = load i32, ptr %14, align 4, !tbaa !9
  %72 = load i32, ptr %13, align 4, !tbaa !9
  %73 = add i32 %72, %71
  store i32 %73, ptr %13, align 4, !tbaa !9
  %74 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %74, ptr %14, align 4, !tbaa !9
  %75 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %75, ptr %15, align 4, !tbaa !9
  store i32 8, ptr %16, align 4, !tbaa !9
  %76 = load i32, ptr %16, align 4, !tbaa !9
  %77 = load i32, ptr %15, align 4, !tbaa !9
  %78 = add i32 %77, %76
  store i32 %78, ptr %15, align 4, !tbaa !9
  %79 = load ptr, ptr %5, align 8, !tbaa !5
  %80 = load i32, ptr %13, align 4, !tbaa !9
  %81 = load i32, ptr %14, align 4, !tbaa !9
  %82 = load i32, ptr %15, align 4, !tbaa !9
  call void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoIntegerOrInfinity0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef %79, i32 noundef %80, i32 noundef %81, i32 noundef %82)
  br label %127

83:                                               ; preds = %4
  %84 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %84, ptr %13, align 4, !tbaa !9
  %85 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %85, ptr %14, align 4, !tbaa !9
  %86 = load ptr, ptr %5, align 8, !tbaa !5
  %87 = getelementptr inbounds %struct.w2c_hermes, ptr %86, i32 0, i32 6
  %88 = load i32, ptr %14, align 4, !tbaa !9
  %89 = zext i32 %88 to i64
  %90 = call i32 @i32_load(ptr noundef %87, i64 noundef %89)
  store i32 %90, ptr %14, align 4, !tbaa !9
  store i32 1, ptr %15, align 4, !tbaa !9
  %91 = load i32, ptr %15, align 4, !tbaa !9
  %92 = load i32, ptr %14, align 4, !tbaa !9
  %93 = add i32 %92, %91
  store i32 %93, ptr %14, align 4, !tbaa !9
  %94 = load ptr, ptr %5, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.w2c_hermes, ptr %94, i32 0, i32 6
  %96 = load i32, ptr %13, align 4, !tbaa !9
  %97 = zext i32 %96 to i64
  %98 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %95, i64 noundef %97, i32 noundef %98)
  %99 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %99, ptr %13, align 4, !tbaa !9
  store i32 16, ptr %14, align 4, !tbaa !9
  %100 = load i32, ptr %14, align 4, !tbaa !9
  %101 = load i32, ptr %13, align 4, !tbaa !9
  %102 = add i32 %101, %100
  store i32 %102, ptr %13, align 4, !tbaa !9
  %103 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %103, ptr %14, align 4, !tbaa !9
  %104 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %104, ptr %15, align 4, !tbaa !9
  store i32 8, ptr %16, align 4, !tbaa !9
  %105 = load i32, ptr %16, align 4, !tbaa !9
  %106 = load i32, ptr %15, align 4, !tbaa !9
  %107 = add i32 %106, %105
  store i32 %107, ptr %15, align 4, !tbaa !9
  %108 = load ptr, ptr %5, align 8, !tbaa !5
  %109 = load i32, ptr %13, align 4, !tbaa !9
  %110 = load i32, ptr %14, align 4, !tbaa !9
  %111 = load i32, ptr %15, align 4, !tbaa !9
  call void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoIntegerOrInfinity0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef %108, i32 noundef %109, i32 noundef %110, i32 noundef %111)
  %112 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %112, ptr %13, align 4, !tbaa !9
  %113 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %113, ptr %14, align 4, !tbaa !9
  %114 = load ptr, ptr %5, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.w2c_hermes, ptr %114, i32 0, i32 6
  %116 = load i32, ptr %14, align 4, !tbaa !9
  %117 = zext i32 %116 to i64
  %118 = call i32 @i32_load(ptr noundef %115, i64 noundef %117)
  store i32 %118, ptr %14, align 4, !tbaa !9
  store i32 1, ptr %15, align 4, !tbaa !9
  %119 = load i32, ptr %15, align 4, !tbaa !9
  %120 = load i32, ptr %14, align 4, !tbaa !9
  %121 = sub i32 %120, %119
  store i32 %121, ptr %14, align 4, !tbaa !9
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct.w2c_hermes, ptr %122, i32 0, i32 6
  %124 = load i32, ptr %13, align 4, !tbaa !9
  %125 = zext i32 %124 to i64
  %126 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %123, i64 noundef %125, i32 noundef %126)
  br label %127

127:                                              ; preds = %83, %69
  %128 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %128, ptr %13, align 4, !tbaa !9
  %129 = load ptr, ptr %5, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.w2c_hermes, ptr %129, i32 0, i32 6
  %131 = load i32, ptr %13, align 4, !tbaa !9
  %132 = zext i32 %131 to i64
  %133 = add i64 %132, 16
  %134 = call i32 @i32_load(ptr noundef %130, i64 noundef %133)
  store i32 %134, ptr %13, align 4, !tbaa !9
  %135 = load i32, ptr %13, align 4, !tbaa !9
  switch i32 %135, label %138 [
    i32 0, label %136
    i32 1, label %137
  ]

136:                                              ; preds = %127
  br label %139

137:                                              ; preds = %127
  br label %164

138:                                              ; preds = %127
  br label %146

139:                                              ; preds = %136
  %140 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %140, ptr %13, align 4, !tbaa !9
  store i32 0, ptr %14, align 4, !tbaa !9
  %141 = load ptr, ptr %5, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.w2c_hermes, ptr %141, i32 0, i32 6
  %143 = load i32, ptr %13, align 4, !tbaa !9
  %144 = zext i32 %143 to i64
  %145 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %142, i64 noundef %144, i32 noundef %145)
  br label %277

146:                                              ; preds = %138
  store i32 0, ptr %13, align 4, !tbaa !9
  %147 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %147, ptr %9, align 4, !tbaa !9
  store i32 109639, ptr %14, align 4, !tbaa !9
  %148 = load i32, ptr %14, align 4, !tbaa !9
  %149 = load i32, ptr %13, align 4, !tbaa !9
  %150 = add i32 %149, %148
  store i32 %150, ptr %13, align 4, !tbaa !9
  %151 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %151, ptr %14, align 4, !tbaa !9
  store i32 77564, ptr %15, align 4, !tbaa !9
  %152 = load i32, ptr %15, align 4, !tbaa !9
  %153 = load i32, ptr %14, align 4, !tbaa !9
  %154 = add i32 %153, %152
  store i32 %154, ptr %14, align 4, !tbaa !9
  store i32 179, ptr %15, align 4, !tbaa !9
  %155 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %155, ptr %16, align 4, !tbaa !9
  store i32 90402, ptr %17, align 4, !tbaa !9
  %156 = load i32, ptr %17, align 4, !tbaa !9
  %157 = load i32, ptr %16, align 4, !tbaa !9
  %158 = add i32 %157, %156
  store i32 %158, ptr %16, align 4, !tbaa !9
  %159 = load ptr, ptr %5, align 8, !tbaa !5
  %160 = load i32, ptr %13, align 4, !tbaa !9
  %161 = load i32, ptr %14, align 4, !tbaa !9
  %162 = load i32, ptr %15, align 4, !tbaa !9
  %163 = load i32, ptr %16, align 4, !tbaa !9
  call void @w2c_hermes_0x5F_assert_fail(ptr noundef %159, i32 noundef %160, i32 noundef %161, i32 noundef %162, i32 noundef %163)
  call void @wasm_rt_trap(i32 noundef 5) #7
  unreachable

164:                                              ; preds = %137
  %165 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %165, ptr %13, align 4, !tbaa !9
  %166 = load ptr, ptr %5, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.w2c_hermes, ptr %166, i32 0, i32 6
  %168 = load i32, ptr %13, align 4, !tbaa !9
  %169 = zext i32 %168 to i64
  %170 = add i64 %169, 24
  %171 = call i64 @i64_load(ptr noundef %167, i64 noundef %170)
  store i64 %171, ptr %18, align 8, !tbaa !11
  %172 = load i64, ptr %18, align 8, !tbaa !11
  store i64 %172, ptr %10, align 8, !tbaa !11
  store i64 -1970324836974592, ptr %19, align 8, !tbaa !11
  %173 = load i64, ptr %18, align 8, !tbaa !11
  %174 = load i64, ptr %19, align 8, !tbaa !11
  %175 = icmp uge i64 %173, %174
  %176 = zext i1 %175 to i32
  store i32 %176, ptr %13, align 4, !tbaa !9
  %177 = load i32, ptr %13, align 4, !tbaa !9
  %178 = icmp ne i32 %177, 0
  br i1 %178, label %179, label %180

179:                                              ; preds = %164
  br label %285

180:                                              ; preds = %164
  %181 = load i64, ptr %10, align 8, !tbaa !11
  store i64 %181, ptr %18, align 8, !tbaa !11
  %182 = load i64, ptr %18, align 8, !tbaa !11
  %183 = call double @f64_reinterpret_i64(i64 noundef %182)
  store double %183, ptr %20, align 8, !tbaa !13
  %184 = load double, ptr %20, align 8, !tbaa !13
  store double %184, ptr %12, align 8, !tbaa !13
  store double 0.000000e+00, ptr %21, align 8, !tbaa !13
  %185 = load double, ptr %20, align 8, !tbaa !13
  %186 = load double, ptr %21, align 8, !tbaa !13
  %187 = fcmp ole double %185, %186
  %188 = zext i1 %187 to i32
  store i32 %188, ptr %13, align 4, !tbaa !9
  %189 = load i32, ptr %13, align 4, !tbaa !9
  %190 = icmp ne i32 %189, 0
  br i1 %190, label %191, label %192

191:                                              ; preds = %180
  br label %208

192:                                              ; preds = %180
  %193 = load double, ptr %12, align 8, !tbaa !13
  store double %193, ptr %20, align 8, !tbaa !13
  %194 = load double, ptr %20, align 8, !tbaa !13
  store double %194, ptr %11, align 8, !tbaa !13
  store double 0x433FFFFFFFFFFFFF, ptr %21, align 8, !tbaa !13
  %195 = load double, ptr %20, align 8, !tbaa !13
  %196 = load double, ptr %21, align 8, !tbaa !13
  %197 = fcmp ogt double %195, %196
  %198 = zext i1 %197 to i32
  store i32 %198, ptr %13, align 4, !tbaa !9
  %199 = load i32, ptr %13, align 4, !tbaa !9
  %200 = icmp ne i32 %199, 0
  %201 = xor i1 %200, true
  %202 = zext i1 %201 to i32
  store i32 %202, ptr %13, align 4, !tbaa !9
  %203 = load i32, ptr %13, align 4, !tbaa !9
  %204 = icmp ne i32 %203, 0
  br i1 %204, label %205, label %206

205:                                              ; preds = %192
  br label %208

206:                                              ; preds = %192
  store double 0x433FFFFFFFFFFFFF, ptr %20, align 8, !tbaa !13
  %207 = load double, ptr %20, align 8, !tbaa !13
  store double %207, ptr %11, align 8, !tbaa !13
  br label %208

208:                                              ; preds = %206, %205, %191
  %209 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %209, ptr %13, align 4, !tbaa !9
  store i32 1, ptr %14, align 4, !tbaa !9
  %210 = load ptr, ptr %5, align 8, !tbaa !5
  %211 = getelementptr inbounds %struct.w2c_hermes, ptr %210, i32 0, i32 6
  %212 = load i32, ptr %13, align 4, !tbaa !9
  %213 = zext i32 %212 to i64
  %214 = load i32, ptr %14, align 4, !tbaa !9
  call void @i32_store(ptr noundef %211, i64 noundef %213, i32 noundef %214)
  %215 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %215, ptr %13, align 4, !tbaa !9
  %216 = load double, ptr %11, align 8, !tbaa !13
  store double %216, ptr %21, align 8, !tbaa !13
  store double 0x43F0000000000000, ptr %22, align 8, !tbaa !13
  %217 = load double, ptr %21, align 8, !tbaa !13
  %218 = load double, ptr %22, align 8, !tbaa !13
  %219 = fcmp olt double %217, %218
  %220 = zext i1 %219 to i32
  store i32 %220, ptr %14, align 4, !tbaa !9
  %221 = load double, ptr %11, align 8, !tbaa !13
  store double %221, ptr %22, align 8, !tbaa !13
  store double 0.000000e+00, ptr %23, align 8, !tbaa !13
  %222 = load double, ptr %22, align 8, !tbaa !13
  %223 = load double, ptr %23, align 8, !tbaa !13
  %224 = fcmp oge double %222, %223
  %225 = zext i1 %224 to i32
  store i32 %225, ptr %15, align 4, !tbaa !9
  %226 = load i32, ptr %15, align 4, !tbaa !9
  %227 = load i32, ptr %14, align 4, !tbaa !9
  %228 = and i32 %227, %226
  store i32 %228, ptr %14, align 4, !tbaa !9
  %229 = load i32, ptr %14, align 4, !tbaa !9
  %230 = icmp ne i32 %229, 0
  br i1 %230, label %231, label %268

231:                                              ; preds = %208
  %232 = load double, ptr %11, align 8, !tbaa !13
  store double %232, ptr %21, align 8, !tbaa !13
  %233 = load double, ptr %21, align 8, !tbaa !13
  %234 = load double, ptr %21, align 8, !tbaa !13
  %235 = fcmp une double %233, %234
  %236 = xor i1 %235, true
  %237 = xor i1 %236, true
  %238 = zext i1 %237 to i32
  %239 = sext i32 %238 to i64
  %240 = call i64 @llvm.expect.i64(i64 %239, i64 0)
  %241 = icmp ne i64 %240, 0
  br i1 %241, label %242, label %244

242:                                              ; preds = %231
  call void @wasm_rt_trap(i32 noundef 4) #7
  unreachable

243:                                              ; No predecessors!
  br label %266

244:                                              ; preds = %231
  %245 = load double, ptr %21, align 8, !tbaa !13
  %246 = fcmp ogt double %245, -1.000000e+00
  br i1 %246, label %247, label %250

247:                                              ; preds = %244
  %248 = load double, ptr %21, align 8, !tbaa !13
  %249 = fcmp olt double %248, 0x43F0000000000000
  br label %250

250:                                              ; preds = %247, %244
  %251 = phi i1 [ false, %244 ], [ %249, %247 ]
  %252 = xor i1 %251, true
  %253 = xor i1 %252, true
  %254 = xor i1 %253, true
  %255 = zext i1 %254 to i32
  %256 = sext i32 %255 to i64
  %257 = call i64 @llvm.expect.i64(i64 %256, i64 0)
  %258 = icmp ne i64 %257, 0
  br i1 %258, label %259, label %261

259:                                              ; preds = %250
  call void @wasm_rt_trap(i32 noundef 2) #7
  unreachable

260:                                              ; No predecessors!
  br label %264

261:                                              ; preds = %250
  %262 = load double, ptr %21, align 8, !tbaa !13
  %263 = fptoui double %262 to i64
  br label %264

264:                                              ; preds = %261, %260
  %265 = phi i64 [ 0, %260 ], [ %263, %261 ]
  br label %266

266:                                              ; preds = %264, %243
  %267 = phi i64 [ 0, %243 ], [ %265, %264 ]
  store i64 %267, ptr %19, align 8, !tbaa !11
  br label %269

268:                                              ; preds = %208
  store i64 0, ptr %19, align 8, !tbaa !11
  br label %269

269:                                              ; preds = %268, %266
  %270 = load i64, ptr %19, align 8, !tbaa !11
  store i64 %270, ptr %10, align 8, !tbaa !11
  %271 = load ptr, ptr %5, align 8, !tbaa !5
  %272 = getelementptr inbounds %struct.w2c_hermes, ptr %271, i32 0, i32 6
  %273 = load i32, ptr %13, align 4, !tbaa !9
  %274 = zext i32 %273 to i64
  %275 = add i64 %274, 8
  %276 = load i64, ptr %19, align 8, !tbaa !11
  call void @i64_store(ptr noundef %272, i64 noundef %275, i64 noundef %276)
  br label %277

277:                                              ; preds = %269, %139
  %278 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %278, ptr %13, align 4, !tbaa !9
  store i32 32, ptr %14, align 4, !tbaa !9
  %279 = load i32, ptr %14, align 4, !tbaa !9
  %280 = load i32, ptr %13, align 4, !tbaa !9
  %281 = add i32 %280, %279
  store i32 %281, ptr %13, align 4, !tbaa !9
  %282 = load i32, ptr %13, align 4, !tbaa !9
  %283 = load ptr, ptr %5, align 8, !tbaa !5
  %284 = getelementptr inbounds %struct.w2c_hermes, ptr %283, i32 0, i32 3
  store i32 %282, ptr %284, align 8, !tbaa !15
  br label %303

285:                                              ; preds = %179
  store i32 0, ptr %13, align 4, !tbaa !9
  %286 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %286, ptr %9, align 4, !tbaa !9
  store i32 118741, ptr %14, align 4, !tbaa !9
  %287 = load i32, ptr %14, align 4, !tbaa !9
  %288 = load i32, ptr %13, align 4, !tbaa !9
  %289 = add i32 %288, %287
  store i32 %289, ptr %13, align 4, !tbaa !9
  %290 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %290, ptr %14, align 4, !tbaa !9
  store i32 83341, ptr %15, align 4, !tbaa !9
  %291 = load i32, ptr %15, align 4, !tbaa !9
  %292 = load i32, ptr %14, align 4, !tbaa !9
  %293 = add i32 %292, %291
  store i32 %293, ptr %14, align 4, !tbaa !9
  store i32 444, ptr %15, align 4, !tbaa !9
  %294 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %294, ptr %16, align 4, !tbaa !9
  store i32 97283, ptr %17, align 4, !tbaa !9
  %295 = load i32, ptr %17, align 4, !tbaa !9
  %296 = load i32, ptr %16, align 4, !tbaa !9
  %297 = add i32 %296, %295
  store i32 %297, ptr %16, align 4, !tbaa !9
  %298 = load ptr, ptr %5, align 8, !tbaa !5
  %299 = load i32, ptr %13, align 4, !tbaa !9
  %300 = load i32, ptr %14, align 4, !tbaa !9
  %301 = load i32, ptr %15, align 4, !tbaa !9
  %302 = load i32, ptr %16, align 4, !tbaa !9
  call void @w2c_hermes_0x5F_assert_fail(ptr noundef %298, i32 noundef %299, i32 noundef %300, i32 noundef %301, i32 noundef %302)
  call void @wasm_rt_trap(i32 noundef 5) #7
  unreachable

303:                                              ; preds = %277
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 8, 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
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoIntegerOrInfinity0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef, i32 noundef, i32 noundef, i32 noundef) #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { nocallback nofree nosync nounwind willreturn memory(none) }
attributes #3 = { 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 #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 uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }
attributes #7 = { 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}
!13 = !{!14, !14, i64 0}
!14 = !{!"double", !7, i64 0}
!15 = !{!16, !10, i64 24}
!16 = !{!"w2c_hermes", !6, i64 0, !6, i64 8, !6, i64 16, !10, i64 24, !10, i64 28, !10, i64 32, !17, i64 40, !19, i64 80}
!17 = !{!"", !6, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !18, i64 32}
!18 = !{!"_Bool", !7, i64 0}
!19 = !{!"", !6, i64 0, !10, i64 8, !10, i64 12}


; 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: inlinehint nounwind uwtable
declare hidden void @i32_store(ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #0

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

; Function Attrs: noreturn
declare void @wasm_rt_trap(i32 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 @i64_store(ptr noundef, i64 noundef, i64 noundef) local_unnamed_addr #0

; Function Attrs: inlinehint nounwind uwtable
declare hidden i64 @i64_load(ptr noundef, i64 noundef) local_unnamed_addr #0

; Function Attrs: inlinehint nounwind uwtable
declare hidden double @f64_reinterpret_i64(i64 noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoLengthU640x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3) local_unnamed_addr #3 {
  %5 = getelementptr inbounds i8, ptr %0, i64 24
  %6 = load i32, ptr %5, align 8, !tbaa !5
  %7 = add i32 %6, -32
  store i32 %7, ptr %5, align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %0, i64 40
  %9 = zext i32 %3 to i64
  %10 = add nuw nsw i64 %9, 4
  %11 = tail call i32 @i32_load(ptr noundef nonnull %8, i64 noundef %10)
  %12 = zext i32 %7 to i64
  %13 = add nuw nsw i64 %12, 12
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %13, i32 noundef %11)
  %14 = tail call i32 @i32_load(ptr noundef nonnull %8, i64 noundef %9)
  %15 = add nuw nsw i64 %12, 8
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %15, i32 noundef %14)
  %.not = icmp eq i32 %14, 0
  br i1 %.not, label %16, label %19

16:                                               ; preds = %4
  %17 = add i32 %6, -16
  %18 = add i32 %6, -24
  tail call void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoIntegerOrInfinity0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef nonnull %0, i32 noundef %17, i32 noundef %2, i32 noundef %18)
  br label %27

19:                                               ; preds = %4
  %20 = zext i32 %14 to i64
  %21 = tail call i32 @i32_load(ptr noundef nonnull %8, i64 noundef %20)
  %22 = add i32 %21, 1
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %20, i32 noundef %22)
  %23 = add i32 %6, -16
  %24 = add i32 %6, -24
  tail call void @w2c_hermes_hermes0x3A0x3Avm0x3A0x3AtoIntegerOrInfinity0x28hermes0x3A0x3Avm0x3A0x3ARuntime0x260x2C0x20hermes0x3A0x3Avm0x3A0x3AHandle0x3Chermes0x3A0x3Avm0x3A0x3AHermesValue0x3E0x29(ptr noundef nonnull %0, i32 noundef %23, i32 noundef %2, i32 noundef %24)
  %25 = tail call i32 @i32_load(ptr noundef nonnull %8, i64 noundef %20)
  %26 = add i32 %25, -1
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %20, i32 noundef %26)
  br label %27

27:                                               ; preds = %19, %16
  %28 = add nuw nsw i64 %12, 16
  %29 = tail call i32 @i32_load(ptr noundef nonnull %8, i64 noundef %28)
  switch i32 %29, label %32 [
    i32 0, label %30
    i32 1, label %33
  ]

30:                                               ; preds = %27
  %31 = zext i32 %1 to i64
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %31, i32 noundef 0)
  br label %58

32:                                               ; preds = %27
  tail call void @w2c_hermes_0x5F_assert_fail(ptr noundef nonnull %0, i32 noundef 109639, i32 noundef 77564, i32 noundef 179, i32 noundef 90402) #4
  tail call void @wasm_rt_trap(i32 noundef 5) #5
  unreachable

33:                                               ; preds = %27
  %34 = add nuw nsw i64 %12, 24
  %35 = tail call i64 @i64_load(ptr noundef nonnull %8, i64 noundef %34)
  %36 = icmp ugt i64 %35, -1970324836974593
  br i1 %36, label %59, label %37

37:                                               ; preds = %33
  %38 = tail call double @f64_reinterpret_i64(i64 noundef %35)
  %39 = fcmp ugt double %38, 0.000000e+00
  br i1 %39, label %40, label %43

40:                                               ; preds = %37
  %41 = fcmp ule double %38, 0x433FFFFFFFFFFFFF
  br i1 %41, label %43, label %42

42:                                               ; preds = %40
  br label %43

43:                                               ; preds = %40, %37, %42
  %.0148 = phi double [ 0.000000e+00, %37 ], [ %38, %40 ], [ 0x433FFFFFFFFFFFFF, %42 ]
  %44 = zext i32 %1 to i64
  tail call void @i32_store(ptr noundef nonnull %8, i64 noundef %44, i32 noundef 1)
  %45 = fcmp olt double %.0148, 0x43F0000000000000
  %46 = fcmp oge double %.0148, 0.000000e+00
  %47 = and i1 %45, %46
  br i1 %47, label %48, label %56

48:                                               ; preds = %43
  %49 = fcmp uno double %.0148, 0.000000e+00
  br i1 %49, label %50, label %51, !prof !15

50:                                               ; preds = %48
  tail call void @wasm_rt_trap(i32 noundef 4) #5
  unreachable

51:                                               ; preds = %48
  %52 = fcmp ogt double %.0148, -1.000000e+00
  br i1 %52, label %54, label %53, !prof !16

53:                                               ; preds = %51
  tail call void @wasm_rt_trap(i32 noundef 2) #5
  unreachable

54:                                               ; preds = %51
  %55 = fptoui double %.0148 to i64
  br label %56

56:                                               ; preds = %43, %54
  %.0 = phi i64 [ %55, %54 ], [ 0, %43 ]
  %57 = add nuw nsw i64 %44, 8
  tail call void @i64_store(ptr noundef nonnull %8, i64 noundef %57, i64 noundef %.0)
  br label %58

58:                                               ; preds = %56, %30
  store i32 %6, ptr %5, align 8, !tbaa !5
  ret void

59:                                               ; preds = %33
  tail call void @w2c_hermes_0x5F_assert_fail(ptr noundef nonnull %0, i32 noundef 118741, i32 noundef 83341, i32 noundef 444, i32 noundef 97283) #4
  tail call void @wasm_rt_trap(i32 noundef 5) #5
  unreachable
}

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

attributes #0 = { 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 #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 = { "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)"}
!5 = !{!6, !10, i64 24}
!6 = !{!"w2c_hermes", !7, i64 0, !7, i64 8, !7, i64 16, !10, i64 24, !10, i64 28, !10, i64 32, !11, i64 40, !14, i64 80}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"", !7, i64 0, !12, i64 8, !12, i64 16, !12, i64 24, !13, i64 32}
!12 = !{!"long", !8, i64 0}
!13 = !{!"_Bool", !8, i64 0}
!14 = !{!"", !7, i64 0, !10, i64 8, !10, i64 12}
!15 = !{!"branch_weights", !"expected", i32 1, i32 2000}
!16 = !{!"branch_weights", !"expected", i32 2000, i32 1}


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