#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_QUADS;
int /*<<< orphan*/ glBegin(int /*<<< orphan*/);
int /*<<< orphan*/ glColor3f(double, double, double);
int /*<<< orphan*/ glEnd();
int /*<<< orphan*/ glNormal3f(double, double, double);
int /*<<< orphan*/ glVertex3f(double, double, double);
void drawCube(void) {
  glBegin(GL_QUADS);
  glNormal3f(-1.0, 0.0, 0.0);
  glColor3f(0.80, 0.50, 0.50);
  glVertex3f(-0.5, -0.5, -0.5);
  glVertex3f(-0.5, -0.5, 0.5);
  glVertex3f(-0.5, 0.5, 0.5);
  glVertex3f(-0.5, 0.5, -0.5);
  glNormal3f(1.0, 0.0, 0.0);
  glColor3f(0.50, 0.80, 0.50);
  glVertex3f(0.5, 0.5, 0.5);
  glVertex3f(0.5, -0.5, 0.5);
  glVertex3f(0.5, -0.5, -0.5);
  glVertex3f(0.5, 0.5, -0.5);
  glNormal3f(0.0, -1.0, 0.0);
  glColor3f(0.50, 0.50, 0.80);
  glVertex3f(-0.5, -0.5, -0.5);
  glVertex3f(0.5, -0.5, -0.5);
  glVertex3f(0.5, -0.5, 0.5);
  glVertex3f(-0.5, -0.5, 0.5);
  glNormal3f(0.0, 1.0, 0.0);
  glColor3f(0.50, 0.80, 0.80);
  glVertex3f(0.5, 0.5, 0.5);
  glVertex3f(0.5, 0.5, -0.5);
  glVertex3f(-0.5, 0.5, -0.5);
  glVertex3f(-0.5, 0.5, 0.5);
  glNormal3f(0.0, 0.0, -1.0);
  glColor3f(0.80, 0.50, 0.80);
  glVertex3f(-0.5, -0.5, -0.5);
  glVertex3f(-0.5, 0.5, -0.5);
  glVertex3f(0.5, 0.5, -0.5);
  glVertex3f(0.5, -0.5, -0.5);
  glNormal3f(0.0, 0.0, 1.0);
  glColor3f(1.00, 0.80, 0.50);
  glVertex3f(0.5, 0.5, 0.5);
  glVertex3f(-0.5, 0.5, 0.5);
  glVertex3f(-0.5, -0.5, 0.5);
  glVertex3f(0.5, -0.5, 0.5);
  glEnd();
}


x86 assembly (clang, -O0):
<drawCube>:
push   %rbp
mov    %rsp,%rbp
mov    0x2e8d(%rip),%rax
mov    (%rax),%edi
call   1060 <glBegin@plt>
movsd  0xeb6(%rip),%xmm0
xorps  %xmm2,%xmm2
movaps %xmm2,%xmm1
call   1070 <glNormal3f@plt>
movsd  0xe9b(%rip),%xmm0
movsd  0xe7b(%rip),%xmm2
movaps %xmm2,%xmm1
call   1050 <glColor3f@plt>
movsd  0xe73(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xe60(%rip),%xmm1
movsd  0xe50(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xe48(%rip),%xmm0
movsd  0xe38(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xe30(%rip),%xmm2
movsd  0xe20(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xe20(%rip),%xmm0
xorps  %xmm2,%xmm2
movaps %xmm2,%xmm1
call   1070 <glNormal3f@plt>
movsd  0xdfd(%rip),%xmm2
movsd  0xe0d(%rip),%xmm1
movaps %xmm2,%xmm0
call   1050 <glColor3f@plt>
movsd  0xde5(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xdd2(%rip),%xmm2
movsd  0xdd2(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xdba(%rip),%xmm0
movsd  0xdba(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xda2(%rip),%xmm1
movsd  0xda2(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
xorps  %xmm2,%xmm2
movsd  0xda7(%rip),%xmm1
movaps %xmm2,%xmm0
call   1070 <glNormal3f@plt>
movsd  0xd77(%rip),%xmm1
movsd  0xd87(%rip),%xmm2
movaps %xmm1,%xmm0
call   1050 <glColor3f@plt>
movsd  0xd67(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xd4c(%rip),%xmm0
movsd  0xd4c(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xd34(%rip),%xmm2
movsd  0xd34(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xd24(%rip),%xmm1
movsd  0xd14(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
xorps  %xmm2,%xmm2
movsd  0xd11(%rip),%xmm1
movaps %xmm2,%xmm0
call   1070 <glNormal3f@plt>
movsd  0xcf1(%rip),%xmm0
movsd  0xd01(%rip),%xmm2
movaps %xmm2,%xmm1
call   1050 <glColor3f@plt>
movsd  0xcd9(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xcc6(%rip),%xmm1
movsd  0xcc6(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xcb6(%rip),%xmm2
movsd  0xca6(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xc9e(%rip),%xmm0
movsd  0xc8e(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
xorps  %xmm1,%xmm1
movsd  0xc9b(%rip),%xmm2
movaps %xmm1,%xmm0
call   1070 <glNormal3f@plt>
movsd  0xc83(%rip),%xmm2
movsd  0xc63(%rip),%xmm1
movaps %xmm2,%xmm0
call   1050 <glColor3f@plt>
movsd  0xc5b(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xc48(%rip),%xmm2
movsd  0xc38(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xc28(%rip),%xmm1
movsd  0xc28(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xc10(%rip),%xmm0
movsd  0xc10(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
xorps  %xmm1,%xmm1
movsd  0xc05(%rip),%xmm2
movaps %xmm1,%xmm0
call   1070 <glNormal3f@plt>
movsd  0xbf5(%rip),%xmm0
movsd  0xbf5(%rip),%xmm1
movsd  0xbd5(%rip),%xmm2
call   1050 <glColor3f@plt>
movsd  0xbc8(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xbbd(%rip),%xmm0
movsd  0xbad(%rip),%xmm2
movaps %xmm2,%xmm1
call   1030 <glVertex3f@plt>
movsd  0xba5(%rip),%xmm1
movsd  0xb95(%rip),%xmm2
movaps %xmm1,%xmm0
call   1030 <glVertex3f@plt>
movsd  0xb85(%rip),%xmm2
movsd  0xb85(%rip),%xmm1
movaps %xmm2,%xmm0
call   1030 <glVertex3f@plt>
mov    $0x0,%al
call   1040 <glEnd@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<drawCube>:
push   %rax
mov    0x2e90(%rip),%rax
mov    (%rax),%edi
call   1060 <glBegin@plt>
movsd  0xe99(%rip),%xmm0
xorps  %xmm1,%xmm1
xorps  %xmm2,%xmm2
call   1070 <glNormal3f@plt>
movsd  0xe8e(%rip),%xmm0
movsd  0xe8e(%rip),%xmm1
movaps %xmm1,%xmm2
call   1050 <glColor3f@plt>
movsd  0xe86(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xe73(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xe60(%rip),%xmm2
call   1030 <glVertex3f@plt>
movsd  0xe5b(%rip),%xmm0
movsd  0xe4b(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xe43(%rip),%xmm0
movsd  0xe33(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xe33(%rip),%xmm0
xorps  %xmm1,%xmm1
xorps  %xmm2,%xmm2
call   1070 <glNormal3f@plt>
movsd  0xe10(%rip),%xmm0
movsd  0xe00(%rip),%xmm1
movaps %xmm0,%xmm2
call   1050 <glColor3f@plt>
movsd  0xdf8(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xde5(%rip),%xmm0
movsd  0xde5(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xdcd(%rip),%xmm0
movsd  0xdcd(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xdb5(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xdb2(%rip),%xmm2
call   1030 <glVertex3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm2,%xmm2
movsd  0xd87(%rip),%xmm1
call   1070 <glNormal3f@plt>
movsd  0xd8a(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xd77(%rip),%xmm2
call   1050 <glColor3f@plt>
movsd  0xd7a(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xd5f(%rip),%xmm0
movsd  0xd5f(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xd47(%rip),%xmm0
movsd  0xd47(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xd37(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xd24(%rip),%xmm2
call   1030 <glVertex3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm2,%xmm2
movsd  0xd21(%rip),%xmm1
call   1070 <glNormal3f@plt>
movsd  0xd04(%rip),%xmm0
movsd  0xcf4(%rip),%xmm1
movaps %xmm1,%xmm2
call   1050 <glColor3f@plt>
movsd  0xcec(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xcd9(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xcd6(%rip),%xmm2
call   1030 <glVertex3f@plt>
movsd  0xcc9(%rip),%xmm0
movsd  0xcb9(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xcb1(%rip),%xmm0
movsd  0xca1(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm1,%xmm1
movsd  0xc7b(%rip),%xmm2
call   1070 <glNormal3f@plt>
movsd  0xc76(%rip),%xmm0
movsd  0xc76(%rip),%xmm1
movaps %xmm0,%xmm2
call   1050 <glColor3f@plt>
movsd  0xc6e(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xc5b(%rip),%xmm0
movsd  0xc4b(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xc3b(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xc38(%rip),%xmm2
call   1030 <glVertex3f@plt>
movsd  0xc23(%rip),%xmm0
movsd  0xc23(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm1,%xmm1
movsd  0xc15(%rip),%xmm2
call   1070 <glNormal3f@plt>
movsd  0xc08(%rip),%xmm0
movsd  0xbe8(%rip),%xmm1
movsd  0xbe8(%rip),%xmm2
call   1050 <glColor3f@plt>
movsd  0xbdb(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xbd0(%rip),%xmm0
movsd  0xbc0(%rip),%xmm1
movaps %xmm1,%xmm2
call   1030 <glVertex3f@plt>
movsd  0xbb8(%rip),%xmm0
movaps %xmm0,%xmm1
movsd  0xba5(%rip),%xmm2
call   1030 <glVertex3f@plt>
movsd  0xb98(%rip),%xmm0
movsd  0xb98(%rip),%xmm1
movaps %xmm0,%xmm2
call   1030 <glVertex3f@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <glEnd@plt>

LLVM IR (-O0):
@GL_QUADS = global i32 0
define void @drawCube() {
%1 = load i32, i32* @GL_QUADS
%2 = call i32 @glBegin(i32 %1)
%3 = call i32 @glNormal3f(double -1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%4 = call i32 @glColor3f(double 8.000000e-01, double 5.000000e-01, double 5.000000e-01)
%5 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%6 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%7 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%8 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%9 = call i32 @glNormal3f(double 1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%10 = call i32 @glColor3f(double 5.000000e-01, double 8.000000e-01, double 5.000000e-01)
%11 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%12 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%13 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%14 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%15 = call i32 @glNormal3f(double 0.000000e+00, double -1.000000e+00, double 0.000000e+00)
%16 = call i32 @glColor3f(double 5.000000e-01, double 5.000000e-01, double 8.000000e-01)
%17 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%18 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%19 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%20 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%21 = call i32 @glNormal3f(double 0.000000e+00, double 1.000000e+00, double 0.000000e+00)
%22 = call i32 @glColor3f(double 5.000000e-01, double 8.000000e-01, double 8.000000e-01)
%23 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%24 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%25 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%26 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%27 = call i32 @glNormal3f(double 0.000000e+00, double 0.000000e+00, double -1.000000e+00)
%28 = call i32 @glColor3f(double 8.000000e-01, double 5.000000e-01, double 8.000000e-01)
%29 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%30 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%31 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%32 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%33 = call i32 @glNormal3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%34 = call i32 @glColor3f(double 1.000000e+00, double 8.000000e-01, double 5.000000e-01)
%35 = call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%36 = call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%37 = call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%38 = call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%39 = call i32 (...) @glEnd()
ret void
}

LLVM IR (-O2):
@GL_QUADS = global i32 0
define void @drawCube() {
%1 = load i32, i32* @GL_QUADS
%2 = tail call i32 @glBegin(i32 %1)
%3 = tail call i32 @glNormal3f(double -1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%4 = tail call i32 @glColor3f(double 8.000000e-01, double 5.000000e-01, double 5.000000e-01)
%5 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%6 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%7 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%8 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%9 = tail call i32 @glNormal3f(double 1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%10 = tail call i32 @glColor3f(double 5.000000e-01, double 8.000000e-01, double 5.000000e-01)
%11 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%12 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%13 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%14 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%15 = tail call i32 @glNormal3f(double 0.000000e+00, double -1.000000e+00, double 0.000000e+00)
%16 = tail call i32 @glColor3f(double 5.000000e-01, double 5.000000e-01, double 8.000000e-01)
%17 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%18 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%19 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%20 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%21 = tail call i32 @glNormal3f(double 0.000000e+00, double 1.000000e+00, double 0.000000e+00)
%22 = tail call i32 @glColor3f(double 5.000000e-01, double 8.000000e-01, double 8.000000e-01)
%23 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%24 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%25 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%26 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%27 = tail call i32 @glNormal3f(double 0.000000e+00, double 0.000000e+00, double -1.000000e+00)
%28 = tail call i32 @glColor3f(double 8.000000e-01, double 5.000000e-01, double 8.000000e-01)
%29 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%30 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%31 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double -5.000000e-01)
%32 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double -5.000000e-01)
%33 = tail call i32 @glNormal3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%34 = tail call i32 @glColor3f(double 1.000000e+00, double 8.000000e-01, double 5.000000e-01)
%35 = tail call i32 @glVertex3f(double 5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%36 = tail call i32 @glVertex3f(double -5.000000e-01, double 5.000000e-01, double 5.000000e-01)
%37 = tail call i32 @glVertex3f(double -5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%38 = tail call i32 @glVertex3f(double 5.000000e-01, double -5.000000e-01, double 5.000000e-01)
%39 = tail call i32 (...) @glEnd()
ret void
}