; 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_device_descriptor = type { ptr, i32, i32, i32, i32, [254 x i8], i32, i32, i32 }
%struct.ma_context = type { %struct.ma_backend_callbacks, i32, ptr, %struct.ma_log, i32, i64, ptr, %struct.ma_allocation_callbacks, %union.pthread_mutex_t, %union.pthread_mutex_t, i32, i32, i32, ptr, %union.anon.41, %union.anon.46 }
%struct.ma_backend_callbacks = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.ma_log = type { [4 x %struct.ma_log_callback], i32, %struct.ma_allocation_callbacks, %union.pthread_mutex_t }
%struct.ma_log_callback = type { ptr, ptr }
%struct.ma_allocation_callbacks = type { ptr, ptr, ptr, ptr }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%union.anon.41 = type { %struct.anon.42 }
%struct.anon.42 = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, %union.pthread_mutex_t, i32 }
%union.anon.46 = type { %struct.anon.47 }
%struct.anon.47 = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.ma_device_config = type { i32, i32, i32, i32, i32, i32, i8, i8, i8, i8, ptr, ptr, ptr, ptr, %struct.ma_resampler_config, %struct.anon.49, %struct.anon.50, %struct.anon.51, %struct.anon.52, %struct.anon.53, %struct.anon.54, %struct.anon.55, %struct.anon.56 }
%struct.ma_resampler_config = type { i32, i32, i32, i32, i32, ptr, ptr, %struct.anon.48 }
%struct.anon.48 = type { i32 }
%struct.anon.49 = type { ptr, i32, i32, ptr, i32, i32 }
%struct.anon.50 = type { ptr, i32, i32, ptr, i32, i32 }
%struct.anon.51 = type { i8, i8, i8, i8 }
%struct.anon.52 = type { i32, i32, i32, i32 }
%struct.anon.53 = type { ptr, ptr }
%struct.anon.54 = type { i32 }
%struct.anon.55 = type { i32, i32 }
%struct.anon.56 = type { i32, i32, i32, i32 }
%struct.ma_device = type { ptr, i32, i32, i32, ptr, ptr, ptr, ptr, %union.pthread_mutex_t, %struct.ma_event, %struct.ma_event, %struct.ma_event, i64, i32, i8, i8, i8, i8, i8, float, %struct.ma_duplex_rb, %struct.anon.24, %struct.anon.26, %struct.anon.31, %union.anon.32 }
%struct.ma_event = type { i32, %union.pthread_mutex_t, %union.pthread_cond_t }
%union.pthread_cond_t = type { %struct.__pthread_cond_s }
%struct.__pthread_cond_s = type { %union.__atomic_wide_counter, %union.__atomic_wide_counter, [2 x i32], [2 x i32], i32, i32, [2 x i32] }
%union.__atomic_wide_counter = type { i64 }
%struct.ma_duplex_rb = type { %struct.ma_pcm_rb }
%struct.ma_pcm_rb = type { %struct.ma_rb, i32, i32 }
%struct.ma_rb = type { ptr, i32, i32, i32, i32, i32, i8, i8, %struct.ma_allocation_callbacks }
%struct.anon.24 = type { i32, ptr, ptr, %struct.anon.25 }
%struct.anon.25 = type { i32 }
%struct.anon.26 = type { ptr, %union.ma_device_id, [256 x i8], i32, i32, i32, [254 x i8], i32, i32, i32, [254 x i8], i32, i32, i32, %struct.ma_data_converter, ptr, i32, i32, ptr, i64, i64, i64 }
%union.ma_device_id = type { %union.anon.17 }
%union.anon.17 = type { ptr, [248 x i8] }
%struct.ma_data_converter = type { i32, i32, i32, i32, i32, i32, i32, i32, %struct.ma_channel_converter, %struct.ma_resampler, i8, i8, i8, i8, i8, i8, ptr }
%struct.ma_channel_converter = type { i32, i32, i32, i32, i32, ptr, ptr, ptr, %union.anon.27, ptr, i32 }
%union.anon.27 = type { ptr }
%struct.ma_resampler = type { ptr, ptr, ptr, i32, i32, i32, i32, %union.anon.28, ptr, i32 }
%union.anon.28 = type { %struct.ma_linear_resampler }
%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 }
%struct.ma_linear_resampler_config = type { i32, i32, i32, i32, i32, double }
%union.anon.29 = type { ptr }
%union.anon.30 = type { ptr }
%struct.ma_lpf = type { i32, i32, i32, i32, i32, ptr, ptr, ptr, i32 }
%struct.anon.31 = type { ptr, %union.ma_device_id, [256 x i8], i32, i32, i32, [254 x i8], i32, i32, i32, [254 x i8], i32, i32, i32, %struct.ma_data_converter, ptr, i32, i32 }
%union.anon.32 = type { %struct.anon.36 }
%struct.anon.36 = type { i64, %struct.ma_event, %struct.ma_event, %struct.ma_semaphore, i32, i32, %union.ma_timer, double, i32, i32, i64, i64, i32 }
%struct.ma_semaphore = type { i32, %union.pthread_mutex_t, %union.pthread_cond_t }
%union.ma_timer = type { i64 }

@.str.6 = external hidden unnamed_addr constant [104 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [56 x i8], align 1
@__PRETTY_FUNCTION__.ma_device_init = external hidden unnamed_addr constant [78 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [9 x i8], align 1

; 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: mustprogress uwtable
declare dso_local ptr @ma_malloc(i64 noundef, ptr noundef) #1

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

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_mutex_init(ptr noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_mutex_uninit(ptr noundef) #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) #3

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_log_postf(ptr noundef, i32 noundef, ptr noundef, ...) #1

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

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_event_init(ptr noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_event_uninit(ptr noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_event_wait(ptr noundef) #1

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

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

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

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL16ma_thread_createPm18ma_thread_prioritymPFPvS1_ES1_PK23ma_allocation_callbacks(ptr noundef, i32 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) #1

; Function Attrs: mustprogress uwtable
define dso_local i32 @ma_device_init(ptr noundef %0, ptr noundef %1, ptr noundef %2) #1 {
  %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_device_descriptor, align 8
  %10 = alloca %struct.ma_device_descriptor, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i64, align 8
  %15 = alloca [256 x i8], align 16
  %16 = alloca [256 x i8], align 16
  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) #7
  call void @llvm.lifetime.start.p0(i64 296, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 296, ptr %10) #7
  %17 = load ptr, ptr %5, align 8, !tbaa !5
  %18 = icmp eq ptr %17, null
  br i1 %18, label %19, label %23

19:                                               ; preds = %3
  %20 = load ptr, ptr %6, align 8, !tbaa !5
  %21 = load ptr, ptr %7, align 8, !tbaa !5
  %22 = call i32 @ma_device_init_ex(ptr noundef null, i32 noundef 0, ptr noundef null, ptr noundef %20, ptr noundef %21)
  store i32 %22, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

23:                                               ; preds = %3
  %24 = load ptr, ptr %7, align 8, !tbaa !5
  %25 = icmp eq ptr %24, null
  br i1 %25, label %26, label %27

26:                                               ; preds = %23
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

27:                                               ; preds = %23
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.memset.p0.i64(ptr align 8 %28, i8 0, i64 3696, i1 false)
  %29 = load ptr, ptr %6, align 8, !tbaa !5
  %30 = icmp eq ptr %29, null
  br i1 %30, label %31, label %32

31:                                               ; preds = %27
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

32:                                               ; preds = %27
  %33 = load ptr, ptr %5, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.ma_context, ptr %33, i32 0, i32 0
  %35 = getelementptr inbounds %struct.ma_backend_callbacks, ptr %34, i32 0, i32 4
  %36 = load ptr, ptr %35, align 8, !tbaa !9
  %37 = icmp eq ptr %36, null
  br i1 %37, label %38, label %39

38:                                               ; preds = %32
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

39:                                               ; preds = %32
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.ma_device_config, ptr %40, i32 0, i32 0
  %42 = load i32, ptr %41, align 8, !tbaa !18
  %43 = icmp eq i32 %42, 2
  br i1 %43, label %49, label %44

44:                                               ; preds = %39
  %45 = load ptr, ptr %6, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.ma_device_config, ptr %45, i32 0, i32 0
  %47 = load i32, ptr %46, align 8, !tbaa !18
  %48 = icmp eq i32 %47, 3
  br i1 %48, label %49, label %69

49:                                               ; preds = %44, %39
  %50 = load ptr, ptr %6, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.ma_device_config, ptr %50, i32 0, i32 16
  %52 = getelementptr inbounds %struct.anon.50, ptr %51, i32 0, i32 2
  %53 = load i32, ptr %52, align 4, !tbaa !41
  %54 = icmp ugt i32 %53, 254
  br i1 %54, label %55, label %56

55:                                               ; preds = %49
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

56:                                               ; preds = %49
  %57 = load ptr, ptr %6, align 8, !tbaa !5
  %58 = getelementptr inbounds %struct.ma_device_config, ptr %57, i32 0, i32 16
  %59 = getelementptr inbounds %struct.anon.50, ptr %58, i32 0, i32 3
  %60 = load ptr, ptr %59, align 8, !tbaa !42
  %61 = load ptr, ptr %6, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.ma_device_config, ptr %61, i32 0, i32 16
  %63 = getelementptr inbounds %struct.anon.50, ptr %62, i32 0, i32 2
  %64 = load i32, ptr %63, align 4, !tbaa !41
  %65 = call noundef i32 @_ZL24ma__is_channel_map_validPKhj(ptr noundef %60, i32 noundef %64)
  %66 = icmp ne i32 %65, 0
  br i1 %66, label %68, label %67

67:                                               ; preds = %56
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

68:                                               ; preds = %56
  br label %69

69:                                               ; preds = %68, %44
  %70 = load ptr, ptr %6, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.ma_device_config, ptr %70, i32 0, i32 0
  %72 = load i32, ptr %71, align 8, !tbaa !18
  %73 = icmp eq i32 %72, 1
  br i1 %73, label %84, label %74

74:                                               ; preds = %69
  %75 = load ptr, ptr %6, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct.ma_device_config, ptr %75, i32 0, i32 0
  %77 = load i32, ptr %76, align 8, !tbaa !18
  %78 = icmp eq i32 %77, 3
  br i1 %78, label %84, label %79

79:                                               ; preds = %74
  %80 = load ptr, ptr %6, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.ma_device_config, ptr %80, i32 0, i32 0
  %82 = load i32, ptr %81, align 8, !tbaa !18
  %83 = icmp eq i32 %82, 4
  br i1 %83, label %84, label %104

84:                                               ; preds = %79, %74, %69
  %85 = load ptr, ptr %6, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.ma_device_config, ptr %85, i32 0, i32 15
  %87 = getelementptr inbounds %struct.anon.49, ptr %86, i32 0, i32 2
  %88 = load i32, ptr %87, align 4, !tbaa !43
  %89 = icmp ugt i32 %88, 254
  br i1 %89, label %90, label %91

90:                                               ; preds = %84
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

91:                                               ; preds = %84
  %92 = load ptr, ptr %6, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct.ma_device_config, ptr %92, i32 0, i32 15
  %94 = getelementptr inbounds %struct.anon.49, ptr %93, i32 0, i32 3
  %95 = load ptr, ptr %94, align 8, !tbaa !44
  %96 = load ptr, ptr %6, align 8, !tbaa !5
  %97 = getelementptr inbounds %struct.ma_device_config, ptr %96, i32 0, i32 15
  %98 = getelementptr inbounds %struct.anon.49, ptr %97, i32 0, i32 2
  %99 = load i32, ptr %98, align 4, !tbaa !43
  %100 = call noundef i32 @_ZL24ma__is_channel_map_validPKhj(ptr noundef %95, i32 noundef %99)
  %101 = icmp ne i32 %100, 0
  br i1 %101, label %103, label %102

102:                                              ; preds = %91
  store i32 -2, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

103:                                              ; preds = %91
  br label %104

104:                                              ; preds = %103, %79
  %105 = load ptr, ptr %5, align 8, !tbaa !5
  %106 = load ptr, ptr %7, align 8, !tbaa !5
  %107 = getelementptr inbounds %struct.ma_device, ptr %106, i32 0, i32 0
  store ptr %105, ptr %107, align 8, !tbaa !45
  %108 = load ptr, ptr %6, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.ma_device_config, ptr %108, i32 0, i32 13
  %110 = load ptr, ptr %109, align 8, !tbaa !65
  %111 = load ptr, ptr %7, align 8, !tbaa !5
  %112 = getelementptr inbounds %struct.ma_device, ptr %111, i32 0, i32 7
  store ptr %110, ptr %112, align 8, !tbaa !66
  %113 = load ptr, ptr %6, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.ma_device_config, ptr %113, i32 0, i32 10
  %115 = load ptr, ptr %114, align 8, !tbaa !67
  %116 = load ptr, ptr %7, align 8, !tbaa !5
  %117 = getelementptr inbounds %struct.ma_device, ptr %116, i32 0, i32 4
  store ptr %115, ptr %117, align 8, !tbaa !68
  %118 = load ptr, ptr %6, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.ma_device_config, ptr %118, i32 0, i32 11
  %120 = load ptr, ptr %119, align 8, !tbaa !69
  %121 = load ptr, ptr %7, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct.ma_device, ptr %121, i32 0, i32 5
  store ptr %120, ptr %122, align 8, !tbaa !70
  %123 = load ptr, ptr %6, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.ma_device_config, ptr %123, i32 0, i32 12
  %125 = load ptr, ptr %124, align 8, !tbaa !71
  %126 = load ptr, ptr %7, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.ma_device, ptr %126, i32 0, i32 6
  store ptr %125, ptr %127, align 8, !tbaa !72
  %128 = load ptr, ptr %6, align 8, !tbaa !5
  %129 = getelementptr inbounds %struct.ma_device_config, ptr %128, i32 0, i32 15
  %130 = getelementptr inbounds %struct.anon.49, ptr %129, i32 0, i32 0
  %131 = load ptr, ptr %130, align 8, !tbaa !73
  %132 = icmp ne ptr %131, null
  br i1 %132, label %133, label %147

133:                                              ; preds = %104
  %134 = load ptr, ptr %7, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.ma_device, ptr %134, i32 0, i32 22
  %136 = getelementptr inbounds %struct.anon.26, ptr %135, i32 0, i32 1
  %137 = load ptr, ptr %6, align 8, !tbaa !5
  %138 = getelementptr inbounds %struct.ma_device_config, ptr %137, i32 0, i32 15
  %139 = getelementptr inbounds %struct.anon.49, ptr %138, i32 0, i32 0
  %140 = load ptr, ptr %139, align 8, !tbaa !73
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %136, ptr align 8 %140, i64 256, i1 false)
  %141 = load ptr, ptr %7, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.ma_device, ptr %141, i32 0, i32 22
  %143 = getelementptr inbounds %struct.anon.26, ptr %142, i32 0, i32 1
  %144 = load ptr, ptr %7, align 8, !tbaa !5
  %145 = getelementptr inbounds %struct.ma_device, ptr %144, i32 0, i32 22
  %146 = getelementptr inbounds %struct.anon.26, ptr %145, i32 0, i32 0
  store ptr %143, ptr %146, align 8, !tbaa !74
  br label %151

147:                                              ; preds = %104
  %148 = load ptr, ptr %7, align 8, !tbaa !5
  %149 = getelementptr inbounds %struct.ma_device, ptr %148, i32 0, i32 22
  %150 = getelementptr inbounds %struct.anon.26, ptr %149, i32 0, i32 0
  store ptr null, ptr %150, align 8, !tbaa !74
  br label %151

151:                                              ; preds = %147, %133
  %152 = load ptr, ptr %6, align 8, !tbaa !5
  %153 = getelementptr inbounds %struct.ma_device_config, ptr %152, i32 0, i32 16
  %154 = getelementptr inbounds %struct.anon.50, ptr %153, i32 0, i32 0
  %155 = load ptr, ptr %154, align 8, !tbaa !75
  %156 = icmp ne ptr %155, null
  br i1 %156, label %157, label %171

157:                                              ; preds = %151
  %158 = load ptr, ptr %7, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.ma_device, ptr %158, i32 0, i32 23
  %160 = getelementptr inbounds %struct.anon.31, ptr %159, i32 0, i32 1
  %161 = load ptr, ptr %6, align 8, !tbaa !5
  %162 = getelementptr inbounds %struct.ma_device_config, ptr %161, i32 0, i32 16
  %163 = getelementptr inbounds %struct.anon.50, ptr %162, i32 0, i32 0
  %164 = load ptr, ptr %163, align 8, !tbaa !75
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %160, ptr align 8 %164, i64 256, i1 false)
  %165 = load ptr, ptr %7, align 8, !tbaa !5
  %166 = getelementptr inbounds %struct.ma_device, ptr %165, i32 0, i32 23
  %167 = getelementptr inbounds %struct.anon.31, ptr %166, i32 0, i32 1
  %168 = load ptr, ptr %7, align 8, !tbaa !5
  %169 = getelementptr inbounds %struct.ma_device, ptr %168, i32 0, i32 23
  %170 = getelementptr inbounds %struct.anon.31, ptr %169, i32 0, i32 0
  store ptr %167, ptr %170, align 8, !tbaa !76
  br label %175

171:                                              ; preds = %151
  %172 = load ptr, ptr %7, align 8, !tbaa !5
  %173 = getelementptr inbounds %struct.ma_device, ptr %172, i32 0, i32 23
  %174 = getelementptr inbounds %struct.anon.31, ptr %173, i32 0, i32 0
  store ptr null, ptr %174, align 8, !tbaa !76
  br label %175

175:                                              ; preds = %171, %157
  %176 = load ptr, ptr %6, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.ma_device_config, ptr %176, i32 0, i32 6
  %178 = load i8, ptr %177, align 8, !tbaa !77
  %179 = load ptr, ptr %7, align 8, !tbaa !5
  %180 = getelementptr inbounds %struct.ma_device, ptr %179, i32 0, i32 15
  store i8 %178, ptr %180, align 1, !tbaa !78
  %181 = load ptr, ptr %6, align 8, !tbaa !5
  %182 = getelementptr inbounds %struct.ma_device_config, ptr %181, i32 0, i32 7
  %183 = load i8, ptr %182, align 1, !tbaa !79
  %184 = load ptr, ptr %7, align 8, !tbaa !5
  %185 = getelementptr inbounds %struct.ma_device, ptr %184, i32 0, i32 16
  store i8 %183, ptr %185, align 2, !tbaa !80
  %186 = load ptr, ptr %6, align 8, !tbaa !5
  %187 = getelementptr inbounds %struct.ma_device_config, ptr %186, i32 0, i32 8
  %188 = load i8, ptr %187, align 2, !tbaa !81
  %189 = load ptr, ptr %7, align 8, !tbaa !5
  %190 = getelementptr inbounds %struct.ma_device, ptr %189, i32 0, i32 17
  store i8 %188, ptr %190, align 1, !tbaa !82
  %191 = load ptr, ptr %6, align 8, !tbaa !5
  %192 = getelementptr inbounds %struct.ma_device_config, ptr %191, i32 0, i32 9
  %193 = load i8, ptr %192, align 1, !tbaa !83
  %194 = load ptr, ptr %7, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.ma_device, ptr %194, i32 0, i32 18
  store i8 %193, ptr %195, align 8, !tbaa !84
  %196 = load ptr, ptr %7, align 8, !tbaa !5
  %197 = getelementptr inbounds %struct.ma_device, ptr %196, i32 0, i32 19
  store float 1.000000e+00, ptr %197, align 4, !tbaa !85
  %198 = load ptr, ptr %6, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct.ma_device_config, ptr %198, i32 0, i32 0
  %200 = load i32, ptr %199, align 8, !tbaa !18
  %201 = load ptr, ptr %7, align 8, !tbaa !5
  %202 = getelementptr inbounds %struct.ma_device, ptr %201, i32 0, i32 1
  store i32 %200, ptr %202, align 8, !tbaa !86
  %203 = load ptr, ptr %6, align 8, !tbaa !5
  %204 = getelementptr inbounds %struct.ma_device_config, ptr %203, i32 0, i32 1
  %205 = load i32, ptr %204, align 4, !tbaa !87
  %206 = load ptr, ptr %7, align 8, !tbaa !5
  %207 = getelementptr inbounds %struct.ma_device, ptr %206, i32 0, i32 2
  store i32 %205, ptr %207, align 4, !tbaa !88
  %208 = load ptr, ptr %6, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.ma_device_config, ptr %208, i32 0, i32 14
  %210 = getelementptr inbounds %struct.ma_resampler_config, ptr %209, i32 0, i32 4
  %211 = load i32, ptr %210, align 8, !tbaa !89
  %212 = load ptr, ptr %7, align 8, !tbaa !5
  %213 = getelementptr inbounds %struct.ma_device, ptr %212, i32 0, i32 21
  %214 = getelementptr inbounds %struct.anon.24, ptr %213, i32 0, i32 0
  store i32 %211, ptr %214, align 8, !tbaa !90
  %215 = load ptr, ptr %6, align 8, !tbaa !5
  %216 = getelementptr inbounds %struct.ma_device_config, ptr %215, i32 0, i32 14
  %217 = getelementptr inbounds %struct.ma_resampler_config, ptr %216, i32 0, i32 7
  %218 = getelementptr inbounds %struct.anon.48, ptr %217, i32 0, i32 0
  %219 = load i32, ptr %218, align 8, !tbaa !91
  %220 = load ptr, ptr %7, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct.ma_device, ptr %220, i32 0, i32 21
  %222 = getelementptr inbounds %struct.anon.24, ptr %221, i32 0, i32 3
  %223 = getelementptr inbounds %struct.anon.25, ptr %222, i32 0, i32 0
  store i32 %219, ptr %223, align 8, !tbaa !92
  %224 = load ptr, ptr %6, align 8, !tbaa !5
  %225 = getelementptr inbounds %struct.ma_device_config, ptr %224, i32 0, i32 14
  %226 = getelementptr inbounds %struct.ma_resampler_config, ptr %225, i32 0, i32 5
  %227 = load ptr, ptr %226, align 8, !tbaa !93
  %228 = load ptr, ptr %7, align 8, !tbaa !5
  %229 = getelementptr inbounds %struct.ma_device, ptr %228, i32 0, i32 21
  %230 = getelementptr inbounds %struct.anon.24, ptr %229, i32 0, i32 1
  store ptr %227, ptr %230, align 8, !tbaa !94
  %231 = load ptr, ptr %6, align 8, !tbaa !5
  %232 = getelementptr inbounds %struct.ma_device_config, ptr %231, i32 0, i32 14
  %233 = getelementptr inbounds %struct.ma_resampler_config, ptr %232, i32 0, i32 6
  %234 = load ptr, ptr %233, align 8, !tbaa !95
  %235 = load ptr, ptr %7, align 8, !tbaa !5
  %236 = getelementptr inbounds %struct.ma_device, ptr %235, i32 0, i32 21
  %237 = getelementptr inbounds %struct.anon.24, ptr %236, i32 0, i32 2
  store ptr %234, ptr %237, align 8, !tbaa !96
  %238 = load ptr, ptr %6, align 8, !tbaa !5
  %239 = getelementptr inbounds %struct.ma_device_config, ptr %238, i32 0, i32 16
  %240 = getelementptr inbounds %struct.anon.50, ptr %239, i32 0, i32 5
  %241 = load i32, ptr %240, align 4, !tbaa !97
  %242 = load ptr, ptr %7, align 8, !tbaa !5
  %243 = getelementptr inbounds %struct.ma_device, ptr %242, i32 0, i32 23
  %244 = getelementptr inbounds %struct.anon.31, ptr %243, i32 0, i32 3
  store i32 %241, ptr %244, align 8, !tbaa !98
  %245 = load ptr, ptr %6, align 8, !tbaa !5
  %246 = getelementptr inbounds %struct.ma_device_config, ptr %245, i32 0, i32 16
  %247 = getelementptr inbounds %struct.anon.50, ptr %246, i32 0, i32 1
  %248 = load i32, ptr %247, align 8, !tbaa !99
  %249 = load ptr, ptr %7, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct.ma_device, ptr %249, i32 0, i32 23
  %251 = getelementptr inbounds %struct.anon.31, ptr %250, i32 0, i32 4
  store i32 %248, ptr %251, align 4, !tbaa !100
  %252 = load ptr, ptr %6, align 8, !tbaa !5
  %253 = getelementptr inbounds %struct.ma_device_config, ptr %252, i32 0, i32 16
  %254 = getelementptr inbounds %struct.anon.50, ptr %253, i32 0, i32 2
  %255 = load i32, ptr %254, align 4, !tbaa !41
  %256 = load ptr, ptr %7, align 8, !tbaa !5
  %257 = getelementptr inbounds %struct.ma_device, ptr %256, i32 0, i32 23
  %258 = getelementptr inbounds %struct.anon.31, ptr %257, i32 0, i32 5
  store i32 %255, ptr %258, align 8, !tbaa !101
  %259 = load ptr, ptr %7, align 8, !tbaa !5
  %260 = getelementptr inbounds %struct.ma_device, ptr %259, i32 0, i32 23
  %261 = getelementptr inbounds %struct.anon.31, ptr %260, i32 0, i32 6
  %262 = getelementptr inbounds [254 x i8], ptr %261, i64 0, i64 0
  %263 = load ptr, ptr %6, align 8, !tbaa !5
  %264 = getelementptr inbounds %struct.ma_device_config, ptr %263, i32 0, i32 16
  %265 = getelementptr inbounds %struct.anon.50, ptr %264, i32 0, i32 3
  %266 = load ptr, ptr %265, align 8, !tbaa !42
  %267 = load ptr, ptr %6, align 8, !tbaa !5
  %268 = getelementptr inbounds %struct.ma_device_config, ptr %267, i32 0, i32 16
  %269 = getelementptr inbounds %struct.anon.50, ptr %268, i32 0, i32 2
  %270 = load i32, ptr %269, align 4, !tbaa !41
  call void @ma_channel_map_copy_or_default(ptr noundef %262, i64 noundef 254, ptr noundef %266, i32 noundef %270)
  %271 = load ptr, ptr %6, align 8, !tbaa !5
  %272 = getelementptr inbounds %struct.ma_device_config, ptr %271, i32 0, i32 16
  %273 = getelementptr inbounds %struct.anon.50, ptr %272, i32 0, i32 4
  %274 = load i32, ptr %273, align 8, !tbaa !102
  %275 = load ptr, ptr %7, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.ma_device, ptr %275, i32 0, i32 23
  %277 = getelementptr inbounds %struct.anon.31, ptr %276, i32 0, i32 13
  store i32 %274, ptr %277, align 8, !tbaa !103
  %278 = load ptr, ptr %6, align 8, !tbaa !5
  %279 = getelementptr inbounds %struct.ma_device_config, ptr %278, i32 0, i32 15
  %280 = getelementptr inbounds %struct.anon.49, ptr %279, i32 0, i32 5
  %281 = load i32, ptr %280, align 4, !tbaa !104
  %282 = load ptr, ptr %7, align 8, !tbaa !5
  %283 = getelementptr inbounds %struct.ma_device, ptr %282, i32 0, i32 22
  %284 = getelementptr inbounds %struct.anon.26, ptr %283, i32 0, i32 3
  store i32 %281, ptr %284, align 8, !tbaa !105
  %285 = load ptr, ptr %6, align 8, !tbaa !5
  %286 = getelementptr inbounds %struct.ma_device_config, ptr %285, i32 0, i32 15
  %287 = getelementptr inbounds %struct.anon.49, ptr %286, i32 0, i32 1
  %288 = load i32, ptr %287, align 8, !tbaa !106
  %289 = load ptr, ptr %7, align 8, !tbaa !5
  %290 = getelementptr inbounds %struct.ma_device, ptr %289, i32 0, i32 22
  %291 = getelementptr inbounds %struct.anon.26, ptr %290, i32 0, i32 4
  store i32 %288, ptr %291, align 4, !tbaa !107
  %292 = load ptr, ptr %6, align 8, !tbaa !5
  %293 = getelementptr inbounds %struct.ma_device_config, ptr %292, i32 0, i32 15
  %294 = getelementptr inbounds %struct.anon.49, ptr %293, i32 0, i32 2
  %295 = load i32, ptr %294, align 4, !tbaa !43
  %296 = load ptr, ptr %7, align 8, !tbaa !5
  %297 = getelementptr inbounds %struct.ma_device, ptr %296, i32 0, i32 22
  %298 = getelementptr inbounds %struct.anon.26, ptr %297, i32 0, i32 5
  store i32 %295, ptr %298, align 8, !tbaa !108
  %299 = load ptr, ptr %7, align 8, !tbaa !5
  %300 = getelementptr inbounds %struct.ma_device, ptr %299, i32 0, i32 22
  %301 = getelementptr inbounds %struct.anon.26, ptr %300, i32 0, i32 6
  %302 = getelementptr inbounds [254 x i8], ptr %301, i64 0, i64 0
  %303 = load ptr, ptr %6, align 8, !tbaa !5
  %304 = getelementptr inbounds %struct.ma_device_config, ptr %303, i32 0, i32 15
  %305 = getelementptr inbounds %struct.anon.49, ptr %304, i32 0, i32 3
  %306 = load ptr, ptr %305, align 8, !tbaa !44
  %307 = load ptr, ptr %6, align 8, !tbaa !5
  %308 = getelementptr inbounds %struct.ma_device_config, ptr %307, i32 0, i32 15
  %309 = getelementptr inbounds %struct.anon.49, ptr %308, i32 0, i32 2
  %310 = load i32, ptr %309, align 4, !tbaa !43
  call void @ma_channel_map_copy_or_default(ptr noundef %302, i64 noundef 254, ptr noundef %306, i32 noundef %310)
  %311 = load ptr, ptr %6, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.ma_device_config, ptr %311, i32 0, i32 15
  %313 = getelementptr inbounds %struct.anon.49, ptr %312, i32 0, i32 4
  %314 = load i32, ptr %313, align 8, !tbaa !109
  %315 = load ptr, ptr %7, align 8, !tbaa !5
  %316 = getelementptr inbounds %struct.ma_device, ptr %315, i32 0, i32 22
  %317 = getelementptr inbounds %struct.anon.26, ptr %316, i32 0, i32 13
  store i32 %314, ptr %317, align 8, !tbaa !110
  %318 = load ptr, ptr %7, align 8, !tbaa !5
  %319 = getelementptr inbounds %struct.ma_device, ptr %318, i32 0, i32 8
  %320 = call i32 @ma_mutex_init(ptr noundef %319)
  store i32 %320, ptr %8, align 4, !tbaa !111
  %321 = load i32, ptr %8, align 4, !tbaa !111
  %322 = icmp ne i32 %321, 0
  br i1 %322, label %323, label %325

323:                                              ; preds = %175
  %324 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %324, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

325:                                              ; preds = %175
  %326 = load ptr, ptr %7, align 8, !tbaa !5
  %327 = getelementptr inbounds %struct.ma_device, ptr %326, i32 0, i32 9
  %328 = call i32 @ma_event_init(ptr noundef %327)
  store i32 %328, ptr %8, align 4, !tbaa !111
  %329 = load i32, ptr %8, align 4, !tbaa !111
  %330 = icmp ne i32 %329, 0
  br i1 %330, label %331, label %335

331:                                              ; preds = %325
  %332 = load ptr, ptr %7, align 8, !tbaa !5
  %333 = getelementptr inbounds %struct.ma_device, ptr %332, i32 0, i32 8
  call void @ma_mutex_uninit(ptr noundef %333)
  %334 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %334, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

335:                                              ; preds = %325
  %336 = load ptr, ptr %7, align 8, !tbaa !5
  %337 = getelementptr inbounds %struct.ma_device, ptr %336, i32 0, i32 10
  %338 = call i32 @ma_event_init(ptr noundef %337)
  store i32 %338, ptr %8, align 4, !tbaa !111
  %339 = load i32, ptr %8, align 4, !tbaa !111
  %340 = icmp ne i32 %339, 0
  br i1 %340, label %341, label %347

341:                                              ; preds = %335
  %342 = load ptr, ptr %7, align 8, !tbaa !5
  %343 = getelementptr inbounds %struct.ma_device, ptr %342, i32 0, i32 9
  call void @ma_event_uninit(ptr noundef %343)
  %344 = load ptr, ptr %7, align 8, !tbaa !5
  %345 = getelementptr inbounds %struct.ma_device, ptr %344, i32 0, i32 8
  call void @ma_mutex_uninit(ptr noundef %345)
  %346 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %346, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

347:                                              ; preds = %335
  %348 = load ptr, ptr %7, align 8, !tbaa !5
  %349 = getelementptr inbounds %struct.ma_device, ptr %348, i32 0, i32 11
  %350 = call i32 @ma_event_init(ptr noundef %349)
  store i32 %350, ptr %8, align 4, !tbaa !111
  %351 = load i32, ptr %8, align 4, !tbaa !111
  %352 = icmp ne i32 %351, 0
  br i1 %352, label %353, label %361

353:                                              ; preds = %347
  %354 = load ptr, ptr %7, align 8, !tbaa !5
  %355 = getelementptr inbounds %struct.ma_device, ptr %354, i32 0, i32 10
  call void @ma_event_uninit(ptr noundef %355)
  %356 = load ptr, ptr %7, align 8, !tbaa !5
  %357 = getelementptr inbounds %struct.ma_device, ptr %356, i32 0, i32 9
  call void @ma_event_uninit(ptr noundef %357)
  %358 = load ptr, ptr %7, align 8, !tbaa !5
  %359 = getelementptr inbounds %struct.ma_device, ptr %358, i32 0, i32 8
  call void @ma_mutex_uninit(ptr noundef %359)
  %360 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %360, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

361:                                              ; preds = %347
  call void @llvm.memset.p0.i64(ptr align 8 %9, i8 0, i64 296, i1 false)
  %362 = load ptr, ptr %6, align 8, !tbaa !5
  %363 = getelementptr inbounds %struct.ma_device_config, ptr %362, i32 0, i32 15
  %364 = getelementptr inbounds %struct.anon.49, ptr %363, i32 0, i32 0
  %365 = load ptr, ptr %364, align 8, !tbaa !73
  %366 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 0
  store ptr %365, ptr %366, align 8, !tbaa !112
  %367 = load ptr, ptr %6, align 8, !tbaa !5
  %368 = getelementptr inbounds %struct.ma_device_config, ptr %367, i32 0, i32 15
  %369 = getelementptr inbounds %struct.anon.49, ptr %368, i32 0, i32 5
  %370 = load i32, ptr %369, align 4, !tbaa !104
  %371 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 1
  store i32 %370, ptr %371, align 8, !tbaa !114
  %372 = load ptr, ptr %6, align 8, !tbaa !5
  %373 = getelementptr inbounds %struct.ma_device_config, ptr %372, i32 0, i32 15
  %374 = getelementptr inbounds %struct.anon.49, ptr %373, i32 0, i32 1
  %375 = load i32, ptr %374, align 8, !tbaa !106
  %376 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 2
  store i32 %375, ptr %376, align 4, !tbaa !115
  %377 = load ptr, ptr %6, align 8, !tbaa !5
  %378 = getelementptr inbounds %struct.ma_device_config, ptr %377, i32 0, i32 15
  %379 = getelementptr inbounds %struct.anon.49, ptr %378, i32 0, i32 2
  %380 = load i32, ptr %379, align 4, !tbaa !43
  %381 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 3
  store i32 %380, ptr %381, align 8, !tbaa !116
  %382 = load ptr, ptr %6, align 8, !tbaa !5
  %383 = getelementptr inbounds %struct.ma_device_config, ptr %382, i32 0, i32 1
  %384 = load i32, ptr %383, align 4, !tbaa !87
  %385 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 4
  store i32 %384, ptr %385, align 4, !tbaa !117
  %386 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 5
  %387 = getelementptr inbounds [254 x i8], ptr %386, i64 0, i64 0
  %388 = load ptr, ptr %6, align 8, !tbaa !5
  %389 = getelementptr inbounds %struct.ma_device_config, ptr %388, i32 0, i32 15
  %390 = getelementptr inbounds %struct.anon.49, ptr %389, i32 0, i32 3
  %391 = load ptr, ptr %390, align 8, !tbaa !44
  %392 = load ptr, ptr %6, align 8, !tbaa !5
  %393 = getelementptr inbounds %struct.ma_device_config, ptr %392, i32 0, i32 15
  %394 = getelementptr inbounds %struct.anon.49, ptr %393, i32 0, i32 2
  %395 = load i32, ptr %394, align 4, !tbaa !43
  call void @ma_channel_map_copy_or_default(ptr noundef %387, i64 noundef 254, ptr noundef %391, i32 noundef %395)
  %396 = load ptr, ptr %6, align 8, !tbaa !5
  %397 = getelementptr inbounds %struct.ma_device_config, ptr %396, i32 0, i32 2
  %398 = load i32, ptr %397, align 8, !tbaa !118
  %399 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 6
  store i32 %398, ptr %399, align 8, !tbaa !119
  %400 = load ptr, ptr %6, align 8, !tbaa !5
  %401 = getelementptr inbounds %struct.ma_device_config, ptr %400, i32 0, i32 3
  %402 = load i32, ptr %401, align 4, !tbaa !120
  %403 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 7
  store i32 %402, ptr %403, align 4, !tbaa !121
  %404 = load ptr, ptr %6, align 8, !tbaa !5
  %405 = getelementptr inbounds %struct.ma_device_config, ptr %404, i32 0, i32 4
  %406 = load i32, ptr %405, align 8, !tbaa !122
  %407 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 8
  store i32 %406, ptr %407, align 8, !tbaa !123
  %408 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 8
  %409 = load i32, ptr %408, align 8, !tbaa !123
  %410 = icmp eq i32 %409, 0
  br i1 %410, label %411, label %413

411:                                              ; preds = %361
  %412 = getelementptr inbounds %struct.ma_device_descriptor, ptr %9, i32 0, i32 8
  store i32 3, ptr %412, align 8, !tbaa !123
  br label %413

413:                                              ; preds = %411, %361
  call void @llvm.memset.p0.i64(ptr align 8 %10, i8 0, i64 296, i1 false)
  %414 = load ptr, ptr %6, align 8, !tbaa !5
  %415 = getelementptr inbounds %struct.ma_device_config, ptr %414, i32 0, i32 16
  %416 = getelementptr inbounds %struct.anon.50, ptr %415, i32 0, i32 0
  %417 = load ptr, ptr %416, align 8, !tbaa !75
  %418 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 0
  store ptr %417, ptr %418, align 8, !tbaa !112
  %419 = load ptr, ptr %6, align 8, !tbaa !5
  %420 = getelementptr inbounds %struct.ma_device_config, ptr %419, i32 0, i32 16
  %421 = getelementptr inbounds %struct.anon.50, ptr %420, i32 0, i32 5
  %422 = load i32, ptr %421, align 4, !tbaa !97
  %423 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 1
  store i32 %422, ptr %423, align 8, !tbaa !114
  %424 = load ptr, ptr %6, align 8, !tbaa !5
  %425 = getelementptr inbounds %struct.ma_device_config, ptr %424, i32 0, i32 16
  %426 = getelementptr inbounds %struct.anon.50, ptr %425, i32 0, i32 1
  %427 = load i32, ptr %426, align 8, !tbaa !99
  %428 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 2
  store i32 %427, ptr %428, align 4, !tbaa !115
  %429 = load ptr, ptr %6, align 8, !tbaa !5
  %430 = getelementptr inbounds %struct.ma_device_config, ptr %429, i32 0, i32 16
  %431 = getelementptr inbounds %struct.anon.50, ptr %430, i32 0, i32 2
  %432 = load i32, ptr %431, align 4, !tbaa !41
  %433 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 3
  store i32 %432, ptr %433, align 8, !tbaa !116
  %434 = load ptr, ptr %6, align 8, !tbaa !5
  %435 = getelementptr inbounds %struct.ma_device_config, ptr %434, i32 0, i32 1
  %436 = load i32, ptr %435, align 4, !tbaa !87
  %437 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 4
  store i32 %436, ptr %437, align 4, !tbaa !117
  %438 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 5
  %439 = getelementptr inbounds [254 x i8], ptr %438, i64 0, i64 0
  %440 = load ptr, ptr %6, align 8, !tbaa !5
  %441 = getelementptr inbounds %struct.ma_device_config, ptr %440, i32 0, i32 16
  %442 = getelementptr inbounds %struct.anon.50, ptr %441, i32 0, i32 3
  %443 = load ptr, ptr %442, align 8, !tbaa !42
  %444 = load ptr, ptr %6, align 8, !tbaa !5
  %445 = getelementptr inbounds %struct.ma_device_config, ptr %444, i32 0, i32 16
  %446 = getelementptr inbounds %struct.anon.50, ptr %445, i32 0, i32 2
  %447 = load i32, ptr %446, align 4, !tbaa !41
  call void @ma_channel_map_copy_or_default(ptr noundef %439, i64 noundef 254, ptr noundef %443, i32 noundef %447)
  %448 = load ptr, ptr %6, align 8, !tbaa !5
  %449 = getelementptr inbounds %struct.ma_device_config, ptr %448, i32 0, i32 2
  %450 = load i32, ptr %449, align 8, !tbaa !118
  %451 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 6
  store i32 %450, ptr %451, align 8, !tbaa !119
  %452 = load ptr, ptr %6, align 8, !tbaa !5
  %453 = getelementptr inbounds %struct.ma_device_config, ptr %452, i32 0, i32 3
  %454 = load i32, ptr %453, align 4, !tbaa !120
  %455 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 7
  store i32 %454, ptr %455, align 4, !tbaa !121
  %456 = load ptr, ptr %6, align 8, !tbaa !5
  %457 = getelementptr inbounds %struct.ma_device_config, ptr %456, i32 0, i32 4
  %458 = load i32, ptr %457, align 8, !tbaa !122
  %459 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 8
  store i32 %458, ptr %459, align 8, !tbaa !123
  %460 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 8
  %461 = load i32, ptr %460, align 8, !tbaa !123
  %462 = icmp eq i32 %461, 0
  br i1 %462, label %463, label %465

463:                                              ; preds = %413
  %464 = getelementptr inbounds %struct.ma_device_descriptor, ptr %10, i32 0, i32 8
  store i32 3, ptr %464, align 8, !tbaa !123
  br label %465

465:                                              ; preds = %463, %413
  %466 = load ptr, ptr %5, align 8, !tbaa !5
  %467 = getelementptr inbounds %struct.ma_context, ptr %466, i32 0, i32 0
  %468 = getelementptr inbounds %struct.ma_backend_callbacks, ptr %467, i32 0, i32 4
  %469 = load ptr, ptr %468, align 8, !tbaa !9
  %470 = load ptr, ptr %7, align 8, !tbaa !5
  %471 = load ptr, ptr %6, align 8, !tbaa !5
  %472 = call noundef i32 %469(ptr noundef %470, ptr noundef %471, ptr noundef %9, ptr noundef %10)
  store i32 %472, ptr %8, align 4, !tbaa !111
  %473 = load i32, ptr %8, align 4, !tbaa !111
  %474 = icmp ne i32 %473, 0
  br i1 %474, label %475, label %483

475:                                              ; preds = %465
  %476 = load ptr, ptr %7, align 8, !tbaa !5
  %477 = getelementptr inbounds %struct.ma_device, ptr %476, i32 0, i32 10
  call void @ma_event_uninit(ptr noundef %477)
  %478 = load ptr, ptr %7, align 8, !tbaa !5
  %479 = getelementptr inbounds %struct.ma_device, ptr %478, i32 0, i32 9
  call void @ma_event_uninit(ptr noundef %479)
  %480 = load ptr, ptr %7, align 8, !tbaa !5
  %481 = getelementptr inbounds %struct.ma_device, ptr %480, i32 0, i32 8
  call void @ma_mutex_uninit(ptr noundef %481)
  %482 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %482, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

483:                                              ; preds = %465
  %484 = load ptr, ptr %7, align 8, !tbaa !5
  %485 = load ptr, ptr %6, align 8, !tbaa !5
  %486 = getelementptr inbounds %struct.ma_device_config, ptr %485, i32 0, i32 0
  %487 = load i32, ptr %486, align 8, !tbaa !18
  %488 = call i32 @ma_device_post_init(ptr noundef %484, i32 noundef %487, ptr noundef %9, ptr noundef %10)
  store i32 %488, ptr %8, align 4, !tbaa !111
  %489 = load i32, ptr %8, align 4, !tbaa !111
  %490 = icmp ne i32 %489, 0
  br i1 %490, label %491, label %494

491:                                              ; preds = %483
  %492 = load ptr, ptr %7, align 8, !tbaa !5
  call void @ma_device_uninit(ptr noundef %492)
  %493 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %493, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

494:                                              ; preds = %483
  %495 = load ptr, ptr %6, align 8, !tbaa !5
  %496 = getelementptr inbounds %struct.ma_device_config, ptr %495, i32 0, i32 9
  %497 = load i8, ptr %496, align 1, !tbaa !83
  %498 = zext i8 %497 to i32
  %499 = icmp eq i32 %498, 0
  br i1 %499, label %500, label %711

500:                                              ; preds = %494
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #7
  %501 = load ptr, ptr %6, align 8, !tbaa !5
  %502 = getelementptr inbounds %struct.ma_device_config, ptr %501, i32 0, i32 2
  %503 = load i32, ptr %502, align 8, !tbaa !118
  store i32 %503, ptr %12, align 4, !tbaa !124
  %504 = load i32, ptr %12, align 4, !tbaa !124
  %505 = icmp eq i32 %504, 0
  br i1 %505, label %506, label %514

506:                                              ; preds = %500
  %507 = load ptr, ptr %6, align 8, !tbaa !5
  %508 = getelementptr inbounds %struct.ma_device_config, ptr %507, i32 0, i32 3
  %509 = load i32, ptr %508, align 4, !tbaa !120
  %510 = load ptr, ptr %7, align 8, !tbaa !5
  %511 = getelementptr inbounds %struct.ma_device, ptr %510, i32 0, i32 2
  %512 = load i32, ptr %511, align 4, !tbaa !88
  %513 = call i32 @ma_calculate_buffer_size_in_frames_from_milliseconds(i32 noundef %509, i32 noundef %512)
  store i32 %513, ptr %12, align 4, !tbaa !124
  br label %514

514:                                              ; preds = %506, %500
  %515 = load ptr, ptr %6, align 8, !tbaa !5
  %516 = getelementptr inbounds %struct.ma_device_config, ptr %515, i32 0, i32 0
  %517 = load i32, ptr %516, align 8, !tbaa !18
  %518 = icmp eq i32 %517, 2
  br i1 %518, label %529, label %519

519:                                              ; preds = %514
  %520 = load ptr, ptr %6, align 8, !tbaa !5
  %521 = getelementptr inbounds %struct.ma_device_config, ptr %520, i32 0, i32 0
  %522 = load i32, ptr %521, align 8, !tbaa !18
  %523 = icmp eq i32 %522, 3
  br i1 %523, label %529, label %524

524:                                              ; preds = %519
  %525 = load ptr, ptr %6, align 8, !tbaa !5
  %526 = getelementptr inbounds %struct.ma_device_config, ptr %525, i32 0, i32 0
  %527 = load i32, ptr %526, align 8, !tbaa !18
  %528 = icmp eq i32 %527, 4
  br i1 %528, label %529, label %608

529:                                              ; preds = %524, %519, %514
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #7
  %530 = load ptr, ptr %7, align 8, !tbaa !5
  %531 = getelementptr inbounds %struct.ma_device, ptr %530, i32 0, i32 23
  %532 = getelementptr inbounds %struct.anon.31, ptr %531, i32 0, i32 17
  store i32 0, ptr %532, align 4, !tbaa !125
  %533 = load i32, ptr %12, align 4, !tbaa !124
  %534 = load ptr, ptr %7, align 8, !tbaa !5
  %535 = getelementptr inbounds %struct.ma_device, ptr %534, i32 0, i32 23
  %536 = getelementptr inbounds %struct.anon.31, ptr %535, i32 0, i32 16
  store i32 %533, ptr %536, align 8, !tbaa !126
  %537 = load ptr, ptr %7, align 8, !tbaa !5
  %538 = getelementptr inbounds %struct.ma_device, ptr %537, i32 0, i32 23
  %539 = getelementptr inbounds %struct.anon.31, ptr %538, i32 0, i32 16
  %540 = load i32, ptr %539, align 8, !tbaa !126
  %541 = icmp eq i32 %540, 0
  br i1 %541, label %542, label %550

542:                                              ; preds = %529
  %543 = load ptr, ptr %7, align 8, !tbaa !5
  %544 = getelementptr inbounds %struct.ma_device, ptr %543, i32 0, i32 23
  %545 = getelementptr inbounds %struct.anon.31, ptr %544, i32 0, i32 11
  %546 = load i32, ptr %545, align 8, !tbaa !127
  %547 = load ptr, ptr %7, align 8, !tbaa !5
  %548 = getelementptr inbounds %struct.ma_device, ptr %547, i32 0, i32 23
  %549 = getelementptr inbounds %struct.anon.31, ptr %548, i32 0, i32 16
  store i32 %546, ptr %549, align 8, !tbaa !126
  br label %550

550:                                              ; preds = %542, %529
  %551 = load ptr, ptr %7, align 8, !tbaa !5
  %552 = getelementptr inbounds %struct.ma_device, ptr %551, i32 0, i32 23
  %553 = getelementptr inbounds %struct.anon.31, ptr %552, i32 0, i32 16
  %554 = load i32, ptr %553, align 8, !tbaa !126
  %555 = load ptr, ptr %7, align 8, !tbaa !5
  %556 = getelementptr inbounds %struct.ma_device, ptr %555, i32 0, i32 23
  %557 = getelementptr inbounds %struct.anon.31, ptr %556, i32 0, i32 4
  %558 = load i32, ptr %557, align 4, !tbaa !100
  %559 = load ptr, ptr %7, align 8, !tbaa !5
  %560 = getelementptr inbounds %struct.ma_device, ptr %559, i32 0, i32 23
  %561 = getelementptr inbounds %struct.anon.31, ptr %560, i32 0, i32 5
  %562 = load i32, ptr %561, align 8, !tbaa !101
  %563 = call noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef %558, i32 noundef %562)
  %564 = mul i32 %554, %563
  store i32 %564, ptr %13, align 4, !tbaa !124
  %565 = load i32, ptr %13, align 4, !tbaa !124
  %566 = zext i32 %565 to i64
  %567 = load ptr, ptr %5, align 8, !tbaa !5
  %568 = getelementptr inbounds %struct.ma_context, ptr %567, i32 0, i32 7
  %569 = call ptr @ma_malloc(i64 noundef %566, ptr noundef %568)
  %570 = load ptr, ptr %7, align 8, !tbaa !5
  %571 = getelementptr inbounds %struct.ma_device, ptr %570, i32 0, i32 23
  %572 = getelementptr inbounds %struct.anon.31, ptr %571, i32 0, i32 15
  store ptr %569, ptr %572, align 8, !tbaa !128
  %573 = load ptr, ptr %7, align 8, !tbaa !5
  %574 = getelementptr inbounds %struct.ma_device, ptr %573, i32 0, i32 23
  %575 = getelementptr inbounds %struct.anon.31, ptr %574, i32 0, i32 15
  %576 = load ptr, ptr %575, align 8, !tbaa !128
  %577 = icmp eq ptr %576, null
  br i1 %577, label %578, label %580

578:                                              ; preds = %550
  %579 = load ptr, ptr %7, align 8, !tbaa !5
  call void @ma_device_uninit(ptr noundef %579)
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %605

580:                                              ; preds = %550
  %581 = load ptr, ptr %7, align 8, !tbaa !5
  %582 = getelementptr inbounds %struct.ma_device, ptr %581, i32 0, i32 23
  %583 = getelementptr inbounds %struct.anon.31, ptr %582, i32 0, i32 15
  %584 = load ptr, ptr %583, align 8, !tbaa !128
  %585 = load ptr, ptr %7, align 8, !tbaa !5
  %586 = getelementptr inbounds %struct.ma_device, ptr %585, i32 0, i32 23
  %587 = getelementptr inbounds %struct.anon.31, ptr %586, i32 0, i32 16
  %588 = load i32, ptr %587, align 8, !tbaa !126
  %589 = zext i32 %588 to i64
  %590 = load ptr, ptr %7, align 8, !tbaa !5
  %591 = getelementptr inbounds %struct.ma_device, ptr %590, i32 0, i32 23
  %592 = getelementptr inbounds %struct.anon.31, ptr %591, i32 0, i32 4
  %593 = load i32, ptr %592, align 4, !tbaa !100
  %594 = load ptr, ptr %7, align 8, !tbaa !5
  %595 = getelementptr inbounds %struct.ma_device, ptr %594, i32 0, i32 23
  %596 = getelementptr inbounds %struct.anon.31, ptr %595, i32 0, i32 5
  %597 = load i32, ptr %596, align 8, !tbaa !101
  call void @ma_silence_pcm_frames(ptr noundef %584, i64 noundef %589, i32 noundef %593, i32 noundef %597)
  %598 = load ptr, ptr %7, align 8, !tbaa !5
  %599 = getelementptr inbounds %struct.ma_device, ptr %598, i32 0, i32 23
  %600 = getelementptr inbounds %struct.anon.31, ptr %599, i32 0, i32 16
  %601 = load i32, ptr %600, align 8, !tbaa !126
  %602 = load ptr, ptr %7, align 8, !tbaa !5
  %603 = getelementptr inbounds %struct.ma_device, ptr %602, i32 0, i32 23
  %604 = getelementptr inbounds %struct.anon.31, ptr %603, i32 0, i32 17
  store i32 %601, ptr %604, align 4, !tbaa !125
  store i32 0, ptr %11, align 4
  br label %605

605:                                              ; preds = %580, %578
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #7
  %606 = load i32, ptr %11, align 4
  switch i32 %606, label %708 [
    i32 0, label %607
  ]

607:                                              ; preds = %605
  br label %608

608:                                              ; preds = %607, %524
  %609 = load ptr, ptr %6, align 8, !tbaa !5
  %610 = getelementptr inbounds %struct.ma_device_config, ptr %609, i32 0, i32 0
  %611 = load i32, ptr %610, align 8, !tbaa !18
  %612 = icmp eq i32 %611, 1
  br i1 %612, label %618, label %613

613:                                              ; preds = %608
  %614 = load ptr, ptr %6, align 8, !tbaa !5
  %615 = getelementptr inbounds %struct.ma_device_config, ptr %614, i32 0, i32 0
  %616 = load i32, ptr %615, align 8, !tbaa !18
  %617 = icmp eq i32 %616, 3
  br i1 %617, label %618, label %707

618:                                              ; preds = %613, %608
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  %619 = load ptr, ptr %7, align 8, !tbaa !5
  %620 = getelementptr inbounds %struct.ma_device, ptr %619, i32 0, i32 22
  %621 = getelementptr inbounds %struct.anon.26, ptr %620, i32 0, i32 17
  store i32 0, ptr %621, align 4, !tbaa !129
  %622 = load ptr, ptr %6, align 8, !tbaa !5
  %623 = getelementptr inbounds %struct.ma_device_config, ptr %622, i32 0, i32 0
  %624 = load i32, ptr %623, align 8, !tbaa !18
  %625 = icmp eq i32 %624, 3
  br i1 %625, label %626, label %634

626:                                              ; preds = %618
  %627 = load ptr, ptr %7, align 8, !tbaa !5
  %628 = getelementptr inbounds %struct.ma_device, ptr %627, i32 0, i32 23
  %629 = getelementptr inbounds %struct.anon.31, ptr %628, i32 0, i32 16
  %630 = load i32, ptr %629, align 8, !tbaa !126
  %631 = load ptr, ptr %7, align 8, !tbaa !5
  %632 = getelementptr inbounds %struct.ma_device, ptr %631, i32 0, i32 22
  %633 = getelementptr inbounds %struct.anon.26, ptr %632, i32 0, i32 16
  store i32 %630, ptr %633, align 8, !tbaa !130
  br label %653

634:                                              ; preds = %618
  %635 = load i32, ptr %12, align 4, !tbaa !124
  %636 = load ptr, ptr %7, align 8, !tbaa !5
  %637 = getelementptr inbounds %struct.ma_device, ptr %636, i32 0, i32 22
  %638 = getelementptr inbounds %struct.anon.26, ptr %637, i32 0, i32 16
  store i32 %635, ptr %638, align 8, !tbaa !130
  %639 = load ptr, ptr %7, align 8, !tbaa !5
  %640 = getelementptr inbounds %struct.ma_device, ptr %639, i32 0, i32 22
  %641 = getelementptr inbounds %struct.anon.26, ptr %640, i32 0, i32 16
  %642 = load i32, ptr %641, align 8, !tbaa !130
  %643 = icmp eq i32 %642, 0
  br i1 %643, label %644, label %652

644:                                              ; preds = %634
  %645 = load ptr, ptr %7, align 8, !tbaa !5
  %646 = getelementptr inbounds %struct.ma_device, ptr %645, i32 0, i32 22
  %647 = getelementptr inbounds %struct.anon.26, ptr %646, i32 0, i32 11
  %648 = load i32, ptr %647, align 8, !tbaa !131
  %649 = load ptr, ptr %7, align 8, !tbaa !5
  %650 = getelementptr inbounds %struct.ma_device, ptr %649, i32 0, i32 22
  %651 = getelementptr inbounds %struct.anon.26, ptr %650, i32 0, i32 16
  store i32 %648, ptr %651, align 8, !tbaa !130
  br label %652

652:                                              ; preds = %644, %634
  br label %653

653:                                              ; preds = %652, %626
  %654 = load ptr, ptr %7, align 8, !tbaa !5
  %655 = getelementptr inbounds %struct.ma_device, ptr %654, i32 0, i32 22
  %656 = getelementptr inbounds %struct.anon.26, ptr %655, i32 0, i32 16
  %657 = load i32, ptr %656, align 8, !tbaa !130
  %658 = load ptr, ptr %7, align 8, !tbaa !5
  %659 = getelementptr inbounds %struct.ma_device, ptr %658, i32 0, i32 22
  %660 = getelementptr inbounds %struct.anon.26, ptr %659, i32 0, i32 4
  %661 = load i32, ptr %660, align 4, !tbaa !107
  %662 = load ptr, ptr %7, align 8, !tbaa !5
  %663 = getelementptr inbounds %struct.ma_device, ptr %662, i32 0, i32 22
  %664 = getelementptr inbounds %struct.anon.26, ptr %663, i32 0, i32 5
  %665 = load i32, ptr %664, align 8, !tbaa !108
  %666 = call noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef %661, i32 noundef %665)
  %667 = mul i32 %657, %666
  %668 = zext i32 %667 to i64
  store i64 %668, ptr %14, align 8, !tbaa !132
  %669 = load i64, ptr %14, align 8, !tbaa !132
  %670 = load ptr, ptr %5, align 8, !tbaa !5
  %671 = getelementptr inbounds %struct.ma_context, ptr %670, i32 0, i32 7
  %672 = call ptr @ma_malloc(i64 noundef %669, ptr noundef %671)
  %673 = load ptr, ptr %7, align 8, !tbaa !5
  %674 = getelementptr inbounds %struct.ma_device, ptr %673, i32 0, i32 22
  %675 = getelementptr inbounds %struct.anon.26, ptr %674, i32 0, i32 15
  store ptr %672, ptr %675, align 8, !tbaa !133
  %676 = load ptr, ptr %7, align 8, !tbaa !5
  %677 = getelementptr inbounds %struct.ma_device, ptr %676, i32 0, i32 22
  %678 = getelementptr inbounds %struct.anon.26, ptr %677, i32 0, i32 15
  %679 = load ptr, ptr %678, align 8, !tbaa !133
  %680 = icmp eq ptr %679, null
  br i1 %680, label %681, label %683

681:                                              ; preds = %653
  %682 = load ptr, ptr %7, align 8, !tbaa !5
  call void @ma_device_uninit(ptr noundef %682)
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %704

683:                                              ; preds = %653
  %684 = load ptr, ptr %7, align 8, !tbaa !5
  %685 = getelementptr inbounds %struct.ma_device, ptr %684, i32 0, i32 22
  %686 = getelementptr inbounds %struct.anon.26, ptr %685, i32 0, i32 15
  %687 = load ptr, ptr %686, align 8, !tbaa !133
  %688 = load ptr, ptr %7, align 8, !tbaa !5
  %689 = getelementptr inbounds %struct.ma_device, ptr %688, i32 0, i32 22
  %690 = getelementptr inbounds %struct.anon.26, ptr %689, i32 0, i32 16
  %691 = load i32, ptr %690, align 8, !tbaa !130
  %692 = zext i32 %691 to i64
  %693 = load ptr, ptr %7, align 8, !tbaa !5
  %694 = getelementptr inbounds %struct.ma_device, ptr %693, i32 0, i32 22
  %695 = getelementptr inbounds %struct.anon.26, ptr %694, i32 0, i32 4
  %696 = load i32, ptr %695, align 4, !tbaa !107
  %697 = load ptr, ptr %7, align 8, !tbaa !5
  %698 = getelementptr inbounds %struct.ma_device, ptr %697, i32 0, i32 22
  %699 = getelementptr inbounds %struct.anon.26, ptr %698, i32 0, i32 5
  %700 = load i32, ptr %699, align 8, !tbaa !108
  call void @ma_silence_pcm_frames(ptr noundef %687, i64 noundef %692, i32 noundef %696, i32 noundef %700)
  %701 = load ptr, ptr %7, align 8, !tbaa !5
  %702 = getelementptr inbounds %struct.ma_device, ptr %701, i32 0, i32 22
  %703 = getelementptr inbounds %struct.anon.26, ptr %702, i32 0, i32 17
  store i32 0, ptr %703, align 4, !tbaa !129
  store i32 0, ptr %11, align 4
  br label %704

704:                                              ; preds = %683, %681
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  %705 = load i32, ptr %11, align 4
  switch i32 %705, label %708 [
    i32 0, label %706
  ]

706:                                              ; preds = %704
  br label %707

707:                                              ; preds = %706, %613
  store i32 0, ptr %11, align 4
  br label %708

708:                                              ; preds = %707, %704, %605
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #7
  %709 = load i32, ptr %11, align 4
  switch i32 %709, label %1067 [
    i32 0, label %710
  ]

710:                                              ; preds = %708
  br label %712

711:                                              ; preds = %494
  br label %712

712:                                              ; preds = %711, %710
  %713 = load ptr, ptr %5, align 8, !tbaa !5
  %714 = call noundef i32 @_ZL34ma_context_is_backend_asynchronousP10ma_context(ptr noundef %713)
  %715 = icmp ne i32 %714, 0
  br i1 %715, label %745, label %716

716:                                              ; preds = %712
  %717 = load ptr, ptr %7, align 8, !tbaa !5
  %718 = getelementptr inbounds %struct.ma_device, ptr %717, i32 0, i32 12
  %719 = load ptr, ptr %5, align 8, !tbaa !5
  %720 = getelementptr inbounds %struct.ma_context, ptr %719, i32 0, i32 4
  %721 = load i32, ptr %720, align 8, !tbaa !134
  %722 = load ptr, ptr %5, align 8, !tbaa !5
  %723 = getelementptr inbounds %struct.ma_context, ptr %722, i32 0, i32 5
  %724 = load i64, ptr %723, align 8, !tbaa !135
  %725 = load ptr, ptr %7, align 8, !tbaa !5
  %726 = load ptr, ptr %5, align 8, !tbaa !5
  %727 = getelementptr inbounds %struct.ma_context, ptr %726, i32 0, i32 7
  %728 = call noundef i32 @_ZL16ma_thread_createPm18ma_thread_prioritymPFPvS1_ES1_PK23ma_allocation_callbacks(ptr noundef %718, i32 noundef %721, i64 noundef %724, ptr noundef @_ZL16ma_worker_threadPv, ptr noundef %725, ptr noundef %727)
  store i32 %728, ptr %8, align 4, !tbaa !111
  %729 = load i32, ptr %8, align 4, !tbaa !111
  %730 = icmp ne i32 %729, 0
  br i1 %730, label %731, label %734

731:                                              ; preds = %716
  %732 = load ptr, ptr %7, align 8, !tbaa !5
  call void @ma_device_uninit(ptr noundef %732)
  %733 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %733, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

734:                                              ; preds = %716
  %735 = load ptr, ptr %7, align 8, !tbaa !5
  %736 = getelementptr inbounds %struct.ma_device, ptr %735, i32 0, i32 11
  %737 = call i32 @ma_event_wait(ptr noundef %736)
  %738 = load ptr, ptr %7, align 8, !tbaa !5
  %739 = call i32 @ma_device_get_state(ptr noundef %738)
  %740 = icmp eq i32 %739, 1
  br i1 %740, label %741, label %742

741:                                              ; preds = %734
  br label %744

742:                                              ; preds = %734
  call void @__assert_fail(ptr noundef @.str.48, ptr noundef @.str.6, i32 noundef 40116, ptr noundef @__PRETTY_FUNCTION__.ma_device_init) #8
  unreachable

743:                                              ; No predecessors!
  br label %744

744:                                              ; preds = %743, %741
  br label %790

745:                                              ; preds = %712
  %746 = load ptr, ptr %5, align 8, !tbaa !5
  %747 = call noundef i32 @_ZL34ma_context_is_backend_asynchronousP10ma_context(ptr noundef %746)
  %748 = icmp ne i32 %747, 0
  br i1 %748, label %749, label %788

749:                                              ; preds = %745
  %750 = load ptr, ptr %6, align 8, !tbaa !5
  %751 = getelementptr inbounds %struct.ma_device_config, ptr %750, i32 0, i32 0
  %752 = load i32, ptr %751, align 8, !tbaa !18
  %753 = icmp eq i32 %752, 3
  br i1 %753, label %754, label %787

754:                                              ; preds = %749
  %755 = load ptr, ptr %7, align 8, !tbaa !5
  %756 = getelementptr inbounds %struct.ma_device, ptr %755, i32 0, i32 23
  %757 = getelementptr inbounds %struct.anon.31, ptr %756, i32 0, i32 4
  %758 = load i32, ptr %757, align 4, !tbaa !100
  %759 = load ptr, ptr %7, align 8, !tbaa !5
  %760 = getelementptr inbounds %struct.ma_device, ptr %759, i32 0, i32 23
  %761 = getelementptr inbounds %struct.anon.31, ptr %760, i32 0, i32 5
  %762 = load i32, ptr %761, align 8, !tbaa !101
  %763 = load ptr, ptr %7, align 8, !tbaa !5
  %764 = getelementptr inbounds %struct.ma_device, ptr %763, i32 0, i32 2
  %765 = load i32, ptr %764, align 4, !tbaa !88
  %766 = load ptr, ptr %7, align 8, !tbaa !5
  %767 = getelementptr inbounds %struct.ma_device, ptr %766, i32 0, i32 23
  %768 = getelementptr inbounds %struct.anon.31, ptr %767, i32 0, i32 9
  %769 = load i32, ptr %768, align 4, !tbaa !136
  %770 = load ptr, ptr %7, align 8, !tbaa !5
  %771 = getelementptr inbounds %struct.ma_device, ptr %770, i32 0, i32 23
  %772 = getelementptr inbounds %struct.anon.31, ptr %771, i32 0, i32 11
  %773 = load i32, ptr %772, align 8, !tbaa !127
  %774 = load ptr, ptr %7, align 8, !tbaa !5
  %775 = getelementptr inbounds %struct.ma_device, ptr %774, i32 0, i32 0
  %776 = load ptr, ptr %775, align 8, !tbaa !45
  %777 = getelementptr inbounds %struct.ma_context, ptr %776, i32 0, i32 7
  %778 = load ptr, ptr %7, align 8, !tbaa !5
  %779 = getelementptr inbounds %struct.ma_device, ptr %778, i32 0, i32 20
  %780 = call i32 @ma_duplex_rb_init(i32 noundef %758, i32 noundef %762, i32 noundef %765, i32 noundef %769, i32 noundef %773, ptr noundef %777, ptr noundef %779)
  store i32 %780, ptr %8, align 4, !tbaa !111
  %781 = load i32, ptr %8, align 4, !tbaa !111
  %782 = icmp ne i32 %781, 0
  br i1 %782, label %783, label %786

783:                                              ; preds = %754
  %784 = load ptr, ptr %7, align 8, !tbaa !5
  call void @ma_device_uninit(ptr noundef %784)
  %785 = load i32, ptr %8, align 4, !tbaa !111
  store i32 %785, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

786:                                              ; preds = %754
  br label %787

787:                                              ; preds = %786, %749
  br label %788

788:                                              ; preds = %787, %745
  %789 = load ptr, ptr %7, align 8, !tbaa !5
  call void @_ZL20ma_device__set_stateP9ma_device15ma_device_state(ptr noundef %789, i32 noundef 1)
  br label %790

790:                                              ; preds = %788, %744
  %791 = load ptr, ptr %7, align 8, !tbaa !5
  %792 = call ptr @ma_device_get_log(ptr noundef %791)
  %793 = load ptr, ptr %7, align 8, !tbaa !5
  %794 = getelementptr inbounds %struct.ma_device, ptr %793, i32 0, i32 0
  %795 = load ptr, ptr %794, align 8, !tbaa !45
  %796 = getelementptr inbounds %struct.ma_context, ptr %795, i32 0, i32 1
  %797 = load i32, ptr %796, align 8, !tbaa !137
  %798 = call ptr @ma_get_backend_name(i32 noundef %797)
  %799 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %792, i32 noundef 3, ptr noundef @.str.49, ptr noundef %798)
  %800 = load ptr, ptr %7, align 8, !tbaa !5
  %801 = getelementptr inbounds %struct.ma_device, ptr %800, i32 0, i32 1
  %802 = load i32, ptr %801, align 8, !tbaa !86
  %803 = icmp eq i32 %802, 2
  br i1 %803, label %809, label %804

804:                                              ; preds = %790
  %805 = load ptr, ptr %7, align 8, !tbaa !5
  %806 = getelementptr inbounds %struct.ma_device, ptr %805, i32 0, i32 1
  %807 = load i32, ptr %806, align 8, !tbaa !86
  %808 = icmp eq i32 %807, 3
  br i1 %808, label %809, label %929

809:                                              ; preds = %804, %790
  call void @llvm.lifetime.start.p0(i64 256, ptr %15) #7
  %810 = load ptr, ptr %7, align 8, !tbaa !5
  %811 = getelementptr inbounds [256 x i8], ptr %15, i64 0, i64 0
  %812 = call i32 @ma_device_get_name(ptr noundef %810, i32 noundef 2, ptr noundef %811, i64 noundef 256, ptr noundef null)
  %813 = load ptr, ptr %7, align 8, !tbaa !5
  %814 = call ptr @ma_device_get_log(ptr noundef %813)
  %815 = getelementptr inbounds [256 x i8], ptr %15, i64 0, i64 0
  %816 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %814, i32 noundef 3, ptr noundef @.str.50, ptr noundef %815, ptr noundef @.str.51)
  %817 = load ptr, ptr %7, align 8, !tbaa !5
  %818 = call ptr @ma_device_get_log(ptr noundef %817)
  %819 = load ptr, ptr %7, align 8, !tbaa !5
  %820 = getelementptr inbounds %struct.ma_device, ptr %819, i32 0, i32 23
  %821 = getelementptr inbounds %struct.anon.31, ptr %820, i32 0, i32 7
  %822 = load i32, ptr %821, align 4, !tbaa !138
  %823 = call ptr @ma_get_format_name(i32 noundef %822)
  %824 = load ptr, ptr %7, align 8, !tbaa !5
  %825 = getelementptr inbounds %struct.ma_device, ptr %824, i32 0, i32 23
  %826 = getelementptr inbounds %struct.anon.31, ptr %825, i32 0, i32 4
  %827 = load i32, ptr %826, align 4, !tbaa !100
  %828 = call ptr @ma_get_format_name(i32 noundef %827)
  %829 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %818, i32 noundef 3, ptr noundef @.str.52, ptr noundef %823, ptr noundef %828)
  %830 = load ptr, ptr %7, align 8, !tbaa !5
  %831 = call ptr @ma_device_get_log(ptr noundef %830)
  %832 = load ptr, ptr %7, align 8, !tbaa !5
  %833 = getelementptr inbounds %struct.ma_device, ptr %832, i32 0, i32 23
  %834 = getelementptr inbounds %struct.anon.31, ptr %833, i32 0, i32 8
  %835 = load i32, ptr %834, align 8, !tbaa !139
  %836 = load ptr, ptr %7, align 8, !tbaa !5
  %837 = getelementptr inbounds %struct.ma_device, ptr %836, i32 0, i32 23
  %838 = getelementptr inbounds %struct.anon.31, ptr %837, i32 0, i32 5
  %839 = load i32, ptr %838, align 8, !tbaa !101
  %840 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %831, i32 noundef 3, ptr noundef @.str.53, i32 noundef %835, i32 noundef %839)
  %841 = load ptr, ptr %7, align 8, !tbaa !5
  %842 = call ptr @ma_device_get_log(ptr noundef %841)
  %843 = load ptr, ptr %7, align 8, !tbaa !5
  %844 = getelementptr inbounds %struct.ma_device, ptr %843, i32 0, i32 23
  %845 = getelementptr inbounds %struct.anon.31, ptr %844, i32 0, i32 9
  %846 = load i32, ptr %845, align 4, !tbaa !136
  %847 = load ptr, ptr %7, align 8, !tbaa !5
  %848 = getelementptr inbounds %struct.ma_device, ptr %847, i32 0, i32 2
  %849 = load i32, ptr %848, align 4, !tbaa !88
  %850 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %842, i32 noundef 3, ptr noundef @.str.54, i32 noundef %846, i32 noundef %849)
  %851 = load ptr, ptr %7, align 8, !tbaa !5
  %852 = call ptr @ma_device_get_log(ptr noundef %851)
  %853 = load ptr, ptr %7, align 8, !tbaa !5
  %854 = getelementptr inbounds %struct.ma_device, ptr %853, i32 0, i32 23
  %855 = getelementptr inbounds %struct.anon.31, ptr %854, i32 0, i32 11
  %856 = load i32, ptr %855, align 8, !tbaa !127
  %857 = load ptr, ptr %7, align 8, !tbaa !5
  %858 = getelementptr inbounds %struct.ma_device, ptr %857, i32 0, i32 23
  %859 = getelementptr inbounds %struct.anon.31, ptr %858, i32 0, i32 12
  %860 = load i32, ptr %859, align 4, !tbaa !140
  %861 = load ptr, ptr %7, align 8, !tbaa !5
  %862 = getelementptr inbounds %struct.ma_device, ptr %861, i32 0, i32 23
  %863 = getelementptr inbounds %struct.anon.31, ptr %862, i32 0, i32 11
  %864 = load i32, ptr %863, align 8, !tbaa !127
  %865 = load ptr, ptr %7, align 8, !tbaa !5
  %866 = getelementptr inbounds %struct.ma_device, ptr %865, i32 0, i32 23
  %867 = getelementptr inbounds %struct.anon.31, ptr %866, i32 0, i32 12
  %868 = load i32, ptr %867, align 4, !tbaa !140
  %869 = mul i32 %864, %868
  %870 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %852, i32 noundef 3, ptr noundef @.str.55, i32 noundef %856, i32 noundef %860, i32 noundef %869)
  %871 = load ptr, ptr %7, align 8, !tbaa !5
  %872 = call ptr @ma_device_get_log(ptr noundef %871)
  %873 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %872, i32 noundef 3, ptr noundef @.str.56)
  %874 = load ptr, ptr %7, align 8, !tbaa !5
  %875 = call ptr @ma_device_get_log(ptr noundef %874)
  %876 = load ptr, ptr %7, align 8, !tbaa !5
  %877 = getelementptr inbounds %struct.ma_device, ptr %876, i32 0, i32 23
  %878 = getelementptr inbounds %struct.anon.31, ptr %877, i32 0, i32 14
  %879 = getelementptr inbounds %struct.ma_data_converter, ptr %878, i32 0, i32 10
  %880 = load i8, ptr %879, align 8, !tbaa !141
  %881 = icmp ne i8 %880, 0
  %882 = zext i1 %881 to i64
  %883 = select i1 %881, ptr @.str.43, ptr @.str.44
  %884 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %875, i32 noundef 3, ptr noundef @.str.57, ptr noundef %883)
  %885 = load ptr, ptr %7, align 8, !tbaa !5
  %886 = call ptr @ma_device_get_log(ptr noundef %885)
  %887 = load ptr, ptr %7, align 8, !tbaa !5
  %888 = getelementptr inbounds %struct.ma_device, ptr %887, i32 0, i32 23
  %889 = getelementptr inbounds %struct.anon.31, ptr %888, i32 0, i32 14
  %890 = getelementptr inbounds %struct.ma_data_converter, ptr %889, i32 0, i32 11
  %891 = load i8, ptr %890, align 1, !tbaa !142
  %892 = icmp ne i8 %891, 0
  %893 = zext i1 %892 to i64
  %894 = select i1 %892, ptr @.str.43, ptr @.str.44
  %895 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %886, i32 noundef 3, ptr noundef @.str.58, ptr noundef %894)
  %896 = load ptr, ptr %7, align 8, !tbaa !5
  %897 = call ptr @ma_device_get_log(ptr noundef %896)
  %898 = load ptr, ptr %7, align 8, !tbaa !5
  %899 = getelementptr inbounds %struct.ma_device, ptr %898, i32 0, i32 23
  %900 = getelementptr inbounds %struct.anon.31, ptr %899, i32 0, i32 14
  %901 = getelementptr inbounds %struct.ma_data_converter, ptr %900, i32 0, i32 12
  %902 = load i8, ptr %901, align 2, !tbaa !143
  %903 = icmp ne i8 %902, 0
  %904 = zext i1 %903 to i64
  %905 = select i1 %903, ptr @.str.43, ptr @.str.44
  %906 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %897, i32 noundef 3, ptr noundef @.str.59, ptr noundef %905)
  %907 = load ptr, ptr %7, align 8, !tbaa !5
  %908 = call ptr @ma_device_get_log(ptr noundef %907)
  %909 = load ptr, ptr %7, align 8, !tbaa !5
  %910 = getelementptr inbounds %struct.ma_device, ptr %909, i32 0, i32 23
  %911 = getelementptr inbounds %struct.anon.31, ptr %910, i32 0, i32 14
  %912 = getelementptr inbounds %struct.ma_data_converter, ptr %911, i32 0, i32 13
  %913 = load i8, ptr %912, align 1, !tbaa !144
  %914 = icmp ne i8 %913, 0
  %915 = zext i1 %914 to i64
  %916 = select i1 %914, ptr @.str.43, ptr @.str.44
  %917 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %908, i32 noundef 3, ptr noundef @.str.60, ptr noundef %916)
  %918 = load ptr, ptr %7, align 8, !tbaa !5
  %919 = call ptr @ma_device_get_log(ptr noundef %918)
  %920 = load ptr, ptr %7, align 8, !tbaa !5
  %921 = getelementptr inbounds %struct.ma_device, ptr %920, i32 0, i32 23
  %922 = getelementptr inbounds %struct.anon.31, ptr %921, i32 0, i32 14
  %923 = getelementptr inbounds %struct.ma_data_converter, ptr %922, i32 0, i32 14
  %924 = load i8, ptr %923, align 4, !tbaa !145
  %925 = icmp ne i8 %924, 0
  %926 = zext i1 %925 to i64
  %927 = select i1 %925, ptr @.str.43, ptr @.str.44
  %928 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %919, i32 noundef 3, ptr noundef @.str.61, ptr noundef %927)
  call void @llvm.lifetime.end.p0(i64 256, ptr %15) #7
  br label %929

929:                                              ; preds = %809, %804
  %930 = load ptr, ptr %7, align 8, !tbaa !5
  %931 = getelementptr inbounds %struct.ma_device, ptr %930, i32 0, i32 1
  %932 = load i32, ptr %931, align 8, !tbaa !86
  %933 = icmp eq i32 %932, 1
  br i1 %933, label %939, label %934

934:                                              ; preds = %929
  %935 = load ptr, ptr %7, align 8, !tbaa !5
  %936 = getelementptr inbounds %struct.ma_device, ptr %935, i32 0, i32 1
  %937 = load i32, ptr %936, align 8, !tbaa !86
  %938 = icmp eq i32 %937, 3
  br i1 %938, label %939, label %1059

939:                                              ; preds = %934, %929
  call void @llvm.lifetime.start.p0(i64 256, ptr %16) #7
  %940 = load ptr, ptr %7, align 8, !tbaa !5
  %941 = getelementptr inbounds [256 x i8], ptr %16, i64 0, i64 0
  %942 = call i32 @ma_device_get_name(ptr noundef %940, i32 noundef 1, ptr noundef %941, i64 noundef 256, ptr noundef null)
  %943 = load ptr, ptr %7, align 8, !tbaa !5
  %944 = call ptr @ma_device_get_log(ptr noundef %943)
  %945 = getelementptr inbounds [256 x i8], ptr %16, i64 0, i64 0
  %946 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %944, i32 noundef 3, ptr noundef @.str.50, ptr noundef %945, ptr noundef @.str.62)
  %947 = load ptr, ptr %7, align 8, !tbaa !5
  %948 = call ptr @ma_device_get_log(ptr noundef %947)
  %949 = load ptr, ptr %7, align 8, !tbaa !5
  %950 = getelementptr inbounds %struct.ma_device, ptr %949, i32 0, i32 22
  %951 = getelementptr inbounds %struct.anon.26, ptr %950, i32 0, i32 4
  %952 = load i32, ptr %951, align 4, !tbaa !107
  %953 = call ptr @ma_get_format_name(i32 noundef %952)
  %954 = load ptr, ptr %7, align 8, !tbaa !5
  %955 = getelementptr inbounds %struct.ma_device, ptr %954, i32 0, i32 22
  %956 = getelementptr inbounds %struct.anon.26, ptr %955, i32 0, i32 7
  %957 = load i32, ptr %956, align 4, !tbaa !146
  %958 = call ptr @ma_get_format_name(i32 noundef %957)
  %959 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %948, i32 noundef 3, ptr noundef @.str.52, ptr noundef %953, ptr noundef %958)
  %960 = load ptr, ptr %7, align 8, !tbaa !5
  %961 = call ptr @ma_device_get_log(ptr noundef %960)
  %962 = load ptr, ptr %7, align 8, !tbaa !5
  %963 = getelementptr inbounds %struct.ma_device, ptr %962, i32 0, i32 22
  %964 = getelementptr inbounds %struct.anon.26, ptr %963, i32 0, i32 5
  %965 = load i32, ptr %964, align 8, !tbaa !108
  %966 = load ptr, ptr %7, align 8, !tbaa !5
  %967 = getelementptr inbounds %struct.ma_device, ptr %966, i32 0, i32 22
  %968 = getelementptr inbounds %struct.anon.26, ptr %967, i32 0, i32 8
  %969 = load i32, ptr %968, align 8, !tbaa !147
  %970 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %961, i32 noundef 3, ptr noundef @.str.53, i32 noundef %965, i32 noundef %969)
  %971 = load ptr, ptr %7, align 8, !tbaa !5
  %972 = call ptr @ma_device_get_log(ptr noundef %971)
  %973 = load ptr, ptr %7, align 8, !tbaa !5
  %974 = getelementptr inbounds %struct.ma_device, ptr %973, i32 0, i32 2
  %975 = load i32, ptr %974, align 4, !tbaa !88
  %976 = load ptr, ptr %7, align 8, !tbaa !5
  %977 = getelementptr inbounds %struct.ma_device, ptr %976, i32 0, i32 22
  %978 = getelementptr inbounds %struct.anon.26, ptr %977, i32 0, i32 9
  %979 = load i32, ptr %978, align 4, !tbaa !148
  %980 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %972, i32 noundef 3, ptr noundef @.str.54, i32 noundef %975, i32 noundef %979)
  %981 = load ptr, ptr %7, align 8, !tbaa !5
  %982 = call ptr @ma_device_get_log(ptr noundef %981)
  %983 = load ptr, ptr %7, align 8, !tbaa !5
  %984 = getelementptr inbounds %struct.ma_device, ptr %983, i32 0, i32 22
  %985 = getelementptr inbounds %struct.anon.26, ptr %984, i32 0, i32 11
  %986 = load i32, ptr %985, align 8, !tbaa !131
  %987 = load ptr, ptr %7, align 8, !tbaa !5
  %988 = getelementptr inbounds %struct.ma_device, ptr %987, i32 0, i32 22
  %989 = getelementptr inbounds %struct.anon.26, ptr %988, i32 0, i32 12
  %990 = load i32, ptr %989, align 4, !tbaa !149
  %991 = load ptr, ptr %7, align 8, !tbaa !5
  %992 = getelementptr inbounds %struct.ma_device, ptr %991, i32 0, i32 22
  %993 = getelementptr inbounds %struct.anon.26, ptr %992, i32 0, i32 11
  %994 = load i32, ptr %993, align 8, !tbaa !131
  %995 = load ptr, ptr %7, align 8, !tbaa !5
  %996 = getelementptr inbounds %struct.ma_device, ptr %995, i32 0, i32 22
  %997 = getelementptr inbounds %struct.anon.26, ptr %996, i32 0, i32 12
  %998 = load i32, ptr %997, align 4, !tbaa !149
  %999 = mul i32 %994, %998
  %1000 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %982, i32 noundef 3, ptr noundef @.str.55, i32 noundef %986, i32 noundef %990, i32 noundef %999)
  %1001 = load ptr, ptr %7, align 8, !tbaa !5
  %1002 = call ptr @ma_device_get_log(ptr noundef %1001)
  %1003 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1002, i32 noundef 3, ptr noundef @.str.56)
  %1004 = load ptr, ptr %7, align 8, !tbaa !5
  %1005 = call ptr @ma_device_get_log(ptr noundef %1004)
  %1006 = load ptr, ptr %7, align 8, !tbaa !5
  %1007 = getelementptr inbounds %struct.ma_device, ptr %1006, i32 0, i32 22
  %1008 = getelementptr inbounds %struct.anon.26, ptr %1007, i32 0, i32 14
  %1009 = getelementptr inbounds %struct.ma_data_converter, ptr %1008, i32 0, i32 10
  %1010 = load i8, ptr %1009, align 8, !tbaa !150
  %1011 = icmp ne i8 %1010, 0
  %1012 = zext i1 %1011 to i64
  %1013 = select i1 %1011, ptr @.str.43, ptr @.str.44
  %1014 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1005, i32 noundef 3, ptr noundef @.str.57, ptr noundef %1013)
  %1015 = load ptr, ptr %7, align 8, !tbaa !5
  %1016 = call ptr @ma_device_get_log(ptr noundef %1015)
  %1017 = load ptr, ptr %7, align 8, !tbaa !5
  %1018 = getelementptr inbounds %struct.ma_device, ptr %1017, i32 0, i32 22
  %1019 = getelementptr inbounds %struct.anon.26, ptr %1018, i32 0, i32 14
  %1020 = getelementptr inbounds %struct.ma_data_converter, ptr %1019, i32 0, i32 11
  %1021 = load i8, ptr %1020, align 1, !tbaa !151
  %1022 = icmp ne i8 %1021, 0
  %1023 = zext i1 %1022 to i64
  %1024 = select i1 %1022, ptr @.str.43, ptr @.str.44
  %1025 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1016, i32 noundef 3, ptr noundef @.str.58, ptr noundef %1024)
  %1026 = load ptr, ptr %7, align 8, !tbaa !5
  %1027 = call ptr @ma_device_get_log(ptr noundef %1026)
  %1028 = load ptr, ptr %7, align 8, !tbaa !5
  %1029 = getelementptr inbounds %struct.ma_device, ptr %1028, i32 0, i32 22
  %1030 = getelementptr inbounds %struct.anon.26, ptr %1029, i32 0, i32 14
  %1031 = getelementptr inbounds %struct.ma_data_converter, ptr %1030, i32 0, i32 12
  %1032 = load i8, ptr %1031, align 2, !tbaa !152
  %1033 = icmp ne i8 %1032, 0
  %1034 = zext i1 %1033 to i64
  %1035 = select i1 %1033, ptr @.str.43, ptr @.str.44
  %1036 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1027, i32 noundef 3, ptr noundef @.str.59, ptr noundef %1035)
  %1037 = load ptr, ptr %7, align 8, !tbaa !5
  %1038 = call ptr @ma_device_get_log(ptr noundef %1037)
  %1039 = load ptr, ptr %7, align 8, !tbaa !5
  %1040 = getelementptr inbounds %struct.ma_device, ptr %1039, i32 0, i32 22
  %1041 = getelementptr inbounds %struct.anon.26, ptr %1040, i32 0, i32 14
  %1042 = getelementptr inbounds %struct.ma_data_converter, ptr %1041, i32 0, i32 13
  %1043 = load i8, ptr %1042, align 1, !tbaa !153
  %1044 = icmp ne i8 %1043, 0
  %1045 = zext i1 %1044 to i64
  %1046 = select i1 %1044, ptr @.str.43, ptr @.str.44
  %1047 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1038, i32 noundef 3, ptr noundef @.str.60, ptr noundef %1046)
  %1048 = load ptr, ptr %7, align 8, !tbaa !5
  %1049 = call ptr @ma_device_get_log(ptr noundef %1048)
  %1050 = load ptr, ptr %7, align 8, !tbaa !5
  %1051 = getelementptr inbounds %struct.ma_device, ptr %1050, i32 0, i32 22
  %1052 = getelementptr inbounds %struct.anon.26, ptr %1051, i32 0, i32 14
  %1053 = getelementptr inbounds %struct.ma_data_converter, ptr %1052, i32 0, i32 14
  %1054 = load i8, ptr %1053, align 4, !tbaa !154
  %1055 = icmp ne i8 %1054, 0
  %1056 = zext i1 %1055 to i64
  %1057 = select i1 %1055, ptr @.str.43, ptr @.str.44
  %1058 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %1049, i32 noundef 3, ptr noundef @.str.61, ptr noundef %1057)
  call void @llvm.lifetime.end.p0(i64 256, ptr %16) #7
  br label %1059

1059:                                             ; preds = %939, %934
  %1060 = load ptr, ptr %7, align 8, !tbaa !5
  %1061 = call i32 @ma_device_get_state(ptr noundef %1060)
  %1062 = icmp eq i32 %1061, 1
  br i1 %1062, label %1063, label %1064

1063:                                             ; preds = %1059
  br label %1066

1064:                                             ; preds = %1059
  call void @__assert_fail(ptr noundef @.str.48, ptr noundef @.str.6, i32 noundef 40172, ptr noundef @__PRETTY_FUNCTION__.ma_device_init) #8
  unreachable

1065:                                             ; No predecessors!
  br label %1066

1066:                                             ; preds = %1065, %1063
  store i32 0, ptr %4, align 4
  store i32 1, ptr %11, align 4
  br label %1067

1067:                                             ; preds = %1066, %783, %731, %708, %491, %475, %353, %341, %331, %323, %102, %90, %67, %55, %38, %31, %26, %19
  call void @llvm.lifetime.end.p0(i64 296, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 296, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #7
  %1068 = load i32, ptr %4, align 4
  ret i32 %1068
}

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_channel_map_copy_or_default(ptr noundef, i64 noundef, ptr noundef, i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_device_uninit(ptr noundef) #1

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare hidden noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef, i32 noundef) #6

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_silence_pcm_frames(ptr noundef, i64 noundef, i32 noundef, i32 noundef) #1

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

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL16ma_worker_threadPv(ptr noundef) #1

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

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare hidden void @_ZL20ma_device__set_stateP9ma_device15ma_device_state(ptr noundef, i32 noundef) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @ma_device_get_log(ptr noundef) #5

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_device_get_name(ptr noundef, i32 noundef, ptr noundef, i64 noundef, ptr noundef) #1

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

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

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 32}
!10 = !{!"_ZTS10ma_context", !11, i64 0, !12, i64 104, !6, i64 112, !13, i64 120, !16, i64 264, !17, i64 272, !6, i64 280, !15, i64 288, !7, i64 320, !7, i64 360, !14, i64 400, !14, i64 404, !14, i64 408, !6, i64 416, !7, i64 424, !7, i64 1008}
!11 = !{!"_ZTS20ma_backend_callbacks", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96}
!12 = !{!"_ZTS10ma_backend", !7, i64 0}
!13 = !{!"_ZTS6ma_log", !7, i64 0, !14, i64 64, !15, i64 72, !7, i64 104}
!14 = !{!"int", !7, i64 0}
!15 = !{!"_ZTS23ma_allocation_callbacks", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!16 = !{!"_ZTS18ma_thread_priority", !7, i64 0}
!17 = !{!"long", !7, i64 0}
!18 = !{!19, !20, i64 0}
!19 = !{!"_ZTS16ma_device_config", !20, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !21, i64 20, !7, i64 24, !7, i64 25, !7, i64 26, !7, i64 27, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !22, i64 64, !26, i64 112, !29, i64 144, !30, i64 176, !31, i64 180, !32, i64 200, !33, i64 216, !34, i64 220, !37, i64 228}
!20 = !{!"_ZTS14ma_device_type", !7, i64 0}
!21 = !{!"_ZTS22ma_performance_profile", !7, i64 0}
!22 = !{!"_ZTS19ma_resampler_config", !23, i64 0, !14, i64 4, !14, i64 8, !14, i64 12, !24, i64 16, !6, i64 24, !6, i64 32, !25, i64 40}
!23 = !{!"_ZTS9ma_format", !7, i64 0}
!24 = !{!"_ZTS21ma_resample_algorithm", !7, i64 0}
!25 = !{!"_ZTSN19ma_resampler_configUt_E", !14, i64 0}
!26 = !{!"_ZTSN16ma_device_configUt_E", !6, i64 0, !23, i64 8, !14, i64 12, !6, i64 16, !27, i64 24, !28, i64 28}
!27 = !{!"_ZTS19ma_channel_mix_mode", !7, i64 0}
!28 = !{!"_ZTS13ma_share_mode", !7, i64 0}
!29 = !{!"_ZTSN16ma_device_configUt0_E", !6, i64 0, !23, i64 8, !14, i64 12, !6, i64 16, !27, i64 24, !28, i64 28}
!30 = !{!"_ZTSN16ma_device_configUt1_E", !7, i64 0, !7, i64 1, !7, i64 2, !7, i64 3}
!31 = !{!"_ZTSN16ma_device_configUt2_E", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12}
!32 = !{!"_ZTSN16ma_device_configUt3_E", !6, i64 0, !6, i64 8}
!33 = !{!"_ZTSN16ma_device_configUt4_E", !14, i64 0}
!34 = !{!"_ZTSN16ma_device_configUt5_E", !35, i64 0, !36, i64 4}
!35 = !{!"_ZTS21ma_opensl_stream_type", !7, i64 0}
!36 = !{!"_ZTS26ma_opensl_recording_preset", !7, i64 0}
!37 = !{!"_ZTSN16ma_device_configUt6_E", !38, i64 0, !39, i64 4, !40, i64 8, !14, i64 12}
!38 = !{!"_ZTS15ma_aaudio_usage", !7, i64 0}
!39 = !{!"_ZTS22ma_aaudio_content_type", !7, i64 0}
!40 = !{!"_ZTS22ma_aaudio_input_preset", !7, i64 0}
!41 = !{!19, !14, i64 156}
!42 = !{!19, !6, i64 160}
!43 = !{!19, !14, i64 124}
!44 = !{!19, !6, i64 128}
!45 = !{!46, !6, i64 0}
!46 = !{!"_ZTS9ma_device", !6, i64 0, !20, i64 8, !14, i64 12, !47, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !7, i64 56, !48, i64 96, !48, i64 192, !48, i64 288, !17, i64 384, !49, i64 392, !7, i64 396, !7, i64 397, !7, i64 398, !7, i64 399, !7, i64 400, !50, i64 404, !51, i64 408, !54, i64 480, !56, i64 512, !64, i64 1944, !7, i64 3344}
!47 = !{!"_ZTS15ma_device_state", !7, i64 0}
!48 = !{!"_ZTS8ma_event", !14, i64 0, !7, i64 8, !7, i64 48}
!49 = !{!"_ZTS9ma_result", !7, i64 0}
!50 = !{!"float", !7, i64 0}
!51 = !{!"_ZTS12ma_duplex_rb", !52, i64 0}
!52 = !{!"_ZTS9ma_pcm_rb", !53, i64 0, !23, i64 64, !14, i64 68}
!53 = !{!"_ZTS5ma_rb", !6, i64 0, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20, !14, i64 24, !7, i64 28, !7, i64 29, !15, i64 32}
!54 = !{!"_ZTSN9ma_deviceUt_E", !24, i64 0, !6, i64 8, !6, i64 16, !55, i64 24}
!55 = !{!"_ZTSN9ma_deviceUt_Ut_E", !14, i64 0}
!56 = !{!"_ZTSN9ma_deviceUt0_E", !6, i64 0, !7, i64 8, !7, i64 264, !28, i64 520, !23, i64 524, !14, i64 528, !7, i64 532, !23, i64 788, !14, i64 792, !14, i64 796, !7, i64 800, !14, i64 1056, !14, i64 1060, !27, i64 1064, !57, i64 1072, !6, i64 1384, !14, i64 1392, !14, i64 1396, !6, i64 1400, !63, i64 1408, !63, i64 1416, !63, i64 1424}
!57 = !{!"_ZTS17ma_data_converter", !23, i64 0, !23, i64 4, !14, i64 8, !14, i64 12, !14, i64 16, !14, i64 20, !58, i64 24, !59, i64 28, !60, i64 32, !62, i64 104, !7, i64 296, !7, i64 297, !7, i64 298, !7, i64 299, !7, i64 300, !7, i64 301, !6, i64 304}
!58 = !{!"_ZTS14ma_dither_mode", !7, i64 0}
!59 = !{!"_ZTS32ma_data_converter_execution_path", !7, i64 0}
!60 = !{!"_ZTS20ma_channel_converter", !23, i64 0, !14, i64 4, !14, i64 8, !27, i64 12, !61, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !7, i64 48, !6, i64 56, !14, i64 64}
!61 = !{!"_ZTS26ma_channel_conversion_path", !7, i64 0}
!62 = !{!"_ZTS12ma_resampler", !6, i64 0, !6, i64 8, !6, i64 16, !23, i64 24, !14, i64 28, !14, i64 32, !14, i64 36, !7, i64 40, !6, i64 176, !14, i64 184}
!63 = !{!"long long", !7, i64 0}
!64 = !{!"_ZTSN9ma_deviceUt1_E", !6, i64 0, !7, i64 8, !7, i64 264, !28, i64 520, !23, i64 524, !14, i64 528, !7, i64 532, !23, i64 788, !14, i64 792, !14, i64 796, !7, i64 800, !14, i64 1056, !14, i64 1060, !27, i64 1064, !57, i64 1072, !6, i64 1384, !14, i64 1392, !14, i64 1396}
!65 = !{!19, !6, i64 56}
!66 = !{!46, !6, i64 48}
!67 = !{!19, !6, i64 32}
!68 = !{!46, !6, i64 24}
!69 = !{!19, !6, i64 40}
!70 = !{!46, !6, i64 32}
!71 = !{!19, !6, i64 48}
!72 = !{!46, !6, i64 40}
!73 = !{!19, !6, i64 112}
!74 = !{!46, !6, i64 512}
!75 = !{!19, !6, i64 144}
!76 = !{!46, !6, i64 1944}
!77 = !{!19, !7, i64 24}
!78 = !{!46, !7, i64 397}
!79 = !{!19, !7, i64 25}
!80 = !{!46, !7, i64 398}
!81 = !{!19, !7, i64 26}
!82 = !{!46, !7, i64 399}
!83 = !{!19, !7, i64 27}
!84 = !{!46, !7, i64 400}
!85 = !{!46, !50, i64 404}
!86 = !{!46, !20, i64 8}
!87 = !{!19, !14, i64 4}
!88 = !{!46, !14, i64 12}
!89 = !{!19, !24, i64 80}
!90 = !{!46, !24, i64 480}
!91 = !{!19, !14, i64 104}
!92 = !{!46, !14, i64 504}
!93 = !{!19, !6, i64 88}
!94 = !{!46, !6, i64 488}
!95 = !{!19, !6, i64 96}
!96 = !{!46, !6, i64 496}
!97 = !{!19, !28, i64 172}
!98 = !{!46, !28, i64 2464}
!99 = !{!19, !23, i64 152}
!100 = !{!46, !23, i64 2468}
!101 = !{!46, !14, i64 2472}
!102 = !{!19, !27, i64 168}
!103 = !{!46, !27, i64 3008}
!104 = !{!19, !28, i64 140}
!105 = !{!46, !28, i64 1032}
!106 = !{!19, !23, i64 120}
!107 = !{!46, !23, i64 1036}
!108 = !{!46, !14, i64 1040}
!109 = !{!19, !27, i64 136}
!110 = !{!46, !27, i64 1576}
!111 = !{!49, !49, i64 0}
!112 = !{!113, !6, i64 0}
!113 = !{!"_ZTS20ma_device_descriptor", !6, i64 0, !28, i64 8, !23, i64 12, !14, i64 16, !14, i64 20, !7, i64 24, !14, i64 280, !14, i64 284, !14, i64 288}
!114 = !{!113, !28, i64 8}
!115 = !{!113, !23, i64 12}
!116 = !{!113, !14, i64 16}
!117 = !{!113, !14, i64 20}
!118 = !{!19, !14, i64 8}
!119 = !{!113, !14, i64 280}
!120 = !{!19, !14, i64 12}
!121 = !{!113, !14, i64 284}
!122 = !{!19, !14, i64 16}
!123 = !{!113, !14, i64 288}
!124 = !{!14, !14, i64 0}
!125 = !{!46, !14, i64 3340}
!126 = !{!46, !14, i64 3336}
!127 = !{!46, !14, i64 3000}
!128 = !{!46, !6, i64 3328}
!129 = !{!46, !14, i64 1908}
!130 = !{!46, !14, i64 1904}
!131 = !{!46, !14, i64 1568}
!132 = !{!63, !63, i64 0}
!133 = !{!46, !6, i64 1896}
!134 = !{!10, !16, i64 264}
!135 = !{!10, !17, i64 272}
!136 = !{!46, !14, i64 2740}
!137 = !{!10, !12, i64 104}
!138 = !{!46, !23, i64 2732}
!139 = !{!46, !14, i64 2736}
!140 = !{!46, !14, i64 3004}
!141 = !{!46, !7, i64 3312}
!142 = !{!46, !7, i64 3313}
!143 = !{!46, !7, i64 3314}
!144 = !{!46, !7, i64 3315}
!145 = !{!46, !7, i64 3316}
!146 = !{!46, !23, i64 1300}
!147 = !{!46, !14, i64 1304}
!148 = !{!46, !14, i64 1308}
!149 = !{!46, !14, i64 1572}
!150 = !{!46, !7, i64 1880}
!151 = !{!46, !7, i64 1881}
!152 = !{!46, !7, i64 1882}
!153 = !{!46, !7, i64 1883}
!154 = !{!46, !7, i64 1884}


; 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_device_descriptor = type { ptr, i32, i32, i32, i32, [254 x i8], i32, i32, i32 }

@.str.6 = external hidden unnamed_addr constant [104 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [56 x i8], align 1
@__PRETTY_FUNCTION__.ma_device_init = external hidden unnamed_addr constant [78 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [8 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [9 x i8], align 1

; 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 uwtable
declare dso_local ptr @ma_malloc(i64 noundef, ptr noundef) local_unnamed_addr #1

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_mutex_uninit(ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress 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) #3

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_log_postf(ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #1

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_event_uninit(ptr noundef) local_unnamed_addr #1

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local i32 @ma_calculate_buffer_size_in_frames_from_milliseconds(i32 noundef, i32 noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare hidden noundef i32 @_ZL16ma_thread_createPm18ma_thread_prioritymPFPvS1_ES1_PK23ma_allocation_callbacks(ptr noundef, i32 noundef, i64 noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local i32 @ma_device_init(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #1 {
  %4 = alloca %struct.ma_device_descriptor, align 8
  %5 = alloca %struct.ma_device_descriptor, align 8
  %6 = alloca [256 x i8], align 16
  %7 = alloca [256 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 296, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 296, ptr nonnull %5) #7
  %8 = icmp eq ptr %0, null
  br i1 %8, label %9, label %11

9:                                                ; preds = %3
  %10 = tail call i32 @ma_device_init_ex(ptr noundef null, i32 noundef 0, ptr noundef null, ptr noundef %1, ptr noundef %2)
  br label %394

11:                                               ; preds = %3
  %12 = icmp eq ptr %2, null
  br i1 %12, label %394, label %13

13:                                               ; preds = %11
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(3696) %2, i8 0, i64 3696, i1 false)
  %14 = icmp eq ptr %1, null
  br i1 %14, label %394, label %15

15:                                               ; preds = %13
  %16 = getelementptr inbounds i8, ptr %0, i64 32
  %17 = load ptr, ptr %16, align 8, !tbaa !5
  %18 = icmp eq ptr %17, null
  br i1 %18, label %394, label %19

19:                                               ; preds = %15
  %20 = load i32, ptr %1, align 8, !tbaa !17
  %21 = and i32 %20, -2
  %switch = icmp eq i32 %21, 2
  br i1 %switch, label %22, label %30

22:                                               ; preds = %19
  %23 = getelementptr inbounds i8, ptr %1, i64 156
  %24 = load i32, ptr %23, align 4, !tbaa !40
  %25 = icmp ugt i32 %24, 254
  br i1 %25, label %394, label %26

26:                                               ; preds = %22
  %27 = getelementptr inbounds i8, ptr %1, i64 160
  %28 = load ptr, ptr %27, align 8, !tbaa !41
  %29 = tail call noundef i32 @_ZL24ma__is_channel_map_validPKhj(ptr noundef %28, i32 noundef %24)
  %.not = icmp eq i32 %29, 0
  br i1 %.not, label %394, label %thread-pre-split

thread-pre-split:                                 ; preds = %26
  %.pr = load i32, ptr %1, align 8, !tbaa !17
  br label %30

30:                                               ; preds = %thread-pre-split, %19
  %31 = phi i32 [ %.pr, %thread-pre-split ], [ %20, %19 ]
  switch i32 %31, label %40 [
    i32 1, label %32
    i32 3, label %32
    i32 4, label %32
  ]

32:                                               ; preds = %30, %30, %30
  %33 = getelementptr inbounds i8, ptr %1, i64 124
  %34 = load i32, ptr %33, align 4, !tbaa !42
  %35 = icmp ugt i32 %34, 254
  br i1 %35, label %394, label %36

36:                                               ; preds = %32
  %37 = getelementptr inbounds i8, ptr %1, i64 128
  %38 = load ptr, ptr %37, align 8, !tbaa !43
  %39 = tail call noundef i32 @_ZL24ma__is_channel_map_validPKhj(ptr noundef %38, i32 noundef %34)
  %.not303 = icmp eq i32 %39, 0
  br i1 %.not303, label %394, label %40

40:                                               ; preds = %30, %36
  store ptr %0, ptr %2, align 8, !tbaa !44
  %41 = getelementptr inbounds i8, ptr %1, i64 56
  %42 = load ptr, ptr %41, align 8, !tbaa !64
  %43 = getelementptr inbounds i8, ptr %2, i64 48
  store ptr %42, ptr %43, align 8, !tbaa !65
  %44 = getelementptr inbounds i8, ptr %1, i64 32
  %45 = getelementptr inbounds i8, ptr %2, i64 24
  %46 = load <2 x ptr>, ptr %44, align 8, !tbaa !66
  store <2 x ptr> %46, ptr %45, align 8, !tbaa !66
  %47 = getelementptr inbounds i8, ptr %1, i64 48
  %48 = load ptr, ptr %47, align 8, !tbaa !67
  %49 = getelementptr inbounds i8, ptr %2, i64 40
  store ptr %48, ptr %49, align 8, !tbaa !68
  %50 = getelementptr inbounds i8, ptr %1, i64 112
  %51 = load ptr, ptr %50, align 8, !tbaa !69
  %.not304 = icmp eq ptr %51, null
  br i1 %.not304, label %54, label %52

52:                                               ; preds = %40
  %53 = getelementptr inbounds i8, ptr %2, i64 520
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(256) %53, ptr noundef nonnull align 8 dereferenceable(256) %51, i64 256, i1 false)
  br label %54

54:                                               ; preds = %40, %52
  %.sink = phi ptr [ %53, %52 ], [ null, %40 ]
  %55 = getelementptr inbounds i8, ptr %2, i64 512
  store ptr %.sink, ptr %55, align 8
  %56 = getelementptr inbounds i8, ptr %1, i64 144
  %57 = load ptr, ptr %56, align 8, !tbaa !70
  %.not305 = icmp eq ptr %57, null
  br i1 %.not305, label %60, label %58

58:                                               ; preds = %54
  %59 = getelementptr inbounds i8, ptr %2, i64 1952
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(256) %59, ptr noundef nonnull align 8 dereferenceable(256) %57, i64 256, i1 false)
  br label %60

60:                                               ; preds = %54, %58
  %.sink336 = phi ptr [ %59, %58 ], [ null, %54 ]
  %61 = getelementptr inbounds i8, ptr %2, i64 1944
  store ptr %.sink336, ptr %61, align 8
  %62 = getelementptr inbounds i8, ptr %1, i64 24
  %63 = getelementptr inbounds i8, ptr %2, i64 397
  %64 = getelementptr inbounds i8, ptr %1, i64 27
  %65 = load <4 x i8>, ptr %62, align 8, !tbaa !71
  store <4 x i8> %65, ptr %63, align 1, !tbaa !71
  %66 = getelementptr inbounds i8, ptr %2, i64 404
  store float 1.000000e+00, ptr %66, align 4, !tbaa !72
  %67 = getelementptr inbounds i8, ptr %2, i64 8
  %68 = getelementptr inbounds i8, ptr %1, i64 4
  %69 = getelementptr inbounds i8, ptr %2, i64 12
  %70 = load <2 x i32>, ptr %1, align 8, !tbaa !71
  store <2 x i32> %70, ptr %67, align 8, !tbaa !71
  %71 = getelementptr inbounds i8, ptr %1, i64 80
  %72 = load i32, ptr %71, align 8, !tbaa !73
  %73 = getelementptr inbounds i8, ptr %2, i64 480
  store i32 %72, ptr %73, align 8, !tbaa !74
  %74 = getelementptr inbounds i8, ptr %1, i64 104
  %75 = load i32, ptr %74, align 8, !tbaa !75
  %76 = getelementptr inbounds i8, ptr %2, i64 504
  store i32 %75, ptr %76, align 8, !tbaa !76
  %77 = getelementptr inbounds i8, ptr %1, i64 88
  %78 = getelementptr inbounds i8, ptr %2, i64 488
  %79 = load <2 x ptr>, ptr %77, align 8, !tbaa !66
  store <2 x ptr> %79, ptr %78, align 8, !tbaa !66
  %80 = getelementptr inbounds i8, ptr %1, i64 172
  %81 = load i32, ptr %80, align 4, !tbaa !77
  %82 = getelementptr inbounds i8, ptr %2, i64 2464
  store i32 %81, ptr %82, align 8, !tbaa !78
  %83 = getelementptr inbounds i8, ptr %1, i64 152
  %84 = load i32, ptr %83, align 8, !tbaa !79
  %85 = getelementptr inbounds i8, ptr %2, i64 2468
  store i32 %84, ptr %85, align 4, !tbaa !80
  %86 = getelementptr inbounds i8, ptr %1, i64 156
  %87 = load i32, ptr %86, align 4, !tbaa !40
  %88 = getelementptr inbounds i8, ptr %2, i64 2472
  store i32 %87, ptr %88, align 8, !tbaa !81
  %89 = getelementptr inbounds i8, ptr %2, i64 2476
  %90 = getelementptr inbounds i8, ptr %1, i64 160
  %91 = load ptr, ptr %90, align 8, !tbaa !41
  tail call void @ma_channel_map_copy_or_default(ptr noundef nonnull %89, i64 noundef 254, ptr noundef %91, i32 noundef %87)
  %92 = getelementptr inbounds i8, ptr %1, i64 168
  %93 = load i32, ptr %92, align 8, !tbaa !82
  %94 = getelementptr inbounds i8, ptr %2, i64 3008
  store i32 %93, ptr %94, align 8, !tbaa !83
  %95 = getelementptr inbounds i8, ptr %1, i64 140
  %96 = load i32, ptr %95, align 4, !tbaa !84
  %97 = getelementptr inbounds i8, ptr %2, i64 1032
  store i32 %96, ptr %97, align 8, !tbaa !85
  %98 = getelementptr inbounds i8, ptr %1, i64 120
  %99 = load i32, ptr %98, align 8, !tbaa !86
  %100 = getelementptr inbounds i8, ptr %2, i64 1036
  store i32 %99, ptr %100, align 4, !tbaa !87
  %101 = getelementptr inbounds i8, ptr %1, i64 124
  %102 = load i32, ptr %101, align 4, !tbaa !42
  %103 = getelementptr inbounds i8, ptr %2, i64 1040
  store i32 %102, ptr %103, align 8, !tbaa !88
  %104 = getelementptr inbounds i8, ptr %2, i64 1044
  %105 = getelementptr inbounds i8, ptr %1, i64 128
  %106 = load ptr, ptr %105, align 8, !tbaa !43
  tail call void @ma_channel_map_copy_or_default(ptr noundef nonnull %104, i64 noundef 254, ptr noundef %106, i32 noundef %102)
  %107 = getelementptr inbounds i8, ptr %1, i64 136
  %108 = load i32, ptr %107, align 8, !tbaa !89
  %109 = getelementptr inbounds i8, ptr %2, i64 1576
  store i32 %108, ptr %109, align 8, !tbaa !90
  %110 = getelementptr inbounds i8, ptr %2, i64 56
  %111 = tail call i32 @ma_mutex_init(ptr noundef nonnull %110)
  %.not306 = icmp eq i32 %111, 0
  br i1 %.not306, label %112, label %394

112:                                              ; preds = %60
  %113 = getelementptr inbounds i8, ptr %2, i64 96
  %114 = tail call i32 @ma_event_init(ptr noundef nonnull %113)
  %.not307 = icmp eq i32 %114, 0
  br i1 %.not307, label %116, label %115

115:                                              ; preds = %112
  tail call void @ma_mutex_uninit(ptr noundef nonnull %110)
  br label %394

116:                                              ; preds = %112
  %117 = getelementptr inbounds i8, ptr %2, i64 192
  %118 = tail call i32 @ma_event_init(ptr noundef nonnull %117)
  %.not308 = icmp eq i32 %118, 0
  br i1 %.not308, label %120, label %119

119:                                              ; preds = %116
  tail call void @ma_event_uninit(ptr noundef nonnull %113)
  tail call void @ma_mutex_uninit(ptr noundef nonnull %110)
  br label %394

120:                                              ; preds = %116
  %121 = getelementptr inbounds i8, ptr %2, i64 288
  %122 = tail call i32 @ma_event_init(ptr noundef nonnull %121)
  %.not309 = icmp eq i32 %122, 0
  br i1 %.not309, label %124, label %123

123:                                              ; preds = %120
  tail call void @ma_event_uninit(ptr noundef nonnull %117)
  tail call void @ma_event_uninit(ptr noundef nonnull %113)
  tail call void @ma_mutex_uninit(ptr noundef nonnull %110)
  br label %394

124:                                              ; preds = %120
  %125 = getelementptr inbounds i8, ptr %4, i64 24
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(296) %125, i8 0, i64 272, i1 false)
  %126 = load ptr, ptr %50, align 8, !tbaa !69
  store ptr %126, ptr %4, align 8, !tbaa !91
  %127 = load i32, ptr %95, align 4, !tbaa !84
  %128 = getelementptr inbounds i8, ptr %4, i64 8
  store i32 %127, ptr %128, align 8, !tbaa !93
  %129 = load i32, ptr %98, align 8, !tbaa !86
  %130 = getelementptr inbounds i8, ptr %4, i64 12
  store i32 %129, ptr %130, align 4, !tbaa !94
  %131 = load i32, ptr %101, align 4, !tbaa !42
  %132 = getelementptr inbounds i8, ptr %4, i64 16
  store i32 %131, ptr %132, align 8, !tbaa !95
  %133 = load i32, ptr %68, align 4, !tbaa !96
  %134 = getelementptr inbounds i8, ptr %4, i64 20
  store i32 %133, ptr %134, align 4, !tbaa !97
  %135 = getelementptr inbounds i8, ptr %4, i64 24
  %136 = load ptr, ptr %105, align 8, !tbaa !43
  call void @ma_channel_map_copy_or_default(ptr noundef nonnull %135, i64 noundef 254, ptr noundef %136, i32 noundef %131)
  %137 = getelementptr inbounds i8, ptr %1, i64 8
  %138 = getelementptr inbounds i8, ptr %4, i64 280
  %139 = getelementptr inbounds i8, ptr %1, i64 12
  %140 = load <2 x i32>, ptr %137, align 8, !tbaa !98
  store <2 x i32> %140, ptr %138, align 8, !tbaa !98
  %141 = getelementptr inbounds i8, ptr %1, i64 16
  %142 = load i32, ptr %141, align 8, !tbaa !99
  %143 = getelementptr inbounds i8, ptr %4, i64 288
  %144 = icmp eq i32 %142, 0
  %spec.select = select i1 %144, i32 3, i32 %142
  store i32 %spec.select, ptr %143, align 8, !tbaa !100
  %145 = getelementptr inbounds i8, ptr %5, i64 24
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(296) %145, i8 0, i64 272, i1 false)
  %146 = load ptr, ptr %56, align 8, !tbaa !70
  store ptr %146, ptr %5, align 8, !tbaa !91
  %147 = load i32, ptr %80, align 4, !tbaa !77
  %148 = getelementptr inbounds i8, ptr %5, i64 8
  store i32 %147, ptr %148, align 8, !tbaa !93
  %149 = load i32, ptr %83, align 8, !tbaa !79
  %150 = getelementptr inbounds i8, ptr %5, i64 12
  store i32 %149, ptr %150, align 4, !tbaa !94
  %151 = load i32, ptr %86, align 4, !tbaa !40
  %152 = getelementptr inbounds i8, ptr %5, i64 16
  store i32 %151, ptr %152, align 8, !tbaa !95
  %153 = load i32, ptr %68, align 4, !tbaa !96
  %154 = getelementptr inbounds i8, ptr %5, i64 20
  store i32 %153, ptr %154, align 4, !tbaa !97
  %155 = getelementptr inbounds i8, ptr %5, i64 24
  %156 = load ptr, ptr %90, align 8, !tbaa !41
  call void @ma_channel_map_copy_or_default(ptr noundef nonnull %155, i64 noundef 254, ptr noundef %156, i32 noundef %151)
  %157 = getelementptr inbounds i8, ptr %5, i64 280
  %158 = load <2 x i32>, ptr %137, align 8, !tbaa !98
  store <2 x i32> %158, ptr %157, align 8, !tbaa !98
  %159 = load i32, ptr %141, align 8, !tbaa !99
  %160 = getelementptr inbounds i8, ptr %5, i64 288
  %161 = icmp eq i32 %159, 0
  %storemerge310 = select i1 %161, i32 3, i32 %159
  store i32 %storemerge310, ptr %160, align 8, !tbaa !100
  %162 = load ptr, ptr %16, align 8, !tbaa !5
  %163 = call noundef i32 %162(ptr noundef nonnull %2, ptr noundef nonnull %1, ptr noundef nonnull %4, ptr noundef nonnull %5)
  %.not311 = icmp eq i32 %163, 0
  br i1 %.not311, label %165, label %164

164:                                              ; preds = %124
  call void @ma_event_uninit(ptr noundef nonnull %117)
  call void @ma_event_uninit(ptr noundef nonnull %113)
  call void @ma_mutex_uninit(ptr noundef nonnull %110)
  br label %394

165:                                              ; preds = %124
  %166 = load i32, ptr %1, align 8, !tbaa !17
  %167 = call i32 @ma_device_post_init(ptr noundef nonnull %2, i32 noundef %166, ptr noundef nonnull %4, ptr noundef nonnull %5)
  %.not312 = icmp eq i32 %167, 0
  br i1 %.not312, label %169, label %168

168:                                              ; preds = %165
  call void @ma_device_uninit(ptr noundef nonnull %2)
  br label %394

169:                                              ; preds = %165
  %170 = load i8, ptr %64, align 1, !tbaa !101
  %171 = icmp eq i8 %170, 0
  br i1 %171, label %172, label %.critedge

172:                                              ; preds = %169
  %173 = load i32, ptr %137, align 8, !tbaa !102
  %174 = icmp eq i32 %173, 0
  br i1 %174, label %175, label %179

175:                                              ; preds = %172
  %176 = load i32, ptr %139, align 4, !tbaa !103
  %177 = load i32, ptr %69, align 4, !tbaa !104
  %178 = call i32 @ma_calculate_buffer_size_in_frames_from_milliseconds(i32 noundef %176, i32 noundef %177)
  br label %179

179:                                              ; preds = %175, %172
  %.0276 = phi i32 [ %178, %175 ], [ %173, %172 ]
  %180 = load i32, ptr %1, align 8, !tbaa !17
  %.off329 = add i32 %180, -2
  %switch330 = icmp ult i32 %.off329, 3
  br i1 %switch330, label %181, label %204

181:                                              ; preds = %179
  %182 = getelementptr inbounds i8, ptr %2, i64 3340
  store i32 0, ptr %182, align 4, !tbaa !105
  %183 = getelementptr inbounds i8, ptr %2, i64 3336
  store i32 %.0276, ptr %183, align 8, !tbaa !106
  %184 = icmp eq i32 %.0276, 0
  br i1 %184, label %185, label %188

185:                                              ; preds = %181
  %186 = getelementptr inbounds i8, ptr %2, i64 3000
  %187 = load i32, ptr %186, align 8, !tbaa !107
  store i32 %187, ptr %183, align 8, !tbaa !106
  br label %188

188:                                              ; preds = %185, %181
  %189 = phi i32 [ %187, %185 ], [ %.0276, %181 ]
  %190 = load i32, ptr %85, align 4, !tbaa !80
  %191 = load i32, ptr %88, align 8, !tbaa !81
  %192 = call noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef %190, i32 noundef %191)
  %193 = mul i32 %192, %189
  %194 = zext i32 %193 to i64
  %195 = getelementptr inbounds i8, ptr %0, i64 288
  %196 = call ptr @ma_malloc(i64 noundef %194, ptr noundef nonnull %195)
  %197 = getelementptr inbounds i8, ptr %2, i64 3328
  store ptr %196, ptr %197, align 8, !tbaa !108
  %.not313 = icmp eq ptr %196, null
  br i1 %.not313, label %.thread, label %198

.thread:                                          ; preds = %188
  call void @ma_device_uninit(ptr noundef nonnull %2)
  br label %394

198:                                              ; preds = %188
  %199 = load i32, ptr %183, align 8, !tbaa !106
  %200 = zext i32 %199 to i64
  %201 = load i32, ptr %85, align 4, !tbaa !80
  %202 = load i32, ptr %88, align 8, !tbaa !81
  call void @ma_silence_pcm_frames(ptr noundef nonnull %196, i64 noundef %200, i32 noundef %201, i32 noundef %202)
  %203 = load i32, ptr %183, align 8, !tbaa !106
  store i32 %203, ptr %182, align 4, !tbaa !105
  %.pr333 = load i32, ptr %1, align 8, !tbaa !17
  br label %204

204:                                              ; preds = %198, %179
  %205 = phi i32 [ %.pr333, %198 ], [ %180, %179 ]
  switch i32 %205, label %.critedge [
    i32 1, label %206
    i32 3, label %206
  ]

206:                                              ; preds = %204, %204
  %207 = getelementptr inbounds i8, ptr %2, i64 1908
  store i32 0, ptr %207, align 4, !tbaa !109
  %208 = icmp eq i32 %205, 3
  br i1 %208, label %209, label %213

209:                                              ; preds = %206
  %210 = getelementptr inbounds i8, ptr %2, i64 3336
  %211 = load i32, ptr %210, align 8, !tbaa !106
  %212 = getelementptr inbounds i8, ptr %2, i64 1904
  store i32 %211, ptr %212, align 8, !tbaa !110
  br label %219

213:                                              ; preds = %206
  %214 = getelementptr inbounds i8, ptr %2, i64 1904
  store i32 %.0276, ptr %214, align 8, !tbaa !110
  %215 = icmp eq i32 %.0276, 0
  br i1 %215, label %216, label %219

216:                                              ; preds = %213
  %217 = getelementptr inbounds i8, ptr %2, i64 1568
  %218 = load i32, ptr %217, align 8, !tbaa !111
  store i32 %218, ptr %214, align 8, !tbaa !110
  br label %219

219:                                              ; preds = %213, %216, %209
  %220 = phi i32 [ %.0276, %213 ], [ %218, %216 ], [ %211, %209 ]
  %221 = load i32, ptr %100, align 4, !tbaa !87
  %222 = load i32, ptr %103, align 8, !tbaa !88
  %223 = call noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef %221, i32 noundef %222)
  %224 = mul i32 %223, %220
  %225 = zext i32 %224 to i64
  %226 = getelementptr inbounds i8, ptr %0, i64 288
  %227 = call ptr @ma_malloc(i64 noundef %225, ptr noundef nonnull %226)
  %228 = getelementptr inbounds i8, ptr %2, i64 1896
  store ptr %227, ptr %228, align 8, !tbaa !112
  %.not314 = icmp eq ptr %227, null
  br i1 %.not314, label %.thread334, label %229

.thread334:                                       ; preds = %219
  call void @ma_device_uninit(ptr noundef nonnull %2)
  br label %394

229:                                              ; preds = %219
  %230 = getelementptr inbounds i8, ptr %2, i64 1904
  %231 = load i32, ptr %230, align 8, !tbaa !110
  %232 = zext i32 %231 to i64
  %233 = load i32, ptr %100, align 4, !tbaa !87
  %234 = load i32, ptr %103, align 8, !tbaa !88
  call void @ma_silence_pcm_frames(ptr noundef nonnull %227, i64 noundef %232, i32 noundef %233, i32 noundef %234)
  store i32 0, ptr %207, align 4, !tbaa !109
  br label %.critedge

.critedge:                                        ; preds = %229, %204, %169
  %235 = call noundef i32 @_ZL34ma_context_is_backend_asynchronousP10ma_context(ptr noundef nonnull %0)
  %.not315 = icmp eq i32 %235, 0
  br i1 %.not315, label %236, label %250

236:                                              ; preds = %.critedge
  %237 = getelementptr inbounds i8, ptr %2, i64 384
  %238 = getelementptr inbounds i8, ptr %0, i64 264
  %239 = load i32, ptr %238, align 8, !tbaa !113
  %240 = getelementptr inbounds i8, ptr %0, i64 272
  %241 = load i64, ptr %240, align 8, !tbaa !114
  %242 = getelementptr inbounds i8, ptr %0, i64 288
  %243 = call noundef i32 @_ZL16ma_thread_createPm18ma_thread_prioritymPFPvS1_ES1_PK23ma_allocation_callbacks(ptr noundef nonnull %237, i32 noundef %239, i64 noundef %241, ptr noundef nonnull @_ZL16ma_worker_threadPv, ptr noundef nonnull %2, ptr noundef nonnull %242)
  %.not316 = icmp eq i32 %243, 0
  br i1 %.not316, label %245, label %244

244:                                              ; preds = %236
  call void @ma_device_uninit(ptr noundef nonnull %2)
  br label %394

245:                                              ; preds = %236
  %246 = call i32 @ma_event_wait(ptr noundef nonnull %121)
  %247 = call i32 @ma_device_get_state(ptr noundef nonnull %2)
  %248 = icmp eq i32 %247, 1
  br i1 %248, label %269, label %249

249:                                              ; preds = %245
  call void @__assert_fail(ptr noundef nonnull @.str.48, ptr noundef nonnull @.str.6, i32 noundef 40116, ptr noundef nonnull @__PRETTY_FUNCTION__.ma_device_init) #8
  unreachable

250:                                              ; preds = %.critedge
  %251 = call noundef i32 @_ZL34ma_context_is_backend_asynchronousP10ma_context(ptr noundef nonnull %0)
  %.not317 = icmp eq i32 %251, 0
  br i1 %.not317, label %268, label %252

252:                                              ; preds = %250
  %253 = load i32, ptr %1, align 8, !tbaa !17
  %254 = icmp eq i32 %253, 3
  br i1 %254, label %255, label %268

255:                                              ; preds = %252
  %256 = load i32, ptr %85, align 4, !tbaa !80
  %257 = load i32, ptr %88, align 8, !tbaa !81
  %258 = load i32, ptr %69, align 4, !tbaa !104
  %259 = getelementptr inbounds i8, ptr %2, i64 2740
  %260 = load i32, ptr %259, align 4, !tbaa !115
  %261 = getelementptr inbounds i8, ptr %2, i64 3000
  %262 = load i32, ptr %261, align 8, !tbaa !107
  %263 = load ptr, ptr %2, align 8, !tbaa !44
  %264 = getelementptr inbounds i8, ptr %263, i64 288
  %265 = getelementptr inbounds i8, ptr %2, i64 408
  %266 = call i32 @ma_duplex_rb_init(i32 noundef %256, i32 noundef %257, i32 noundef %258, i32 noundef %260, i32 noundef %262, ptr noundef nonnull %264, ptr noundef nonnull %265)
  %.not318 = icmp eq i32 %266, 0
  br i1 %.not318, label %268, label %267

267:                                              ; preds = %255
  call void @ma_device_uninit(ptr noundef nonnull %2)
  br label %394

268:                                              ; preds = %252, %255, %250
  call void @_ZL20ma_device__set_stateP9ma_device15ma_device_state(ptr noundef nonnull %2, i32 noundef 1)
  br label %269

269:                                              ; preds = %245, %268
  %270 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %271 = load ptr, ptr %2, align 8, !tbaa !44
  %272 = getelementptr inbounds i8, ptr %271, i64 104
  %273 = load i32, ptr %272, align 8, !tbaa !116
  %274 = call ptr @ma_get_backend_name(i32 noundef %273)
  %275 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %270, i32 noundef 3, ptr noundef nonnull @.str.49, ptr noundef %274)
  %276 = load i32, ptr %67, align 8, !tbaa !117
  %277 = and i32 %276, -2
  %switch332 = icmp eq i32 %277, 2
  br i1 %switch332, label %278, label %333

278:                                              ; preds = %269
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %6) #7
  %279 = call i32 @ma_device_get_name(ptr noundef nonnull %2, i32 noundef 2, ptr noundef nonnull %6, i64 noundef 256, ptr noundef null)
  %280 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %281 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %280, i32 noundef 3, ptr noundef nonnull @.str.50, ptr noundef nonnull %6, ptr noundef nonnull @.str.51)
  %282 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %283 = getelementptr inbounds i8, ptr %2, i64 2732
  %284 = load i32, ptr %283, align 4, !tbaa !118
  %285 = call ptr @ma_get_format_name(i32 noundef %284)
  %286 = load i32, ptr %85, align 4, !tbaa !80
  %287 = call ptr @ma_get_format_name(i32 noundef %286)
  %288 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %282, i32 noundef 3, ptr noundef nonnull @.str.52, ptr noundef %285, ptr noundef %287)
  %289 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %290 = getelementptr inbounds i8, ptr %2, i64 2736
  %291 = load i32, ptr %290, align 8, !tbaa !119
  %292 = load i32, ptr %88, align 8, !tbaa !81
  %293 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %289, i32 noundef 3, ptr noundef nonnull @.str.53, i32 noundef %291, i32 noundef %292)
  %294 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %295 = getelementptr inbounds i8, ptr %2, i64 2740
  %296 = load i32, ptr %295, align 4, !tbaa !115
  %297 = load i32, ptr %69, align 4, !tbaa !104
  %298 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %294, i32 noundef 3, ptr noundef nonnull @.str.54, i32 noundef %296, i32 noundef %297)
  %299 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %300 = getelementptr inbounds i8, ptr %2, i64 3000
  %301 = load i32, ptr %300, align 8, !tbaa !107
  %302 = getelementptr inbounds i8, ptr %2, i64 3004
  %303 = load i32, ptr %302, align 4, !tbaa !120
  %304 = mul i32 %303, %301
  %305 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %299, i32 noundef 3, ptr noundef nonnull @.str.55, i32 noundef %301, i32 noundef %303, i32 noundef %304)
  %306 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %307 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %306, i32 noundef 3, ptr noundef nonnull @.str.56)
  %308 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %309 = getelementptr inbounds i8, ptr %2, i64 3312
  %310 = load i8, ptr %309, align 8, !tbaa !121
  %.not319 = icmp eq i8 %310, 0
  %311 = select i1 %.not319, ptr @.str.44, ptr @.str.43
  %312 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %308, i32 noundef 3, ptr noundef nonnull @.str.57, ptr noundef nonnull %311)
  %313 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %314 = getelementptr inbounds i8, ptr %2, i64 3313
  %315 = load i8, ptr %314, align 1, !tbaa !122
  %.not320 = icmp eq i8 %315, 0
  %316 = select i1 %.not320, ptr @.str.44, ptr @.str.43
  %317 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %313, i32 noundef 3, ptr noundef nonnull @.str.58, ptr noundef nonnull %316)
  %318 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %319 = getelementptr inbounds i8, ptr %2, i64 3314
  %320 = load i8, ptr %319, align 2, !tbaa !123
  %.not321 = icmp eq i8 %320, 0
  %321 = select i1 %.not321, ptr @.str.44, ptr @.str.43
  %322 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %318, i32 noundef 3, ptr noundef nonnull @.str.59, ptr noundef nonnull %321)
  %323 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %324 = getelementptr inbounds i8, ptr %2, i64 3315
  %325 = load i8, ptr %324, align 1, !tbaa !124
  %.not322 = icmp eq i8 %325, 0
  %326 = select i1 %.not322, ptr @.str.44, ptr @.str.43
  %327 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %323, i32 noundef 3, ptr noundef nonnull @.str.60, ptr noundef nonnull %326)
  %328 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %329 = getelementptr inbounds i8, ptr %2, i64 3316
  %330 = load i8, ptr %329, align 4, !tbaa !125
  %.not323 = icmp eq i8 %330, 0
  %331 = select i1 %.not323, ptr @.str.44, ptr @.str.43
  %332 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %328, i32 noundef 3, ptr noundef nonnull @.str.61, ptr noundef nonnull %331)
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %6) #7
  %.pr335 = load i32, ptr %67, align 8, !tbaa !117
  br label %333

333:                                              ; preds = %269, %278
  %334 = phi i32 [ %276, %269 ], [ %.pr335, %278 ]
  switch i32 %334, label %390 [
    i32 1, label %335
    i32 3, label %335
  ]

335:                                              ; preds = %333, %333
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %7) #7
  %336 = call i32 @ma_device_get_name(ptr noundef nonnull %2, i32 noundef 1, ptr noundef nonnull %7, i64 noundef 256, ptr noundef null)
  %337 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %338 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %337, i32 noundef 3, ptr noundef nonnull @.str.50, ptr noundef nonnull %7, ptr noundef nonnull @.str.62)
  %339 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %340 = load i32, ptr %100, align 4, !tbaa !87
  %341 = call ptr @ma_get_format_name(i32 noundef %340)
  %342 = getelementptr inbounds i8, ptr %2, i64 1300
  %343 = load i32, ptr %342, align 4, !tbaa !126
  %344 = call ptr @ma_get_format_name(i32 noundef %343)
  %345 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %339, i32 noundef 3, ptr noundef nonnull @.str.52, ptr noundef %341, ptr noundef %344)
  %346 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %347 = load i32, ptr %103, align 8, !tbaa !88
  %348 = getelementptr inbounds i8, ptr %2, i64 1304
  %349 = load i32, ptr %348, align 8, !tbaa !127
  %350 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %346, i32 noundef 3, ptr noundef nonnull @.str.53, i32 noundef %347, i32 noundef %349)
  %351 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %352 = load i32, ptr %69, align 4, !tbaa !104
  %353 = getelementptr inbounds i8, ptr %2, i64 1308
  %354 = load i32, ptr %353, align 4, !tbaa !128
  %355 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %351, i32 noundef 3, ptr noundef nonnull @.str.54, i32 noundef %352, i32 noundef %354)
  %356 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %357 = getelementptr inbounds i8, ptr %2, i64 1568
  %358 = load i32, ptr %357, align 8, !tbaa !111
  %359 = getelementptr inbounds i8, ptr %2, i64 1572
  %360 = load i32, ptr %359, align 4, !tbaa !129
  %361 = mul i32 %360, %358
  %362 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %356, i32 noundef 3, ptr noundef nonnull @.str.55, i32 noundef %358, i32 noundef %360, i32 noundef %361)
  %363 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %364 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %363, i32 noundef 3, ptr noundef nonnull @.str.56)
  %365 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %366 = getelementptr inbounds i8, ptr %2, i64 1880
  %367 = load i8, ptr %366, align 8, !tbaa !130
  %.not324 = icmp eq i8 %367, 0
  %368 = select i1 %.not324, ptr @.str.44, ptr @.str.43
  %369 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %365, i32 noundef 3, ptr noundef nonnull @.str.57, ptr noundef nonnull %368)
  %370 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %371 = getelementptr inbounds i8, ptr %2, i64 1881
  %372 = load i8, ptr %371, align 1, !tbaa !131
  %.not325 = icmp eq i8 %372, 0
  %373 = select i1 %.not325, ptr @.str.44, ptr @.str.43
  %374 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %370, i32 noundef 3, ptr noundef nonnull @.str.58, ptr noundef nonnull %373)
  %375 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %376 = getelementptr inbounds i8, ptr %2, i64 1882
  %377 = load i8, ptr %376, align 2, !tbaa !132
  %.not326 = icmp eq i8 %377, 0
  %378 = select i1 %.not326, ptr @.str.44, ptr @.str.43
  %379 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %375, i32 noundef 3, ptr noundef nonnull @.str.59, ptr noundef nonnull %378)
  %380 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %381 = getelementptr inbounds i8, ptr %2, i64 1883
  %382 = load i8, ptr %381, align 1, !tbaa !133
  %.not327 = icmp eq i8 %382, 0
  %383 = select i1 %.not327, ptr @.str.44, ptr @.str.43
  %384 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %380, i32 noundef 3, ptr noundef nonnull @.str.60, ptr noundef nonnull %383)
  %385 = call ptr @ma_device_get_log(ptr noundef nonnull %2)
  %386 = getelementptr inbounds i8, ptr %2, i64 1884
  %387 = load i8, ptr %386, align 4, !tbaa !134
  %.not328 = icmp eq i8 %387, 0
  %388 = select i1 %.not328, ptr @.str.44, ptr @.str.43
  %389 = call i32 (ptr, i32, ptr, ...) @ma_log_postf(ptr noundef %385, i32 noundef 3, ptr noundef nonnull @.str.61, ptr noundef nonnull %388)
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %7) #7
  br label %390

390:                                              ; preds = %333, %335
  %391 = call i32 @ma_device_get_state(ptr noundef nonnull %2)
  %392 = icmp eq i32 %391, 1
  br i1 %392, label %394, label %393

393:                                              ; preds = %390
  call void @__assert_fail(ptr noundef nonnull @.str.48, ptr noundef nonnull @.str.6, i32 noundef 40172, ptr noundef nonnull @__PRETTY_FUNCTION__.ma_device_init) #8
  unreachable

394:                                              ; preds = %.thread334, %.thread, %390, %60, %36, %32, %26, %22, %15, %13, %11, %267, %244, %168, %164, %123, %119, %115, %9
  %.5 = phi i32 [ %10, %9 ], [ %114, %115 ], [ %118, %119 ], [ %122, %123 ], [ %163, %164 ], [ %167, %168 ], [ %266, %267 ], [ %243, %244 ], [ -2, %11 ], [ -2, %13 ], [ -3, %15 ], [ -2, %22 ], [ -2, %26 ], [ -2, %32 ], [ -2, %36 ], [ %111, %60 ], [ 0, %390 ], [ -4, %.thread ], [ -4, %.thread334 ]
  call void @llvm.lifetime.end.p0(i64 296, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 296, ptr nonnull %4) #7
  ret i32 %.5
}

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_channel_map_copy_or_default(ptr noundef, i64 noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_device_uninit(ptr noundef) local_unnamed_addr #1

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare hidden noundef i32 @_ZL22ma_get_bytes_per_frame9ma_formatj(i32 noundef, i32 noundef) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local void @ma_silence_pcm_frames(ptr noundef, i64 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZL34ma_context_is_backend_asynchronousP10ma_context(ptr noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZL16ma_worker_threadPv(ptr noundef) #1

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

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

; Function Attrs: alwaysinline mustprogress nounwind uwtable
declare hidden void @_ZL20ma_device__set_stateP9ma_device15ma_device_state(ptr noundef, i32 noundef) local_unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @ma_device_get_log(ptr noundef) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local i32 @ma_device_get_name(ptr noundef, i32 noundef, ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #1

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { 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 #6 = { alwaysinline 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 #7 = { nounwind }
attributes #8 = { 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, !8, i64 32}
!6 = !{!"_ZTS10ma_context", !7, i64 0, !11, i64 104, !8, i64 112, !12, i64 120, !15, i64 264, !16, i64 272, !8, i64 280, !14, i64 288, !9, i64 320, !9, i64 360, !13, i64 400, !13, i64 404, !13, i64 408, !8, i64 416, !9, i64 424, !9, i64 1008}
!7 = !{!"_ZTS20ma_backend_callbacks", !8, i64 0, !8, i64 8, !8, i64 16, !8, i64 24, !8, i64 32, !8, i64 40, !8, i64 48, !8, i64 56, !8, i64 64, !8, i64 72, !8, i64 80, !8, i64 88, !8, i64 96}
!8 = !{!"any pointer", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"_ZTS10ma_backend", !9, i64 0}
!12 = !{!"_ZTS6ma_log", !9, i64 0, !13, i64 64, !14, i64 72, !9, i64 104}
!13 = !{!"int", !9, i64 0}
!14 = !{!"_ZTS23ma_allocation_callbacks", !8, i64 0, !8, i64 8, !8, i64 16, !8, i64 24}
!15 = !{!"_ZTS18ma_thread_priority", !9, i64 0}
!16 = !{!"long", !9, i64 0}
!17 = !{!18, !19, i64 0}
!18 = !{!"_ZTS16ma_device_config", !19, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !20, i64 20, !9, i64 24, !9, i64 25, !9, i64 26, !9, i64 27, !8, i64 32, !8, i64 40, !8, i64 48, !8, i64 56, !21, i64 64, !25, i64 112, !28, i64 144, !29, i64 176, !30, i64 180, !31, i64 200, !32, i64 216, !33, i64 220, !36, i64 228}
!19 = !{!"_ZTS14ma_device_type", !9, i64 0}
!20 = !{!"_ZTS22ma_performance_profile", !9, i64 0}
!21 = !{!"_ZTS19ma_resampler_config", !22, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !23, i64 16, !8, i64 24, !8, i64 32, !24, i64 40}
!22 = !{!"_ZTS9ma_format", !9, i64 0}
!23 = !{!"_ZTS21ma_resample_algorithm", !9, i64 0}
!24 = !{!"_ZTSN19ma_resampler_configUt_E", !13, i64 0}
!25 = !{!"_ZTSN16ma_device_configUt_E", !8, i64 0, !22, i64 8, !13, i64 12, !8, i64 16, !26, i64 24, !27, i64 28}
!26 = !{!"_ZTS19ma_channel_mix_mode", !9, i64 0}
!27 = !{!"_ZTS13ma_share_mode", !9, i64 0}
!28 = !{!"_ZTSN16ma_device_configUt0_E", !8, i64 0, !22, i64 8, !13, i64 12, !8, i64 16, !26, i64 24, !27, i64 28}
!29 = !{!"_ZTSN16ma_device_configUt1_E", !9, i64 0, !9, i64 1, !9, i64 2, !9, i64 3}
!30 = !{!"_ZTSN16ma_device_configUt2_E", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12}
!31 = !{!"_ZTSN16ma_device_configUt3_E", !8, i64 0, !8, i64 8}
!32 = !{!"_ZTSN16ma_device_configUt4_E", !13, i64 0}
!33 = !{!"_ZTSN16ma_device_configUt5_E", !34, i64 0, !35, i64 4}
!34 = !{!"_ZTS21ma_opensl_stream_type", !9, i64 0}
!35 = !{!"_ZTS26ma_opensl_recording_preset", !9, i64 0}
!36 = !{!"_ZTSN16ma_device_configUt6_E", !37, i64 0, !38, i64 4, !39, i64 8, !13, i64 12}
!37 = !{!"_ZTS15ma_aaudio_usage", !9, i64 0}
!38 = !{!"_ZTS22ma_aaudio_content_type", !9, i64 0}
!39 = !{!"_ZTS22ma_aaudio_input_preset", !9, i64 0}
!40 = !{!18, !13, i64 156}
!41 = !{!18, !8, i64 160}
!42 = !{!18, !13, i64 124}
!43 = !{!18, !8, i64 128}
!44 = !{!45, !8, i64 0}
!45 = !{!"_ZTS9ma_device", !8, i64 0, !19, i64 8, !13, i64 12, !46, i64 16, !8, i64 24, !8, i64 32, !8, i64 40, !8, i64 48, !9, i64 56, !47, i64 96, !47, i64 192, !47, i64 288, !16, i64 384, !48, i64 392, !9, i64 396, !9, i64 397, !9, i64 398, !9, i64 399, !9, i64 400, !49, i64 404, !50, i64 408, !53, i64 480, !55, i64 512, !63, i64 1944, !9, i64 3344}
!46 = !{!"_ZTS15ma_device_state", !9, i64 0}
!47 = !{!"_ZTS8ma_event", !13, i64 0, !9, i64 8, !9, i64 48}
!48 = !{!"_ZTS9ma_result", !9, i64 0}
!49 = !{!"float", !9, i64 0}
!50 = !{!"_ZTS12ma_duplex_rb", !51, i64 0}
!51 = !{!"_ZTS9ma_pcm_rb", !52, i64 0, !22, i64 64, !13, i64 68}
!52 = !{!"_ZTS5ma_rb", !8, i64 0, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !9, i64 28, !9, i64 29, !14, i64 32}
!53 = !{!"_ZTSN9ma_deviceUt_E", !23, i64 0, !8, i64 8, !8, i64 16, !54, i64 24}
!54 = !{!"_ZTSN9ma_deviceUt_Ut_E", !13, i64 0}
!55 = !{!"_ZTSN9ma_deviceUt0_E", !8, i64 0, !9, i64 8, !9, i64 264, !27, i64 520, !22, i64 524, !13, i64 528, !9, i64 532, !22, i64 788, !13, i64 792, !13, i64 796, !9, i64 800, !13, i64 1056, !13, i64 1060, !26, i64 1064, !56, i64 1072, !8, i64 1384, !13, i64 1392, !13, i64 1396, !8, i64 1400, !62, i64 1408, !62, i64 1416, !62, i64 1424}
!56 = !{!"_ZTS17ma_data_converter", !22, i64 0, !22, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !57, i64 24, !58, i64 28, !59, i64 32, !61, i64 104, !9, i64 296, !9, i64 297, !9, i64 298, !9, i64 299, !9, i64 300, !9, i64 301, !8, i64 304}
!57 = !{!"_ZTS14ma_dither_mode", !9, i64 0}
!58 = !{!"_ZTS32ma_data_converter_execution_path", !9, i64 0}
!59 = !{!"_ZTS20ma_channel_converter", !22, i64 0, !13, i64 4, !13, i64 8, !26, i64 12, !60, i64 16, !8, i64 24, !8, i64 32, !8, i64 40, !9, i64 48, !8, i64 56, !13, i64 64}
!60 = !{!"_ZTS26ma_channel_conversion_path", !9, i64 0}
!61 = !{!"_ZTS12ma_resampler", !8, i64 0, !8, i64 8, !8, i64 16, !22, i64 24, !13, i64 28, !13, i64 32, !13, i64 36, !9, i64 40, !8, i64 176, !13, i64 184}
!62 = !{!"long long", !9, i64 0}
!63 = !{!"_ZTSN9ma_deviceUt1_E", !8, i64 0, !9, i64 8, !9, i64 264, !27, i64 520, !22, i64 524, !13, i64 528, !9, i64 532, !22, i64 788, !13, i64 792, !13, i64 796, !9, i64 800, !13, i64 1056, !13, i64 1060, !26, i64 1064, !56, i64 1072, !8, i64 1384, !13, i64 1392, !13, i64 1396}
!64 = !{!18, !8, i64 56}
!65 = !{!45, !8, i64 48}
!66 = !{!8, !8, i64 0}
!67 = !{!18, !8, i64 48}
!68 = !{!45, !8, i64 40}
!69 = !{!18, !8, i64 112}
!70 = !{!18, !8, i64 144}
!71 = !{!9, !9, i64 0}
!72 = !{!45, !49, i64 404}
!73 = !{!18, !23, i64 80}
!74 = !{!45, !23, i64 480}
!75 = !{!18, !13, i64 104}
!76 = !{!45, !13, i64 504}
!77 = !{!18, !27, i64 172}
!78 = !{!45, !27, i64 2464}
!79 = !{!18, !22, i64 152}
!80 = !{!45, !22, i64 2468}
!81 = !{!45, !13, i64 2472}
!82 = !{!18, !26, i64 168}
!83 = !{!45, !26, i64 3008}
!84 = !{!18, !27, i64 140}
!85 = !{!45, !27, i64 1032}
!86 = !{!18, !22, i64 120}
!87 = !{!45, !22, i64 1036}
!88 = !{!45, !13, i64 1040}
!89 = !{!18, !26, i64 136}
!90 = !{!45, !26, i64 1576}
!91 = !{!92, !8, i64 0}
!92 = !{!"_ZTS20ma_device_descriptor", !8, i64 0, !27, i64 8, !22, i64 12, !13, i64 16, !13, i64 20, !9, i64 24, !13, i64 280, !13, i64 284, !13, i64 288}
!93 = !{!92, !27, i64 8}
!94 = !{!92, !22, i64 12}
!95 = !{!92, !13, i64 16}
!96 = !{!18, !13, i64 4}
!97 = !{!92, !13, i64 20}
!98 = !{!13, !13, i64 0}
!99 = !{!18, !13, i64 16}
!100 = !{!92, !13, i64 288}
!101 = !{!18, !9, i64 27}
!102 = !{!18, !13, i64 8}
!103 = !{!18, !13, i64 12}
!104 = !{!45, !13, i64 12}
!105 = !{!45, !13, i64 3340}
!106 = !{!45, !13, i64 3336}
!107 = !{!45, !13, i64 3000}
!108 = !{!45, !8, i64 3328}
!109 = !{!45, !13, i64 1908}
!110 = !{!45, !13, i64 1904}
!111 = !{!45, !13, i64 1568}
!112 = !{!45, !8, i64 1896}
!113 = !{!6, !15, i64 264}
!114 = !{!6, !16, i64 272}
!115 = !{!45, !13, i64 2740}
!116 = !{!6, !11, i64 104}
!117 = !{!45, !19, i64 8}
!118 = !{!45, !22, i64 2732}
!119 = !{!45, !13, i64 2736}
!120 = !{!45, !13, i64 3004}
!121 = !{!45, !9, i64 3312}
!122 = !{!45, !9, i64 3313}
!123 = !{!45, !9, i64 3314}
!124 = !{!45, !9, i64 3315}
!125 = !{!45, !9, i64 3316}
!126 = !{!45, !22, i64 1300}
!127 = !{!45, !13, i64 1304}
!128 = !{!45, !13, i64 1308}
!129 = !{!45, !13, i64 1572}
!130 = !{!45, !9, i64 1880}
!131 = !{!45, !9, i64 1881}
!132 = !{!45, !9, i64 1882}
!133 = !{!45, !9, i64 1883}
!134 = !{!45, !9, i64 1884}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,MergedLoadStoreMotionPass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass