#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*/ replace_number(int **, int, int);
void break_down_wall(int maze[25][25], int walls[25 - 1][25], int i, int j) {
  walls[i][j] = 0;
  replace_number(maze, maze[i][j], maze[i + 1][j]);
}


x86 assembly (clang, -O0):
<break_down_wall>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
imul   $0x64,%rcx,%rcx
add    %rcx,%rax
movslq -0x18(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rax
movslq -0x14(%rbp),%rcx
imul   $0x64,%rcx,%rcx
add    %rcx,%rax
movslq -0x18(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
mov    -0x8(%rbp),%rax
mov    -0x14(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
imul   $0x64,%rcx,%rcx
add    %rcx,%rax
movslq -0x18(%rbp),%rcx
mov    (%rax,%rcx,4),%edx
call   1030 <replace_number@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<break_down_wall>:
movslq %edx,%rax
movslq %ecx,%rcx
imul   $0x64,%rax,%rdx
add    %rdx,%rsi
movl   $0x0,(%rsi,%rcx,4)
add    %rdi,%rdx
mov    (%rdx,%rcx,4),%esi
add    $0x1,%eax
cltq
imul   $0x64,%rax,%rax
add    %rdi,%rax
mov    (%rax,%rcx,4),%edx
jmp    1030 <replace_number@plt>

LLVM IR (-O0):
define void @break_down_wall([25 x i32]* %0, [25 x i32]* %1, i32 %2, i32 %3) {
%5 = alloca [25 x i32]*
%6 = alloca [25 x i32]*
%7 = alloca i32
%8 = alloca i32
store [25 x i32]* %0, [25 x i32]** %5
store [25 x i32]* %1, [25 x i32]** %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%9 = load [25 x i32]*, [25 x i32]** %6
%10 = load i32, i32* %7
%11 = sext i32 %10 to i64
%12 = getelementptr inbounds [25 x i32], [25 x i32]* %9, i64 %11
%13 = load i32, i32* %8
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [25 x i32], [25 x i32]* %12, i64 0, i64 %14
store i32 0, i32* %15
%16 = load [25 x i32]*, [25 x i32]** %5
%17 = bitcast [25 x i32]* %16 to i32**
%18 = load [25 x i32]*, [25 x i32]** %5
%19 = load i32, i32* %7
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds [25 x i32], [25 x i32]* %18, i64 %20
%22 = load i32, i32* %8
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds [25 x i32], [25 x i32]* %21, i64 0, i64 %23
%25 = load i32, i32* %24
%26 = load [25 x i32]*, [25 x i32]** %5
%27 = load i32, i32* %7
%28 = add nsw i32 %27, 1
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds [25 x i32], [25 x i32]* %26, i64 %29
%31 = load i32, i32* %8
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [25 x i32], [25 x i32]* %30, i64 0, i64 %32
%34 = load i32, i32* %33
%35 = call i32 @replace_number(i32** %17, i32 %25, i32 %34)
ret void
}

LLVM IR (-O2):
define void @break_down_wall([25 x i32]* %0, [25 x i32]* nocapture writeonly %1, i32 %2, i32 %3) {
%5 = sext i32 %2 to i64
%6 = sext i32 %3 to i64
%7 = getelementptr inbounds [25 x i32], [25 x i32]* %1, i64 %5, i64 %6
store i32 0, i32* %7
%8 = bitcast [25 x i32]* %0 to i32**
%9 = getelementptr inbounds [25 x i32], [25 x i32]* %0, i64 %5, i64 %6
%10 = load i32, i32* %9
%11 = add nsw i32 %2, 1
%12 = sext i32 %11 to i64
%13 = getelementptr inbounds [25 x i32], [25 x i32]* %0, i64 %12, i64 %6
%14 = load i32, i32* %13
%15 = tail call i32 @replace_number(i32** %8, i32 %10, i32 %14)
ret void
}