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

/* Variables and functions */
int /*<<< orphan*/ GLUT_CURSOR_NONE;
int /*<<< orphan*/ GL_AMBIENT;
int /*<<< orphan*/ GL_DEPTH_TEST;
int /*<<< orphan*/ GL_DIFFUSE;
int /*<<< orphan*/ GL_LIGHT1;
int /*<<< orphan*/ GL_LIGHTING;
int /*<<< orphan*/ GL_LINE_SMOOTH;
int /*<<< orphan*/ GL_LINE_SMOOTH_HINT;
int /*<<< orphan*/ GL_MODELVIEW;
int /*<<< orphan*/ GL_NICEST;
int /*<<< orphan*/ GL_POLYGON_SMOOTH;
int /*<<< orphan*/ GL_POLYGON_SMOOTH_HINT;
int /*<<< orphan*/ GL_POSITION;
int /*<<< orphan*/ GL_SMOOTH;
int /*<<< orphan*/ GL_TEXTURE_2D;
int /*<<< orphan*/ glEnable(int /*<<< orphan*/);
int /*<<< orphan*/ glHint(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ glLightfv(int /*<<< orphan*/, int /*<<< orphan*/, float *);
int /*<<< orphan*/ glMatrixMode(int /*<<< orphan*/);
int /*<<< orphan*/ glShadeModel(int /*<<< orphan*/);
int /*<<< orphan*/ glutSetCursor(int /*<<< orphan*/);
void settings(void) {
  glMatrixMode(GL_MODELVIEW);
  glEnable(GL_TEXTURE_2D);
  glEnable(GL_LINE_SMOOTH);
  glEnable(GL_POLYGON_SMOOTH);
  glHint(GL_LINE_SMOOTH_HINT, GL_NICEST);
  glHint(GL_POLYGON_SMOOTH_HINT, GL_NICEST);
  glEnable(GL_DEPTH_TEST);
  glShadeModel(GL_SMOOTH);
  glutSetCursor(GLUT_CURSOR_NONE);
  glEnable(GL_LIGHTING);
  GLfloat LightAmbient[] = {1.f, 1.0f, 1.0f, 1.0f};
  GLfloat LightDiffuse[] = {1.0f, 1.0f, 1.0f, 1.0f};
  GLfloat LightPosition[] = {0, 100, 0, 1.0};
  glLightfv(GL_LIGHT1, GL_AMBIENT, LightAmbient);
  glLightfv(GL_LIGHT1, GL_DIFFUSE, LightDiffuse);
  glLightfv(GL_LIGHT1, GL_POSITION, LightPosition);
  glEnable(GL_LIGHT1);
}


x86 assembly (clang, -O0):
<settings>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    0x2e59(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
mov    0x2e3b(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e05(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e17(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e39(%rip),%rax
mov    (%rax),%edi
mov    0x2df0(%rip),%rax
mov    (%rax),%esi
call   1070 <glHint@plt>
mov    0x2e12(%rip),%rax
mov    (%rax),%edi
mov    0x2dd9(%rip),%rax
mov    (%rax),%esi
call   1070 <glHint@plt>
mov    0x2da3(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2d9d(%rip),%rax
mov    (%rax),%edi
call   1080 <glShadeModel@plt>
mov    0x2de7(%rip),%rax
mov    (%rax),%edi
call   1060 <glutSetCursor@plt>
mov    0x2d99(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0xdf3(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    0xdf0(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    0xddd(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xdda(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    0xdd7(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xdd4(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0x2d21(%rip),%rax
mov    (%rax),%edi
mov    0x2d98(%rip),%rax
mov    (%rax),%esi
lea    -0x10(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2d06(%rip),%rax
mov    (%rax),%edi
mov    0x2d15(%rip),%rax
mov    (%rax),%esi
lea    -0x20(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2ceb(%rip),%rax
mov    (%rax),%edi
mov    0x2d1a(%rip),%rax
mov    (%rax),%esi
lea    -0x30(%rbp),%rdx
call   1030 <glLightfv@plt>
mov    0x2cd0(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<settings>:
push   %rbx
sub    $0x30,%rsp
mov    0x2e5c(%rip),%rax
mov    (%rax),%edi
call   1040 <glMatrixMode@plt>
mov    0x2e3e(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e08(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e1a(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2e3c(%rip),%rax
mov    (%rax),%edi
mov    0x2df3(%rip),%rbx
mov    (%rbx),%esi
call   1070 <glHint@plt>
mov    0x2e15(%rip),%rax
mov    (%rax),%edi
mov    (%rbx),%esi
call   1070 <glHint@plt>
mov    0x2dad(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
mov    0x2da7(%rip),%rax
mov    (%rax),%edi
call   1080 <glShadeModel@plt>
mov    0x2df1(%rip),%rax
mov    (%rax),%edi
call   1060 <glutSetCursor@plt>
mov    0x2da3(%rip),%rax
mov    (%rax),%edi
call   1050 <glEnable@plt>
movaps 0xdfd(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movaps %xmm0,0x10(%rsp)
movaps 0xdfc(%rip),%xmm0
movaps %xmm0,(%rsp)
mov    0x2d51(%rip),%rbx
mov    (%rbx),%edi
mov    0x2dc8(%rip),%rax
mov    (%rax),%esi
lea    0x20(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    (%rbx),%edi
mov    0x2d4b(%rip),%rax
mov    (%rax),%esi
lea    0x10(%rsp),%rdx
call   1030 <glLightfv@plt>
mov    (%rbx),%edi
mov    0x2d56(%rip),%rax
mov    (%rax),%esi
mov    %rsp,%rdx
call   1030 <glLightfv@plt>
mov    (%rbx),%edi
call   1050 <glEnable@plt>
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@GL_MODELVIEW = global i32 0
@GL_TEXTURE_2D = global i32 0
@GL_LINE_SMOOTH = global i32 0
@GL_POLYGON_SMOOTH = global i32 0
@GL_LINE_SMOOTH_HINT = global i32 0
@GL_NICEST = global i32 0
@GL_POLYGON_SMOOTH_HINT = global i32 0
@GL_DEPTH_TEST = global i32 0
@GL_SMOOTH = global i32 0
@GLUT_CURSOR_NONE = global i32 0
@GL_LIGHTING = global i32 0
@__const.settings.LightAmbient = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00]
@__const.settings.LightDiffuse = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00]
@__const.settings.LightPosition = [4 x float] [float 0.000000e+00, float 1.000000e+02, float 0.000000e+00, float 1.000000e+00]
@GL_LIGHT1 = global i32 0
@GL_AMBIENT = global i32 0
@GL_DIFFUSE = global i32 0
@GL_POSITION = global i32 0
define void @settings() {
%1 = alloca [4 x float]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = load i32, i32* @GL_MODELVIEW
%5 = call i32 @glMatrixMode(i32 %4)
%6 = load i32, i32* @GL_TEXTURE_2D
%7 = call i32 @glEnable(i32 %6)
%8 = load i32, i32* @GL_LINE_SMOOTH
%9 = call i32 @glEnable(i32 %8)
%10 = load i32, i32* @GL_POLYGON_SMOOTH
%11 = call i32 @glEnable(i32 %10)
%12 = load i32, i32* @GL_LINE_SMOOTH_HINT
%13 = load i32, i32* @GL_NICEST
%14 = call i32 @glHint(i32 %12, i32 %13)
%15 = load i32, i32* @GL_POLYGON_SMOOTH_HINT
%16 = load i32, i32* @GL_NICEST
%17 = call i32 @glHint(i32 %15, i32 %16)
%18 = load i32, i32* @GL_DEPTH_TEST
%19 = call i32 @glEnable(i32 %18)
%20 = load i32, i32* @GL_SMOOTH
%21 = call i32 @glShadeModel(i32 %20)
%22 = load i32, i32* @GLUT_CURSOR_NONE
%23 = call i32 @glutSetCursor(i32 %22)
%24 = load i32, i32* @GL_LIGHTING
%25 = call i32 @glEnable(i32 %24)
%26 = bitcast [4 x float]* %1 to i8*
%27 = bitcast [4 x float]* %2 to i8*
%28 = bitcast [4 x float]* %3 to i8*
%29 = load i32, i32* @GL_LIGHT1
%30 = load i32, i32* @GL_AMBIENT
%31 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%32 = call i32 @glLightfv(i32 %29, i32 %30, float* %31)
%33 = load i32, i32* @GL_LIGHT1
%34 = load i32, i32* @GL_DIFFUSE
%35 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%36 = call i32 @glLightfv(i32 %33, i32 %34, float* %35)
%37 = load i32, i32* @GL_LIGHT1
%38 = load i32, i32* @GL_POSITION
%39 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%40 = call i32 @glLightfv(i32 %37, i32 %38, float* %39)
%41 = load i32, i32* @GL_LIGHT1
%42 = call i32 @glEnable(i32 %41)
ret void
}

LLVM IR (-O2):
@GL_MODELVIEW = global i32 0
@GL_TEXTURE_2D = global i32 0
@GL_LINE_SMOOTH = global i32 0
@GL_POLYGON_SMOOTH = global i32 0
@GL_LINE_SMOOTH_HINT = global i32 0
@GL_NICEST = global i32 0
@GL_POLYGON_SMOOTH_HINT = global i32 0
@GL_DEPTH_TEST = global i32 0
@GL_SMOOTH = global i32 0
@GLUT_CURSOR_NONE = global i32 0
@GL_LIGHTING = global i32 0
@__const.settings.LightDiffuse = [4 x float] [float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00]
@__const.settings.LightPosition = [4 x float] [float 0.000000e+00, float 1.000000e+02, float 0.000000e+00, float 1.000000e+00]
@GL_LIGHT1 = global i32 0
@GL_AMBIENT = global i32 0
@GL_DIFFUSE = global i32 0
@GL_POSITION = global i32 0
define void @settings() {
%1 = alloca [4 x float]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = load i32, i32* @GL_MODELVIEW
%5 = tail call i32 @glMatrixMode(i32 %4)
%6 = load i32, i32* @GL_TEXTURE_2D
%7 = tail call i32 @glEnable(i32 %6)
%8 = load i32, i32* @GL_LINE_SMOOTH
%9 = tail call i32 @glEnable(i32 %8)
%10 = load i32, i32* @GL_POLYGON_SMOOTH
%11 = tail call i32 @glEnable(i32 %10)
%12 = load i32, i32* @GL_LINE_SMOOTH_HINT
%13 = load i32, i32* @GL_NICEST
%14 = tail call i32 @glHint(i32 %12, i32 %13)
%15 = load i32, i32* @GL_POLYGON_SMOOTH_HINT
%16 = load i32, i32* @GL_NICEST
%17 = tail call i32 @glHint(i32 %15, i32 %16)
%18 = load i32, i32* @GL_DEPTH_TEST
%19 = tail call i32 @glEnable(i32 %18)
%20 = load i32, i32* @GL_SMOOTH
%21 = tail call i32 @glShadeModel(i32 %20)
%22 = load i32, i32* @GLUT_CURSOR_NONE
%23 = tail call i32 @glutSetCursor(i32 %22)
%24 = load i32, i32* @GL_LIGHTING
%25 = tail call i32 @glEnable(i32 %24)
%26 = bitcast [4 x float]* %1 to i8*
%27 = bitcast [4 x float]* %2 to i8*
%28 = bitcast [4 x float]* %3 to i8*
%29 = load i32, i32* @GL_LIGHT1
%30 = load i32, i32* @GL_AMBIENT
%31 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%32 = call i32 @glLightfv(i32 %29, i32 %30, float* %31)
%33 = load i32, i32* @GL_LIGHT1
%34 = load i32, i32* @GL_DIFFUSE
%35 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%36 = call i32 @glLightfv(i32 %33, i32 %34, float* %35)
%37 = load i32, i32* @GL_LIGHT1
%38 = load i32, i32* @GL_POSITION
%39 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%40 = call i32 @glLightfv(i32 %37, i32 %38, float* %39)
%41 = load i32, i32* @GL_LIGHT1
%42 = call i32 @glEnable(i32 %41)
ret void
}