#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*/ rotate(double *, double, double *);
int /*<<< orphan*/ simetric(double *, double *);
int /*<<< orphan*/ translate(double *, double *, double *);
double *rotate_p(double *p, double rad, double *origin, double *s,
                 double *aux) {
  simetric(origin, aux);
  translate(p, aux, s);
  rotate(s, rad, aux);
  translate(aux, origin, s);
  return s;
}


x86 assembly (clang, -O0):
<rotate_p>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1030 <simetric@plt>
mov    -0x8(%rbp),%rdi
mov    -0x28(%rbp),%rsi
mov    -0x20(%rbp),%rdx
call   1050 <translate@plt>
mov    -0x20(%rbp),%rdi
movsd  -0x10(%rbp),%xmm0
mov    -0x28(%rbp),%rsi
call   1040 <rotate@plt>
mov    -0x28(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x20(%rbp),%rdx
call   1050 <translate@plt>
mov    -0x20(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<rotate_p>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %rcx,%rbx
mov    %rdx,%r14
mov    %rsi,%r15
movsd  %xmm0,(%rsp)
mov    %rdi,%r12
mov    %rsi,%rdi
mov    %rcx,%rsi
call   1030 <simetric@plt>
mov    %r12,%rdi
mov    %rbx,%rsi
mov    %r14,%rdx
call   1050 <translate@plt>
mov    %r14,%rdi
movsd  (%rsp),%xmm0
mov    %rbx,%rsi
call   1040 <rotate@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    %r14,%rdx
call   1050 <translate@plt>
mov    %r14,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define double* @rotate_p(double* %0, double %1, double* %2, double* %3, double* %4) {
%6 = alloca double*
%7 = alloca double
%8 = alloca double*
%9 = alloca double*
%10 = alloca double*
store double* %0, double** %6
store double %1, double* %7
store double* %2, double** %8
store double* %3, double** %9
store double* %4, double** %10
%11 = load double*, double** %8
%12 = load double*, double** %10
%13 = call i32 @simetric(double* %11, double* %12)
%14 = load double*, double** %6
%15 = load double*, double** %10
%16 = load double*, double** %9
%17 = call i32 @translate(double* %14, double* %15, double* %16)
%18 = load double*, double** %9
%19 = load double, double* %7
%20 = load double*, double** %10
%21 = call i32 @rotate(double* %18, double %19, double* %20)
%22 = load double*, double** %10
%23 = load double*, double** %8
%24 = load double*, double** %9
%25 = call i32 @translate(double* %22, double* %23, double* %24)
%26 = load double*, double** %9
ret double* %26
}

LLVM IR (-O2):
define double* @rotate_p(double* %0, double %1, double* %2, double* returned %3, double* %4) {
%6 = tail call i32 @simetric(double* %2, double* %4)
%7 = tail call i32 @translate(double* %0, double* %4, double* %3)
%8 = tail call i32 @rotate(double* %3, double %1, double* %4)
%9 = tail call i32 @translate(double* %4, double* %2, double* %3)
ret double* %3
}