#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);
int verifica(char *, char **);
int main(void) {
  char parola[] = {'P', 'I', 'E', 'R', 'O', 'C', 'H', 'A', 'T', '\0'};
  char schema[5][5] = {'Z', 'B', 'C', 'O', 'P', 'E', 'F', 'A', 'I',
                       'T', 'O', 'I', 'A', 'E', 'A', 'M', 'B', 'R',
                       'O', 'H', 'M', 'P', 'A', 'C', 'F'};
  printf("\nVerifica: %d", verifica(parola, schema));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeca(%rip),%rax
mov    %rax,-0xe(%rbp)
mov    0xec7(%rip),%ax
mov    %ax,-0x6(%rbp)
mov    0xed4(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xed1(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xece(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xecc(%rip),%al
mov    %al,-0x18(%rbp)
lea    -0xe(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1040 <verifica@plt>
mov    %eax,%esi
lea    0xe85(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x38,%rsp
movabs $0x4148434f52454950,%rax
43 48 41
mov    %rax,(%rsp)
movw   $0x54,0x8(%rsp)
movups 0xee9(%rip),%xmm0
movups %xmm0,0x19(%rsp)
movaps 0xed4(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
mov    %rsp,%rdi
lea    0x10(%rsp),%rsi
call   1040 <verifica@plt>
lea    0xea5(%rip),%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x38,%rsp
ret

LLVM IR (-O0):
@__const.main.parola = [10 x i8] c"PIEROCHAT\00"
@__const.main.schema = [5 x [5 x i8]] [[5 x i8] c"ZBCOP", [5 x i8] c"EFAIT", [5 x i8] c"OIAEA", [5 x i8] c"MBROH", [5 x i8] c"MPACF"]
@.str = [14 x i8] c"\0AVerifica: %d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [10 x i8]
%3 = alloca [5 x [5 x i8]]
store i32 0, i32* %1
%4 = bitcast [10 x i8]* %2 to i8*
%5 = bitcast [5 x [5 x i8]]* %3 to i8*
%6 = getelementptr inbounds [10 x i8], [10 x i8]* %2, i64 0, i64 0
%7 = getelementptr inbounds [5 x [5 x i8]], [5 x [5 x i8]]* %3, i64 0, i64 0
%8 = bitcast [5 x i8]* %7 to i8**
%9 = call i32 @verifica(i8* %6, i8** %8)
%10 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 %9)
ret i32 0
}

LLVM IR (-O2):
@__const.main.parola = [10 x i8] c"PIEROCHAT\00"
@__const.main.schema = [5 x [5 x i8]] [[5 x i8] c"ZBCOP", [5 x i8] c"EFAIT", [5 x i8] c"OIAEA", [5 x i8] c"MBROH", [5 x i8] c"MPACF"]
@.str = [14 x i8] c"\0AVerifica: %d\00"
define i32 @main() {
%1 = alloca [10 x i8]
%2 = alloca [5 x [5 x i8]]
%3 = getelementptr inbounds [10 x i8], [10 x i8]* %1, i64 0, i64 0
%4 = getelementptr inbounds [5 x [5 x i8]], [5 x [5 x i8]]* %2, i64 0, i64 0, i64 0
%5 = bitcast [5 x [5 x i8]]* %2 to i8**
%6 = call i32 @verifica(i8* %3, i8** %5)
%7 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i32 %6)
ret i32 0
}