#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 */
typedef int /*<<< orphan*/ matrix;
typedef int /*<<< orphan*/ arreglo;

/* Variables and functions */
int /*<<< orphan*/ print_address(int, double *);
int /*<<< orphan*/ print_value(int, double *);
int /*<<< orphan*/ printf(char *, ...);
void main() {
  double arreglo[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9};
  double matrix[2][3] = {{11, 12, 13}, {21, 22, 23}};
  int n_arr, area, rows, cols;
  n_arr = sizeof(arreglo) / sizeof(arreglo[0]);
  rows = sizeof(matrix) / sizeof(matrix[0]);
  cols = sizeof(matrix[0]) / sizeof(matrix[0][0]);
  area = sizeof(matrix) / sizeof(matrix[0][0]);
  printf("n arreglo = %d \n", n_arr);
  print_value(n_arr, arreglo);
  print_address(n_arr, arreglo);
  printf("\n");
  printf("Fila %d y Columna %d\n", rows, cols);
  print_value(area, matrix[0]);
  print_address(area, matrix[0]);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
lea    -0x50(%rbp),%rdi
lea    0xeca(%rip),%rsi
mov    $0x50,%edx
call   1070 <memcpy@plt>
lea    -0x80(%rbp),%rdi
xor    %esi,%esi
mov    $0x30,%edx
call   1060 <memset@plt>
movsd  0xea0(%rip),%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  0xe8b(%rip),%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  0xe76(%rip),%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  0xe61(%rip),%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  0xe4c(%rip),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  0xe37(%rip),%xmm0
movsd  %xmm0,-0x58(%rbp)
movl   $0xa,-0x84(%rbp)
movl   $0x2,-0x8c(%rbp)
movl   $0x3,-0x90(%rbp)
movl   $0x6,-0x88(%rbp)
mov    -0x84(%rbp),%esi
lea    0xe7d(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x84(%rbp),%edi
lea    -0x50(%rbp),%rsi
call   1040 <print_value@plt>
mov    -0x84(%rbp),%edi
lea    -0x50(%rbp),%rsi
call   1030 <print_address@plt>
lea    0xe60(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x8c(%rbp),%esi
mov    -0x90(%rbp),%edx
lea    0xe48(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x88(%rbp),%edi
lea    -0x80(%rbp),%rsi
call   1040 <print_value@plt>
mov    -0x88(%rbp),%edi
lea    -0x80(%rbp),%rsi
call   1030 <print_address@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x80,%rsp
movaps 0xf21(%rip),%xmm0
movaps %xmm0,0x70(%rsp)
movaps 0xf05(%rip),%xmm0
movaps %xmm0,0x60(%rsp)
movaps 0xee9(%rip),%xmm0
movaps %xmm0,0x50(%rsp)
movaps 0xecd(%rip),%xmm0
movaps %xmm0,0x40(%rsp)
movaps 0xeb1(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
movaps 0xe75(%rip),%xmm0
movaps %xmm0,(%rsp)
movaps 0xe7a(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xe7e(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
lea    0xed2(%rip),%rdi
mov    $0xa,%esi
xor    %eax,%eax
call   1060 <printf@plt>
lea    0x30(%rsp),%rbx
mov    $0xa,%edi
mov    %rbx,%rsi
call   1050 <print_value@plt>
mov    $0xa,%edi
mov    %rbx,%rsi
call   1040 <print_address@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xea7(%rip),%rdi
mov    $0x2,%esi
mov    $0x3,%edx
xor    %eax,%eax
call   1060 <printf@plt>
mov    %rsp,%rbx
mov    $0x6,%edi
mov    %rbx,%rsi
call   1050 <print_value@plt>
mov    $0x6,%edi
mov    %rbx,%rsi
call   1040 <print_address@plt>
add    $0x80,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@__const.main.arreglo = [10 x double] [double 0.000000e+00, double 1.000000e+00, double 2.000000e+00, double 3.000000e+00, double 4.000000e+00, double 5.000000e+00, double 6.000000e+00, double 7.000000e+00, double 8.000000e+00, double 9.000000e+00]
@.str = [17 x i8] c"n arreglo = %d \0A\00"
@.str.1 = [2 x i8] c"\0A\00"
@.str.2 = [22 x i8] c"Fila %d y Columna %d\0A\00"
define void @main() {
%1 = alloca [10 x double]
%2 = alloca [2 x [3 x double]]
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = bitcast [10 x double]* %1 to i8*
%8 = bitcast [2 x [3 x double]]* %2 to i8*
%9 = bitcast i8* %8 to [2 x [3 x double]]*
%10 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %9, i32 0, i32 0
%11 = getelementptr inbounds [3 x double], [3 x double]* %10, i32 0, i32 0
store double 1.100000e+01, double* %11
%12 = getelementptr inbounds [3 x double], [3 x double]* %10, i32 0, i32 1
store double 1.200000e+01, double* %12
%13 = getelementptr inbounds [3 x double], [3 x double]* %10, i32 0, i32 2
store double 1.300000e+01, double* %13
%14 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %9, i32 0, i32 1
%15 = getelementptr inbounds [3 x double], [3 x double]* %14, i32 0, i32 0
store double 2.100000e+01, double* %15
%16 = getelementptr inbounds [3 x double], [3 x double]* %14, i32 0, i32 1
store double 2.200000e+01, double* %16
%17 = getelementptr inbounds [3 x double], [3 x double]* %14, i32 0, i32 2
store double 2.300000e+01, double* %17
store i32 10, i32* %3
store i32 2, i32* %5
store i32 3, i32* %6
store i32 6, i32* %4
%18 = load i32, i32* %3
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 %18)
%20 = load i32, i32* %3
%21 = getelementptr inbounds [10 x double], [10 x double]* %1, i64 0, i64 0
%22 = call i32 @print_value(i32 %20, double* %21)
%23 = load i32, i32* %3
%24 = getelementptr inbounds [10 x double], [10 x double]* %1, i64 0, i64 0
%25 = call i32 @print_address(i32 %23, double* %24)
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%27 = load i32, i32* %5
%28 = load i32, i32* %6
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i32 %27, i32 %28)
%30 = load i32, i32* %4
%31 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %2, i64 0, i64 0
%32 = getelementptr inbounds [3 x double], [3 x double]* %31, i64 0, i64 0
%33 = call i32 @print_value(i32 %30, double* %32)
%34 = load i32, i32* %4
%35 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %2, i64 0, i64 0
%36 = getelementptr inbounds [3 x double], [3 x double]* %35, i64 0, i64 0
%37 = call i32 @print_address(i32 %34, double* %36)
ret void
}

LLVM IR (-O2):
@__const.main.arreglo = [10 x double] [double 0.000000e+00, double 1.000000e+00, double 2.000000e+00, double 3.000000e+00, double 4.000000e+00, double 5.000000e+00, double 6.000000e+00, double 7.000000e+00, double 8.000000e+00, double 9.000000e+00]
@.str = [17 x i8] c"n arreglo = %d \0A\00"
@.str.2 = [22 x i8] c"Fila %d y Columna %d\0A\00"
define void @main() {
%1 = alloca [10 x double]
%2 = alloca [2 x [3 x double]]
%3 = bitcast [10 x double]* %1 to i8*
%4 = bitcast [2 x [3 x double]]* %2 to i8*
%5 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %2, i64 0, i64 0, i64 0
%6 = bitcast [2 x [3 x double]]* %2 to <2 x double>*
store <2 x double> <double 1.100000e+01, double 1.200000e+01>, <2 x double>* %6
%7 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %2, i64 0, i64 0, i64 2
%8 = bitcast double* %7 to <2 x double>*
store <2 x double> <double 1.300000e+01, double 2.100000e+01>, <2 x double>* %8
%9 = getelementptr inbounds [2 x [3 x double]], [2 x [3 x double]]* %2, i64 0, i64 1, i64 1
%10 = bitcast double* %9 to <2 x double>*
store <2 x double> <double 2.200000e+01, double 2.300000e+01>, <2 x double>* %10
%11 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str, i64 0, i64 0), i32 10)
%12 = getelementptr inbounds [10 x double], [10 x double]* %1, i64 0, i64 0
%13 = call i32 @print_value(i32 10, double* %12)
%14 = call i32 @print_address(i32 10, double* %12)
%15 = call i32 @putchar(i32 10)
%16 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i32 2, i32 3)
%17 = call i32 @print_value(i32 6, double* %5)
%18 = call i32 @print_address(i32 6, double* %5)
ret void
}