#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ normalize3d(double *);
int /*<<< orphan*/ normalize3dp(double *, double *, double *);
void recondition33d(double *matrix) {
  normalize3d(matrix);
  normalize3d(matrix + 3);
  normalize3d(matrix + 6);
  normalize3dp(matrix + 0, matrix + 3, matrix + 6);
  normalize3dp(matrix + 1, matrix + 4, matrix + 7);
  normalize3dp(matrix + 2, matrix + 5, matrix + 8);
  normalize3d(matrix);
  normalize3d(matrix + 3);
  normalize3d(matrix + 6);
  normalize3dp(matrix + 0, matrix + 3, matrix + 6);
  normalize3dp(matrix + 1, matrix + 4, matrix + 7);
  normalize3dp(matrix + 2, matrix + 5, matrix + 8);
  normalize3d(matrix);
  normalize3d(matrix + 3);
  normalize3d(matrix + 6);
}


x86 assembly (clang, -O0):
<recondition33d>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x18,%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x30,%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x18,%rsi
mov    -0x8(%rbp),%rdx
add    $0x30,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
add    $0x8,%rdi
mov    -0x8(%rbp),%rsi
add    $0x20,%rsi
mov    -0x8(%rbp),%rdx
add    $0x38,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
add    $0x10,%rdi
mov    -0x8(%rbp),%rsi
add    $0x28,%rsi
mov    -0x8(%rbp),%rdx
add    $0x40,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x18,%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x30,%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rsi
add    $0x18,%rsi
mov    -0x8(%rbp),%rdx
add    $0x30,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
add    $0x8,%rdi
mov    -0x8(%rbp),%rsi
add    $0x20,%rsi
mov    -0x8(%rbp),%rdx
add    $0x38,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
add    $0x10,%rdi
mov    -0x8(%rbp),%rsi
add    $0x28,%rsi
mov    -0x8(%rbp),%rdx
add    $0x40,%rdx
call   1040 <normalize3dp@plt>
mov    -0x8(%rbp),%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x18,%rdi
call   1030 <normalize3d@plt>
mov    -0x8(%rbp),%rdi
add    $0x30,%rdi
call   1030 <normalize3d@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<recondition33d>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rdi,%rbx
call   1030 <normalize3d@plt>
lea    0x18(%rbx),%r14
mov    %r14,%rdi
call   1030 <normalize3d@plt>
lea    0x30(%rbx),%r15
mov    %r15,%rdi
call   1030 <normalize3d@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %r15,%rdx
call   1040 <normalize3dp@plt>
lea    0x8(%rbx),%rdi
mov    %rdi,0x10(%rsp)
lea    0x20(%rbx),%rsi
mov    %rsi,0x8(%rsp)
lea    0x38(%rbx),%rdx
mov    %rdx,(%rsp)
call   1040 <normalize3dp@plt>
lea    0x10(%rbx),%r12
lea    0x28(%rbx),%r13
lea    0x40(%rbx),%rbp
mov    %r12,%rdi
mov    %r13,%rsi
mov    %rbp,%rdx
call   1040 <normalize3dp@plt>
mov    %rbx,%rdi
call   1030 <normalize3d@plt>
mov    %r14,%rdi
call   1030 <normalize3d@plt>
mov    %r15,%rdi
call   1030 <normalize3d@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %r15,%rdx
call   1040 <normalize3dp@plt>
mov    0x10(%rsp),%rdi
mov    0x8(%rsp),%rsi
mov    (%rsp),%rdx
call   1040 <normalize3dp@plt>
mov    %r12,%rdi
mov    %r13,%rsi
mov    %rbp,%rdx
call   1040 <normalize3dp@plt>
mov    %rbx,%rdi
call   1030 <normalize3d@plt>
mov    %r14,%rdi
call   1030 <normalize3d@plt>
mov    %r15,%rdi
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <normalize3d@plt>

LLVM IR (-O0):
define void @recondition33d(double* %0) {
%2 = alloca double*
store double* %0, double** %2
%3 = load double*, double** %2
%4 = call i32 @normalize3d(double* %3)
%5 = load double*, double** %2
%6 = getelementptr inbounds double, double* %5, i64 3
%7 = call i32 @normalize3d(double* %6)
%8 = load double*, double** %2
%9 = getelementptr inbounds double, double* %8, i64 6
%10 = call i32 @normalize3d(double* %9)
%11 = load double*, double** %2
%12 = getelementptr inbounds double, double* %11, i64 0
%13 = load double*, double** %2
%14 = getelementptr inbounds double, double* %13, i64 3
%15 = load double*, double** %2
%16 = getelementptr inbounds double, double* %15, i64 6
%17 = call i32 @normalize3dp(double* %12, double* %14, double* %16)
%18 = load double*, double** %2
%19 = getelementptr inbounds double, double* %18, i64 1
%20 = load double*, double** %2
%21 = getelementptr inbounds double, double* %20, i64 4
%22 = load double*, double** %2
%23 = getelementptr inbounds double, double* %22, i64 7
%24 = call i32 @normalize3dp(double* %19, double* %21, double* %23)
%25 = load double*, double** %2
%26 = getelementptr inbounds double, double* %25, i64 2
%27 = load double*, double** %2
%28 = getelementptr inbounds double, double* %27, i64 5
%29 = load double*, double** %2
%30 = getelementptr inbounds double, double* %29, i64 8
%31 = call i32 @normalize3dp(double* %26, double* %28, double* %30)
%32 = load double*, double** %2
%33 = call i32 @normalize3d(double* %32)
%34 = load double*, double** %2
%35 = getelementptr inbounds double, double* %34, i64 3
%36 = call i32 @normalize3d(double* %35)
%37 = load double*, double** %2
%38 = getelementptr inbounds double, double* %37, i64 6
%39 = call i32 @normalize3d(double* %38)
%40 = load double*, double** %2
%41 = getelementptr inbounds double, double* %40, i64 0
%42 = load double*, double** %2
%43 = getelementptr inbounds double, double* %42, i64 3
%44 = load double*, double** %2
%45 = getelementptr inbounds double, double* %44, i64 6
%46 = call i32 @normalize3dp(double* %41, double* %43, double* %45)
%47 = load double*, double** %2
%48 = getelementptr inbounds double, double* %47, i64 1
%49 = load double*, double** %2
%50 = getelementptr inbounds double, double* %49, i64 4
%51 = load double*, double** %2
%52 = getelementptr inbounds double, double* %51, i64 7
%53 = call i32 @normalize3dp(double* %48, double* %50, double* %52)
%54 = load double*, double** %2
%55 = getelementptr inbounds double, double* %54, i64 2
%56 = load double*, double** %2
%57 = getelementptr inbounds double, double* %56, i64 5
%58 = load double*, double** %2
%59 = getelementptr inbounds double, double* %58, i64 8
%60 = call i32 @normalize3dp(double* %55, double* %57, double* %59)
%61 = load double*, double** %2
%62 = call i32 @normalize3d(double* %61)
%63 = load double*, double** %2
%64 = getelementptr inbounds double, double* %63, i64 3
%65 = call i32 @normalize3d(double* %64)
%66 = load double*, double** %2
%67 = getelementptr inbounds double, double* %66, i64 6
%68 = call i32 @normalize3d(double* %67)
ret void
}

LLVM IR (-O2):
define void @recondition33d(double* %0) {
%2 = tail call i32 @normalize3d(double* %0)
%3 = getelementptr inbounds double, double* %0, i64 3
%4 = tail call i32 @normalize3d(double* %3)
%5 = getelementptr inbounds double, double* %0, i64 6
%6 = tail call i32 @normalize3d(double* %5)
%7 = tail call i32 @normalize3dp(double* %0, double* %3, double* %5)
%8 = getelementptr inbounds double, double* %0, i64 1
%9 = getelementptr inbounds double, double* %0, i64 4
%10 = getelementptr inbounds double, double* %0, i64 7
%11 = tail call i32 @normalize3dp(double* %8, double* %9, double* %10)
%12 = getelementptr inbounds double, double* %0, i64 2
%13 = getelementptr inbounds double, double* %0, i64 5
%14 = getelementptr inbounds double, double* %0, i64 8
%15 = tail call i32 @normalize3dp(double* %12, double* %13, double* %14)
%16 = tail call i32 @normalize3d(double* %0)
%17 = tail call i32 @normalize3d(double* %3)
%18 = tail call i32 @normalize3d(double* %5)
%19 = tail call i32 @normalize3dp(double* %0, double* %3, double* %5)
%20 = tail call i32 @normalize3dp(double* %8, double* %9, double* %10)
%21 = tail call i32 @normalize3dp(double* %12, double* %13, double* %14)
%22 = tail call i32 @normalize3d(double* %0)
%23 = tail call i32 @normalize3d(double* %3)
%24 = tail call i32 @normalize3d(double* %5)
ret void
}