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

/* Variables and functions */
int /*<<< orphan*/ Sprint(int, int, int, char *);
int /*<<< orphan*/ glColor3f(double, double, double);
int /*<<< orphan*/ glPopMatrix();
int /*<<< orphan*/ glPushMatrix();
int /*<<< orphan*/ glRotatef(int, double, double, int);
int /*<<< orphan*/ glTranslatef(int, int, int);
int /*<<< orphan*/ glutSolidSphere(int, int, int);
int /*<<< orphan*/ glutSolidTorus(double, int, int, int);
void Draw_atom_He(GLfloat x, GLfloat y, GLfloat z, int elec, int orbit) {
  glColor3f(0.0, 1.0, 0.5);
  Sprint(22, -20, 2, "HELIUM");
  Sprint(20, 25, 2, "  1st : 2");
  glRotatef(60, 1.0, 0.0, 0.0);
  glPushMatrix();
  glTranslatef(x, y, z);
  glColor3f(1.0, 0.0, 0.0);
  glutSolidSphere(5, 16, 10);
  glPushMatrix();
  glColor3f(1.0, 1.0, 1.0);
  glRotatef(orbit, 0, 0, 1);
  glutSolidTorus(0.12, 10, 16, 32);
  glPushMatrix();
  glTranslatef(0, 10, 0);
  glColor3f(0.0, 0.0, 1.0);
  glutSolidSphere(1, 16, 8);
  glPopMatrix();
  glPushMatrix();
  glTranslatef(0, -10, 0);
  glColor3f(0.0, 0.0, 1.0);
  glutSolidSphere(1, 16, 8);
  glPopMatrix();
  glPopMatrix();
  glPopMatrix();
}


x86 assembly (clang, -O0):
<Draw_atom_He>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8d,-0x14(%rbp)
xorps  %xmm0,%xmm0
movsd  0xe5d(%rip),%xmm1
movsd  0xe65(%rip),%xmm2
call   1040 <glColor3f@plt>
mov    $0x16,%edi
mov    $0xffffffec,%esi
mov    $0x2,%edx
lea    0xe52(%rip),%rcx
call   1060 <Sprint@plt>
mov    $0x14,%edi
mov    $0x19,%esi
mov    $0x2,%edx
lea    0xe3e(%rip),%rcx
call   1060 <Sprint@plt>
mov    $0x3c,%edi
movsd  0xe0d(%rip),%xmm0
xorps  %xmm1,%xmm1
xor    %esi,%esi
call   1090 <glRotatef@plt>
mov    $0x0,%al
call   1050 <glPushMatrix@plt>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
call   1080 <glTranslatef@plt>
movsd  0xde6(%rip),%xmm0
xorps  %xmm2,%xmm2
movaps %xmm2,%xmm1
call   1040 <glColor3f@plt>
mov    $0x5,%edi
mov    $0x10,%esi
mov    $0xa,%edx
call   1070 <glutSolidSphere@plt>
mov    $0x0,%al
call   1050 <glPushMatrix@plt>
movsd  0xdb8(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1040 <glColor3f@plt>
mov    -0x14(%rbp),%edi
xorps  %xmm1,%xmm1
mov    $0x1,%esi
movaps %xmm1,%xmm0
call   1090 <glRotatef@plt>
movsd  0xd9a(%rip),%xmm0
mov    $0xa,%edi
mov    $0x10,%esi
mov    $0x20,%edx
call   10a0 <glutSolidTorus@plt>
mov    $0x0,%al
call   1050 <glPushMatrix@plt>
xor    %edx,%edx
mov    $0xa,%esi
mov    %edx,%edi
call   1080 <glTranslatef@plt>
xorps  %xmm1,%xmm1
movsd  0xd5e(%rip),%xmm2
movaps %xmm1,%xmm0
call   1040 <glColor3f@plt>
mov    $0x1,%edi
mov    $0x10,%esi
mov    $0x8,%edx
call   1070 <glutSolidSphere@plt>
mov    $0x0,%al
call   1030 <glPopMatrix@plt>
mov    $0x0,%al
call   1050 <glPushMatrix@plt>
xor    %edx,%edx
mov    $0xfffffff6,%esi
mov    %edx,%edi
call   1080 <glTranslatef@plt>
xorps  %xmm1,%xmm1
movsd  0xd1b(%rip),%xmm2
movaps %xmm1,%xmm0
call   1040 <glColor3f@plt>
mov    $0x1,%edi
mov    $0x10,%esi
mov    $0x8,%edx
call   1070 <glutSolidSphere@plt>
mov    $0x0,%al
call   1030 <glPopMatrix@plt>
mov    $0x0,%al
call   1030 <glPopMatrix@plt>
mov    $0x0,%al
call   1030 <glPopMatrix@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Draw_atom_He>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %r8d,%r14d
mov    %edx,%r15d
mov    %esi,%ebx
mov    %edi,%ebp
movsd  0xe67(%rip),%xmm1
movsd  0xe67(%rip),%xmm2
xorps  %xmm0,%xmm0
call   1040 <glColor3f@plt>
lea    0xe68(%rip),%rcx
mov    $0x16,%edi
mov    $0xffffffec,%esi
mov    $0x2,%edx
call   1060 <Sprint@plt>
lea    0xe54(%rip),%rcx
mov    $0x14,%edi
mov    $0x19,%esi
mov    $0x2,%edx
call   1060 <Sprint@plt>
xorps  %xmm1,%xmm1
mov    $0x3c,%edi
movsd  0xe11(%rip),%xmm0
xor    %esi,%esi
call   1090 <glRotatef@plt>
xor    %eax,%eax
call   1050 <glPushMatrix@plt>
mov    %ebp,%edi
mov    %ebx,%esi
mov    %r15d,%edx
call   1080 <glTranslatef@plt>
xorps  %xmm1,%xmm1
xorps  %xmm2,%xmm2
movsd  0xde9(%rip),%xmm0
call   1040 <glColor3f@plt>
mov    $0x5,%edi
mov    $0x10,%esi
mov    $0xa,%edx
call   1070 <glutSolidSphere@plt>
xor    %eax,%eax
call   1050 <glPushMatrix@plt>
movsd  0xdc1(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1040 <glColor3f@plt>
xorps  %xmm0,%xmm0
xorps  %xmm1,%xmm1
mov    %r14d,%edi
mov    $0x1,%esi
call   1090 <glRotatef@plt>
movsd  0xdab(%rip),%xmm0
mov    $0xa,%edi
mov    $0x10,%esi
mov    $0x20,%edx
call   10a0 <glutSolidTorus@plt>
xor    %eax,%eax
call   1050 <glPushMatrix@plt>
xor    %edi,%edi
mov    $0xa,%esi
xor    %edx,%edx
call   1080 <glTranslatef@plt>
xorps  %xmm0,%xmm0
xorps  %xmm1,%xmm1
movsd  0xd64(%rip),%xmm2
call   1040 <glColor3f@plt>
mov    $0x1,%edi
mov    $0x10,%esi
mov    $0x8,%edx
call   1070 <glutSolidSphere@plt>
xor    %eax,%eax
call   1030 <glPopMatrix@plt>
xor    %eax,%eax
call   1050 <glPushMatrix@plt>
xor    %edi,%edi
mov    $0xfffffff6,%esi
xor    %edx,%edx
call   1080 <glTranslatef@plt>
xorps  %xmm0,%xmm0
xorps  %xmm1,%xmm1
movsd  0xd21(%rip),%xmm2
call   1040 <glColor3f@plt>
mov    $0x1,%edi
mov    $0x10,%esi
mov    $0x8,%edx
call   1070 <glutSolidSphere@plt>
xor    %eax,%eax
call   1030 <glPopMatrix@plt>
xor    %eax,%eax
call   1030 <glPopMatrix@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <glPopMatrix@plt>

LLVM IR (-O0):
@.str = [7 x i8] c"HELIUM\00"
@.str.1 = [10 x i8] c" 1st : 2\00"
define void @Draw_atom_He(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 %0, i32* %6
store i32 %1, i32* %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i32 %4, i32* %10
%11 = call i32 @glColor3f(double 0.000000e+00, double 1.000000e+00, double 5.000000e-01)
%12 = call i32 @Sprint(i32 22, i32 -20, i32 2, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%13 = call i32 @Sprint(i32 20, i32 25, i32 2, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%14 = call i32 @glRotatef(i32 60, double 1.000000e+00, double 0.000000e+00, i32 0)
%15 = call i32 (...) @glPushMatrix()
%16 = load i32, i32* %6
%17 = load i32, i32* %7
%18 = load i32, i32* %8
%19 = call i32 @glTranslatef(i32 %16, i32 %17, i32 %18)
%20 = call i32 @glColor3f(double 1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%21 = call i32 @glutSolidSphere(i32 5, i32 16, i32 10)
%22 = call i32 (...) @glPushMatrix()
%23 = call i32 @glColor3f(double 1.000000e+00, double 1.000000e+00, double 1.000000e+00)
%24 = load i32, i32* %10
%25 = call i32 @glRotatef(i32 %24, double 0.000000e+00, double 0.000000e+00, i32 1)
%26 = call i32 @glutSolidTorus(double 1.200000e-01, i32 10, i32 16, i32 32)
%27 = call i32 (...) @glPushMatrix()
%28 = call i32 @glTranslatef(i32 0, i32 10, i32 0)
%29 = call i32 @glColor3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%30 = call i32 @glutSolidSphere(i32 1, i32 16, i32 8)
%31 = call i32 (...) @glPopMatrix()
%32 = call i32 (...) @glPushMatrix()
%33 = call i32 @glTranslatef(i32 0, i32 -10, i32 0)
%34 = call i32 @glColor3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%35 = call i32 @glutSolidSphere(i32 1, i32 16, i32 8)
%36 = call i32 (...) @glPopMatrix()
%37 = call i32 (...) @glPopMatrix()
%38 = call i32 (...) @glPopMatrix()
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"HELIUM\00"
@.str.1 = [10 x i8] c" 1st : 2\00"
define void @Draw_atom_He(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = tail call i32 @glColor3f(double 0.000000e+00, double 1.000000e+00, double 5.000000e-01)
%7 = tail call i32 @Sprint(i32 22, i32 -20, i32 2, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0))
%8 = tail call i32 @Sprint(i32 20, i32 25, i32 2, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%9 = tail call i32 @glRotatef(i32 60, double 1.000000e+00, double 0.000000e+00, i32 0)
%10 = tail call i32 (...) @glPushMatrix()
%11 = tail call i32 @glTranslatef(i32 %0, i32 %1, i32 %2)
%12 = tail call i32 @glColor3f(double 1.000000e+00, double 0.000000e+00, double 0.000000e+00)
%13 = tail call i32 @glutSolidSphere(i32 5, i32 16, i32 10)
%14 = tail call i32 (...) @glPushMatrix()
%15 = tail call i32 @glColor3f(double 1.000000e+00, double 1.000000e+00, double 1.000000e+00)
%16 = tail call i32 @glRotatef(i32 %4, double 0.000000e+00, double 0.000000e+00, i32 1)
%17 = tail call i32 @glutSolidTorus(double 1.200000e-01, i32 10, i32 16, i32 32)
%18 = tail call i32 (...) @glPushMatrix()
%19 = tail call i32 @glTranslatef(i32 0, i32 10, i32 0)
%20 = tail call i32 @glColor3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%21 = tail call i32 @glutSolidSphere(i32 1, i32 16, i32 8)
%22 = tail call i32 (...) @glPopMatrix()
%23 = tail call i32 (...) @glPushMatrix()
%24 = tail call i32 @glTranslatef(i32 0, i32 -10, i32 0)
%25 = tail call i32 @glColor3f(double 0.000000e+00, double 0.000000e+00, double 1.000000e+00)
%26 = tail call i32 @glutSolidSphere(i32 1, i32 16, i32 8)
%27 = tail call i32 (...) @glPopMatrix()
%28 = tail call i32 (...) @glPopMatrix()
%29 = tail call i32 (...) @glPopMatrix()
ret void
}