#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 */
typedef int /*<<< orphan*/ names;

/* Variables and functions */
double evaluator_evaluate(void *, int, char **, double *);
double evaluator_evaluate_x_y_z(void *evaluator, double x, double y, double z) {
  char *names[] = {"x", "y", "z"};
  double values[3];
  values[0] = x, values[1] = y, values[2] = z;
  return evaluator_evaluate(evaluator, sizeof(names) / sizeof(names[0]), names,
                            values);
}


x86 assembly (clang, -O0):
<evaluator_evaluate_x_y_z>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
movsd  %xmm0,-0x10(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm2,-0x20(%rbp)
mov    0x2cce(%rip),%rax
mov    %rax,-0x40(%rbp)
mov    0x2ccb(%rip),%rax
mov    %rax,-0x38(%rbp)
mov    0x2cc8(%rip),%rax
mov    %rax,-0x30(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0x40(%rbp),%rdx
lea    -0x60(%rbp),%rcx
mov    $0x3,%esi
call   1030 <evaluator_evaluate@plt>
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<evaluator_evaluate_x_y_z>:
sub    $0x38,%rsp
mov    0x2cf5(%rip),%rax
mov    %rax,0x30(%rsp)
movaps 0x2cd9(%rip),%xmm3
movaps %xmm3,0x20(%rsp)
movsd  %xmm0,(%rsp)
movsd  %xmm1,0x8(%rsp)
movsd  %xmm2,0x10(%rsp)
lea    0x20(%rsp),%rdx
mov    %rsp,%rcx
mov    $0x3,%esi
call   1030 <evaluator_evaluate@plt>
add    $0x38,%rsp
ret

LLVM IR (-O0):
@.str = [2 x i8] c"x\00"
@.str.1 = [2 x i8] c"y\00"
@.str.2 = [2 x i8] c"z\00"
@__const.evaluator_evaluate_x_y_z.names = [3 x i8*] [i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i32 0, i32 0)]
define double @evaluator_evaluate_x_y_z(i8* %0, double %1, double %2, double %3) {
%5 = alloca i8*
%6 = alloca double
%7 = alloca double
%8 = alloca double
%9 = alloca [3 x i8*]
%10 = alloca [3 x double]
store i8* %0, i8** %5
store double %1, double* %6
store double %2, double* %7
store double %3, double* %8
%11 = bitcast [3 x i8*]* %9 to i8*
%12 = load double, double* %6
%13 = getelementptr inbounds [3 x double], [3 x double]* %10, i64 0, i64 0
store double %12, double* %13
%14 = load double, double* %7
%15 = getelementptr inbounds [3 x double], [3 x double]* %10, i64 0, i64 1
store double %14, double* %15
%16 = load double, double* %8
%17 = getelementptr inbounds [3 x double], [3 x double]* %10, i64 0, i64 2
store double %16, double* %17
%18 = load i8*, i8** %5
%19 = getelementptr inbounds [3 x i8*], [3 x i8*]* %9, i64 0, i64 0
%20 = getelementptr inbounds [3 x double], [3 x double]* %10, i64 0, i64 0
%21 = call double @evaluator_evaluate(i8* %18, i32 3, i8** %19, double* %20)
ret double %21
}

LLVM IR (-O2):
@.str = [2 x i8] c"x\00"
@.str.1 = [2 x i8] c"y\00"
@.str.2 = [2 x i8] c"z\00"
@__const.evaluator_evaluate_x_y_z.names = [3 x i8*] [i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i32 0, i32 0)]
define double @evaluator_evaluate_x_y_z(i8* %0, double %1, double %2, double %3) {
%5 = alloca [3 x i8*]
%6 = alloca [3 x double]
%7 = bitcast [3 x i8*]* %5 to i8*
%8 = bitcast [3 x double]* %6 to i8*
%9 = getelementptr inbounds [3 x double], [3 x double]* %6, i64 0, i64 0
store double %1, double* %9
%10 = getelementptr inbounds [3 x double], [3 x double]* %6, i64 0, i64 1
store double %2, double* %10
%11 = getelementptr inbounds [3 x double], [3 x double]* %6, i64 0, i64 2
store double %3, double* %11
%12 = getelementptr inbounds [3 x i8*], [3 x i8*]* %5, i64 0, i64 0
%13 = call double @evaluator_evaluate(i8* %0, i32 3, i8** %12, double* %9)
ret double %13
}