; LLVM IR from SelfishOlex/MiniAudioO3DE :: MiniAudio/Code/Source/Clients (MiniAudioImplementation)

; 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.ma_linear_resampler_config = type { i32, i32, i32, i32, i32, double }
%struct.ma_engine_node_heap_layout = type { i64, i64, i64, i64 }
%struct.ma_node_config = type { ptr, i32, i32, i32, ptr, ptr }
%struct.ma_fader_config = type { i32, i32, i32 }
%struct.ma_spatializer_config = type { i32, i32, ptr, i32, i32, i32, float, float, float, float, float, float, float, float, float, float, i32 }
%struct.ma_panner_config = type { i32, i32, i32, float }
%struct.ma_engine_node_config = type { ptr, i32, i32, i32, i32, i8, i8, i8 }
%struct.ma_engine_node = type { %struct.ma_node_base, ptr, i32, %struct.ma_fader, %struct.ma_linear_resampler, %struct.ma_spatializer, %struct.ma_panner, float, float, float, i32, i32, i32, i8, ptr }
%struct.ma_node_base = type { ptr, ptr, ptr, i16, i16, i16, i16, i32, [2 x i64], i64, i32, i32, ptr, ptr, [2 x %struct.ma_node_input_bus], [2 x %struct.ma_node_output_bus], ptr, i32 }
%struct.ma_node_input_bus = type { %struct.ma_node_output_bus, i32, i32, i8 }
%struct.ma_node_output_bus = type { ptr, i8, i8, i8, i32, i32, i32, i32, float, ptr, ptr, ptr }
%struct.ma_fader = type { %struct.ma_fader_config, float, float, i64, i64 }
%struct.ma_linear_resampler = type { %struct.ma_linear_resampler_config, i32, i32, i32, i32, %union.anon.29, %union.anon.30, %struct.ma_lpf, ptr, i32 }
%union.anon.29 = type { ptr }
%union.anon.30 = type { ptr }
%struct.ma_lpf = type { i32, i32, i32, i32, i32, ptr, ptr, ptr, i32 }
%struct.ma_spatializer = type { i32, i32, ptr, i32, i32, i32, float, float, float, float, float, float, float, float, float, float, i32, %struct.ma_vec3f, %struct.ma_vec3f, %struct.ma_vec3f, float, %struct.ma_gainer, ptr, ptr, i32 }
%struct.ma_vec3f = type { float, float, float }
%struct.ma_gainer = type { %struct.ma_gainer_config, i32, ptr, ptr, ptr, i32 }
%struct.ma_gainer_config = type { i32, i32 }
%struct.ma_panner = type { i32, i32, i32, float }
%struct.ma_engine = type { %struct.ma_node_graph, ptr, ptr, ptr, i32, i32, [4 x %struct.ma_spatializer_listener], %struct.ma_allocation_callbacks, i8, i8, i32, ptr, i32, i32, i32 }
%struct.ma_node_graph = type { %struct.ma_node_base, %struct.ma_node_base, i16, i32 }
%struct.ma_spatializer_listener = type { %struct.ma_spatializer_listener_config, %struct.ma_vec3f, %struct.ma_vec3f, %struct.ma_vec3f, i32, i32, ptr }
%struct.ma_spatializer_listener_config = type { i32, ptr, i32, float, float, float, float, %struct.ma_vec3f }
%struct.ma_allocation_callbacks = type { ptr, ptr, ptr, ptr }

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

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #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) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local { i64, i64 } @ma_panner_config_init(i32 noundef, i32 noundef) #3

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local { i64, i32 } @ma_fader_config_init(i32 noundef, i32 noundef, i32 noundef) #3

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @ma_linear_resampler_config_init(ptr dead_on_unwind noalias writable sret(%struct.ma_linear_resampler_config) align 8, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #3

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local i32 @ma_engine_node_init_preallocated(ptr noundef %0, ptr noundef %1, ptr noundef %2) #5 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca %struct.ma_engine_node_heap_layout, align 8
  %10 = alloca %struct.ma_node_config, align 8
  %11 = alloca %struct.ma_linear_resampler_config, align 8
  %12 = alloca %struct.ma_fader_config, align 4
  %13 = alloca %struct.ma_spatializer_config, align 8
  %14 = alloca %struct.ma_panner_config, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca %struct.ma_node_config, align 8
  %19 = alloca %struct.ma_linear_resampler_config, align 8
  %20 = alloca %struct.ma_fader_config, align 4
  %21 = alloca { i64, i32 }, align 8
  %22 = alloca %struct.ma_spatializer_config, align 8
  %23 = alloca %struct.ma_panner_config, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 40, ptr %10) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 72, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 16, 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
  %24 = load ptr, ptr %7, align 8, !tbaa !5
  %25 = icmp eq ptr %24, null
  br i1 %25, label %26, label %27

26:                                               ; preds = %3
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %236

27:                                               ; preds = %3
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.memset.p0.i64(ptr align 8 %28, i8 0, i64 792, i1 false)
  %29 = load ptr, ptr %5, align 8, !tbaa !5
  %30 = call noundef i32 @_ZL30ma_engine_node_get_heap_layoutPK21ma_engine_node_configP26ma_engine_node_heap_layout(ptr noundef %29, ptr noundef %9)
  store i32 %30, ptr %8, align 4, !tbaa !9
  %31 = load i32, ptr %8, align 4, !tbaa !9
  %32 = icmp ne i32 %31, 0
  br i1 %32, label %33, label %35

33:                                               ; preds = %27
  %34 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %34, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %236

35:                                               ; preds = %27
  %36 = load ptr, ptr %5, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.ma_engine_node_config, ptr %36, i32 0, i32 7
  %38 = load i8, ptr %37, align 2, !tbaa !11
  %39 = zext i8 %38 to i32
  %40 = icmp ne i32 %39, 255
  br i1 %40, label %41, label %52

41:                                               ; preds = %35
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.ma_engine_node_config, ptr %42, i32 0, i32 7
  %44 = load i8, ptr %43, align 2, !tbaa !11
  %45 = zext i8 %44 to i32
  %46 = load ptr, ptr %5, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.ma_engine_node_config, ptr %46, i32 0, i32 0
  %48 = load ptr, ptr %47, align 8, !tbaa !15
  %49 = call i32 @ma_engine_get_listener_count(ptr noundef %48)
  %50 = icmp uge i32 %45, %49
  br i1 %50, label %51, label %52

51:                                               ; preds = %41
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %236

52:                                               ; preds = %41, %35
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = load ptr, ptr %7, align 8, !tbaa !5
  %55 = getelementptr inbounds %struct.ma_engine_node, ptr %54, i32 0, i32 14
  store ptr %53, ptr %55, align 8, !tbaa !16
  %56 = load ptr, ptr %6, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.ma_engine_node_heap_layout, ptr %9, i32 0, i32 0
  %58 = load i64, ptr %57, align 8, !tbaa !39
  call void @llvm.memset.p0.i64(ptr align 1 %56, i8 0, i64 %58, i1 false)
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.ma_engine_node_config, ptr %59, i32 0, i32 0
  %61 = load ptr, ptr %60, align 8, !tbaa !15
  %62 = load ptr, ptr %7, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.ma_engine_node, ptr %62, i32 0, i32 1
  store ptr %61, ptr %63, align 8, !tbaa !42
  %64 = load ptr, ptr %5, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct.ma_engine_node_config, ptr %64, i32 0, i32 4
  %66 = load i32, ptr %65, align 4, !tbaa !43
  %67 = icmp ugt i32 %66, 0
  br i1 %67, label %68, label %72

68:                                               ; preds = %52
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.ma_engine_node_config, ptr %69, i32 0, i32 4
  %71 = load i32, ptr %70, align 4, !tbaa !43
  br label %77

72:                                               ; preds = %52
  %73 = load ptr, ptr %7, align 8, !tbaa !5
  %74 = getelementptr inbounds %struct.ma_engine_node, ptr %73, i32 0, i32 1
  %75 = load ptr, ptr %74, align 8, !tbaa !42
  %76 = call i32 @ma_engine_get_sample_rate(ptr noundef %75)
  br label %77

77:                                               ; preds = %72, %68
  %78 = phi i32 [ %71, %68 ], [ %76, %72 ]
  %79 = load ptr, ptr %7, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.ma_engine_node, ptr %79, i32 0, i32 2
  store i32 %78, ptr %80, align 8, !tbaa !44
  %81 = load ptr, ptr %7, align 8, !tbaa !5
  %82 = getelementptr inbounds %struct.ma_engine_node, ptr %81, i32 0, i32 7
  store float 1.000000e+00, ptr %82, align 8, !tbaa !45
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.ma_engine_node, ptr %83, i32 0, i32 8
  store float 1.000000e+00, ptr %84, align 4, !tbaa !46
  %85 = load ptr, ptr %7, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.ma_engine_node, ptr %85, i32 0, i32 9
  store float 1.000000e+00, ptr %86, align 8, !tbaa !47
  %87 = load ptr, ptr %5, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.ma_engine_node_config, ptr %87, i32 0, i32 5
  %89 = load i8, ptr %88, align 8, !tbaa !48
  %90 = zext i8 %89 to i32
  %91 = load ptr, ptr %7, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.ma_engine_node, ptr %91, i32 0, i32 10
  store i32 %90, ptr %92, align 4, !tbaa !49
  %93 = load ptr, ptr %5, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.ma_engine_node_config, ptr %93, i32 0, i32 6
  %95 = load i8, ptr %94, align 1, !tbaa !50
  %96 = zext i8 %95 to i32
  %97 = load ptr, ptr %7, align 8, !tbaa !5
  %98 = getelementptr inbounds %struct.ma_engine_node, ptr %97, i32 0, i32 11
  store i32 %96, ptr %98, align 8, !tbaa !51
  %99 = load ptr, ptr %5, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.ma_engine_node_config, ptr %99, i32 0, i32 7
  %101 = load i8, ptr %100, align 2, !tbaa !11
  %102 = zext i8 %101 to i32
  %103 = load ptr, ptr %7, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.ma_engine_node, ptr %103, i32 0, i32 12
  store i32 %102, ptr %104, align 4, !tbaa !52
  %105 = load ptr, ptr %5, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.ma_engine_node_config, ptr %105, i32 0, i32 2
  %107 = load i32, ptr %106, align 4, !tbaa !53
  %108 = icmp ne i32 %107, 0
  br i1 %108, label %109, label %113

109:                                              ; preds = %77
  %110 = load ptr, ptr %5, align 8, !tbaa !5
  %111 = getelementptr inbounds %struct.ma_engine_node_config, ptr %110, i32 0, i32 2
  %112 = load i32, ptr %111, align 4, !tbaa !53
  br label %118

113:                                              ; preds = %77
  %114 = load ptr, ptr %5, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.ma_engine_node_config, ptr %114, i32 0, i32 0
  %116 = load ptr, ptr %115, align 8, !tbaa !15
  %117 = call i32 @ma_engine_get_channels(ptr noundef %116)
  br label %118

118:                                              ; preds = %113, %109
  %119 = phi i32 [ %112, %109 ], [ %117, %113 ]
  store i32 %119, ptr %15, align 4, !tbaa !54
  %120 = load ptr, ptr %5, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct.ma_engine_node_config, ptr %120, i32 0, i32 3
  %122 = load i32, ptr %121, align 8, !tbaa !55
  %123 = icmp ne i32 %122, 0
  br i1 %123, label %124, label %128

124:                                              ; preds = %118
  %125 = load ptr, ptr %5, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.ma_engine_node_config, ptr %125, i32 0, i32 3
  %127 = load i32, ptr %126, align 8, !tbaa !55
  br label %133

128:                                              ; preds = %118
  %129 = load ptr, ptr %5, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.ma_engine_node_config, ptr %129, i32 0, i32 0
  %131 = load ptr, ptr %130, align 8, !tbaa !15
  %132 = call i32 @ma_engine_get_channels(ptr noundef %131)
  br label %133

133:                                              ; preds = %128, %124
  %134 = phi i32 [ %127, %124 ], [ %132, %128 ]
  store i32 %134, ptr %16, align 4, !tbaa !54
  call void @llvm.lifetime.start.p0(i64 40, ptr %18) #6
  %135 = load ptr, ptr %5, align 8, !tbaa !5
  call void @_ZL36ma_engine_node_base_node_config_initPK21ma_engine_node_config(ptr dead_on_unwind writable sret(%struct.ma_node_config) align 8 %18, ptr noundef %135)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %10, ptr align 8 %18, i64 40, i1 false), !tbaa.struct !56
  call void @llvm.lifetime.end.p0(i64 40, ptr %18) #6
  %136 = getelementptr inbounds %struct.ma_node_config, ptr %10, i32 0, i32 4
  store ptr %15, ptr %136, align 8, !tbaa !58
  %137 = getelementptr inbounds %struct.ma_node_config, ptr %10, i32 0, i32 5
  store ptr %16, ptr %137, align 8, !tbaa !60
  %138 = load ptr, ptr %5, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.ma_engine_node_config, ptr %138, i32 0, i32 0
  %140 = load ptr, ptr %139, align 8, !tbaa !15
  %141 = getelementptr inbounds %struct.ma_engine, ptr %140, i32 0, i32 0
  %142 = load ptr, ptr %6, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct.ma_engine_node_heap_layout, ptr %9, i32 0, i32 1
  %144 = load i64, ptr %143, align 8, !tbaa !61
  %145 = getelementptr inbounds i8, ptr %142, i64 %144
  %146 = load ptr, ptr %7, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.ma_engine_node, ptr %146, i32 0, i32 0
  %148 = call i32 @ma_node_init_preallocated(ptr noundef %141, ptr noundef %10, ptr noundef %145, ptr noundef %147)
  store i32 %148, ptr %8, align 4, !tbaa !9
  %149 = load i32, ptr %8, align 4, !tbaa !9
  %150 = icmp ne i32 %149, 0
  br i1 %150, label %151, label %152

151:                                              ; preds = %133
  br label %234

152:                                              ; preds = %133
  call void @llvm.lifetime.start.p0(i64 32, ptr %19) #6
  %153 = getelementptr inbounds %struct.ma_node_config, ptr %10, i32 0, i32 4
  %154 = load ptr, ptr %153, align 8, !tbaa !58
  %155 = getelementptr inbounds i32, ptr %154, i64 0
  %156 = load i32, ptr %155, align 4, !tbaa !54
  %157 = load ptr, ptr %7, align 8, !tbaa !5
  %158 = getelementptr inbounds %struct.ma_engine_node, ptr %157, i32 0, i32 2
  %159 = load i32, ptr %158, align 8, !tbaa !44
  %160 = load ptr, ptr %7, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.ma_engine_node, ptr %160, i32 0, i32 1
  %162 = load ptr, ptr %161, align 8, !tbaa !42
  %163 = call i32 @ma_engine_get_sample_rate(ptr noundef %162)
  call void @ma_linear_resampler_config_init(ptr dead_on_unwind writable sret(%struct.ma_linear_resampler_config) align 8 %19, i32 noundef 5, i32 noundef %156, i32 noundef %159, i32 noundef %163)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %11, ptr align 8 %19, i64 32, i1 false), !tbaa.struct !62
  call void @llvm.lifetime.end.p0(i64 32, ptr %19) #6
  %164 = getelementptr inbounds %struct.ma_linear_resampler_config, ptr %11, i32 0, i32 4
  store i32 0, ptr %164, align 8, !tbaa !65
  %165 = load ptr, ptr %6, align 8, !tbaa !5
  %166 = getelementptr inbounds %struct.ma_engine_node_heap_layout, ptr %9, i32 0, i32 2
  %167 = load i64, ptr %166, align 8, !tbaa !66
  %168 = getelementptr inbounds i8, ptr %165, i64 %167
  %169 = load ptr, ptr %7, align 8, !tbaa !5
  %170 = getelementptr inbounds %struct.ma_engine_node, ptr %169, i32 0, i32 4
  %171 = call i32 @ma_linear_resampler_init_preallocated(ptr noundef %11, ptr noundef %168, ptr noundef %170)
  store i32 %171, ptr %8, align 4, !tbaa !9
  %172 = load i32, ptr %8, align 4, !tbaa !9
  %173 = icmp ne i32 %172, 0
  br i1 %173, label %174, label %175

174:                                              ; preds = %152
  br label %231

175:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 12, ptr %20) #6
  %176 = getelementptr inbounds %struct.ma_node_config, ptr %10, i32 0, i32 4
  %177 = load ptr, ptr %176, align 8, !tbaa !58
  %178 = getelementptr inbounds i32, ptr %177, i64 0
  %179 = load i32, ptr %178, align 4, !tbaa !54
  %180 = load ptr, ptr %7, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.ma_engine_node, ptr %180, i32 0, i32 1
  %182 = load ptr, ptr %181, align 8, !tbaa !42
  %183 = call i32 @ma_engine_get_sample_rate(ptr noundef %182)
  %184 = call { i64, i32 } @ma_fader_config_init(i32 noundef 5, i32 noundef %179, i32 noundef %183)
  store { i64, i32 } %184, ptr %21, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %20, ptr align 8 %21, i64 12, i1 false)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %20, i64 12, i1 false), !tbaa.struct !67
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #6
  %185 = load ptr, ptr %7, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.ma_engine_node, ptr %185, i32 0, i32 3
  %187 = call i32 @ma_fader_init(ptr noundef %12, ptr noundef %186)
  store i32 %187, ptr %8, align 4, !tbaa !9
  %188 = load i32, ptr %8, align 4, !tbaa !9
  %189 = icmp ne i32 %188, 0
  br i1 %189, label %190, label %191

190:                                              ; preds = %175
  br label %228

191:                                              ; preds = %175
  call void @llvm.lifetime.start.p0(i64 72, ptr %22) #6
  call void @_ZL38ma_engine_node_spatializer_config_initPK14ma_node_config(ptr dead_on_unwind writable sret(%struct.ma_spatializer_config) align 8 %22, ptr noundef %10)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %13, ptr align 8 %22, i64 72, i1 false), !tbaa.struct !68
  call void @llvm.lifetime.end.p0(i64 72, ptr %22) #6
  %192 = load ptr, ptr %7, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.ma_engine_node, ptr %192, i32 0, i32 1
  %194 = load ptr, ptr %193, align 8, !tbaa !42
  %195 = getelementptr inbounds %struct.ma_engine, ptr %194, i32 0, i32 13
  %196 = load i32, ptr %195, align 4, !tbaa !73
  %197 = getelementptr inbounds %struct.ma_spatializer_config, ptr %13, i32 0, i32 16
  store i32 %196, ptr %197, align 4, !tbaa !78
  %198 = load ptr, ptr %6, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct.ma_engine_node_heap_layout, ptr %9, i32 0, i32 3
  %200 = load i64, ptr %199, align 8, !tbaa !80
  %201 = getelementptr inbounds i8, ptr %198, i64 %200
  %202 = load ptr, ptr %7, align 8, !tbaa !5
  %203 = getelementptr inbounds %struct.ma_engine_node, ptr %202, i32 0, i32 5
  %204 = call i32 @ma_spatializer_init_preallocated(ptr noundef %13, ptr noundef %201, ptr noundef %203)
  store i32 %204, ptr %8, align 4, !tbaa !9
  %205 = load i32, ptr %8, align 4, !tbaa !9
  %206 = icmp ne i32 %205, 0
  br i1 %206, label %207, label %208

207:                                              ; preds = %191
  br label %228

208:                                              ; preds = %191
  call void @llvm.lifetime.start.p0(i64 16, ptr %23) #6
  %209 = getelementptr inbounds %struct.ma_node_config, ptr %10, i32 0, i32 5
  %210 = load ptr, ptr %209, align 8, !tbaa !60
  %211 = getelementptr inbounds i32, ptr %210, i64 0
  %212 = load i32, ptr %211, align 4, !tbaa !54
  %213 = call { i64, i64 } @ma_panner_config_init(i32 noundef 5, i32 noundef %212)
  %214 = getelementptr inbounds { i64, i64 }, ptr %23, i32 0, i32 0
  %215 = extractvalue { i64, i64 } %213, 0
  store i64 %215, ptr %214, align 4
  %216 = getelementptr inbounds { i64, i64 }, ptr %23, i32 0, i32 1
  %217 = extractvalue { i64, i64 } %213, 1
  store i64 %217, ptr %216, align 4
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %23, i64 16, i1 false), !tbaa.struct !81
  call void @llvm.lifetime.end.p0(i64 16, ptr %23) #6
  %218 = load ptr, ptr %7, align 8, !tbaa !5
  %219 = getelementptr inbounds %struct.ma_engine_node, ptr %218, i32 0, i32 6
  %220 = call i32 @ma_panner_init(ptr noundef %14, ptr noundef %219)
  store i32 %220, ptr %8, align 4, !tbaa !9
  %221 = load i32, ptr %8, align 4, !tbaa !9
  %222 = icmp ne i32 %221, 0
  br i1 %222, label %223, label %224

223:                                              ; preds = %208
  br label %225

224:                                              ; preds = %208
  store i32 0, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %236

225:                                              ; preds = %223
  %226 = load ptr, ptr %7, align 8, !tbaa !5
  %227 = getelementptr inbounds %struct.ma_engine_node, ptr %226, i32 0, i32 5
  call void @ma_spatializer_uninit(ptr noundef %227, ptr noundef null)
  br label %228

228:                                              ; preds = %225, %207, %190
  %229 = load ptr, ptr %7, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.ma_engine_node, ptr %229, i32 0, i32 4
  call void @ma_linear_resampler_uninit(ptr noundef %230, ptr noundef null)
  br label %231

231:                                              ; preds = %228, %174
  %232 = load ptr, ptr %7, align 8, !tbaa !5
  %233 = getelementptr inbounds %struct.ma_engine_node, ptr %232, i32 0, i32 0
  call void @ma_node_uninit(ptr noundef %233, ptr noundef null)
  br label %234

234:                                              ; preds = %231, %151
  %235 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %235, ptr %4, align 4
  store i32 1, ptr %17, align 4
  br label %236

236:                                              ; preds = %234, %224, %51, %33, %26
  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 16, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 72, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 40, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  %237 = load i32, ptr %4, align 4
  ret i32 %237
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local i32 @ma_engine_get_listener_count(ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local i32 @ma_engine_get_sample_rate(ptr noundef) #3

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_engine_get_channels(ptr noundef) #5

; Function Attrs: mustprogress nounwind uwtable
declare hidden void @_ZL36ma_engine_node_base_node_config_initPK21ma_engine_node_config(ptr dead_on_unwind noalias writable sret(%struct.ma_node_config) align 8, ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden void @_ZL38ma_engine_node_spatializer_config_initPK14ma_node_config(ptr dead_on_unwind noalias writable sret(%struct.ma_spatializer_config) align 8, ptr noundef) #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #2 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { mustprogress 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 = { 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 = { 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 #6 = { 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 = !{!"_ZTS9ma_result", !7, i64 0}
!11 = !{!12, !7, i64 26}
!12 = !{!"_ZTS21ma_engine_node_config", !6, i64 0, !13, i64 8, !14, i64 12, !14, i64 16, !14, i64 20, !7, i64 24, !7, i64 25, !7, i64 26}
!13 = !{!"_ZTS19ma_engine_node_type", !7, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!12, !6, i64 0}
!16 = !{!17, !6, i64 784}
!17 = !{!"_ZTS14ma_engine_node", !18, i64 0, !6, i64 360, !14, i64 368, !22, i64 376, !26, i64 416, !30, i64 552, !37, i64 736, !25, i64 752, !25, i64 756, !25, i64 760, !14, i64 764, !14, i64 768, !14, i64 772, !7, i64 776, !6, i64 784}
!18 = !{!"_ZTS12ma_node_base", !6, i64 0, !6, i64 8, !6, i64 16, !19, i64 24, !19, i64 26, !19, i64 28, !19, i64 30, !20, i64 32, !7, i64 40, !21, i64 56, !14, i64 64, !14, i64 68, !6, i64 72, !6, i64 80, !7, i64 88, !7, i64 232, !6, i64 344, !14, i64 352}
!19 = !{!"short", !7, i64 0}
!20 = !{!"_ZTS13ma_node_state", !7, i64 0}
!21 = !{!"long long", !7, i64 0}
!22 = !{!"_ZTS8ma_fader", !23, i64 0, !25, i64 12, !25, i64 16, !21, i64 24, !21, i64 32}
!23 = !{!"_ZTS15ma_fader_config", !24, i64 0, !14, i64 4, !14, i64 8}
!24 = !{!"_ZTS9ma_format", !7, i64 0}
!25 = !{!"float", !7, i64 0}
!26 = !{!"_ZTS19ma_linear_resampler", !27, i64 0, !14, i64 32, !14, i64 36, !14, i64 40, !14, i64 44, !7, i64 48, !7, i64 56, !29, i64 64, !6, i64 120, !14, i64 128}
!27 = !{!"_ZTS26ma_linear_resampler_config", !24, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !28, i64 24}
!28 = !{!"double", !7, i64 0}
!29 = !{!"_ZTS6ma_lpf", !24, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !14, i64 48}
!30 = !{!"_ZTS14ma_spatializer", !14, i64 0, !14, i64 4, !6, i64 8, !31, i64 16, !32, i64 20, !33, i64 24, !25, i64 28, !25, i64 32, !25, i64 36, !25, i64 40, !25, i64 44, !25, i64 48, !25, i64 52, !25, i64 56, !25, i64 60, !25, i64 64, !14, i64 68, !34, i64 72, !34, i64 84, !34, i64 96, !25, i64 108, !35, i64 112, !6, i64 160, !6, i64 168, !14, i64 176}
!31 = !{!"_ZTS20ma_attenuation_model", !7, i64 0}
!32 = !{!"_ZTS14ma_positioning", !7, i64 0}
!33 = !{!"_ZTS13ma_handedness", !7, i64 0}
!34 = !{!"_ZTS8ma_vec3f", !25, i64 0, !25, i64 4, !25, i64 8}
!35 = !{!"_ZTS9ma_gainer", !36, i64 0, !14, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !14, i64 40}
!36 = !{!"_ZTS16ma_gainer_config", !14, i64 0, !14, i64 4}
!37 = !{!"_ZTS9ma_panner", !24, i64 0, !14, i64 4, !38, i64 8, !25, i64 12}
!38 = !{!"_ZTS11ma_pan_mode", !7, i64 0}
!39 = !{!40, !41, i64 0}
!40 = !{!"_ZTS26ma_engine_node_heap_layout", !41, i64 0, !41, i64 8, !41, i64 16, !41, i64 24}
!41 = !{!"long", !7, i64 0}
!42 = !{!17, !6, i64 360}
!43 = !{!12, !14, i64 20}
!44 = !{!17, !14, i64 368}
!45 = !{!17, !25, i64 752}
!46 = !{!17, !25, i64 756}
!47 = !{!17, !25, i64 760}
!48 = !{!12, !7, i64 24}
!49 = !{!17, !14, i64 764}
!50 = !{!12, !7, i64 25}
!51 = !{!17, !14, i64 768}
!52 = !{!17, !14, i64 772}
!53 = !{!12, !14, i64 12}
!54 = !{!14, !14, i64 0}
!55 = !{!12, !14, i64 16}
!56 = !{i64 0, i64 8, !5, i64 8, i64 4, !57, i64 12, i64 4, !54, i64 16, i64 4, !54, i64 24, i64 8, !5, i64 32, i64 8, !5}
!57 = !{!20, !20, i64 0}
!58 = !{!59, !6, i64 24}
!59 = !{!"_ZTS14ma_node_config", !6, i64 0, !20, i64 8, !14, i64 12, !14, i64 16, !6, i64 24, !6, i64 32}
!60 = !{!59, !6, i64 32}
!61 = !{!40, !41, i64 8}
!62 = !{i64 0, i64 4, !63, i64 4, i64 4, !54, i64 8, i64 4, !54, i64 12, i64 4, !54, i64 16, i64 4, !54, i64 24, i64 8, !64}
!63 = !{!24, !24, i64 0}
!64 = !{!28, !28, i64 0}
!65 = !{!27, !14, i64 16}
!66 = !{!40, !41, i64 16}
!67 = !{i64 0, i64 4, !63, i64 4, i64 4, !54, i64 8, i64 4, !54}
!68 = !{i64 0, i64 4, !54, i64 4, i64 4, !54, i64 8, i64 8, !5, i64 16, i64 4, !69, i64 20, i64 4, !70, i64 24, i64 4, !71, i64 28, i64 4, !72, i64 32, i64 4, !72, i64 36, i64 4, !72, i64 40, i64 4, !72, i64 44, i64 4, !72, i64 48, i64 4, !72, i64 52, i64 4, !72, i64 56, i64 4, !72, i64 60, i64 4, !72, i64 64, i64 4, !72, i64 68, i64 4, !54}
!69 = !{!31, !31, i64 0}
!70 = !{!32, !32, i64 0}
!71 = !{!33, !33, i64 0}
!72 = !{!25, !25, i64 0}
!73 = !{!74, !14, i64 1228}
!74 = !{!"_ZTS9ma_engine", !75, i64 0, !6, i64 728, !6, i64 736, !6, i64 744, !14, i64 752, !14, i64 756, !7, i64 760, !76, i64 1176, !7, i64 1208, !7, i64 1209, !14, i64 1212, !6, i64 1216, !14, i64 1224, !14, i64 1228, !77, i64 1232}
!75 = !{!"_ZTS13ma_node_graph", !18, i64 0, !18, i64 360, !19, i64 720, !14, i64 724}
!76 = !{!"_ZTS23ma_allocation_callbacks", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!77 = !{!"_ZTS22ma_mono_expansion_mode", !7, i64 0}
!78 = !{!79, !14, i64 68}
!79 = !{!"_ZTS21ma_spatializer_config", !14, i64 0, !14, i64 4, !6, i64 8, !31, i64 16, !32, i64 20, !33, i64 24, !25, i64 28, !25, i64 32, !25, i64 36, !25, i64 40, !25, i64 44, !25, i64 48, !25, i64 52, !25, i64 56, !25, i64 60, !25, i64 64, !14, i64 68}
!80 = !{!40, !41, i64 24}
!81 = !{i64 0, i64 4, !63, i64 4, i64 4, !54, i64 8, i64 4, !82, i64 12, i64 4, !72}
!82 = !{!38, !38, 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"

%struct.ma_linear_resampler_config = type { i32, i32, i32, i32, i32, double }
%struct.ma_engine_node_heap_layout = type { i64, i64, i64, i64 }
%struct.ma_node_config = type { ptr, i32, i32, i32, ptr, ptr }
%struct.ma_fader_config = type { i32, i32, i32 }
%struct.ma_spatializer_config = type { i32, i32, ptr, i32, i32, i32, float, float, float, float, float, float, float, float, float, float, i32 }
%struct.ma_panner_config = type { i32, i32, i32, float }

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local { i64, i64 } @ma_panner_config_init(i32 noundef, i32 noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local { i64, i32 } @ma_fader_config_init(i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @ma_linear_resampler_config_init(ptr dead_on_unwind noalias writable sret(%struct.ma_linear_resampler_config) align 8, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #2

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local i32 @ma_engine_node_init_preallocated(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #4 {
  %4 = alloca %struct.ma_engine_node_heap_layout, align 8
  %5 = alloca %struct.ma_node_config, align 8
  %6 = alloca %struct.ma_linear_resampler_config, align 8
  %7 = alloca %struct.ma_fader_config, align 8
  %8 = alloca %struct.ma_spatializer_config, align 8
  %9 = alloca %struct.ma_panner_config, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #5
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #5
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %8) #5
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #5
  %12 = icmp eq ptr %2, null
  br i1 %12, label %105, label %13

13:                                               ; preds = %3
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(792) %2, i8 0, i64 792, i1 false)
  %14 = call noundef i32 @_ZL30ma_engine_node_get_heap_layoutPK21ma_engine_node_configP26ma_engine_node_heap_layout(ptr noundef %0, ptr noundef nonnull %4)
  %.not = icmp eq i32 %14, 0
  br i1 %.not, label %15, label %105

15:                                               ; preds = %13
  %16 = getelementptr inbounds i8, ptr %0, i64 26
  %17 = load i8, ptr %16, align 2, !tbaa !5
  %.not70 = icmp eq i8 %17, -1
  br i1 %.not70, label %22, label %18

18:                                               ; preds = %15
  %19 = zext i8 %17 to i32
  %20 = load ptr, ptr %0, align 8, !tbaa !12
  %21 = call i32 @ma_engine_get_listener_count(ptr noundef %20)
  %.not71 = icmp ugt i32 %21, %19
  br i1 %.not71, label %22, label %105

22:                                               ; preds = %18, %15
  %23 = getelementptr inbounds i8, ptr %2, i64 784
  store ptr %1, ptr %23, align 8, !tbaa !13
  %24 = load i64, ptr %4, align 8, !tbaa !36
  call void @llvm.memset.p0.i64(ptr align 1 %1, i8 0, i64 %24, i1 false)
  %25 = load ptr, ptr %0, align 8, !tbaa !12
  %26 = getelementptr inbounds i8, ptr %2, i64 360
  store ptr %25, ptr %26, align 8, !tbaa !39
  %27 = getelementptr inbounds i8, ptr %0, i64 20
  %28 = load i32, ptr %27, align 4, !tbaa !40
  %.not72 = icmp eq i32 %28, 0
  br i1 %.not72, label %29, label %31

29:                                               ; preds = %22
  %30 = call i32 @ma_engine_get_sample_rate(ptr noundef %25)
  br label %31

31:                                               ; preds = %22, %29
  %32 = phi i32 [ %30, %29 ], [ %28, %22 ]
  %33 = getelementptr inbounds i8, ptr %2, i64 368
  store i32 %32, ptr %33, align 8, !tbaa !41
  %34 = getelementptr inbounds i8, ptr %2, i64 752
  store <2 x float> <float 1.000000e+00, float 1.000000e+00>, ptr %34, align 8, !tbaa !42
  %35 = getelementptr inbounds i8, ptr %2, i64 760
  store float 1.000000e+00, ptr %35, align 8, !tbaa !43
  %36 = getelementptr inbounds i8, ptr %0, i64 24
  %37 = getelementptr inbounds i8, ptr %2, i64 764
  %38 = load <2 x i8>, ptr %36, align 8, !tbaa !44
  %39 = zext <2 x i8> %38 to <2 x i32>
  store <2 x i32> %39, ptr %37, align 4, !tbaa !45
  %40 = load i8, ptr %16, align 2, !tbaa !5
  %41 = zext i8 %40 to i32
  %42 = getelementptr inbounds i8, ptr %2, i64 772
  store i32 %41, ptr %42, align 4, !tbaa !46
  %43 = getelementptr inbounds i8, ptr %0, i64 12
  %44 = load i32, ptr %43, align 4, !tbaa !47
  %.not73 = icmp eq i32 %44, 0
  br i1 %.not73, label %45, label %48

45:                                               ; preds = %31
  %46 = load ptr, ptr %0, align 8, !tbaa !12
  %47 = call i32 @ma_engine_get_channels(ptr noundef %46)
  br label %48

48:                                               ; preds = %31, %45
  %49 = phi i32 [ %47, %45 ], [ %44, %31 ]
  store i32 %49, ptr %10, align 4, !tbaa !45
  %50 = getelementptr inbounds i8, ptr %0, i64 16
  %51 = load i32, ptr %50, align 8, !tbaa !48
  %.not74 = icmp eq i32 %51, 0
  br i1 %.not74, label %52, label %55

52:                                               ; preds = %48
  %53 = load ptr, ptr %0, align 8, !tbaa !12
  %54 = call i32 @ma_engine_get_channels(ptr noundef %53)
  br label %55

55:                                               ; preds = %48, %52
  %56 = phi i32 [ %54, %52 ], [ %51, %48 ]
  store i32 %56, ptr %11, align 4, !tbaa !45
  call void @_ZL36ma_engine_node_base_node_config_initPK21ma_engine_node_config(ptr dead_on_unwind nonnull writable sret(%struct.ma_node_config) align 8 %5, ptr noundef nonnull %0)
  %57 = getelementptr inbounds i8, ptr %5, i64 24
  store ptr %10, ptr %57, align 8, !tbaa !49
  %58 = getelementptr inbounds i8, ptr %5, i64 32
  store ptr %11, ptr %58, align 8, !tbaa !51
  %59 = load ptr, ptr %0, align 8, !tbaa !12
  %60 = getelementptr inbounds i8, ptr %4, i64 8
  %61 = load i64, ptr %60, align 8, !tbaa !52
  %62 = getelementptr inbounds i8, ptr %1, i64 %61
  %63 = call i32 @ma_node_init_preallocated(ptr noundef %59, ptr noundef nonnull %5, ptr noundef %62, ptr noundef nonnull %2)
  %.not75 = icmp eq i32 %63, 0
  br i1 %.not75, label %64, label %105

64:                                               ; preds = %55
  %65 = load ptr, ptr %57, align 8, !tbaa !49
  %66 = load i32, ptr %65, align 4, !tbaa !45
  %67 = load i32, ptr %33, align 8, !tbaa !41
  %68 = load ptr, ptr %26, align 8, !tbaa !39
  %69 = call i32 @ma_engine_get_sample_rate(ptr noundef %68)
  call void @ma_linear_resampler_config_init(ptr dead_on_unwind nonnull writable sret(%struct.ma_linear_resampler_config) align 8 %6, i32 noundef 5, i32 noundef %66, i32 noundef %67, i32 noundef %69)
  %70 = getelementptr inbounds i8, ptr %6, i64 16
  store i32 0, ptr %70, align 8, !tbaa !53
  %71 = getelementptr inbounds i8, ptr %4, i64 16
  %72 = load i64, ptr %71, align 8, !tbaa !54
  %73 = getelementptr inbounds i8, ptr %1, i64 %72
  %74 = getelementptr inbounds i8, ptr %2, i64 416
  %75 = call i32 @ma_linear_resampler_init_preallocated(ptr noundef nonnull %6, ptr noundef %73, ptr noundef nonnull %74)
  %.not76 = icmp eq i32 %75, 0
  br i1 %.not76, label %76, label %104

76:                                               ; preds = %64
  %77 = load ptr, ptr %57, align 8, !tbaa !49
  %78 = load i32, ptr %77, align 4, !tbaa !45
  %79 = load ptr, ptr %26, align 8, !tbaa !39
  %80 = call i32 @ma_engine_get_sample_rate(ptr noundef %79)
  %81 = call { i64, i32 } @ma_fader_config_init(i32 noundef 5, i32 noundef %78, i32 noundef %80)
  %.fca.0.extract = extractvalue { i64, i32 } %81, 0
  %.fca.1.extract = extractvalue { i64, i32 } %81, 1
  store i64 %.fca.0.extract, ptr %7, align 8
  %.sroa.43.0..sroa_idx = getelementptr inbounds i8, ptr %7, i64 8
  store i32 %.fca.1.extract, ptr %.sroa.43.0..sroa_idx, align 8, !tbaa !45
  %82 = getelementptr inbounds i8, ptr %2, i64 376
  %83 = call i32 @ma_fader_init(ptr noundef nonnull %7, ptr noundef nonnull %82)
  %.not77 = icmp eq i32 %83, 0
  br i1 %.not77, label %84, label %103

84:                                               ; preds = %76
  call void @_ZL38ma_engine_node_spatializer_config_initPK14ma_node_config(ptr dead_on_unwind nonnull writable sret(%struct.ma_spatializer_config) align 8 %8, ptr noundef nonnull %5)
  %85 = load ptr, ptr %26, align 8, !tbaa !39
  %86 = getelementptr inbounds i8, ptr %85, i64 1228
  %87 = load i32, ptr %86, align 4, !tbaa !55
  %88 = getelementptr inbounds i8, ptr %8, i64 68
  store i32 %87, ptr %88, align 4, !tbaa !60
  %89 = getelementptr inbounds i8, ptr %4, i64 24
  %90 = load i64, ptr %89, align 8, !tbaa !62
  %91 = getelementptr inbounds i8, ptr %1, i64 %90
  %92 = getelementptr inbounds i8, ptr %2, i64 552
  %93 = call i32 @ma_spatializer_init_preallocated(ptr noundef nonnull %8, ptr noundef %91, ptr noundef nonnull %92)
  %.not78 = icmp eq i32 %93, 0
  br i1 %.not78, label %94, label %103

94:                                               ; preds = %84
  %95 = load ptr, ptr %58, align 8, !tbaa !51
  %96 = load i32, ptr %95, align 4, !tbaa !45
  %97 = call { i64, i64 } @ma_panner_config_init(i32 noundef 5, i32 noundef %96)
  %98 = extractvalue { i64, i64 } %97, 0
  %99 = extractvalue { i64, i64 } %97, 1
  store i64 %98, ptr %9, align 8
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %9, i64 8
  store i64 %99, ptr %.sroa.4.0..sroa_idx, align 8
  %100 = getelementptr inbounds i8, ptr %2, i64 736
  %101 = call i32 @ma_panner_init(ptr noundef nonnull %9, ptr noundef nonnull %100)
  %.not79 = icmp eq i32 %101, 0
  br i1 %.not79, label %105, label %102

102:                                              ; preds = %94
  call void @ma_spatializer_uninit(ptr noundef nonnull %92, ptr noundef null)
  br label %103

103:                                              ; preds = %84, %76, %102
  %.058 = phi i32 [ %83, %76 ], [ %93, %84 ], [ %101, %102 ]
  call void @ma_linear_resampler_uninit(ptr noundef nonnull %74, ptr noundef null)
  br label %104

104:                                              ; preds = %64, %103
  %.1 = phi i32 [ %75, %64 ], [ %.058, %103 ]
  call void @ma_node_uninit(ptr noundef nonnull %2, ptr noundef null)
  br label %105

105:                                              ; preds = %104, %55, %94, %18, %13, %3
  %.0 = phi i32 [ -2, %3 ], [ %14, %13 ], [ -2, %18 ], [ 0, %94 ], [ %63, %55 ], [ %.1, %104 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #5
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #5
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #5
  ret i32 %.0
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local i32 @ma_engine_get_listener_count(ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local i32 @ma_engine_get_sample_rate(ptr noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress nounwind uwtable
declare hidden void @_ZL36ma_engine_node_base_node_config_initPK21ma_engine_node_config(ptr dead_on_unwind noalias writable sret(%struct.ma_node_config) align 8, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare hidden void @_ZL38ma_engine_node_spatializer_config_initPK14ma_node_config(ptr dead_on_unwind noalias writable sret(%struct.ma_spatializer_config) align 8, ptr noundef) local_unnamed_addr #2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #2 = { mustprogress 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 = { 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 #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 = { 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, !8, i64 26}
!6 = !{!"_ZTS21ma_engine_node_config", !7, i64 0, !10, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !8, i64 24, !8, i64 25, !8, i64 26}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTS19ma_engine_node_type", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!6, !7, i64 0}
!13 = !{!14, !7, i64 784}
!14 = !{!"_ZTS14ma_engine_node", !15, i64 0, !7, i64 360, !11, i64 368, !19, i64 376, !23, i64 416, !27, i64 552, !34, i64 736, !22, i64 752, !22, i64 756, !22, i64 760, !11, i64 764, !11, i64 768, !11, i64 772, !8, i64 776, !7, i64 784}
!15 = !{!"_ZTS12ma_node_base", !7, i64 0, !7, i64 8, !7, i64 16, !16, i64 24, !16, i64 26, !16, i64 28, !16, i64 30, !17, i64 32, !8, i64 40, !18, i64 56, !11, i64 64, !11, i64 68, !7, i64 72, !7, i64 80, !8, i64 88, !8, i64 232, !7, i64 344, !11, i64 352}
!16 = !{!"short", !8, i64 0}
!17 = !{!"_ZTS13ma_node_state", !8, i64 0}
!18 = !{!"long long", !8, i64 0}
!19 = !{!"_ZTS8ma_fader", !20, i64 0, !22, i64 12, !22, i64 16, !18, i64 24, !18, i64 32}
!20 = !{!"_ZTS15ma_fader_config", !21, i64 0, !11, i64 4, !11, i64 8}
!21 = !{!"_ZTS9ma_format", !8, i64 0}
!22 = !{!"float", !8, i64 0}
!23 = !{!"_ZTS19ma_linear_resampler", !24, i64 0, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !8, i64 48, !8, i64 56, !26, i64 64, !7, i64 120, !11, i64 128}
!24 = !{!"_ZTS26ma_linear_resampler_config", !21, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !25, i64 24}
!25 = !{!"double", !8, i64 0}
!26 = !{!"_ZTS6ma_lpf", !21, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !11, i64 48}
!27 = !{!"_ZTS14ma_spatializer", !11, i64 0, !11, i64 4, !7, i64 8, !28, i64 16, !29, i64 20, !30, i64 24, !22, i64 28, !22, i64 32, !22, i64 36, !22, i64 40, !22, i64 44, !22, i64 48, !22, i64 52, !22, i64 56, !22, i64 60, !22, i64 64, !11, i64 68, !31, i64 72, !31, i64 84, !31, i64 96, !22, i64 108, !32, i64 112, !7, i64 160, !7, i64 168, !11, i64 176}
!28 = !{!"_ZTS20ma_attenuation_model", !8, i64 0}
!29 = !{!"_ZTS14ma_positioning", !8, i64 0}
!30 = !{!"_ZTS13ma_handedness", !8, i64 0}
!31 = !{!"_ZTS8ma_vec3f", !22, i64 0, !22, i64 4, !22, i64 8}
!32 = !{!"_ZTS9ma_gainer", !33, i64 0, !11, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !11, i64 40}
!33 = !{!"_ZTS16ma_gainer_config", !11, i64 0, !11, i64 4}
!34 = !{!"_ZTS9ma_panner", !21, i64 0, !11, i64 4, !35, i64 8, !22, i64 12}
!35 = !{!"_ZTS11ma_pan_mode", !8, i64 0}
!36 = !{!37, !38, i64 0}
!37 = !{!"_ZTS26ma_engine_node_heap_layout", !38, i64 0, !38, i64 8, !38, i64 16, !38, i64 24}
!38 = !{!"long", !8, i64 0}
!39 = !{!14, !7, i64 360}
!40 = !{!6, !11, i64 20}
!41 = !{!14, !11, i64 368}
!42 = !{!22, !22, i64 0}
!43 = !{!14, !22, i64 760}
!44 = !{!8, !8, i64 0}
!45 = !{!11, !11, i64 0}
!46 = !{!14, !11, i64 772}
!47 = !{!6, !11, i64 12}
!48 = !{!6, !11, i64 16}
!49 = !{!50, !7, i64 24}
!50 = !{!"_ZTS14ma_node_config", !7, i64 0, !17, i64 8, !11, i64 12, !11, i64 16, !7, i64 24, !7, i64 32}
!51 = !{!50, !7, i64 32}
!52 = !{!37, !38, i64 8}
!53 = !{!24, !11, i64 16}
!54 = !{!37, !38, i64 16}
!55 = !{!56, !11, i64 1228}
!56 = !{!"_ZTS9ma_engine", !57, i64 0, !7, i64 728, !7, i64 736, !7, i64 744, !11, i64 752, !11, i64 756, !8, i64 760, !58, i64 1176, !8, i64 1208, !8, i64 1209, !11, i64 1212, !7, i64 1216, !11, i64 1224, !11, i64 1228, !59, i64 1232}
!57 = !{!"_ZTS13ma_node_graph", !15, i64 0, !15, i64 360, !16, i64 720, !11, i64 724}
!58 = !{!"_ZTS23ma_allocation_callbacks", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24}
!59 = !{!"_ZTS22ma_mono_expansion_mode", !8, i64 0}
!60 = !{!61, !11, i64 68}
!61 = !{!"_ZTS21ma_spatializer_config", !11, i64 0, !11, i64 4, !7, i64 8, !28, i64 16, !29, i64 20, !30, i64 24, !22, i64 28, !22, i64 32, !22, i64 36, !22, i64 40, !22, i64 44, !22, i64 48, !22, i64 52, !22, i64 56, !22, i64 60, !22, i64 64, !11, i64 68}
!62 = !{!37, !38, i64 24}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,MemCpyOptPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass