#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*/ llena_vector(int *, int);
int /*<<< orphan*/ ordena_vector(int *, int);
int /*<<< orphan*/ pinta_vector(int *, int);
int /*<<< orphan*/ printf(char *);
int main(void) {
  int m[25];
  llena_vector(m, 25);
  printf("\n\nVector original (Antes de ordenar):");
  pinta_vector(m, 25);
  ordena_vector(m, 25);
  printf("Vector final (Despues de ordenar):");
  pinta_vector(m, 25);
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x70(%rbp),%rdi
mov    $0x19,%esi
call   1060 <llena_vector@plt>
lea    0xe9c(%rip),%rdi
call   1030 <printf@plt>
lea    -0x70(%rbp),%rdi
mov    $0x19,%esi
call   1040 <pinta_vector@plt>
lea    -0x70(%rbp),%rdi
mov    $0x19,%esi
call   1050 <ordena_vector@plt>
lea    0xe9a(%rip),%rdi
call   1030 <printf@plt>
lea    -0x70(%rbp),%rdi
mov    $0x19,%esi
call   1040 <pinta_vector@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x70,%rsp
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0x19,%esi
call   1060 <llena_vector@plt>
lea    0xea4(%rip),%rdi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x19,%esi
call   1040 <pinta_vector@plt>
mov    %rbx,%rdi
mov    $0x19,%esi
call   1050 <ordena_vector@plt>
lea    0xea4(%rip),%rdi
call   1030 <printf@plt>
mov    %rbx,%rdi
mov    $0x19,%esi
call   1040 <pinta_vector@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [38 x i8] c"\0A\0AVector original (Antes de ordenar):\00"
@.str.1 = [35 x i8] c"Vector final (Despues de ordenar):\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [25 x i32]
store i32 0, i32* %1
%3 = getelementptr inbounds [25 x i32], [25 x i32]* %2, i64 0, i64 0
%4 = call i32 @llena_vector(i32* %3, i32 25)
%5 = call i32 @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
%6 = getelementptr inbounds [25 x i32], [25 x i32]* %2, i64 0, i64 0
%7 = call i32 @pinta_vector(i32* %6, i32 25)
%8 = getelementptr inbounds [25 x i32], [25 x i32]* %2, i64 0, i64 0
%9 = call i32 @ordena_vector(i32* %8, i32 25)
%10 = call i32 @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0))
%11 = getelementptr inbounds [25 x i32], [25 x i32]* %2, i64 0, i64 0
%12 = call i32 @pinta_vector(i32* %11, i32 25)
ret i32 0
}

LLVM IR (-O2):
@.str = [38 x i8] c"\0A\0AVector original (Antes de ordenar):\00"
@.str.1 = [35 x i8] c"Vector final (Despues de ordenar):\00"
define i32 @main() {
%1 = alloca [25 x i32]
%2 = bitcast [25 x i32]* %1 to i8*
%3 = getelementptr inbounds [25 x i32], [25 x i32]* %1, i64 0, i64 0
%4 = call i32 @llena_vector(i32* %3, i32 25)
%5 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0))
%6 = call i32 @pinta_vector(i32* %3, i32 25)
%7 = call i32 @ordena_vector(i32* %3, i32 25)
%8 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0))
%9 = call i32 @pinta_vector(i32* %3, i32 25)
ret i32 0
}