#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*/ CLK(int);
int /*<<< orphan*/ KEY(int, int);
int /*<<< orphan*/ OPC(int, int, int, int);
int /*<<< orphan*/ RGA(int, int, int, int, int, int, int, int);
int /*<<< orphan*/ RGB(int, int, int, int, int, int, int, int);
int /*<<< orphan*/ RST(int);
int /*<<< orphan*/ delay(int);
void blinky() {
  CLK(0);
  RST(0);
  KEY(0, 0);
  OPC(0, 0, 0, 0);
  RGA(0, 0, 0, 0, 0, 0, 0, 0);
  RGB(0, 0, 0, 0, 0, 0, 0, 0);
  delay(500);
  CLK(1);
  RST(1);
  KEY(1, 1);
  OPC(1, 1, 1, 1);
  RGA(1, 1, 1, 1, 1, 1, 1, 1);
  RGB(1, 1, 1, 1, 1, 1, 1, 1);
  delay(500);
}


x86 assembly (clang, -O0):
<blinky>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
xor    %edi,%edi
call   1080 <CLK@plt>
xor    %edi,%edi
call   1060 <RST@plt>
xor    %esi,%esi
mov    %esi,%edi
call   1030 <KEY@plt>
xor    %ecx,%ecx
mov    %ecx,%edi
mov    %ecx,%esi
mov    %ecx,%edx
call   1040 <OPC@plt>
xor    %r9d,%r9d
mov    %r9d,%edi
mov    %r9d,%esi
mov    %r9d,%edx
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x0,(%rsp)
movl   $0x0,0x8(%rsp)
call   1050 <RGA@plt>
xor    %r9d,%r9d
mov    %r9d,%edi
mov    %r9d,%esi
mov    %r9d,%edx
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x0,(%rsp)
movl   $0x0,0x8(%rsp)
call   1090 <RGB@plt>
mov    $0x1f4,%edi
call   1070 <delay@plt>
mov    $0x1,%edi
call   1080 <CLK@plt>
mov    $0x1,%edi
call   1060 <RST@plt>
mov    $0x1,%esi
mov    %esi,%edi
call   1030 <KEY@plt>
mov    $0x1,%ecx
mov    %ecx,%edi
mov    %ecx,%esi
mov    %ecx,%edx
call   1040 <OPC@plt>
mov    $0x1,%r9d
mov    %r9d,%edi
mov    %r9d,%esi
mov    %r9d,%edx
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x1,(%rsp)
movl   $0x1,0x8(%rsp)
call   1050 <RGA@plt>
mov    $0x1,%r9d
mov    %r9d,%edi
mov    %r9d,%esi
mov    %r9d,%edx
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x1,(%rsp)
movl   $0x1,0x8(%rsp)
call   1090 <RGB@plt>
mov    $0x1f4,%edi
call   1070 <delay@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<blinky>:
push   %rax
xor    %edi,%edi
call   1080 <CLK@plt>
xor    %edi,%edi
call   1060 <RST@plt>
xor    %edi,%edi
xor    %esi,%esi
call   1030 <KEY@plt>
xor    %edi,%edi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
call   1040 <OPC@plt>
xor    %edi,%edi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
xor    %r9d,%r9d
push   $0x0
push   $0x0
call   1050 <RGA@plt>
add    $0x10,%rsp
xor    %edi,%edi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
xor    %r9d,%r9d
push   $0x0
push   $0x0
call   1090 <RGB@plt>
add    $0x10,%rsp
mov    $0x1f4,%edi
call   1070 <delay@plt>
mov    $0x1,%edi
call   1080 <CLK@plt>
mov    $0x1,%edi
call   1060 <RST@plt>
mov    $0x1,%edi
mov    $0x1,%esi
call   1030 <KEY@plt>
mov    $0x1,%edi
mov    $0x1,%esi
mov    $0x1,%edx
mov    $0x1,%ecx
call   1040 <OPC@plt>
mov    $0x1,%edi
mov    $0x1,%esi
mov    $0x1,%edx
mov    $0x1,%ecx
mov    $0x1,%r8d
mov    $0x1,%r9d
push   $0x1
push   $0x1
call   1050 <RGA@plt>
add    $0x10,%rsp
mov    $0x1,%edi
mov    $0x1,%esi
mov    $0x1,%edx
mov    $0x1,%ecx
mov    $0x1,%r8d
mov    $0x1,%r9d
push   $0x1
push   $0x1
call   1090 <RGB@plt>
add    $0x10,%rsp
mov    $0x1f4,%edi
pop    %rax
jmp    1070 <delay@plt>

LLVM IR (-O0):
define void @blinky() {
%1 = call i32 @CLK(i32 0)
%2 = call i32 @RST(i32 0)
%3 = call i32 @KEY(i32 0, i32 0)
%4 = call i32 @OPC(i32 0, i32 0, i32 0, i32 0)
%5 = call i32 @RGA(i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
%6 = call i32 @RGB(i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
%7 = call i32 @delay(i32 500)
%8 = call i32 @CLK(i32 1)
%9 = call i32 @RST(i32 1)
%10 = call i32 @KEY(i32 1, i32 1)
%11 = call i32 @OPC(i32 1, i32 1, i32 1, i32 1)
%12 = call i32 @RGA(i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1)
%13 = call i32 @RGB(i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1)
%14 = call i32 @delay(i32 500)
ret void
}

LLVM IR (-O2):
define void @blinky() {
%1 = tail call i32 @CLK(i32 0)
%2 = tail call i32 @RST(i32 0)
%3 = tail call i32 @KEY(i32 0, i32 0)
%4 = tail call i32 @OPC(i32 0, i32 0, i32 0, i32 0)
%5 = tail call i32 @RGA(i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
%6 = tail call i32 @RGB(i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
%7 = tail call i32 @delay(i32 500)
%8 = tail call i32 @CLK(i32 1)
%9 = tail call i32 @RST(i32 1)
%10 = tail call i32 @KEY(i32 1, i32 1)
%11 = tail call i32 @OPC(i32 1, i32 1, i32 1, i32 1)
%12 = tail call i32 @RGA(i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1)
%13 = tail call i32 @RGB(i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1)
%14 = tail call i32 @delay(i32 500)
ret void
}