#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*/ codeGoTo(int);
int /*<<< orphan*/ codeStr(char *);
int /*<<< orphan*/ popCells(int);
int pushCells(int);
void incrementXbyY(int x, int y) {
  int temp0 = pushCells(1);
  codeGoTo(temp0);
  codeStr("[-]");
  codeGoTo(y);
  codeStr("[");
  codeGoTo(x);
  codeStr("+");
  codeGoTo(temp0);
  codeStr("+");
  codeGoTo(y);
  codeStr("-]");
  codeGoTo(temp0);
  codeStr("[");
  codeGoTo(y);
  codeStr("+");
  codeGoTo(temp0);
  codeStr("-]");
  popCells(1);
}


x86 assembly (clang, -O0):
<incrementXbyY>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    $0x1,%edi
call   1040 <pushCells@plt>
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe96(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0x8(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe86(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0x4(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe74(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0xc(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe60(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0x8(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe47(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0xc(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe36(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0x8(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe24(%rip),%rdi
call   1050 <codeStr@plt>
mov    -0xc(%rbp),%edi
call   1030 <codeGoTo@plt>
lea    0xe0b(%rip),%rdi
call   1050 <codeStr@plt>
mov    $0x1,%edi
call   1060 <popCells@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<incrementXbyY>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %esi,%ebp
mov    %edi,%r15d
mov    $0x1,%edi
call   1040 <pushCells@plt>
mov    %eax,%ebx
mov    %eax,%edi
call   1030 <codeGoTo@plt>
lea    0xe99(%rip),%rdi
call   1050 <codeStr@plt>
mov    %ebp,%edi
call   1030 <codeGoTo@plt>
lea    0xe8a(%rip),%r14
mov    %r14,%rdi
call   1050 <codeStr@plt>
mov    %r15d,%edi
call   1030 <codeGoTo@plt>
lea    0xe75(%rip),%r15
mov    %r15,%rdi
call   1050 <codeStr@plt>
mov    %ebx,%edi
call   1030 <codeGoTo@plt>
mov    %r15,%rdi
call   1050 <codeStr@plt>
mov    %ebp,%edi
call   1030 <codeGoTo@plt>
lea    0xe4b(%rip),%r12
mov    %r12,%rdi
call   1050 <codeStr@plt>
mov    %ebx,%edi
call   1030 <codeGoTo@plt>
mov    %r14,%rdi
call   1050 <codeStr@plt>
mov    %ebp,%edi
call   1030 <codeGoTo@plt>
mov    %r15,%rdi
call   1050 <codeStr@plt>
mov    %ebx,%edi
call   1030 <codeGoTo@plt>
mov    %r12,%rdi
call   1050 <codeStr@plt>
mov    $0x1,%edi
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
jmp    1060 <popCells@plt>

LLVM IR (-O0):
@.str = [4 x i8] c"[-]\00"
@.str.1 = [2 x i8] c"[\00"
@.str.2 = [2 x i8] c"+\00"
@.str.3 = [3 x i8] c"-]\00"
define void @incrementXbyY(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%6 = call i32 @pushCells(i32 1)
store i32 %6, i32* %5
%7 = load i32, i32* %5
%8 = call i32 @codeGoTo(i32 %7)
%9 = call i32 @codeStr(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%10 = load i32, i32* %4
%11 = call i32 @codeGoTo(i32 %10)
%12 = call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%13 = load i32, i32* %3
%14 = call i32 @codeGoTo(i32 %13)
%15 = call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%16 = load i32, i32* %5
%17 = call i32 @codeGoTo(i32 %16)
%18 = call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%19 = load i32, i32* %4
%20 = call i32 @codeGoTo(i32 %19)
%21 = call i32 @codeStr(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%22 = load i32, i32* %5
%23 = call i32 @codeGoTo(i32 %22)
%24 = call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%25 = load i32, i32* %4
%26 = call i32 @codeGoTo(i32 %25)
%27 = call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%28 = load i32, i32* %5
%29 = call i32 @codeGoTo(i32 %28)
%30 = call i32 @codeStr(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%31 = call i32 @popCells(i32 1)
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"[-]\00"
@.str.1 = [2 x i8] c"[\00"
@.str.2 = [2 x i8] c"+\00"
@.str.3 = [3 x i8] c"-]\00"
define void @incrementXbyY(i32 %0, i32 %1) {
%3 = tail call i32 @pushCells(i32 1)
%4 = tail call i32 @codeGoTo(i32 %3)
%5 = tail call i32 @codeStr(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%6 = tail call i32 @codeGoTo(i32 %1)
%7 = tail call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%8 = tail call i32 @codeGoTo(i32 %0)
%9 = tail call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%10 = tail call i32 @codeGoTo(i32 %3)
%11 = tail call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%12 = tail call i32 @codeGoTo(i32 %1)
%13 = tail call i32 @codeStr(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%14 = tail call i32 @codeGoTo(i32 %3)
%15 = tail call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%16 = tail call i32 @codeGoTo(i32 %1)
%17 = tail call i32 @codeStr(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%18 = tail call i32 @codeGoTo(i32 %3)
%19 = tail call i32 @codeStr(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%20 = tail call i32 @popCells(i32 1)
ret void
}