#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 double GLfloat;

/* Variables and functions */
int /*<<< orphan*/ GL_DEPTH_TEST;
int /*<<< orphan*/ GL_DIFFUSE;
int /*<<< orphan*/ GL_LESS;
int /*<<< orphan*/ GL_LIGHT0;
int /*<<< orphan*/ GL_LIGHT1;
int /*<<< orphan*/ GL_LIGHTING;
int /*<<< orphan*/ GL_LIGHT_MODEL_AMBIENT;
int /*<<< orphan*/ GL_LINEAR_ATTENUATION;
int /*<<< orphan*/ GL_MODELVIEW;
int /*<<< orphan*/ GL_NORMALIZE;
int /*<<< orphan*/ GL_POSITION;
int /*<<< orphan*/ GL_PROJECTION;
int /*<<< orphan*/ GL_SPECULAR;
int /*<<< orphan*/ glDepthFunc(int /*<<< orphan*/);
int /*<<< orphan*/ glEnable(int /*<<< orphan*/);
int /*<<< orphan*/ glFlush();
int /*<<< orphan*/ glLightModelfv(int /*<<< orphan*/, double *);
int /*<<< orphan*/ glLightf(int /*<<< orphan*/, int /*<<< orphan*/, double);
int /*<<< orphan*/ glLightfv(int /*<<< orphan*/, int /*<<< orphan*/, double *);
int /*<<< orphan*/ glLoadIdentity();
int /*<<< orphan*/ glMatrixMode(int /*<<< orphan*/);
void myglInit(void) {
  GLfloat light0_position[] = {1.0, 0.2, 1.0, 0.0};
  GLfloat light1_position[] = {0.0, 0.0, 0.0, 1.0};
  GLfloat light1_diffuse[] = {1.0, 1.0, 1.0, 1.0};
  GLfloat light1_specular[] = {1.0, 1.0, 1.0, 1.0};
  GLfloat lm_ambient[] = {0.2, 0.2, 0.2, 1.0};
  glEnable(GL_NORMALIZE);
  glMatrixMode(GL_PROJECTION);
  glLoadIdentity();
  glMatrixMode(GL_MODELVIEW);
  glLoadIdentity();
  glLightfv(GL_LIGHT0, GL_POSITION, light0_position);
  glLightfv(GL_LIGHT1, GL_POSITION, light1_position);
  glLightfv(GL_LIGHT1, GL_DIFFUSE, light1_diffuse);
  glLightfv(GL_LIGHT1, GL_SPECULAR, light1_specular);
  glLightf(GL_LIGHT1, GL_LINEAR_ATTENUATION, 0.2);
  glLightModelfv(GL_LIGHT_MODEL_AMBIENT, lm_ambient);
  glEnable(GL_LIGHTING);
  glEnable(GL_LIGHT0);
  glEnable(GL_LIGHT1);
  glDepthFunc(GL_LESS);
  glEnable(GL_DEPTH_TEST);
  glFlush();
}


x86 assembly (clang, -O0):
<myglInit>:
push   %rbp
mov    %rsp,%rbp
sub    $0xa0,%rsp
mov    0xe7e(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xe7b(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    0xe78(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    0xe75(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    0xe72(%rip),%rax
mov    %rax,-0x40(%rbp)
mov    0xe6f(%rip),%rax
mov    %rax,-0x38(%rbp)
mov    0xe6c(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xe69(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xe66(%rip),%rax
mov    %rax,-0x60(%rbp)
mov    0xe63(%rip),%rax
mov    %rax,-0x58(%rbp)
mov    0xe60(%rip),%rax
mov    %rax,-0x50(%rbp)
mov    0xe5d(%rip),%rax
mov    %rax,-0x48(%rbp)
mov    0xe3a(%rip),%rax
mov    %rax,-0x80(%rbp)
mov    0xe37(%rip),%rax
mov    %rax,-0x78(%rbp)
mov    0xe34(%rip),%rax
mov    %rax,-0x70(%rbp)
mov    0xe31(%rip),%rax
mov    %rax,-0x68(%rbp)
mov    0xe2e(%rip),%rax
mov    %rax,-0xa0(%rbp)
mov    0xe28(%rip),%rax
mov    %rax,-0x98(%rbp)
mov    0xe22(%rip),%rax
mov    %rax,-0x90(%rbp)
mov    0xe1c(%rip),%rax
mov    %rax,-0x88(%rbp)
mov    0x2d3e(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    0x2d20(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
mov    $0x0,%al
call   1080 <glLoadIdentity@plt>
mov    0x2d33(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
mov    $0x0,%al
call   1080 <glLoadIdentity@plt>
mov    0x2d26(%rip),%rax
mov    (%rax),%edi
mov    0x2d05(%rip),%rax
mov    (%rax),%esi
lea    -0x20(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2cbb(%rip),%rax
mov    (%rax),%edi
mov    0x2cea(%rip),%rax
mov    (%rax),%esi
lea    -0x40(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2ca0(%rip),%rax
mov    (%rax),%edi
mov    0x2ca7(%rip),%rax
mov    (%rax),%esi
lea    -0x60(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2c85(%rip),%rax
mov    (%rax),%edi
mov    0x2ce4(%rip),%rax
mov    (%rax),%esi
lea    -0x80(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2c6a(%rip),%rax
mov    (%rax),%edi
mov    0x2c89(%rip),%rax
mov    (%rax),%esi
movsd  0xccf(%rip),%xmm0
call   10a0 <glLightf@plt>
mov    0x2ca3(%rip),%rax
mov    (%rax),%edi
lea    -0xa0(%rbp),%rsi
call   1050 <glLightModelfv@plt>
mov    0x2c4e(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    0x2c78(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    0x2c1a(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    0x2bfc(%rip),%rax
mov    (%rax),%edi
call   1070 <glDepthFunc@plt>
mov    0x2c06(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    $0x0,%al
call   1090 <glFlush@plt>
add    $0xa0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<myglInit>:
push   %r15
push   %r14
push   %rbx
sub    $0xa0,%rsp
movaps 0xe8d(%rip),%xmm0
movaps %xmm0,0x90(%rsp)
movaps 0xe6e(%rip),%xmm0
movaps %xmm0,0x80(%rsp)
movaps 0xe8f(%rip),%xmm0
movaps %xmm0,0x70(%rsp)
movaps 0xe73(%rip),%xmm0
movaps %xmm0,0x60(%rsp)
movaps 0xe97(%rip),%xmm0
movaps %xmm0,0x50(%rsp)
movaps 0xe7b(%rip),%xmm1
movaps %xmm1,0x40(%rsp)
movaps %xmm0,0x30(%rsp)
movaps %xmm1,0x20(%rsp)
movaps 0xe95(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xe79(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    0x2db6(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    0x2d98(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
xor    %eax,%eax
call   1080 <glLoadIdentity@plt>
mov    0x2dab(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
xor    %eax,%eax
call   1080 <glLoadIdentity@plt>
mov    0x2d9e(%rip),%r14
mov    (%r14),%edi
mov    0x2d7c(%rip),%rbx
mov    (%rbx),%esi
lea    0x80(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    0x2d2e(%rip),%r15
mov    (%r15),%edi
mov    (%rbx),%esi
lea    0x60(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    (%r15),%edi
mov    0x2d25(%rip),%rax
mov    (%rax),%esi
lea    0x40(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    (%r15),%edi
mov    0x2d67(%rip),%rax
mov    (%rax),%esi
lea    0x20(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    (%r15),%edi
mov    0x2d11(%rip),%rax
mov    (%rax),%esi
movsd  0xd57(%rip),%xmm0
call   10a0 <glLightf@plt>
mov    0x2d2b(%rip),%rax
mov    (%rax),%edi
mov    %rsp,%rsi
call   1050 <glLightModelfv@plt>
mov    0x2cda(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
mov    (%r14),%edi
call   1060 <glEnable@plt>
mov    (%r15),%edi
call   1060 <glEnable@plt>
mov    0x2c94(%rip),%rax
mov    (%rax),%edi
call   1070 <glDepthFunc@plt>
mov    0x2c9e(%rip),%rax
mov    (%rax),%edi
call   1060 <glEnable@plt>
xor    %eax,%eax
call   1090 <glFlush@plt>
add    $0xa0,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@__const.myglInit.light0_position = [4 x double] [double 1.000000e+00, double 2.000000e-01, double 1.000000e+00, double 0.000000e+00]
@__const.myglInit.light1_position = [4 x double] [double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 1.000000e+00]
@__const.myglInit.light1_diffuse = [4 x double] [double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00]
@__const.myglInit.light1_specular = [4 x double] [double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00]
@__const.myglInit.lm_ambient = [4 x double] [double 2.000000e-01, double 2.000000e-01, double 2.000000e-01, double 1.000000e+00]
@GL_NORMALIZE = global i32 0
@GL_PROJECTION = global i32 0
@GL_MODELVIEW = global i32 0
@GL_LIGHT0 = global i32 0
@GL_POSITION = global i32 0
@GL_LIGHT1 = global i32 0
@GL_DIFFUSE = global i32 0
@GL_SPECULAR = global i32 0
@GL_LINEAR_ATTENUATION = global i32 0
@GL_LIGHT_MODEL_AMBIENT = global i32 0
@GL_LIGHTING = global i32 0
@GL_LESS = global i32 0
@GL_DEPTH_TEST = global i32 0
define void @myglInit() {
%1 = alloca [4 x double]
%2 = alloca [4 x double]
%3 = alloca [4 x double]
%4 = alloca [4 x double]
%5 = alloca [4 x double]
%6 = bitcast [4 x double]* %1 to i8*
%7 = bitcast [4 x double]* %2 to i8*
%8 = bitcast [4 x double]* %3 to i8*
%9 = bitcast [4 x double]* %4 to i8*
%10 = bitcast [4 x double]* %5 to i8*
%11 = load i32, i32* @GL_NORMALIZE
%12 = call i32 @glEnable(i32 %11)
%13 = load i32, i32* @GL_PROJECTION
%14 = call i32 @glMatrixMode(i32 %13)
%15 = call i32 (...) @glLoadIdentity()
%16 = load i32, i32* @GL_MODELVIEW
%17 = call i32 @glMatrixMode(i32 %16)
%18 = call i32 (...) @glLoadIdentity()
%19 = load i32, i32* @GL_LIGHT0
%20 = load i32, i32* @GL_POSITION
%21 = getelementptr inbounds [4 x double], [4 x double]* %1, i64 0, i64 0
%22 = call i32 @glLightfv(i32 %19, i32 %20, double* %21)
%23 = load i32, i32* @GL_LIGHT1
%24 = load i32, i32* @GL_POSITION
%25 = getelementptr inbounds [4 x double], [4 x double]* %2, i64 0, i64 0
%26 = call i32 @glLightfv(i32 %23, i32 %24, double* %25)
%27 = load i32, i32* @GL_LIGHT1
%28 = load i32, i32* @GL_DIFFUSE
%29 = getelementptr inbounds [4 x double], [4 x double]* %3, i64 0, i64 0
%30 = call i32 @glLightfv(i32 %27, i32 %28, double* %29)
%31 = load i32, i32* @GL_LIGHT1
%32 = load i32, i32* @GL_SPECULAR
%33 = getelementptr inbounds [4 x double], [4 x double]* %4, i64 0, i64 0
%34 = call i32 @glLightfv(i32 %31, i32 %32, double* %33)
%35 = load i32, i32* @GL_LIGHT1
%36 = load i32, i32* @GL_LINEAR_ATTENUATION
%37 = call i32 @glLightf(i32 %35, i32 %36, double 2.000000e-01)
%38 = load i32, i32* @GL_LIGHT_MODEL_AMBIENT
%39 = getelementptr inbounds [4 x double], [4 x double]* %5, i64 0, i64 0
%40 = call i32 @glLightModelfv(i32 %38, double* %39)
%41 = load i32, i32* @GL_LIGHTING
%42 = call i32 @glEnable(i32 %41)
%43 = load i32, i32* @GL_LIGHT0
%44 = call i32 @glEnable(i32 %43)
%45 = load i32, i32* @GL_LIGHT1
%46 = call i32 @glEnable(i32 %45)
%47 = load i32, i32* @GL_LESS
%48 = call i32 @glDepthFunc(i32 %47)
%49 = load i32, i32* @GL_DEPTH_TEST
%50 = call i32 @glEnable(i32 %49)
%51 = call i32 (...) @glFlush()
ret void
}

LLVM IR (-O2):
@__const.myglInit.light0_position = [4 x double] [double 1.000000e+00, double 2.000000e-01, double 1.000000e+00, double 0.000000e+00]
@__const.myglInit.light1_position = [4 x double] [double 0.000000e+00, double 0.000000e+00, double 0.000000e+00, double 1.000000e+00]
@__const.myglInit.light1_specular = [4 x double] [double 1.000000e+00, double 1.000000e+00, double 1.000000e+00, double 1.000000e+00]
@__const.myglInit.lm_ambient = [4 x double] [double 2.000000e-01, double 2.000000e-01, double 2.000000e-01, double 1.000000e+00]
@GL_NORMALIZE = global i32 0
@GL_PROJECTION = global i32 0
@GL_MODELVIEW = global i32 0
@GL_LIGHT0 = global i32 0
@GL_POSITION = global i32 0
@GL_LIGHT1 = global i32 0
@GL_DIFFUSE = global i32 0
@GL_SPECULAR = global i32 0
@GL_LINEAR_ATTENUATION = global i32 0
@GL_LIGHT_MODEL_AMBIENT = global i32 0
@GL_LIGHTING = global i32 0
@GL_LESS = global i32 0
@GL_DEPTH_TEST = global i32 0
define void @myglInit() {
%1 = alloca [4 x double]
%2 = alloca [4 x double]
%3 = alloca [4 x double]
%4 = alloca [4 x double]
%5 = alloca [4 x double]
%6 = bitcast [4 x double]* %1 to i8*
%7 = bitcast [4 x double]* %2 to i8*
%8 = bitcast [4 x double]* %3 to i8*
%9 = bitcast [4 x double]* %4 to i8*
%10 = bitcast [4 x double]* %5 to i8*
%11 = load i32, i32* @GL_NORMALIZE
%12 = tail call i32 @glEnable(i32 %11)
%13 = load i32, i32* @GL_PROJECTION
%14 = tail call i32 @glMatrixMode(i32 %13)
%15 = tail call i32 (...) @glLoadIdentity()
%16 = load i32, i32* @GL_MODELVIEW
%17 = tail call i32 @glMatrixMode(i32 %16)
%18 = tail call i32 (...) @glLoadIdentity()
%19 = load i32, i32* @GL_LIGHT0
%20 = load i32, i32* @GL_POSITION
%21 = getelementptr inbounds [4 x double], [4 x double]* %1, i64 0, i64 0
%22 = call i32 @glLightfv(i32 %19, i32 %20, double* %21)
%23 = load i32, i32* @GL_LIGHT1
%24 = load i32, i32* @GL_POSITION
%25 = getelementptr inbounds [4 x double], [4 x double]* %2, i64 0, i64 0
%26 = call i32 @glLightfv(i32 %23, i32 %24, double* %25)
%27 = load i32, i32* @GL_LIGHT1
%28 = load i32, i32* @GL_DIFFUSE
%29 = getelementptr inbounds [4 x double], [4 x double]* %3, i64 0, i64 0
%30 = call i32 @glLightfv(i32 %27, i32 %28, double* %29)
%31 = load i32, i32* @GL_LIGHT1
%32 = load i32, i32* @GL_SPECULAR
%33 = getelementptr inbounds [4 x double], [4 x double]* %4, i64 0, i64 0
%34 = call i32 @glLightfv(i32 %31, i32 %32, double* %33)
%35 = load i32, i32* @GL_LIGHT1
%36 = load i32, i32* @GL_LINEAR_ATTENUATION
%37 = call i32 @glLightf(i32 %35, i32 %36, double 2.000000e-01)
%38 = load i32, i32* @GL_LIGHT_MODEL_AMBIENT
%39 = getelementptr inbounds [4 x double], [4 x double]* %5, i64 0, i64 0
%40 = call i32 @glLightModelfv(i32 %38, double* %39)
%41 = load i32, i32* @GL_LIGHTING
%42 = call i32 @glEnable(i32 %41)
%43 = load i32, i32* @GL_LIGHT0
%44 = call i32 @glEnable(i32 %43)
%45 = load i32, i32* @GL_LIGHT1
%46 = call i32 @glEnable(i32 %45)
%47 = load i32, i32* @GL_LESS
%48 = call i32 @glDepthFunc(i32 %47)
%49 = load i32, i32* @GL_DEPTH_TEST
%50 = call i32 @glEnable(i32 %49)
%51 = call i32 (...) @glFlush()
ret void
}