#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*/ errx(int, char *);
int /*<<< orphan*/ printf(char *, char *);
int /*<<< orphan*/ srand(int /*<<< orphan*/);
char *strfry(char *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
int main(int argc, char *argv[]) {
  if (argc < 2)
    errx(1, "usage: word ...");
  srand(time(NULL));
  for (int i = 1; i < argc; i++) {
    printf("%s -> ", argv[i]);
    printf("%s\n", strfry(argv[i]));
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jge    1181 <main+0x31>
mov    $0x1,%edi
lea    0xe84(%rip),%rsi
call   1030 <errx@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1060 <time@plt>
mov    %eax,%edi
call   1050 <srand@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11ea <main+0x9a>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rsi
lea    0xe59(%rip),%rdi
call   1040 <printf@plt>
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
call   1070 <strfry@plt>
mov    %rax,%rsi
lea    0xe40(%rip),%rdi
call   1040 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1198 <main+0x48>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
mov    %rsi,%rbx
mov    %edi,%ebp
cmp    $0x1,%edi
jg     1173 <main+0x23>
lea    0xe97(%rip),%rsi
mov    $0x1,%edi
call   1030 <errx@plt>
xor    %edi,%edi
call   1060 <time@plt>
mov    %eax,%edi
call   1050 <srand@plt>
cmp    $0x2,%ebp
jl     11c9 <main+0x79>
mov    %ebp,%r12d
mov    $0x1,%ebp
lea    0xe7b(%rip),%r14
lea    0xe7b(%rip),%r15
nopl   0x0(%rax)
mov    (%rbx,%rbp,8),%rsi
mov    %r14,%rdi
call   1040 <printf@plt>
mov    (%rbx,%rbp,8),%rdi
call   1070 <strfry@plt>
mov    %r15,%rdi
mov    %rax,%rsi
call   1040 <printf@plt>
add    $0x1,%rbp
cmp    %rbp,%r12
jne    11a0 <main+0x50>
xor    %eax,%eax
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [16 x i8] c"usage: word ...\00"
@.str.1 = [7 x i8] c"%s -> \00"
@.str.2 = [4 x i8] c"%s\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%7 = load i32, i32* %4
%8 = icmp slt i32 %7, 2
br i1 %8, label %9, label %11
9: ; preds = %2
%10 = call i32 @errx(i32 1, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
br label %11
11: ; preds = %9, %2
%12 = call i32 @time(i32* null)
%13 = call i32 @srand(i32 %12)
store i32 1, i32* %6
br label %14
14: ; preds = %32, %11
%15 = load i32, i32* %6
%16 = load i32, i32* %4
%17 = icmp slt i32 %15, %16
br i1 %17, label %18, label %35
18: ; preds = %14
%19 = load i8**, i8*** %5
%20 = load i32, i32* %6
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds i8*, i8** %19, i64 %21
%23 = load i8*, i8** %22
%24 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %23)
%25 = load i8**, i8*** %5
%26 = load i32, i32* %6
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds i8*, i8** %25, i64 %27
%29 = load i8*, i8** %28
%30 = call i8* @strfry(i8* %29)
%31 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %30)
br label %32
32: ; preds = %18
%33 = load i32, i32* %6
%34 = add nsw i32 %33, 1
store i32 %34, i32* %6
br label %14
35: ; preds = %14
ret i32 0
}

LLVM IR (-O2):
@.str = [16 x i8] c"usage: word ...\00"
@.str.1 = [7 x i8] c"%s -> \00"
@.str.2 = [4 x i8] c"%s\0A\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp slt i32 %0, 2
br i1 %3, label %4, label %6
4: ; preds = %2
%5 = tail call i32 @errx(i32 1, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
br label %6
6: ; preds = %4, %2
%7 = tail call i32 @time(i32* null)
%8 = tail call i32 @srand(i32 %7)
%9 = icmp sgt i32 %0, 1
br i1 %9, label %10, label %12
10: ; preds = %6
%11 = zext i32 %0 to i64
br label %13
12: ; preds = %13, %6
ret i32 0
13: ; preds = %10, %13
%14 = phi i64 [ 1, %10 ], [ %21, %13 ]
%15 = getelementptr inbounds i8*, i8** %1, i64 %14
%16 = load i8*, i8** %15
%17 = tail call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %16)
%18 = load i8*, i8** %15
%19 = tail call i8* @strfry(i8* %18)
%20 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %19)
%21 = add nuw nsw i64 %14, 1
%22 = icmp eq i64 %21, %11
br i1 %22, label %12, label %13
}