#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*/ GL_AMBIENT;
int /*<<< orphan*/ GL_DIFFUSE;
int /*<<< orphan*/ GL_LIGHT0;
int /*<<< orphan*/ GL_POSITION;
int /*<<< orphan*/ GL_SPECULAR;
int /*<<< orphan*/ glLightfv(int /*<<< orphan*/, int /*<<< orphan*/, float *);
void init_light() {
  float position[] = {1, 1, 1, 0};
  glLightfv(GL_LIGHT0, GL_POSITION, position);
  float ambient_color[] = {0.125, 0.125, 0.125, 1};
  glLightfv(GL_LIGHT0, GL_AMBIENT, ambient_color);
  float diffuse_color[] = {1, 1, 1, 1};
  glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuse_color);
  float specular_color[] = {0.75, 0.75, 0.75, 1};
  glLightfv(GL_LIGHT0, GL_SPECULAR, specular_color);
}


x86 assembly (clang, -O0):
<init_light>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    0xee1(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    0xede(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    0x2ea3(%rip),%rax
mov    (%rax),%edi
mov    0x2e8a(%rip),%rax
mov    (%rax),%esi
lea    -0x10(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0xec0(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xebd(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    0x2e72(%rip),%rax
mov    (%rax),%edi
mov    0x2e81(%rip),%rax
mov    (%rax),%esi
lea    -0x20(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0xe9f(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xe9c(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0x2e41(%rip),%rax
mov    (%rax),%edi
mov    0x2e20(%rip),%rax
mov    (%rax),%esi
lea    -0x30(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0xe7e(%rip),%rax
mov    %rax,-0x40(%rbp)
mov    0xe7b(%rip),%rax
mov    %rax,-0x38(%rbp)
mov    0x2e10(%rip),%rax
mov    (%rax),%edi
mov    0x2e17(%rip),%rax
mov    (%rax),%esi
lea    -0x40(%rbp),%rdx
call   1030 <glLightfv@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<init_light>:
push   %rbx
sub    $0x40,%rsp
movaps 0xee4(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
mov    0x2eb0(%rip),%rbx
mov    (%rbx),%edi
mov    0x2e97(%rip),%rax
mov    (%rax),%esi
lea    0x30(%rsp),%rdx
call   1030 <glLightfv@plt>
movaps 0xecc(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
mov    (%rbx),%edi
mov    0x2e9e(%rip),%rax
mov    (%rax),%esi
lea    0x20(%rsp),%rdx
call   1030 <glLightfv@plt>
movaps 0xebb(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
mov    (%rbx),%edi
mov    0x2e4d(%rip),%rax
mov    (%rax),%esi
lea    0x10(%rsp),%rdx
call   1030 <glLightfv@plt>
movaps 0xeaa(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    (%rbx),%edi
mov    0x2e55(%rip),%rax
mov    (%rax),%esi
mov    %rsp,%rdx
call   1030 <glLightfv@plt>
add    $0x40,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.init_light.position = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 0.000000e+00]
@GL_LIGHT0 = global i32 0
@GL_POSITION = global i32 0
@__const.init_light.ambient_color = [4 x float] [float 1.250000e-01, float 1.250000e-01, float 1.250000e-01, float 1.000000e+00]
@GL_AMBIENT = global i32 0
@__const.init_light.diffuse_color = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00]
@GL_DIFFUSE = global i32 0
@__const.init_light.specular_color = [4 x float] [float 7.500000e-01, float 7.500000e-01, float 7.500000e-01, float 1.000000e+00]
@GL_SPECULAR = global i32 0
define void @init_light() {
%1 = alloca [4 x float]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = alloca [4 x float]
%5 = bitcast [4 x float]* %1 to i8*
%6 = load i32, i32* @GL_LIGHT0
%7 = load i32, i32* @GL_POSITION
%8 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%9 = call i32 @glLightfv(i32 %6, i32 %7, float* %8)
%10 = bitcast [4 x float]* %2 to i8*
%11 = load i32, i32* @GL_LIGHT0
%12 = load i32, i32* @GL_AMBIENT
%13 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%14 = call i32 @glLightfv(i32 %11, i32 %12, float* %13)
%15 = bitcast [4 x float]* %3 to i8*
%16 = load i32, i32* @GL_LIGHT0
%17 = load i32, i32* @GL_DIFFUSE
%18 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%19 = call i32 @glLightfv(i32 %16, i32 %17, float* %18)
%20 = bitcast [4 x float]* %4 to i8*
%21 = load i32, i32* @GL_LIGHT0
%22 = load i32, i32* @GL_SPECULAR
%23 = getelementptr inbounds [4 x float], [4 x float]* %4, i64 0, i64 0
%24 = call i32 @glLightfv(i32 %21, i32 %22, float* %23)
ret void
}

LLVM IR (-O2):
@__const.init_light.position = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 0.000000e+00]
@GL_LIGHT0 = global i32 0
@GL_POSITION = global i32 0
@__const.init_light.ambient_color = [4 x float] [float 1.250000e-01, float 1.250000e-01, float 1.250000e-01, float 1.000000e+00]
@GL_AMBIENT = global i32 0
@__const.init_light.diffuse_color = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00]
@GL_DIFFUSE = global i32 0
@__const.init_light.specular_color = [4 x float] [float 7.500000e-01, float 7.500000e-01, float 7.500000e-01, float 1.000000e+00]
@GL_SPECULAR = global i32 0
define void @init_light() {
%1 = alloca [4 x float]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = alloca [4 x float]
%5 = bitcast [4 x float]* %1 to i8*
%6 = load i32, i32* @GL_LIGHT0
%7 = load i32, i32* @GL_POSITION
%8 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%9 = call i32 @glLightfv(i32 %6, i32 %7, float* %8)
%10 = bitcast [4 x float]* %2 to i8*
%11 = load i32, i32* @GL_LIGHT0
%12 = load i32, i32* @GL_AMBIENT
%13 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%14 = call i32 @glLightfv(i32 %11, i32 %12, float* %13)
%15 = bitcast [4 x float]* %3 to i8*
%16 = load i32, i32* @GL_LIGHT0
%17 = load i32, i32* @GL_DIFFUSE
%18 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%19 = call i32 @glLightfv(i32 %16, i32 %17, float* %18)
%20 = bitcast [4 x float]* %4 to i8*
%21 = load i32, i32* @GL_LIGHT0
%22 = load i32, i32* @GL_SPECULAR
%23 = getelementptr inbounds [4 x float], [4 x float]* %4, i64 0, i64 0
%24 = call i32 @glLightfv(i32 %21, i32 %22, float* %23)
ret void
}