#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*/ printf(char *, ...);
void print_matrix(int m[750][750]) {
  int i, j;
  for (i = 0; i < 750; i++) {
    printf("\n\t| ");
    for (j = 0; j < 750; j++)
      printf("%4d ", m[i][j]);
    printf("|");
  }
}


x86 assembly (clang, -O0):
<print_matrix>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x2ee,-0xc(%rbp)
jge    11a3 <print_matrix+0x93>
lea    0xec9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x10(%rbp)
cmpl   $0x2ee,-0x10(%rbp)
jge    1187 <print_matrix+0x77>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
imul   $0xbb8,%rcx,%rcx
add    %rcx,%rax
movslq -0x10(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0xe93(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1145 <print_matrix+0x35>
lea    0xe7c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1123 <print_matrix+0x13>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_matrix>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
mov    %rdi,%r13
lea    0xecd(%rip),%r14
lea    0xecb(%rip),%r15
xor    %r12d,%r12d
nopl   (%rax)
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
xor    %ebx,%ebx
nopl   0x0(%rax)
mov    0x0(%r13,%rbx,4),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%rbx
cmp    $0x2ee,%rbx
jne    1150 <print_matrix+0x30>
mov    $0x7c,%edi
call   1030 <putchar@plt>
add    $0x1,%r12
add    $0xbb8,%r13
cmp    $0x2ee,%r12
jne    1140 <print_matrix+0x20>
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [5 x i8] c"\0A\09| \00"
@.str.1 = [5 x i8] c"%4d \00"
@.str.2 = [2 x i8] c"|\00"
define void @print_matrix([750 x i32]* %0) {
%2 = alloca [750 x i32]*
%3 = alloca i32
%4 = alloca i32
store [750 x i32]* %0, [750 x i32]** %2
store i32 0, i32* %3
br label %5
5: ; preds = %28, %1
%6 = load i32, i32* %3
%7 = icmp slt i32 %6, 750
br i1 %7, label %8, label %31
8: ; preds = %5
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %4
br label %10
10: ; preds = %23, %8
%11 = load i32, i32* %4
%12 = icmp slt i32 %11, 750
br i1 %12, label %13, label %26
13: ; preds = %10
%14 = load [750 x i32]*, [750 x i32]** %2
%15 = load i32, i32* %3
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds [750 x i32], [750 x i32]* %14, i64 %16
%18 = load i32, i32* %4
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds [750 x i32], [750 x i32]* %17, i64 0, i64 %19
%21 = load i32, i32* %20
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %21)
br label %23
23: ; preds = %13
%24 = load i32, i32* %4
%25 = add nsw i32 %24, 1
store i32 %25, i32* %4
br label %10
26: ; preds = %10
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %28
28: ; preds = %26
%29 = load i32, i32* %3
%30 = add nsw i32 %29, 1
store i32 %30, i32* %3
br label %5
31: ; preds = %5
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"\0A\09| \00"
@.str.1 = [5 x i8] c"%4d \00"
define void @print_matrix([750 x i32]* nocapture %0) {
br label %2
2: ; preds = %1, %12
%3 = phi i64 [ 0, %1 ], [ %14, %12 ]
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
br label %5
5: ; preds = %2, %5
%6 = phi i64 [ 0, %2 ], [ %10, %5 ]
%7 = getelementptr inbounds [750 x i32], [750 x i32]* %0, i64 %3, i64 %6
%8 = load i32, i32* %7
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %8)
%10 = add nuw nsw i64 %6, 1
%11 = icmp eq i64 %10, 750
br i1 %11, label %12, label %5
12: ; preds = %5
%13 = tail call i32 @putchar(i32 124)
%14 = add nuw nsw i64 %3, 1
%15 = icmp eq i64 %14, 750
br i1 %15, label %16, label %2
16: ; preds = %12
ret void
}