#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 *, ...);
int imprime(double *matrizr, double *matrizi, int n, int v) {
  int i, j;
  for (i = 0; i < n; i++, matrizr += n, matrizi += n) {
    for (j = 0; j < n; j++)
      printf("% 2.2e % 2.2ei  ", *(matrizr + j), *(matrizi + j));
    printf("\n");
    if (v)
      break;
  }
  printf("\n");
}


x86 assembly (clang, -O0):
<imprime>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %edx,-0x1c(%rbp)
mov    %ecx,-0x20(%rbp)
movl   $0x0,-0x24(%rbp)
mov    -0x24(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jge    11dc <imprime+0xcc>
movl   $0x0,-0x28(%rbp)
mov    -0x28(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jge    1182 <imprime+0x72>
mov    -0x10(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x28(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm1
lea    0xe93(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    1140 <imprime+0x30>
lea    0xe88(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
cmpl   $0x0,-0x20(%rbp)
je     119f <imprime+0x8f>
jmp    11dc <imprime+0xcc>
jmp    11a4 <imprime+0x94>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
mov    -0x1c(%rbp),%ecx
mov    -0x10(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    -0x1c(%rbp),%ecx
mov    -0x18(%rbp),%rax
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x18(%rbp)
jmp    112d <imprime+0x1d>
lea    0xe2e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<imprime>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %ecx,0xc(%rsp)
mov    %edx,0x8(%rsp)
test   %edx,%edx
jle    11b7 <imprime+0x97>
mov    %rsi,%rbx
mov    %rdi,%rbp
mov    0x8(%rsp),%r13d
lea    0x0(,%r13,8),%rax
mov    %rax,0x10(%rsp)
xor    %r15d,%r15d
lea    0xea4(%rip),%r12
nopl   0x0(%rax)
xor    %r14d,%r14d
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movsd  0x0(%rbp,%r14,8),%xmm0
movsd  (%rbx,%r14,8),%xmm1
mov    %r12,%rdi
mov    $0x2,%al
call   1040 <printf@plt>
add    $0x1,%r14
cmp    %r14,%r13
jne    1170 <imprime+0x50>
mov    $0xa,%edi
call   1030 <putchar@plt>
cmpl   $0x0,0xc(%rsp)
jne    11b7 <imprime+0x97>
add    $0x1,%r15d
mov    0x10(%rsp),%rax
add    %rax,%rbx
add    %rax,%rbp
cmp    0x8(%rsp),%r15d
jl     1160 <imprime+0x40>
mov    $0xa,%edi
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <putchar@plt>

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

LLVM IR (-O2):
@.str = [17 x i8] c"% 2.2e % 2.2ei \00"
define i32 @imprime(double* nocapture %0, double* nocapture %1, i32 %2, i32 %3) {
%5 = icmp sgt i32 %2, 0
br i1 %5, label %6, label %30
6: ; preds = %4
%7 = icmp eq i32 %3, 0
%8 = zext i32 %2 to i64
%9 = zext i32 %2 to i64
br label %10
10: ; preds = %6, %23
%11 = phi i32 [ 0, %6 ], [ %25, %23 ]
%12 = phi double* [ %0, %6 ], [ %26, %23 ]
%13 = phi double* [ %1, %6 ], [ %27, %23 ]
br label %14
14: ; preds = %10, %14
%15 = phi i64 [ 0, %10 ], [ %21, %14 ]
%16 = getelementptr inbounds double, double* %12, i64 %15
%17 = load double, double* %16
%18 = getelementptr inbounds double, double* %13, i64 %15
%19 = load double, double* %18
%20 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), double %17, double %19)
%21 = add nuw nsw i64 %15, 1
%22 = icmp eq i64 %21, %9
br i1 %22, label %23, label %14
23: ; preds = %14
%24 = tail call i32 @putchar(i32 10)
%25 = add nuw nsw i32 %11, 1
%26 = getelementptr inbounds double, double* %12, i64 %8
%27 = getelementptr inbounds double, double* %13, i64 %8
%28 = icmp slt i32 %25, %2
%29 = select i1 %7, i1 %28, i1 false
br i1 %29, label %10, label %30
30: ; preds = %23, %4
%31 = tail call i32 @putchar(i32 10)
ret i32 undef
}