#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 printSepuku(int tab[9][9]) {
  for (int i = 0; i < 9; i++) {
    for (int j = 0; j < 9; j++) {
      printf(" %1x ", tab[i][j]);
      if (j % 3 == 2)
        printf("|");
    }
    printf("\n");
    if (i % 3 == 2) {
      for (int j = 0; j < 3 * (1 + 3 * 3); j++)
        printf("-");
      printf("\n");
    }
  }
}


x86 assembly (clang, -O0):
<printSepuku>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x9,-0xc(%rbp)
jge    1207 <printSepuku+0xf7>
movl   $0x0,-0x10(%rbp)
cmpl   $0x9,-0x10(%rbp)
jge    1197 <printSepuku+0x87>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
imul   $0x24,%rcx,%rcx
add    %rcx,%rax
movslq -0x10(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0xea5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
cmp    $0x2,%edx
jne    1184 <printSepuku+0x74>
lea    0xe89(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1189 <printSepuku+0x79>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1134 <printSepuku+0x24>
lea    0xe6a(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
cmp    $0x2,%edx
jne    11f4 <printSepuku+0xe4>
movl   $0x0,-0x14(%rbp)
cmpl   $0x1e,-0x14(%rbp)
jge    11e6 <printSepuku+0xd6>
lea    0xe39(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    11c0 <printSepuku+0xb0>
lea    0xe1b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    11f9 <printSepuku+0xe9>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1123 <printSepuku+0x13>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printSepuku>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %rdi,%r15
mov    $0x20,%ebx
mov    $0x2,%r13d
lea    0xec0(%rip),%r14
xor    %ebp,%ebp
jmp    1168 <printSepuku+0x48>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
add    $0x24,%rbx
add    $0xffffffff,%r13d
add    $0x1,%ebp
cmp    $0x164,%rbx
je     136d <printSepuku+0x24d>
mov    %ebp,%eax
mov    $0xaaaaaaab,%ecx
imul   %rcx,%rax
shr    $0x21,%rax
lea    (%rax,%rax,2),%r12d
mov    -0x20(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    -0x1c(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    -0x18(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x7c,%edi
call   1030 <putchar@plt>
mov    -0x14(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    -0x10(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    -0xc(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x7c,%edi
call   1030 <putchar@plt>
mov    -0x8(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    -0x4(%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    (%r15,%rbx,1),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x7c,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    %r13d,%r12d
jne    1150 <printSepuku+0x30>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0x2d,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
jmp    1150 <printSepuku+0x30>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [6 x i8] c" %1x \00"
@.str.1 = [2 x i8] c"|\00"
@.str.2 = [2 x i8] c"\0A\00"
@.str.3 = [2 x i8] c"-\00"
define void @printSepuku([9 x i32]* %0) {
%2 = alloca [9 x i32]*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store [9 x i32]* %0, [9 x i32]** %2
store i32 0, i32* %3
br label %6
6: ; preds = %49, %1
%7 = load i32, i32* %3
%8 = icmp slt i32 %7, 9
br i1 %8, label %9, label %52
9: ; preds = %6
store i32 0, i32* %4
br label %10
10: ; preds = %29, %9
%11 = load i32, i32* %4
%12 = icmp slt i32 %11, 9
br i1 %12, label %13, label %32
13: ; preds = %10
%14 = load [9 x i32]*, [9 x i32]** %2
%15 = load i32, i32* %3
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds [9 x i32], [9 x i32]* %14, i64 %16
%18 = load i32, i32* %4
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds [9 x i32], [9 x i32]* %17, i64 0, i64 %19
%21 = load i32, i32* %20
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %21)
%23 = load i32, i32* %4
%24 = srem i32 %23, 3
%25 = icmp eq i32 %24, 2
br i1 %25, label %26, label %28
26: ; preds = %13
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %28
28: ; preds = %26, %13
br label %29
29: ; preds = %28
%30 = load i32, i32* %4
%31 = add nsw i32 %30, 1
store i32 %31, i32* %4
br label %10
32: ; preds = %10
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%34 = load i32, i32* %3
%35 = srem i32 %34, 3
%36 = icmp eq i32 %35, 2
br i1 %36, label %37, label %48
37: ; preds = %32
store i32 0, i32* %5
br label %38
38: ; preds = %43, %37
%39 = load i32, i32* %5
%40 = icmp slt i32 %39, 30
br i1 %40, label %41, label %46
41: ; preds = %38
%42 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
br label %43
43: ; preds = %41
%44 = load i32, i32* %5
%45 = add nsw i32 %44, 1
store i32 %45, i32* %5
br label %38
46: ; preds = %38
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %48
48: ; preds = %46, %32
br label %49
49: ; preds = %48
%50 = load i32, i32* %3
%51 = add nsw i32 %50, 1
store i32 %51, i32* %3
br label %6
52: ; preds = %6
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c" %1x \00"
define void @printSepuku([9 x i32]* nocapture %0) {
br label %35
2: ; preds = %71
ret void
3: ; preds = %35
%4 = tail call i32 @putchar(i32 45)
%5 = tail call i32 @putchar(i32 45)
%6 = tail call i32 @putchar(i32 45)
%7 = tail call i32 @putchar(i32 45)
%8 = tail call i32 @putchar(i32 45)
%9 = tail call i32 @putchar(i32 45)
%10 = tail call i32 @putchar(i32 45)
%11 = tail call i32 @putchar(i32 45)
%12 = tail call i32 @putchar(i32 45)
%13 = tail call i32 @putchar(i32 45)
%14 = tail call i32 @putchar(i32 45)
%15 = tail call i32 @putchar(i32 45)
%16 = tail call i32 @putchar(i32 45)
%17 = tail call i32 @putchar(i32 45)
%18 = tail call i32 @putchar(i32 45)
%19 = tail call i32 @putchar(i32 45)
%20 = tail call i32 @putchar(i32 45)
%21 = tail call i32 @putchar(i32 45)
%22 = tail call i32 @putchar(i32 45)
%23 = tail call i32 @putchar(i32 45)
%24 = tail call i32 @putchar(i32 45)
%25 = tail call i32 @putchar(i32 45)
%26 = tail call i32 @putchar(i32 45)
%27 = tail call i32 @putchar(i32 45)
%28 = tail call i32 @putchar(i32 45)
%29 = tail call i32 @putchar(i32 45)
%30 = tail call i32 @putchar(i32 45)
%31 = tail call i32 @putchar(i32 45)
%32 = tail call i32 @putchar(i32 45)
%33 = tail call i32 @putchar(i32 45)
%34 = tail call i32 @putchar(i32 10)
br label %71
35: ; preds = %1, %71
%36 = phi i64 [ 0, %1 ], [ %72, %71 ]
%37 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 0
%38 = load i32, i32* %37
%39 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %38)
%40 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 1
%41 = load i32, i32* %40
%42 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %41)
%43 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 2
%44 = load i32, i32* %43
%45 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %44)
%46 = tail call i32 @putchar(i32 124)
%47 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 3
%48 = load i32, i32* %47
%49 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %48)
%50 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 4
%51 = load i32, i32* %50
%52 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %51)
%53 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 5
%54 = load i32, i32* %53
%55 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %54)
%56 = tail call i32 @putchar(i32 124)
%57 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 6
%58 = load i32, i32* %57
%59 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %58)
%60 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 7
%61 = load i32, i32* %60
%62 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %61)
%63 = getelementptr inbounds [9 x i32], [9 x i32]* %0, i64 %36, i64 8
%64 = load i32, i32* %63
%65 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %64)
%66 = tail call i32 @putchar(i32 124)
%67 = tail call i32 @putchar(i32 10)
%68 = trunc i64 %36 to i32
%69 = urem i32 %68, 3
%70 = icmp eq i32 %69, 2
br i1 %70, label %3, label %71
71: ; preds = %35, %3
%72 = add nuw nsw i64 %36, 1
%73 = icmp eq i64 %72, 9
br i1 %73, label %2, label %35
}