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

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

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

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

; Function Attrs: nounwind uwtable
define dso_local void @w2c_hermes_void0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fpop_heap0x5Babi0x3Av150070x5D0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x2C0x20unsigned0x20int0x2A0x3E0x28unsigned0x20int0x2A0x2C0x20unsigned0x20int0x2A0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20std0x3A0x3A_0x5F20x3A0x3Aiterator_traits0x3Cunsigned0x20int0x2A0x3E0x3A0x3Adifference_type0x29(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4) #2 {
  %6 = alloca ptr, align 8
  %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 i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store i32 %1, ptr %7, align 4, !tbaa !9
  store i32 %2, ptr %8, align 4, !tbaa !9
  store i32 %3, ptr %9, align 4, !tbaa !9
  store i32 %4, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  store i32 0, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #3
  %17 = load ptr, ptr %6, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.w2c_hermes, ptr %17, i32 0, i32 3
  %19 = load i32, ptr %18, align 8, !tbaa !11
  store i32 %19, ptr %12, align 4, !tbaa !9
  store i32 16, ptr %13, align 4, !tbaa !9
  %20 = load i32, ptr %13, align 4, !tbaa !9
  %21 = load i32, ptr %12, align 4, !tbaa !9
  %22 = sub i32 %21, %20
  store i32 %22, ptr %12, align 4, !tbaa !9
  %23 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %23, ptr %11, align 4, !tbaa !9
  %24 = load i32, ptr %12, align 4, !tbaa !9
  %25 = load ptr, ptr %6, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.w2c_hermes, ptr %25, i32 0, i32 3
  store i32 %24, ptr %26, align 8, !tbaa !11
  %27 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %27, ptr %12, align 4, !tbaa !9
  %28 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %28, ptr %13, align 4, !tbaa !9
  %29 = load ptr, ptr %6, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct.w2c_hermes, ptr %29, i32 0, i32 6
  %31 = load i32, ptr %12, align 4, !tbaa !9
  %32 = zext i32 %31 to i64
  %33 = add i64 %32, 12
  %34 = load i32, ptr %13, align 4, !tbaa !9
  call void @i32_store(ptr noundef %30, i64 noundef %33, i32 noundef %34)
  %35 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %35, ptr %12, align 4, !tbaa !9
  store i32 2, ptr %13, align 4, !tbaa !9
  %36 = load i32, ptr %12, align 4, !tbaa !9
  %37 = load i32, ptr %13, align 4, !tbaa !9
  %38 = icmp ult i32 %36, %37
  %39 = zext i1 %38 to i32
  store i32 %39, ptr %12, align 4, !tbaa !9
  %40 = load i32, ptr %12, align 4, !tbaa !9
  %41 = icmp ne i32 %40, 0
  br i1 %41, label %42, label %43

42:                                               ; preds = %5
  br label %160

43:                                               ; preds = %5
  %44 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %44, ptr %12, align 4, !tbaa !9
  store i32 12, ptr %13, align 4, !tbaa !9
  %45 = load i32, ptr %13, align 4, !tbaa !9
  %46 = load i32, ptr %12, align 4, !tbaa !9
  %47 = add i32 %46, %45
  store i32 %47, ptr %12, align 4, !tbaa !9
  %48 = load ptr, ptr %6, align 8, !tbaa !5
  %49 = load i32, ptr %12, align 4, !tbaa !9
  %50 = call i32 @w2c_hermes_std0x3A0x3A_0x5F20x3A0x3Aenable_if0x3Cis_reference0x3Cdecltype0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x3E0x3A0x3Avalue0x2C0x20decltype0x28std0x3A0x3Amove0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x290x3E0x3A0x3Atype0x20std0x3A0x3A_0x5F20x3A0x3A_IterOps0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x3E0x3A0x3A_0x5Fiter_move0x5Babi0x3Av150070x5D0x3Cunsigned0x20int0x2A0x260x3E0x28unsigned0x20int0x2A0x260x29(ptr noundef %48, i32 noundef %49)
  store i32 %50, ptr %12, align 4, !tbaa !9
  %51 = load ptr, ptr %6, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.w2c_hermes, ptr %51, i32 0, i32 6
  %53 = load i32, ptr %12, align 4, !tbaa !9
  %54 = zext i32 %53 to i64
  %55 = call i32 @i32_load(ptr noundef %52, i64 noundef %54)
  store i32 %55, ptr %12, align 4, !tbaa !9
  %56 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %56, ptr %7, align 4, !tbaa !9
  %57 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %57, ptr %12, align 4, !tbaa !9
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.w2c_hermes, ptr %58, i32 0, i32 6
  %60 = load i32, ptr %12, align 4, !tbaa !9
  %61 = zext i32 %60 to i64
  %62 = add i64 %61, 12
  %63 = call i32 @i32_load(ptr noundef %59, i64 noundef %62)
  store i32 %63, ptr %12, align 4, !tbaa !9
  %64 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %64, ptr %13, align 4, !tbaa !9
  %65 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %65, ptr %14, align 4, !tbaa !9
  %66 = load ptr, ptr %6, align 8, !tbaa !5
  %67 = load i32, ptr %12, align 4, !tbaa !9
  %68 = load i32, ptr %13, align 4, !tbaa !9
  %69 = load i32, ptr %14, align 4, !tbaa !9
  %70 = call i32 @w2c_hermes_unsigned0x20int0x2A0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Ffloyd_sift_down0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20unsigned0x20int0x2A0x3E0x28unsigned0x20int0x2A0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20std0x3A0x3A_0x5F20x3A0x3Aiterator_traits0x3Cunsigned0x20int0x2A0x3E0x3A0x3Adifference_type0x29(ptr noundef %66, i32 noundef %67, i32 noundef %68, i32 noundef %69)
  store i32 %70, ptr %12, align 4, !tbaa !9
  %71 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %71, ptr %10, align 4, !tbaa !9
  %72 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %72, ptr %12, align 4, !tbaa !9
  %73 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %73, ptr %13, align 4, !tbaa !9
  store i32 4, ptr %14, align 4, !tbaa !9
  %74 = load i32, ptr %14, align 4, !tbaa !9
  %75 = load i32, ptr %13, align 4, !tbaa !9
  %76 = sub i32 %75, %74
  store i32 %76, ptr %13, align 4, !tbaa !9
  %77 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %77, ptr %8, align 4, !tbaa !9
  %78 = load ptr, ptr %6, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.w2c_hermes, ptr %78, i32 0, i32 6
  %80 = load i32, ptr %12, align 4, !tbaa !9
  %81 = zext i32 %80 to i64
  %82 = add i64 %81, 8
  %83 = load i32, ptr %13, align 4, !tbaa !9
  call void @i32_store(ptr noundef %79, i64 noundef %82, i32 noundef %83)
  %84 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %84, ptr %12, align 4, !tbaa !9
  %85 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %85, ptr %13, align 4, !tbaa !9
  %86 = load i32, ptr %12, align 4, !tbaa !9
  %87 = load i32, ptr %13, align 4, !tbaa !9
  %88 = icmp eq i32 %86, %87
  %89 = zext i1 %88 to i32
  store i32 %89, ptr %12, align 4, !tbaa !9
  %90 = load i32, ptr %12, align 4, !tbaa !9
  %91 = icmp ne i32 %90, 0
  br i1 %91, label %92, label %100

92:                                               ; preds = %43
  %93 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %93, ptr %12, align 4, !tbaa !9
  %94 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %94, ptr %13, align 4, !tbaa !9
  %95 = load ptr, ptr %6, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.w2c_hermes, ptr %95, i32 0, i32 6
  %97 = load i32, ptr %12, align 4, !tbaa !9
  %98 = zext i32 %97 to i64
  %99 = load i32, ptr %13, align 4, !tbaa !9
  call void @i32_store(ptr noundef %96, i64 noundef %98, i32 noundef %99)
  br label %160

100:                                              ; preds = %43
  %101 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %101, ptr %12, align 4, !tbaa !9
  %102 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %102, ptr %13, align 4, !tbaa !9
  store i32 8, ptr %14, align 4, !tbaa !9
  %103 = load i32, ptr %14, align 4, !tbaa !9
  %104 = load i32, ptr %13, align 4, !tbaa !9
  %105 = add i32 %104, %103
  store i32 %105, ptr %13, align 4, !tbaa !9
  %106 = load ptr, ptr %6, align 8, !tbaa !5
  %107 = load i32, ptr %13, align 4, !tbaa !9
  %108 = call i32 @w2c_hermes_std0x3A0x3A_0x5F20x3A0x3Aenable_if0x3Cis_reference0x3Cdecltype0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x3E0x3A0x3Avalue0x2C0x20decltype0x28std0x3A0x3Amove0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x290x3E0x3A0x3Atype0x20std0x3A0x3A_0x5F20x3A0x3A_IterOps0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x3E0x3A0x3A_0x5Fiter_move0x5Babi0x3Av150070x5D0x3Cunsigned0x20int0x2A0x260x3E0x28unsigned0x20int0x2A0x260x29(ptr noundef %106, i32 noundef %107)
  store i32 %108, ptr %13, align 4, !tbaa !9
  %109 = load ptr, ptr %6, align 8, !tbaa !5
  %110 = getelementptr inbounds %struct.w2c_hermes, ptr %109, i32 0, i32 6
  %111 = load i32, ptr %13, align 4, !tbaa !9
  %112 = zext i32 %111 to i64
  %113 = call i32 @i32_load(ptr noundef %110, i64 noundef %112)
  store i32 %113, ptr %13, align 4, !tbaa !9
  %114 = load ptr, ptr %6, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.w2c_hermes, ptr %114, i32 0, i32 6
  %116 = load i32, ptr %12, align 4, !tbaa !9
  %117 = zext i32 %116 to i64
  %118 = load i32, ptr %13, align 4, !tbaa !9
  call void @i32_store(ptr noundef %115, i64 noundef %117, i32 noundef %118)
  %119 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %119, ptr %12, align 4, !tbaa !9
  %120 = load ptr, ptr %6, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct.w2c_hermes, ptr %120, i32 0, i32 6
  %122 = load i32, ptr %12, align 4, !tbaa !9
  %123 = zext i32 %122 to i64
  %124 = add i64 %123, 8
  %125 = call i32 @i32_load(ptr noundef %121, i64 noundef %124)
  store i32 %125, ptr %12, align 4, !tbaa !9
  %126 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %126, ptr %13, align 4, !tbaa !9
  %127 = load ptr, ptr %6, align 8, !tbaa !5
  %128 = getelementptr inbounds %struct.w2c_hermes, ptr %127, i32 0, i32 6
  %129 = load i32, ptr %12, align 4, !tbaa !9
  %130 = zext i32 %129 to i64
  %131 = load i32, ptr %13, align 4, !tbaa !9
  call void @i32_store(ptr noundef %128, i64 noundef %130, i32 noundef %131)
  %132 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %132, ptr %12, align 4, !tbaa !9
  %133 = load ptr, ptr %6, align 8, !tbaa !5
  %134 = getelementptr inbounds %struct.w2c_hermes, ptr %133, i32 0, i32 6
  %135 = load i32, ptr %12, align 4, !tbaa !9
  %136 = zext i32 %135 to i64
  %137 = add i64 %136, 12
  %138 = call i32 @i32_load(ptr noundef %134, i64 noundef %137)
  store i32 %138, ptr %12, align 4, !tbaa !9
  %139 = load i32, ptr %12, align 4, !tbaa !9
  store i32 %139, ptr %7, align 4, !tbaa !9
  %140 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %140, ptr %13, align 4, !tbaa !9
  store i32 4, ptr %14, align 4, !tbaa !9
  %141 = load i32, ptr %14, align 4, !tbaa !9
  %142 = load i32, ptr %13, align 4, !tbaa !9
  %143 = add i32 %142, %141
  store i32 %143, ptr %13, align 4, !tbaa !9
  %144 = load i32, ptr %13, align 4, !tbaa !9
  store i32 %144, ptr %10, align 4, !tbaa !9
  %145 = load i32, ptr %9, align 4, !tbaa !9
  store i32 %145, ptr %14, align 4, !tbaa !9
  %146 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %146, ptr %15, align 4, !tbaa !9
  %147 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %147, ptr %16, align 4, !tbaa !9
  %148 = load i32, ptr %16, align 4, !tbaa !9
  %149 = load i32, ptr %15, align 4, !tbaa !9
  %150 = sub i32 %149, %148
  store i32 %150, ptr %15, align 4, !tbaa !9
  store i32 2, ptr %16, align 4, !tbaa !9
  %151 = load i32, ptr %15, align 4, !tbaa !9
  %152 = load i32, ptr %16, align 4, !tbaa !9
  %153 = and i32 %152, 31
  %154 = ashr i32 %151, %153
  store i32 %154, ptr %15, align 4, !tbaa !9
  %155 = load ptr, ptr %6, align 8, !tbaa !5
  %156 = load i32, ptr %12, align 4, !tbaa !9
  %157 = load i32, ptr %13, align 4, !tbaa !9
  %158 = load i32, ptr %14, align 4, !tbaa !9
  %159 = load i32, ptr %15, align 4, !tbaa !9
  call void @w2c_hermes_void0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fsift_up0x5Babi0x3Av150070x5D0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20unsigned0x20int0x2A0x3E0x28unsigned0x20int0x2A0x2C0x20unsigned0x20int0x2A0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20std0x3A0x3A_0x5F20x3A0x3Aiterator_traits0x3Cunsigned0x20int0x2A0x3E0x3A0x3Adifference_type0x29(ptr noundef %155, i32 noundef %156, i32 noundef %157, i32 noundef %158, i32 noundef %159)
  br label %160

160:                                              ; preds = %100, %92, %42
  %161 = load i32, ptr %11, align 4, !tbaa !9
  store i32 %161, ptr %12, align 4, !tbaa !9
  store i32 16, ptr %13, align 4, !tbaa !9
  %162 = load i32, ptr %13, align 4, !tbaa !9
  %163 = load i32, ptr %12, align 4, !tbaa !9
  %164 = add i32 %163, %162
  store i32 %164, ptr %12, align 4, !tbaa !9
  %165 = load i32, ptr %12, align 4, !tbaa !9
  %166 = load ptr, ptr %6, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.w2c_hermes, ptr %166, i32 0, i32 3
  store i32 %165, ptr %167, align 8, !tbaa !11
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  ret void
}

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

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

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 = { 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 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 24}
!12 = !{!"w2c_hermes", !6, i64 0, !6, i64 8, !6, i64 16, !10, i64 24, !10, i64 28, !10, i64 32, !13, i64 40, !16, i64 80}
!13 = !{!"", !6, i64 0, !14, i64 8, !14, i64 16, !14, i64 24, !15, i64 32}
!14 = !{!"long", !7, i64 0}
!15 = !{!"_Bool", !7, i64 0}
!16 = !{!"", !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 i32 @i32_load(ptr noundef, i64 noundef) local_unnamed_addr #0

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

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

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

13:                                               ; preds = %5
  %14 = add i32 %7, -4
  %15 = tail call i32 @w2c_hermes_std0x3A0x3A_0x5F20x3A0x3Aenable_if0x3Cis_reference0x3Cdecltype0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x3E0x3A0x3Avalue0x2C0x20decltype0x28std0x3A0x3Amove0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x290x3E0x3A0x3Atype0x20std0x3A0x3A_0x5F20x3A0x3A_IterOps0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x3E0x3A0x3A_0x5Fiter_move0x5Babi0x3Av150070x5D0x3Cunsigned0x20int0x2A0x260x3E0x28unsigned0x20int0x2A0x260x29(ptr noundef nonnull %0, i32 noundef %14)
  %16 = zext i32 %15 to i64
  %17 = tail call i32 @i32_load(ptr noundef nonnull %9, i64 noundef %16)
  %18 = tail call i32 @i32_load(ptr noundef nonnull %9, i64 noundef %11)
  %19 = tail call i32 @w2c_hermes_unsigned0x20int0x2A0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Ffloyd_sift_down0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20unsigned0x20int0x2A0x3E0x28unsigned0x20int0x2A0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20std0x3A0x3A_0x5F20x3A0x3Aiterator_traits0x3Cunsigned0x20int0x2A0x3E0x3A0x3Adifference_type0x29(ptr noundef nonnull %0, i32 noundef %18, i32 noundef %3, i32 noundef %4)
  %20 = add i32 %2, -4
  %21 = add nuw nsw i64 %10, 8
  tail call void @i32_store(ptr noundef nonnull %9, i64 noundef %21, i32 noundef %20)
  %22 = icmp eq i32 %20, %19
  br i1 %22, label %23, label %25

23:                                               ; preds = %13
  %24 = zext i32 %19 to i64
  tail call void @i32_store(ptr noundef nonnull %9, i64 noundef %24, i32 noundef %17)
  br label %37

25:                                               ; preds = %13
  %26 = add i32 %7, -8
  %27 = tail call i32 @w2c_hermes_std0x3A0x3A_0x5F20x3A0x3Aenable_if0x3Cis_reference0x3Cdecltype0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x3E0x3A0x3Avalue0x2C0x20decltype0x28std0x3A0x3Amove0x280x2Astd0x3A0x3Adeclval0x3Cunsigned0x20int0x2A0x260x3E0x280x290x290x290x3E0x3A0x3Atype0x20std0x3A0x3A_0x5F20x3A0x3A_IterOps0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x3E0x3A0x3A_0x5Fiter_move0x5Babi0x3Av150070x5D0x3Cunsigned0x20int0x2A0x260x3E0x28unsigned0x20int0x2A0x260x29(ptr noundef nonnull %0, i32 noundef %26)
  %28 = zext i32 %27 to i64
  %29 = tail call i32 @i32_load(ptr noundef nonnull %9, i64 noundef %28)
  %30 = zext i32 %19 to i64
  tail call void @i32_store(ptr noundef nonnull %9, i64 noundef %30, i32 noundef %29)
  %31 = tail call i32 @i32_load(ptr noundef nonnull %9, i64 noundef %21)
  %32 = zext i32 %31 to i64
  tail call void @i32_store(ptr noundef nonnull %9, i64 noundef %32, i32 noundef %17)
  %33 = tail call i32 @i32_load(ptr noundef nonnull %9, i64 noundef %11)
  %34 = add i32 %19, 4
  %35 = sub i32 %34, %33
  %36 = ashr i32 %35, 2
  tail call void @w2c_hermes_void0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fsift_up0x5Babi0x3Av150070x5D0x3Cstd0x3A0x3A_0x5F20x3A0x3A_ClassicAlgPolicy0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20unsigned0x20int0x2A0x3E0x28unsigned0x20int0x2A0x2C0x20unsigned0x20int0x2A0x2C0x20std0x3A0x3A_0x5F20x3A0x3A_0x5Fless0x3Cunsigned0x20int0x2C0x20unsigned0x20int0x3E0x260x2C0x20std0x3A0x3A_0x5F20x3A0x3Aiterator_traits0x3Cunsigned0x20int0x2A0x3E0x3A0x3Adifference_type0x29(ptr noundef nonnull %0, i32 noundef %33, i32 noundef %34, i32 noundef %3, i32 noundef %36)
  br label %37

37:                                               ; preds = %5, %25, %23
  store i32 %7, ptr %6, align 8, !tbaa !5
  ret void
}

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

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

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 = { 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" }

!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}


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