#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 */
char *permuationDicitonary(char *, char *);
int /*<<< orphan*/ printf(char *, ...);
int main() {
  char *a = "The eyes";
  char *b = "They see";
  char *c = "dac";
  printf("Permutation dictionary method:\n");
  printf("%s matches %s: %s\n", a, b, permuationDicitonary(a, b));
  printf("%s matches %s: %s\n", a, c, permuationDicitonary(a, c));
  printf("%s matches %s: %s\n", b, c, permuationDicitonary(b, c));
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
lea    0xed1(%rip),%rax
mov    %rax,-0x8(%rbp)
lea    0xecf(%rip),%rax
mov    %rax,-0x10(%rbp)
lea    0xecd(%rip),%rax
mov    %rax,-0x18(%rbp)
lea    0xec6(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%rax
mov    %rax,-0x48(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <permuationDicitonary@plt>
mov    -0x48(%rbp),%rsi
mov    -0x40(%rbp),%rdx
mov    %rax,%rcx
lea    0xeb0(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%rax
mov    %rax,-0x38(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x30(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <permuationDicitonary@plt>
mov    -0x38(%rbp),%rsi
mov    -0x30(%rbp),%rdx
mov    %rax,%rcx
lea    0xe7a(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <permuationDicitonary@plt>
mov    -0x28(%rbp),%rsi
mov    -0x20(%rbp),%rdx
mov    %rax,%rcx
lea    0xe44(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
lea    0xeea(%rip),%rdi
call   1030 <puts@plt>
lea    0xeb5(%rip),%r12
lea    0xeb7(%rip),%r15
mov    %r12,%rdi
mov    %r15,%rsi
call   1040 <permuationDicitonary@plt>
lea    0xeb2(%rip),%r14
mov    %r14,%rdi
mov    %r12,%rsi
mov    %r15,%rdx
mov    %rax,%rcx
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe94(%rip),%rbx
mov    %r12,%rdi
mov    %rbx,%rsi
call   1040 <permuationDicitonary@plt>
mov    %r14,%rdi
mov    %r12,%rsi
mov    %rbx,%rdx
mov    %rax,%rcx
xor    %eax,%eax
call   1050 <printf@plt>
mov    %r15,%rdi
mov    %rbx,%rsi
call   1040 <permuationDicitonary@plt>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %rbx,%rdx
mov    %rax,%rcx
xor    %eax,%eax
call   1050 <printf@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [9 x i8] c"The eyes\00"
@.str.1 = [9 x i8] c"They see\00"
@.str.2 = [4 x i8] c"dac\00"
@.str.3 = [32 x i8] c"Permutation dictionary method:\0A\00"
@.str.4 = [19 x i8] c"%s matches %s: %s\0A\00"
define i32 @main() {
%1 = alloca i8*
%2 = alloca i8*
%3 = alloca i8*
store i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8** %1
store i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8** %2
store i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8** %3
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3, i64 0, i64 0))
%5 = load i8*, i8** %1
%6 = load i8*, i8** %2
%7 = load i8*, i8** %1
%8 = load i8*, i8** %2
%9 = call i8* @permuationDicitonary(i8* %7, i8* %8)
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* %5, i8* %6, i8* %9)
%11 = load i8*, i8** %1
%12 = load i8*, i8** %3
%13 = load i8*, i8** %1
%14 = load i8*, i8** %3
%15 = call i8* @permuationDicitonary(i8* %13, i8* %14)
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* %11, i8* %12, i8* %15)
%17 = load i8*, i8** %2
%18 = load i8*, i8** %3
%19 = load i8*, i8** %2
%20 = load i8*, i8** %3
%21 = call i8* @permuationDicitonary(i8* %19, i8* %20)
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* %17, i8* %18, i8* %21)
ret i32 0
}

LLVM IR (-O2):
@.str = [9 x i8] c"The eyes\00"
@.str.1 = [9 x i8] c"They see\00"
@.str.2 = [4 x i8] c"dac\00"
@.str.4 = [19 x i8] c"%s matches %s: %s\0A\00"
@str = [31 x i8] c"Permutation dictionary method:\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str, i64 0, i64 0))
%2 = tail call i8* @permuationDicitonary(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* %2)
%4 = tail call i8* @permuationDicitonary(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %4)
%6 = tail call i8* @permuationDicitonary(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
%7 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %6)
ret i32 0
}