#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*/ leer(int *, int);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ prvc(int *, int *, int);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int v[100], vc[100], a;
  do {
    printf("**************************************\n");
    printf("*   Introduzca el tamaño del vector  *\n");
    printf("**************************************\n");
    scanf("%d", &a);
  } while (a <= 0 || a > 100);
  printf("**************************************\n");
  printf("* Introduza Datos para el vector '1' *\n");
  printf("**************************************\n");
  leer(v, a);
  printf("**************************************\n");
  printf("* Introduza Datos para el vector '2'*\n");
  printf("**************************************\n");
  leer(vc, a);
  prvc(v, vc, a);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x340,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xea7(%rip),%rdi
call   1040 <printf@plt>
lea    0xec3(%rip),%rdi
call   1040 <printf@plt>
lea    0xe8f(%rip),%rdi
call   1040 <printf@plt>
lea    0xed4(%rip),%rdi
lea    -0x334(%rbp),%rsi
call   1060 <scanf@plt>
mov    $0x1,%al
cmpl   $0x0,-0x334(%rbp)
mov    %al,-0x335(%rbp)
jle    11ae <main+0x6e>
cmpl   $0x64,-0x334(%rbp)
setg   %al
mov    %al,-0x335(%rbp)
mov    -0x335(%rbp),%al
test   $0x1,%al
jne    1152 <main+0x12>
lea    0xe3d(%rip),%rdi
call   1040 <printf@plt>
lea    0xe85(%rip),%rdi
call   1040 <printf@plt>
lea    0xe25(%rip),%rdi
call   1040 <printf@plt>
lea    -0x1a0(%rbp),%rdi
mov    -0x334(%rbp),%esi
call   1050 <leer@plt>
lea    0xe07(%rip),%rdi
call   1040 <printf@plt>
lea    0xe77(%rip),%rdi
call   1040 <printf@plt>
lea    0xdef(%rip),%rdi
call   1040 <printf@plt>
lea    -0x330(%rbp),%rdi
mov    -0x334(%rbp),%esi
call   1050 <leer@plt>
lea    -0x1a0(%rbp),%rdi
lea    -0x330(%rbp),%rsi
mov    -0x334(%rbp),%edx
call   1030 <prvc@plt>
xor    %eax,%eax
add    $0x340,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x338,%rsp
lea    0xf23(%rip),%rbx
lea    0xea7(%rip),%r14
lea    0xe9d(%rip),%r15
lea    0xc(%rsp),%r12
nopl   0x0(%rax,%rax,1)
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    %r14,%rdi
call   1030 <puts@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    %r15,%rdi
mov    %r12,%rsi
call   1060 <scanf@plt>
mov    0xc(%rsp),%eax
add    $0xffffff9b,%eax
cmp    $0xffffff9c,%eax
jb     1170 <main+0x30>
lea    0xed2(%rip),%rbx
mov    %rbx,%rdi
call   1030 <puts@plt>
lea    0xe76(%rip),%rdi
call   1030 <puts@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    0xc(%rsp),%esi
lea    0x1a0(%rsp),%r14
mov    %r14,%rdi
call   1050 <leer@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
lea    0xe6d(%rip),%rdi
call   1030 <puts@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
mov    0xc(%rsp),%esi
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
call   1050 <leer@plt>
mov    0xc(%rsp),%edx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <prvc@plt>
xor    %eax,%eax
add    $0x338,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [40 x i8] c"**************************************\0A\00"
@.str.1 = [41 x i8] c"* Introduzca el tama\C3\B1o del vector *\0A\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [40 x i8] c"* Introduza Datos para el vector '1' *\0A\00"
@.str.4 = [39 x i8] c"* Introduza Datos para el vector '2'*\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [100 x i32]
%3 = alloca [100 x i32]
%4 = alloca i32
store i32 0, i32* %1
br label %5
5: ; preds = %16, %0
%6 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%9 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %4)
br label %10
10: ; preds = %5
%11 = load i32, i32* %4
%12 = icmp sle i32 %11, 0
br i1 %12, label %16, label %13
13: ; preds = %10
%14 = load i32, i32* %4
%15 = icmp sgt i32 %14, 100
br label %16
16: ; preds = %13, %10
%17 = phi i1 [ true, %10 ], [ %15, %13 ]
br i1 %17, label %5, label %18
18: ; preds = %16
%19 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%20 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.3, i64 0, i64 0))
%21 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%22 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 0
%23 = load i32, i32* %4
%24 = call i32 @leer(i32* %22, i32 %23)
%25 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%26 = call i32 @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.4, i64 0, i64 0))
%27 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%28 = getelementptr inbounds [100 x i32], [100 x i32]* %3, i64 0, i64 0
%29 = load i32, i32* %4
%30 = call i32 @leer(i32* %28, i32 %29)
%31 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 0
%32 = getelementptr inbounds [100 x i32], [100 x i32]* %3, i64 0, i64 0
%33 = load i32, i32* %4
%34 = call i32 @prvc(i32* %31, i32* %32, i32 %33)
ret i32 0
}

LLVM IR (-O2):
@.str.2 = [3 x i8] c"%d\00"
@str.5 = [40 x i8] c"* Introduzca el tama\C3\B1o del vector *\00"
@str.8 = [39 x i8] c"* Introduza Datos para el vector '1' *\00"
@str.11 = [38 x i8] c"* Introduza Datos para el vector '2'*\00"
@str.12 = [39 x i8] c"**************************************\00"
define i32 @main() {
%1 = alloca [100 x i32]
%2 = alloca [100 x i32]
%3 = alloca i32
%4 = bitcast [100 x i32]* %1 to i8*
%5 = bitcast [100 x i32]* %2 to i8*
%6 = bitcast i32* %3 to i8*
br label %7
7: ; preds = %7, %0
%8 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%9 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @str.5, i64 0, i64 0))
%10 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%11 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %3)
%12 = load i32, i32* %3
%13 = add i32 %12, -101
%14 = icmp ult i32 %13, -100
br i1 %14, label %7, label %15
15: ; preds = %7
%16 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%17 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.8, i64 0, i64 0))
%18 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%19 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 0
%20 = load i32, i32* %3
%21 = call i32 @leer(i32* %19, i32 %20)
%22 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%23 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str.11, i64 0, i64 0))
%24 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%25 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 0
%26 = load i32, i32* %3
%27 = call i32 @leer(i32* %25, i32 %26)
%28 = load i32, i32* %3
%29 = call i32 @prvc(i32* %19, i32* %25, i32 %28)
ret i32 0
}