; LLVM IR from recp/cglm :: test/src (tests)

; 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.test_status_t = type { ptr, i32 }

@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [94 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [97 x i8], align 1
@.str.681 = external hidden unnamed_addr constant [77 x i8], align 1
@.str.682 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.683 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.685 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.728 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.787 = external hidden unnamed_addr constant [64 x i8], align 1
@.str.863 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.864 = external hidden unnamed_addr constant [40 x i8], align 1
@__const.test_glm_quat_mat4t.axis2 = external hidden unnamed_addr constant [3 x float], align 4

; 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden zeroext i1 @test_eq(float noundef, float noundef) #2

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #3

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

declare { ptr, i32 } @test_assert_vec3_eq(ptr noundef, ptr noundef) #4

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_vec3_normalize(ptr noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_rotate_make(ptr noundef, float noundef, ptr noundef) #2

declare { ptr, i32 } @test_assert_vec4_eq(ptr noundef, ptr noundef) #4

declare { ptr, i32 } @test_assert_mat4_eq(ptr noundef, ptr noundef) #4

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat(ptr noundef, float noundef, float noundef, float noundef, float noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat_axis(ptr noundef, ptr noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden float @glm_quat_angle(ptr noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_mat4_quat(ptr noundef, ptr noundef) #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_mat4_transpose(ptr noundef) #2

declare { ptr, i32 } @test_assert_mat4_eq2(ptr noundef, ptr noundef, float noundef) #4

declare void @test_rand_quat(ptr noundef) #4

declare { ptr, i32 } @test_assert_quat_eq_abs(ptr noundef, ptr noundef) #4

; Function Attrs: nounwind uwtable
define dso_local { ptr, i32 } @test_glm_quat_mat4t() #5 {
  %1 = alloca %struct.test_status_t, align 8
  %2 = alloca [4 x [4 x float]], align 16
  %3 = alloca [4 x [4 x float]], align 16
  %4 = alloca [4 x float], align 16
  %5 = alloca [4 x float], align 16
  %6 = alloca [4 x float], align 16
  %7 = alloca [3 x float], align 4
  %8 = alloca [3 x float], align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca %struct.test_status_t, align 8
  %12 = alloca %struct.test_status_t, align 8
  %13 = alloca %struct.test_status_t, align 8
  %14 = alloca %struct.test_status_t, align 8
  %15 = alloca %struct.test_status_t, align 8
  %16 = alloca %struct.test_status_t, align 8
  %17 = alloca %struct.test_status_t, align 8
  %18 = alloca %struct.test_status_t, align 8
  %19 = alloca %struct.test_status_t, align 8
  %20 = alloca %struct.test_status_t, align 8
  %21 = alloca %struct.test_status_t, align 8
  %22 = alloca %struct.test_status_t, align 8
  call void @llvm.lifetime.start.p0(i64 64, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 64, ptr %3) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %5) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %6) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %7) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %8) #6
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %8, ptr align 4 @__const.test_glm_quat_mat4t.axis2, i64 12, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  %23 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  call void @glm_quat(ptr noundef %23, float noundef 0x3FE921FB60000000, float noundef 0x3FFE666660000000, float noundef 0x4002666660000000, float noundef 4.500000e+00)
  %24 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  %25 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  call void @glm_quat_mat4t(ptr noundef %24, ptr noundef %25)
  %26 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  call void @glm_mat4_transpose(ptr noundef %26)
  %27 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  %28 = getelementptr inbounds [4 x float], ptr %5, i64 0, i64 0
  call void @glm_mat4_quat(ptr noundef %27, ptr noundef %28)
  %29 = getelementptr inbounds [4 x [4 x float]], ptr %3, i64 0, i64 0
  %30 = getelementptr inbounds [3 x float], ptr %8, i64 0, i64 0
  call void @glm_rotate_make(ptr noundef %29, float noundef 0x3FE921FB60000000, ptr noundef %30)
  %31 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  %32 = getelementptr inbounds [4 x float], ptr %6, i64 0, i64 0
  call void @glm_mat4_quat(ptr noundef %31, ptr noundef %32)
  %33 = getelementptr inbounds [4 x float], ptr %6, i64 0, i64 0
  %34 = getelementptr inbounds [3 x float], ptr %7, i64 0, i64 0
  call void @glm_quat_axis(ptr noundef %33, ptr noundef %34)
  %35 = getelementptr inbounds [3 x float], ptr %7, i64 0, i64 0
  call void @glm_vec3_normalize(ptr noundef %35)
  %36 = getelementptr inbounds [3 x float], ptr %8, i64 0, i64 0
  call void @glm_vec3_normalize(ptr noundef %36)
  br label %37

37:                                               ; preds = %0
  %38 = getelementptr inbounds [4 x float], ptr %6, i64 0, i64 0
  %39 = call float @glm_quat_angle(ptr noundef %38)
  %40 = call zeroext i1 @test_eq(float noundef %39, float noundef 0x3FE921FB60000000)
  br i1 %40, label %46, label %41

41:                                               ; preds = %37
  %42 = load ptr, ptr @stderr, align 8, !tbaa !5
  %43 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %42, ptr noundef @.str, ptr noundef @.str.787, i32 noundef 571, ptr noundef @.str.681) #6
  %44 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  store ptr null, ptr %44, align 8, !tbaa !9
  %45 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %45, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %212

46:                                               ; preds = %37
  br label %47

47:                                               ; preds = %46
  br label %48

48:                                               ; preds = %47
  br label %49

49:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 16, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #6
  %50 = getelementptr inbounds [3 x float], ptr %7, i64 0, i64 0
  %51 = getelementptr inbounds [3 x float], ptr %8, i64 0, i64 0
  %52 = call { ptr, i32 } @test_assert_vec3_eq(ptr noundef %50, ptr noundef %51)
  %53 = getelementptr inbounds { ptr, i32 }, ptr %12, i32 0, i32 0
  %54 = extractvalue { ptr, i32 } %52, 0
  store ptr %54, ptr %53, align 8
  %55 = getelementptr inbounds { ptr, i32 }, ptr %12, i32 0, i32 1
  %56 = extractvalue { ptr, i32 } %52, 1
  store i32 %56, ptr %55, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %11, ptr align 8 %12, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #6
  %57 = getelementptr inbounds %struct.test_status_t, ptr %11, i32 0, i32 1
  %58 = load i32, ptr %57, align 8, !tbaa !12
  %59 = icmp ne i32 %58, 1
  br i1 %59, label %60, label %67

60:                                               ; preds = %49
  %61 = load ptr, ptr @stderr, align 8, !tbaa !5
  %62 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %61, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 572, ptr noundef @.str.682) #6
  %63 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %64 = getelementptr inbounds %struct.test_status_t, ptr %11, i32 0, i32 0
  %65 = load ptr, ptr %64, align 8, !tbaa !9
  store ptr %65, ptr %63, align 8, !tbaa !9
  %66 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %66, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %68

67:                                               ; preds = %49
  store i32 0, ptr %10, align 4
  br label %68

68:                                               ; preds = %67, %60
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #6
  %69 = load i32, ptr %10, align 4
  switch i32 %69, label %212 [
    i32 0, label %70
  ]

70:                                               ; preds = %68
  br label %71

71:                                               ; preds = %70
  br label %72

72:                                               ; preds = %71
  br label %73

73:                                               ; preds = %72
  call void @llvm.lifetime.start.p0(i64 16, ptr %13) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #6
  %74 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  %75 = getelementptr inbounds [4 x float], ptr %5, i64 0, i64 0
  %76 = call { ptr, i32 } @test_assert_vec4_eq(ptr noundef %74, ptr noundef %75)
  %77 = getelementptr inbounds { ptr, i32 }, ptr %14, i32 0, i32 0
  %78 = extractvalue { ptr, i32 } %76, 0
  store ptr %78, ptr %77, align 8
  %79 = getelementptr inbounds { ptr, i32 }, ptr %14, i32 0, i32 1
  %80 = extractvalue { ptr, i32 } %76, 1
  store i32 %80, ptr %79, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %13, ptr align 8 %14, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #6
  %81 = getelementptr inbounds %struct.test_status_t, ptr %13, i32 0, i32 1
  %82 = load i32, ptr %81, align 8, !tbaa !12
  %83 = icmp ne i32 %82, 1
  br i1 %83, label %84, label %91

84:                                               ; preds = %73
  %85 = load ptr, ptr @stderr, align 8, !tbaa !5
  %86 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %85, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 573, ptr noundef @.str.683) #6
  %87 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %88 = getelementptr inbounds %struct.test_status_t, ptr %13, i32 0, i32 0
  %89 = load ptr, ptr %88, align 8, !tbaa !9
  store ptr %89, ptr %87, align 8, !tbaa !9
  %90 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %90, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %92

91:                                               ; preds = %73
  store i32 0, ptr %10, align 4
  br label %92

92:                                               ; preds = %91, %84
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #6
  %93 = load i32, ptr %10, align 4
  switch i32 %93, label %212 [
    i32 0, label %94
  ]

94:                                               ; preds = %92
  br label %95

95:                                               ; preds = %94
  br label %96

96:                                               ; preds = %95
  br label %97

97:                                               ; preds = %96
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #6
  %98 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  %99 = getelementptr inbounds [4 x [4 x float]], ptr %3, i64 0, i64 0
  %100 = call { ptr, i32 } @test_assert_mat4_eq(ptr noundef %98, ptr noundef %99)
  %101 = getelementptr inbounds { ptr, i32 }, ptr %16, i32 0, i32 0
  %102 = extractvalue { ptr, i32 } %100, 0
  store ptr %102, ptr %101, align 8
  %103 = getelementptr inbounds { ptr, i32 }, ptr %16, i32 0, i32 1
  %104 = extractvalue { ptr, i32 } %100, 1
  store i32 %104, ptr %103, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %15, ptr align 8 %16, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #6
  %105 = getelementptr inbounds %struct.test_status_t, ptr %15, i32 0, i32 1
  %106 = load i32, ptr %105, align 8, !tbaa !12
  %107 = icmp ne i32 %106, 1
  br i1 %107, label %108, label %115

108:                                              ; preds = %97
  %109 = load ptr, ptr @stderr, align 8, !tbaa !5
  %110 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %109, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 574, ptr noundef @.str.728) #6
  %111 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %112 = getelementptr inbounds %struct.test_status_t, ptr %15, i32 0, i32 0
  %113 = load ptr, ptr %112, align 8, !tbaa !9
  store ptr %113, ptr %111, align 8, !tbaa !9
  %114 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %114, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %116

115:                                              ; preds = %97
  store i32 0, ptr %10, align 4
  br label %116

116:                                              ; preds = %115, %108
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #6
  %117 = load i32, ptr %10, align 4
  switch i32 %117, label %212 [
    i32 0, label %118
  ]

118:                                              ; preds = %116
  br label %119

119:                                              ; preds = %118
  br label %120

120:                                              ; preds = %119
  br label %121

121:                                              ; preds = %120
  call void @llvm.lifetime.start.p0(i64 16, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #6
  %122 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  %123 = getelementptr inbounds [4 x float], ptr %6, i64 0, i64 0
  %124 = call { ptr, i32 } @test_assert_vec4_eq(ptr noundef %122, ptr noundef %123)
  %125 = getelementptr inbounds { ptr, i32 }, ptr %18, i32 0, i32 0
  %126 = extractvalue { ptr, i32 } %124, 0
  store ptr %126, ptr %125, align 8
  %127 = getelementptr inbounds { ptr, i32 }, ptr %18, i32 0, i32 1
  %128 = extractvalue { ptr, i32 } %124, 1
  store i32 %128, ptr %127, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %17, ptr align 8 %18, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #6
  %129 = getelementptr inbounds %struct.test_status_t, ptr %17, i32 0, i32 1
  %130 = load i32, ptr %129, align 8, !tbaa !12
  %131 = icmp ne i32 %130, 1
  br i1 %131, label %132, label %139

132:                                              ; preds = %121
  %133 = load ptr, ptr @stderr, align 8, !tbaa !5
  %134 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %133, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 575, ptr noundef @.str.685) #6
  %135 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %136 = getelementptr inbounds %struct.test_status_t, ptr %17, i32 0, i32 0
  %137 = load ptr, ptr %136, align 8, !tbaa !9
  store ptr %137, ptr %135, align 8, !tbaa !9
  %138 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %138, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %140

139:                                              ; preds = %121
  store i32 0, ptr %10, align 4
  br label %140

140:                                              ; preds = %139, %132
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #6
  %141 = load i32, ptr %10, align 4
  switch i32 %141, label %212 [
    i32 0, label %142
  ]

142:                                              ; preds = %140
  br label %143

143:                                              ; preds = %142
  br label %144

144:                                              ; preds = %143
  store i32 0, ptr %9, align 4, !tbaa !14
  br label %145

145:                                              ; preds = %206, %144
  %146 = load i32, ptr %9, align 4, !tbaa !14
  %147 = icmp slt i32 %146, 1000
  br i1 %147, label %148, label %209

148:                                              ; preds = %145
  %149 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  call void @test_rand_quat(ptr noundef %149)
  %150 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  %151 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  call void @glm_quat_mat4t(ptr noundef %150, ptr noundef %151)
  %152 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  call void @glm_mat4_transpose(ptr noundef %152)
  %153 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  %154 = getelementptr inbounds [4 x float], ptr %5, i64 0, i64 0
  call void @glm_mat4_quat(ptr noundef %153, ptr noundef %154)
  %155 = getelementptr inbounds [4 x float], ptr %5, i64 0, i64 0
  %156 = getelementptr inbounds [4 x [4 x float]], ptr %3, i64 0, i64 0
  call void @glm_quat_mat4t(ptr noundef %155, ptr noundef %156)
  %157 = getelementptr inbounds [4 x [4 x float]], ptr %3, i64 0, i64 0
  call void @glm_mat4_transpose(ptr noundef %157)
  br label %158

158:                                              ; preds = %148
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #6
  %159 = getelementptr inbounds [4 x float], ptr %4, i64 0, i64 0
  %160 = getelementptr inbounds [4 x float], ptr %5, i64 0, i64 0
  %161 = call { ptr, i32 } @test_assert_quat_eq_abs(ptr noundef %159, ptr noundef %160)
  %162 = getelementptr inbounds { ptr, i32 }, ptr %20, i32 0, i32 0
  %163 = extractvalue { ptr, i32 } %161, 0
  store ptr %163, ptr %162, align 8
  %164 = getelementptr inbounds { ptr, i32 }, ptr %20, i32 0, i32 1
  %165 = extractvalue { ptr, i32 } %161, 1
  store i32 %165, ptr %164, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %19, ptr align 8 %20, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #6
  %166 = getelementptr inbounds %struct.test_status_t, ptr %19, i32 0, i32 1
  %167 = load i32, ptr %166, align 8, !tbaa !12
  %168 = icmp ne i32 %167, 1
  br i1 %168, label %169, label %176

169:                                              ; preds = %158
  %170 = load ptr, ptr @stderr, align 8, !tbaa !5
  %171 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %170, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 590, ptr noundef @.str.863) #6
  %172 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %173 = getelementptr inbounds %struct.test_status_t, ptr %19, i32 0, i32 0
  %174 = load ptr, ptr %173, align 8, !tbaa !9
  store ptr %174, ptr %172, align 8, !tbaa !9
  %175 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %175, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %177

176:                                              ; preds = %158
  store i32 0, ptr %10, align 4
  br label %177

177:                                              ; preds = %176, %169
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #6
  %178 = load i32, ptr %10, align 4
  switch i32 %178, label %212 [
    i32 0, label %179
  ]

179:                                              ; preds = %177
  br label %180

180:                                              ; preds = %179
  br label %181

181:                                              ; preds = %180
  br label %182

182:                                              ; preds = %181
  call void @llvm.lifetime.start.p0(i64 16, ptr %21) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %22) #6
  %183 = getelementptr inbounds [4 x [4 x float]], ptr %2, i64 0, i64 0
  %184 = getelementptr inbounds [4 x [4 x float]], ptr %3, i64 0, i64 0
  %185 = call { ptr, i32 } @test_assert_mat4_eq2(ptr noundef %183, ptr noundef %184, float noundef 0x3EE2DFD6A0000000)
  %186 = getelementptr inbounds { ptr, i32 }, ptr %22, i32 0, i32 0
  %187 = extractvalue { ptr, i32 } %185, 0
  store ptr %187, ptr %186, align 8
  %188 = getelementptr inbounds { ptr, i32 }, ptr %22, i32 0, i32 1
  %189 = extractvalue { ptr, i32 } %185, 1
  store i32 %189, ptr %188, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %21, ptr align 8 %22, i64 16, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 16, ptr %22) #6
  %190 = getelementptr inbounds %struct.test_status_t, ptr %21, i32 0, i32 1
  %191 = load i32, ptr %190, align 8, !tbaa !12
  %192 = icmp ne i32 %191, 1
  br i1 %192, label %193, label %200

193:                                              ; preds = %182
  %194 = load ptr, ptr @stderr, align 8, !tbaa !5
  %195 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %194, ptr noundef @.str.13, ptr noundef @.str.787, i32 noundef 594, ptr noundef @.str.864) #6
  %196 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  %197 = getelementptr inbounds %struct.test_status_t, ptr %21, i32 0, i32 0
  %198 = load ptr, ptr %197, align 8, !tbaa !9
  store ptr %198, ptr %196, align 8, !tbaa !9
  %199 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 0, ptr %199, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %201

200:                                              ; preds = %182
  store i32 0, ptr %10, align 4
  br label %201

201:                                              ; preds = %200, %193
  call void @llvm.lifetime.end.p0(i64 16, ptr %21) #6
  %202 = load i32, ptr %10, align 4
  switch i32 %202, label %212 [
    i32 0, label %203
  ]

203:                                              ; preds = %201
  br label %204

204:                                              ; preds = %203
  br label %205

205:                                              ; preds = %204
  br label %206

206:                                              ; preds = %205
  %207 = load i32, ptr %9, align 4, !tbaa !14
  %208 = add nsw i32 %207, 1
  store i32 %208, ptr %9, align 4, !tbaa !14
  br label %145, !llvm.loop !15

209:                                              ; preds = %145
  %210 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 0
  store ptr null, ptr %210, align 8, !tbaa !9
  %211 = getelementptr inbounds %struct.test_status_t, ptr %1, i32 0, i32 1
  store i32 1, ptr %211, align 8, !tbaa !12
  store i32 1, ptr %10, align 4
  br label %212

212:                                              ; preds = %209, %201, %177, %140, %116, %92, %68, %41
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr %3) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr %2) #6
  %213 = load { ptr, i32 }, ptr %1, align 8
  ret { ptr, i32 } %213
}

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat_mat4t(ptr noundef, ptr noundef) #2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !6, i64 0}
!10 = !{!"test_status_t", !6, i64 0, !11, i64 8}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !11, i64 8}
!13 = !{i64 0, i64 8, !5, i64 8, i64 4, !14}
!14 = !{!11, !11, i64 0}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}


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

@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [94 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [97 x i8], align 1
@.str.681 = external hidden unnamed_addr constant [77 x i8], align 1
@.str.682 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.683 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.685 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.728 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.787 = external hidden unnamed_addr constant [64 x i8], align 1
@.str.863 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.864 = external hidden unnamed_addr constant [40 x i8], align 1
@__const.test_glm_quat_mat4t.axis2 = external hidden unnamed_addr constant [3 x float], align 4

; 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; Function Attrs: alwaysinline nounwind uwtable
declare hidden zeroext i1 @test_eq(float noundef, float noundef) local_unnamed_addr #2

; Function Attrs: nofree nounwind
declare noundef i32 @fprintf(ptr nocapture noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #3

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

declare { ptr, i32 } @test_assert_vec3_eq(ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_vec3_normalize(ptr noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_rotate_make(ptr noundef, float noundef, ptr noundef) local_unnamed_addr #2

declare { ptr, i32 } @test_assert_vec4_eq(ptr noundef, ptr noundef) local_unnamed_addr #4

declare { ptr, i32 } @test_assert_mat4_eq(ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat(ptr noundef, float noundef, float noundef, float noundef, float noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat_axis(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden float @glm_quat_angle(ptr noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_mat4_quat(ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_mat4_transpose(ptr noundef) local_unnamed_addr #2

declare { ptr, i32 } @test_assert_mat4_eq2(ptr noundef, ptr noundef, float noundef) local_unnamed_addr #4

declare void @test_rand_quat(ptr noundef) local_unnamed_addr #4

declare { ptr, i32 } @test_assert_quat_eq_abs(ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: nounwind uwtable
define dso_local { ptr, i32 } @test_glm_quat_mat4t() local_unnamed_addr #5 {
  %1 = alloca [4 x [4 x float]], align 16
  %2 = alloca [4 x [4 x float]], align 16
  %3 = alloca [4 x float], align 16
  %4 = alloca [4 x float], align 16
  %5 = alloca [4 x float], align 16
  %6 = alloca [3 x float], align 4
  %7 = alloca [3 x float], align 4
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %1) #6
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %4) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %6) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #6
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) @__const.test_glm_quat_mat4t.axis2, i64 12, i1 false)
  call void @glm_quat(ptr noundef nonnull %3, float noundef 0x3FE921FB60000000, float noundef 0x3FFE666660000000, float noundef 0x4002666660000000, float noundef 4.500000e+00)
  call void @glm_quat_mat4t(ptr noundef nonnull %3, ptr noundef nonnull %1)
  call void @glm_mat4_transpose(ptr noundef nonnull %1)
  call void @glm_mat4_quat(ptr noundef nonnull %1, ptr noundef nonnull %4)
  call void @glm_rotate_make(ptr noundef nonnull %2, float noundef 0x3FE921FB60000000, ptr noundef nonnull %7)
  call void @glm_mat4_quat(ptr noundef nonnull %1, ptr noundef nonnull %5)
  call void @glm_quat_axis(ptr noundef nonnull %5, ptr noundef nonnull %6)
  call void @glm_vec3_normalize(ptr noundef nonnull %6)
  call void @glm_vec3_normalize(ptr noundef nonnull %7)
  %8 = call float @glm_quat_angle(ptr noundef nonnull %5)
  %9 = call zeroext i1 @test_eq(float noundef %8, float noundef 0x3FE921FB60000000)
  br i1 %9, label %13, label %10

10:                                               ; preds = %0
  %11 = load ptr, ptr @stderr, align 8, !tbaa !5
  %12 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %11, ptr noundef nonnull @.str, ptr noundef nonnull @.str.787, i32 noundef 571, ptr noundef nonnull @.str.681) #7
  br label %.loopexit

13:                                               ; preds = %0
  %14 = call { ptr, i32 } @test_assert_vec3_eq(ptr noundef nonnull %6, ptr noundef nonnull %7) #6
  %15 = extractvalue { ptr, i32 } %14, 1
  %.not = icmp eq i32 %15, 1
  br i1 %.not, label %.critedge, label %16

16:                                               ; preds = %13
  %17 = extractvalue { ptr, i32 } %14, 0
  %18 = load ptr, ptr @stderr, align 8, !tbaa !5
  %19 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %18, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 572, ptr noundef nonnull @.str.682) #7
  br label %.loopexit

.critedge:                                        ; preds = %13
  %20 = call { ptr, i32 } @test_assert_vec4_eq(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %21 = extractvalue { ptr, i32 } %20, 1
  %.not47 = icmp eq i32 %21, 1
  br i1 %.not47, label %26, label %22

22:                                               ; preds = %.critedge
  %23 = extractvalue { ptr, i32 } %20, 0
  %24 = load ptr, ptr @stderr, align 8, !tbaa !5
  %25 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %24, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 573, ptr noundef nonnull @.str.683) #7
  br label %.loopexit

26:                                               ; preds = %.critedge
  %27 = call { ptr, i32 } @test_assert_mat4_eq(ptr noundef nonnull %1, ptr noundef nonnull %2) #6
  %28 = extractvalue { ptr, i32 } %27, 1
  %.not48 = icmp eq i32 %28, 1
  br i1 %.not48, label %33, label %29

29:                                               ; preds = %26
  %30 = extractvalue { ptr, i32 } %27, 0
  %31 = load ptr, ptr @stderr, align 8, !tbaa !5
  %32 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %31, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 574, ptr noundef nonnull @.str.728) #7
  br label %.loopexit

33:                                               ; preds = %26
  %34 = call { ptr, i32 } @test_assert_vec4_eq(ptr noundef nonnull %3, ptr noundef nonnull %5) #6
  %35 = extractvalue { ptr, i32 } %34, 1
  %.not49 = icmp eq i32 %35, 1
  br i1 %.not49, label %.preheader, label %.thread57

.thread57:                                        ; preds = %33
  %36 = extractvalue { ptr, i32 } %34, 0
  %37 = load ptr, ptr @stderr, align 8, !tbaa !5
  %38 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %37, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 575, ptr noundef nonnull @.str.685) #7
  br label %.loopexit

39:                                               ; preds = %47
  %40 = add nuw nsw i32 %.067, 1
  %exitcond.not = icmp eq i32 %40, 1000
  br i1 %exitcond.not, label %.loopexit, label %.preheader, !llvm.loop !9

.preheader:                                       ; preds = %33, %39
  %.067 = phi i32 [ %40, %39 ], [ 0, %33 ]
  call void @test_rand_quat(ptr noundef nonnull %3) #6
  call void @glm_quat_mat4t(ptr noundef nonnull %3, ptr noundef nonnull %1)
  call void @glm_mat4_transpose(ptr noundef nonnull %1)
  call void @glm_mat4_quat(ptr noundef nonnull %1, ptr noundef nonnull %4)
  call void @glm_quat_mat4t(ptr noundef nonnull %4, ptr noundef nonnull %2)
  call void @glm_mat4_transpose(ptr noundef nonnull %2)
  %41 = call { ptr, i32 } @test_assert_quat_eq_abs(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %42 = extractvalue { ptr, i32 } %41, 1
  %.not50 = icmp eq i32 %42, 1
  br i1 %.not50, label %47, label %43

43:                                               ; preds = %.preheader
  %44 = extractvalue { ptr, i32 } %41, 0
  %45 = load ptr, ptr @stderr, align 8, !tbaa !5
  %46 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %45, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 590, ptr noundef nonnull @.str.863) #7
  br label %.loopexit

47:                                               ; preds = %.preheader
  %48 = call { ptr, i32 } @test_assert_mat4_eq2(ptr noundef nonnull %1, ptr noundef nonnull %2, float noundef 0x3EE2DFD6A0000000) #6
  %49 = extractvalue { ptr, i32 } %48, 1
  %.not51 = icmp eq i32 %49, 1
  br i1 %.not51, label %39, label %50

50:                                               ; preds = %47
  %51 = extractvalue { ptr, i32 } %48, 0
  %52 = load ptr, ptr @stderr, align 8, !tbaa !5
  %53 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %52, ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.787, i32 noundef 594, ptr noundef nonnull @.str.864) #7
  br label %.loopexit

.loopexit:                                        ; preds = %39, %50, %43, %.thread57, %29, %22, %16, %10
  %.sroa.045.7 = phi ptr [ %51, %50 ], [ %44, %43 ], [ %30, %29 ], [ %23, %22 ], [ %17, %16 ], [ null, %10 ], [ %36, %.thread57 ], [ null, %39 ]
  %.sroa.9.7 = phi i32 [ 0, %50 ], [ 0, %43 ], [ 0, %29 ], [ 0, %22 ], [ 0, %16 ], [ 0, %10 ], [ 0, %.thread57 ], [ 1, %39 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %2) #6
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %1) #6
  %.fca.0.insert = insertvalue { ptr, i32 } poison, ptr %.sroa.045.7, 0
  %.fca.1.insert = insertvalue { ptr, i32 } %.fca.0.insert, i32 %.sroa.9.7, 1
  ret { ptr, i32 } %.fca.1.insert
}

; Function Attrs: alwaysinline nounwind uwtable
declare hidden void @glm_quat_mat4t(ptr noundef, ptr noundef) local_unnamed_addr #2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass