#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*/ lerMatrizInteiros(int **, int, int);
int /*<<< orphan*/ mostrarMatrizInteiros(int **, int, int);
scalar_t__ multiplicarMatrizesInteiros(int **, int, int, int **, int, int,
                                       int **);
int main() {
  int A[100][100], B[100][100], C[100][100];
  lerMatrizInteiros(A, 3, 2);
  lerMatrizInteiros(B, 2, 3);
  if (multiplicarMatrizesInteiros(A, 3, 2, B, 2, 3, C))
    mostrarMatrizInteiros(C, 3, 3);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1d4e0,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x9c50(%rbp),%rdi
mov    $0x3,%esi
mov    $0x2,%edx
call   1030 <lerMatrizInteiros@plt>
lea    -0x13890(%rbp),%rdi
mov    $0x2,%esi
mov    $0x3,%edx
call   1030 <lerMatrizInteiros@plt>
lea    -0x9c50(%rbp),%rdi
lea    -0x13890(%rbp),%rcx
lea    -0x1d4d0(%rbp),%rax
mov    $0x3,%r9d
mov    $0x2,%r8d
mov    %r9d,%esi
mov    %r8d,%edx
mov    %rax,(%rsp)
call   1050 <multiplicarMatrizesInteiros@plt>
cmp    $0x0,%rax
je     11bb <main+0x8b>
lea    -0x1d4d0(%rbp),%rdi
mov    $0x3,%edx
mov    %edx,%esi
call   1040 <mostrarMatrizInteiros@plt>
xor    %eax,%eax
add    $0x1d4e0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
sub    $0x1d4d8,%rsp
lea    0x13890(%rsp),%r14
mov    %r14,%rdi
mov    $0x3,%esi
mov    $0x2,%edx
call   1030 <lerMatrizInteiros@plt>
lea    0x9c50(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x2,%esi
mov    $0x3,%edx
call   1030 <lerMatrizInteiros@plt>
lea    0x10(%rsp),%rax
mov    %rax,(%rsp)
mov    %r14,%rdi
mov    $0x3,%esi
mov    $0x2,%edx
mov    %rbx,%rcx
mov    $0x2,%r8d
mov    $0x3,%r9d
call   1050 <multiplicarMatrizesInteiros@plt>
test   %rax,%rax
je     11b1 <main+0x81>
lea    0x10(%rsp),%rdi
mov    $0x3,%esi
mov    $0x3,%edx
call   1040 <mostrarMatrizInteiros@plt>
xor    %eax,%eax
add    $0x1d4d8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca [100 x [100 x i32]]
%3 = alloca [100 x [100 x i32]]
%4 = alloca [100 x [100 x i32]]
store i32 0, i32* %1
%5 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %2, i64 0, i64 0
%6 = bitcast [100 x i32]* %5 to i32**
%7 = call i32 @lerMatrizInteiros(i32** %6, i32 3, i32 2)
%8 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %3, i64 0, i64 0
%9 = bitcast [100 x i32]* %8 to i32**
%10 = call i32 @lerMatrizInteiros(i32** %9, i32 2, i32 3)
%11 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %2, i64 0, i64 0
%12 = bitcast [100 x i32]* %11 to i32**
%13 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %3, i64 0, i64 0
%14 = bitcast [100 x i32]* %13 to i32**
%15 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %4, i64 0, i64 0
%16 = bitcast [100 x i32]* %15 to i32**
%17 = call i64 @multiplicarMatrizesInteiros(i32** %12, i32 3, i32 2, i32** %14, i32 2, i32 3, i32** %16)
%18 = icmp ne i64 %17, 0
br i1 %18, label %19, label %23
19: ; preds = %0
%20 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* %4, i64 0, i64 0
%21 = bitcast [100 x i32]* %20 to i32**
%22 = call i32 @mostrarMatrizInteiros(i32** %21, i32 3, i32 3)
br label %23
23: ; preds = %19, %0
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca [100 x [100 x i32]]
%2 = alloca [100 x [100 x i32]]
%3 = alloca [100 x [100 x i32]]
%4 = bitcast [100 x [100 x i32]]* %1 to i8*
%5 = bitcast [100 x [100 x i32]]* %2 to i8*
%6 = bitcast [100 x [100 x i32]]* %3 to i8*
%7 = bitcast [100 x [100 x i32]]* %1 to i32**
%8 = call i32 @lerMatrizInteiros(i32** %7, i32 3, i32 2)
%9 = bitcast [100 x [100 x i32]]* %2 to i32**
%10 = call i32 @lerMatrizInteiros(i32** %9, i32 2, i32 3)
%11 = bitcast [100 x [100 x i32]]* %3 to i32**
%12 = call i64 @multiplicarMatrizesInteiros(i32** %7, i32 3, i32 2, i32** %9, i32 2, i32 3, i32** %11)
%13 = icmp eq i64 %12, 0
br i1 %13, label %16, label %14
14: ; preds = %0
%15 = call i32 @mostrarMatrizInteiros(i32** %11, i32 3, i32 3)
br label %16
16: ; preds = %14, %0
ret i32 0
}