#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 *, float);
scalar_t__ strlen(char *);
float timeit();
int main(int argc, char *argv[]) {
  float start = timeit();
  int count_to = 1000;
  int letter_count = 0;
  int tens_offset = 2;
  char *number_words[5][10] = {{"", "one", "two", "three", "four", "five",
                                "six", "seven", "eight", "nine"},
                               {"ten", "eleven", "twelve", "thirteen",
                                "fourteen", "fifteen", "sixteen", "seventeen",
                                "eighteen", "nineteen"},
                               {"twenty", "thirty", "forty", "fifty", "sixty",
                                "seventy", "eighty", "ninety"},
                               {"", "hundred", "hundredand"},
                               {"", "thousand"}};
  int i, current;
  for (i = 1, current = i; i <= count_to; i++, current = i) {
    letter_count += strlen(number_words[0][current / 1000]);
    letter_count += strlen(number_words[4][current / 1000]);
    current %= 1000;
    letter_count += current / 100 > 0
                        ? current % 100 > 0
                              ? strlen(number_words[0][current / 100]) +
                                    strlen(number_words[3][2])
                              : strlen(number_words[0][current / 100]) +
                                    strlen(number_words[3][1])
                        : strlen(number_words[3][0]);
    current %= 100;
    letter_count +=
        current / 10 > 0
            ? current / 10 == 1
                  ? strlen(number_words[1][current % 10])
                  : strlen(number_words[2][(current / 10) - tens_offset]) +
                        strlen(number_words[0][current % 10])
            : strlen(number_words[0][current % 10]);
  }
  float stop = timeit();
  printf("Answer: %d\n", letter_count);
  printf("Time: %f\n", stop - start);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x200,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1060 <timeit@plt>
movss  %xmm0,-0x14(%rbp)
movl   $0x3e8,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
movl   $0x2,-0x20(%rbp)
lea    -0x1b0(%rbp),%rdi
lea    0x2b08(%rip),%rsi
mov    $0x190,%edx
call   1050 <memcpy@plt>
movl   $0x1,-0x1b4(%rbp)
mov    -0x1b4(%rbp),%eax
mov    %eax,-0x1b8(%rbp)
mov    -0x1b4(%rbp),%eax
cmp    -0x18(%rbp),%eax
jg     143c <main+0x2fc>
mov    -0x1b8(%rbp),%eax
mov    $0x3e8,%ecx
cltd
idiv   %ecx
cltq
mov    -0x1b0(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0x3e8,%ecx
cltd
idiv   %ecx
cltq
mov    -0x70(%rbp,%rax,8),%rdi
call   1030 <strlen@plt>
mov    %rax,%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0x3e8,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1b8(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
cmp    $0x0,%eax
jle    12ea <main+0x1aa>
mov    -0x1b8(%rbp),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jle    1293 <main+0x153>
mov    -0x1b8(%rbp),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
cltq
mov    -0x1b0(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,-0x1d0(%rbp)
mov    -0xb0(%rbp),%rdi
call   1030 <strlen@plt>
mov    %rax,%rcx
mov    -0x1d0(%rbp),%rax
add    %rcx,%rax
mov    %rax,-0x1c8(%rbp)
jmp    12d7 <main+0x197>
mov    -0x1b8(%rbp),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
cltq
mov    -0x1b0(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,-0x1d8(%rbp)
mov    -0xb8(%rbp),%rdi
call   1030 <strlen@plt>
mov    %rax,%rcx
mov    -0x1d8(%rbp),%rax
add    %rcx,%rax
mov    %rax,-0x1c8(%rbp)
mov    -0x1c8(%rbp),%rax
mov    %rax,-0x1e0(%rbp)
jmp    12fd <main+0x1bd>
mov    -0xc0(%rbp),%rdi
call   1030 <strlen@plt>
mov    %rax,-0x1e0(%rbp)
mov    -0x1e0(%rbp),%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1b8(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
cmp    $0x0,%eax
jle    13e6 <main+0x2a6>
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
cmp    $0x1,%eax
jne    137a <main+0x23a>
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
movslq %edx,%rax
mov    -0x160(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,-0x1e8(%rbp)
jmp    13d3 <main+0x293>
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
sub    -0x20(%rbp),%eax
cltq
mov    -0x110(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,-0x1f0(%rbp)
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
movslq %edx,%rax
mov    -0x1b0(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,%rcx
mov    -0x1f0(%rbp),%rax
add    %rcx,%rax
mov    %rax,-0x1e8(%rbp)
mov    -0x1e8(%rbp),%rax
mov    %rax,-0x1f8(%rbp)
jmp    140b <main+0x2cb>
mov    -0x1b8(%rbp),%eax
mov    $0xa,%ecx
cltd
idiv   %ecx
movslq %edx,%rax
mov    -0x1b0(%rbp,%rax,8),%rdi
ff
call   1030 <strlen@plt>
mov    %rax,-0x1f8(%rbp)
mov    -0x1f8(%rbp),%rcx
movslq -0x1c(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x1c(%rbp)
mov    -0x1b4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1b4(%rbp)
mov    -0x1b4(%rbp),%eax
mov    %eax,-0x1b8(%rbp)
jmp    11a8 <main+0x68>
mov    $0x0,%al
call   1060 <timeit@plt>
movss  %xmm0,-0x1bc(%rbp)
ff
cvtsi2ssl -0x1c(%rbp),%xmm0
lea    0xc78(%rip),%rdi
call   1040 <printf@plt>
movss  -0x1bc(%rbp),%xmm0
ff
subss  -0x14(%rbp),%xmm0
lea    0xc6b(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x200,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
xor    %r15d,%r15d
xor    %eax,%eax
call   1050 <timeit@plt>
movss  %xmm0,0xc(%rsp)
mov    $0xfffffc18,%r12d
mov    $0x1,%bx
jmp    119d <main+0x6d>
nopw   0x0(%rax,%rax,1)
add    %eax,%r14d
add    $0x7,%r14d
xor    %ebp,%ebp
movzbl %bpl,%eax
imul   $0xcd,%eax,%ecx
shr    $0xa,%ecx
and    $0xfffffffe,%ecx
lea    (%rcx,%rcx,4),%ecx
sub    %cl,%al
movzbl %al,%eax
mov    0x0(%r13,%rax,8),%rdi
call   1030 <strlen@plt>
mov    %rax,%r15
add    %r14d,%r15d
add    $0x1,%ebx
inc    %r12d
je     134a <main+0x21a>
mov    %rbx,0x10(%rsp)
movzwl %bx,%ebp
mov    %ebp,%eax
shr    $0x3,%eax
imul   $0x20c5,%eax,%r13d
shr    $0x14,%r13d
imul   $0xfffffc18,%r13d,%eax
movzwl %ax,%eax
mov    %rax,(%rsp)
lea    0x3e9(%r12),%eax
movzwl %ax,%eax
shr    $0x3,%eax
imul   $0x20c5,%eax,%eax
shr    $0x14,%eax
lea    0x2aaf(%rip),%rcx
mov    (%rcx,%rax,8),%rdi
mov    0x140(%rcx,%rax,8),%r14
call   1030 <strlen@plt>
mov    %rax,%rbx
add    %r15d,%ebx
mov    %r14,%rdi
call   1030 <strlen@plt>
mov    %rax,%r14
add    %ebx,%r14d
mov    (%rsp),%rax
add    %r12d,%eax
add    $0x3e9,%eax
cmp    $0x63,%ax
ja     1260 <main+0x130>
shl    $0x3,%r13d
lea    0x0(%r13,%r13,2),%eax
mov    0x10(%rsp),%rsi
lea    (%rsi,%rax,1),%ecx
movzbl %cl,%ecx
lea    (%rcx,%rcx,4),%edx
lea    (%rcx,%rdx,8),%ecx
shr    $0xc,%ecx
imul   $0x64,%ecx,%ecx
sub    %cl,%al
movzbl %al,%eax
add    %r12d,%eax
add    $0x3e9,%eax
movzbl %al,%ebp
xor    %eax,%eax
mov    %rsi,%rbx
lea    0x2a3c(%rip),%r13
jmp    12ca <main+0x19a>
cs nopw 0x0(%rax,%rax,1)
mov    0x10(%rsp),%rbx
imul   $0x3e8,%r13d,%ecx
sub    %ecx,%ebp
movzwl %bp,%edx
shr    $0x2,%edx
imul   $0x147b,%edx,%edx
shr    $0x11,%edx
imul   $0xffffff9c,%edx,%edx
sub    %ecx,%edx
or     $0x1,%edx
movzwl %dx,%r15d
movzwl %ax,%eax
shr    $0x2,%eax
imul   $0x147b,%eax,%eax
shr    $0x11,%eax
lea    (%r12,%r15,1),%ecx
movzwl %cx,%ebp
lea    0x29ea(%rip),%r13
mov    0x0(%r13,%rax,8),%rdi
call   1030 <strlen@plt>
cmp    $0xfc18,%ebp
je     1160 <main+0x30>
lea    (%r12,%r15,1),%ebp
add    $0x3e8,%ebp
add    $0xa,%rax
add    %eax,%r14d
cmp    $0xa,%bp
jb     1169 <main+0x39>
movzwl %bp,%eax
add    $0xfffffff6,%eax
cmp    $0x9,%eax
ja     1306 <main+0x1d6>
movzbl %bpl,%eax
imul   $0xcd,%eax,%eax
shr    $0xa,%eax
and    $0xfffffffe,%eax
lea    (%rax,%rax,4),%eax
sub    %al,%bpl
movzbl %bpl,%eax
mov    0x50(%r13,%rax,8),%rdi
jmp    1186 <main+0x56>
movzbl %bpl,%eax
imul   $0xcd,%eax,%eax
shr    $0xb,%eax
lea    (%rax,%rax,1),%ecx
lea    (%rcx,%rcx,4),%ecx
sub    %cl,%bpl
add    $0xfffffffe,%eax
mov    0xa0(%r13,%rax,8),%rdi
call   1030 <strlen@plt>
mov    %r13,%rcx
mov    %rax,%r13
movzbl %bpl,%eax
mov    (%rcx,%rax,8),%rdi
call   1030 <strlen@plt>
mov    %rax,%r15
add    %r13,%r15
jmp    118e <main+0x5e>
xor    %eax,%eax
call   1050 <timeit@plt>
movss  %xmm0,(%rsp)
xorps  %xmm0,%xmm0
cvtsi2ss %r15d,%xmm0
lea    0xd6a(%rip),%rdi
call   1040 <printf@plt>
movss  (%rsp),%xmm0
subss  0xc(%rsp),%xmm0
lea    0xd5f(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [1 x i8] zeroinitializer
@.str.1 = [4 x i8] c"one\00"
@.str.2 = [4 x i8] c"two\00"
@.str.3 = [6 x i8] c"three\00"
@.str.4 = [5 x i8] c"four\00"
@.str.5 = [5 x i8] c"five\00"
@.str.6 = [4 x i8] c"six\00"
@.str.7 = [6 x i8] c"seven\00"
@.str.8 = [6 x i8] c"eight\00"
@.str.9 = [5 x i8] c"nine\00"
@.str.10 = [4 x i8] c"ten\00"
@.str.11 = [7 x i8] c"eleven\00"
@.str.12 = [7 x i8] c"twelve\00"
@.str.13 = [9 x i8] c"thirteen\00"
@.str.14 = [9 x i8] c"fourteen\00"
@.str.15 = [8 x i8] c"fifteen\00"
@.str.16 = [8 x i8] c"sixteen\00"
@.str.17 = [10 x i8] c"seventeen\00"
@.str.18 = [9 x i8] c"eighteen\00"
@.str.19 = [9 x i8] c"nineteen\00"
@.str.20 = [7 x i8] c"twenty\00"
@.str.21 = [7 x i8] c"thirty\00"
@.str.22 = [6 x i8] c"forty\00"
@.str.23 = [6 x i8] c"fifty\00"
@.str.24 = [6 x i8] c"sixty\00"
@.str.25 = [8 x i8] c"seventy\00"
@.str.26 = [7 x i8] c"eighty\00"
@.str.27 = [7 x i8] c"ninety\00"
@.str.28 = [8 x i8] c"hundred\00"
@.str.29 = [11 x i8] c"hundredand\00"
@.str.30 = [9 x i8] c"thousand\00"
@__const.main.number_words = <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }> <{ [10 x i8*] [i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i32 0, i32 0)], [10 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.11, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.13, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.14, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.15, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.16, i32 0, i32 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.17, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.19, i32 0, i32 0)], [10 x i8*] [i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.20, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.21, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.22, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.23, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.24, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.25, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.26, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.27, i32 0, i32 0), i8* null, i8* null], [10 x i8*] [i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.28, i32 0, i32 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.29, i32 0, i32 0), i8* null, i8* null, i8* null, i8* null, i8* null, i8* null, i8* null], <{ i8*, i8*, [8 x i8*] }> <{ i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.30, i32 0, i32 0), [8 x i8*] zeroinitializer }> }>
@.str.31 = [12 x i8] c"Answer: %d\0A\00"
@.str.32 = [10 x i8] c"Time: %f\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca float
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca [5 x [10 x i8*]]
%11 = alloca i32
%12 = alloca i32
%13 = alloca float
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%14 = call float (...) @timeit()
store float %14, float* %6
store i32 1000, i32* %7
store i32 0, i32* %8
store i32 2, i32* %9
%15 = bitcast [5 x [10 x i8*]]* %10 to i8*
store i32 1, i32* %11
%16 = load i32, i32* %11
store i32 %16, i32* %12
br label %17
17: ; preds = %143, %2
%18 = load i32, i32* %11
%19 = load i32, i32* %7
%20 = icmp sle i32 %18, %19
br i1 %20, label %21, label %147
21: ; preds = %17
%22 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 0
%23 = load i32, i32* %12
%24 = sdiv i32 %23, 1000
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds [10 x i8*], [10 x i8*]* %22, i64 0, i64 %25
%27 = load i8*, i8** %26
%28 = call i64 @strlen(i8* %27)
%29 = load i32, i32* %8
%30 = sext i32 %29 to i64
%31 = add nsw i64 %30, %28
%32 = trunc i64 %31 to i32
store i32 %32, i32* %8
%33 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 4
%34 = load i32, i32* %12
%35 = sdiv i32 %34, 1000
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds [10 x i8*], [10 x i8*]* %33, i64 0, i64 %36
%38 = load i8*, i8** %37
%39 = call i64 @strlen(i8* %38)
%40 = load i32, i32* %8
%41 = sext i32 %40 to i64
%42 = add nsw i64 %41, %39
%43 = trunc i64 %42 to i32
store i32 %43, i32* %8
%44 = load i32, i32* %12
%45 = srem i32 %44, 1000
store i32 %45, i32* %12
%46 = load i32, i32* %12
%47 = sdiv i32 %46, 100
%48 = icmp sgt i32 %47, 0
br i1 %48, label %49, label %81
49: ; preds = %21
%50 = load i32, i32* %12
%51 = srem i32 %50, 100
%52 = icmp sgt i32 %51, 0
br i1 %52, label %53, label %66
53: ; preds = %49
%54 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 0
%55 = load i32, i32* %12
%56 = sdiv i32 %55, 100
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds [10 x i8*], [10 x i8*]* %54, i64 0, i64 %57
%59 = load i8*, i8** %58
%60 = call i64 @strlen(i8* %59)
%61 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 3
%62 = getelementptr inbounds [10 x i8*], [10 x i8*]* %61, i64 0, i64 2
%63 = load i8*, i8** %62
%64 = call i64 @strlen(i8* %63)
%65 = add nsw i64 %60, %64
br label %79
66: ; preds = %49
%67 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 0
%68 = load i32, i32* %12
%69 = sdiv i32 %68, 100
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds [10 x i8*], [10 x i8*]* %67, i64 0, i64 %70
%72 = load i8*, i8** %71
%73 = call i64 @strlen(i8* %72)
%74 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 3
%75 = getelementptr inbounds [10 x i8*], [10 x i8*]* %74, i64 0, i64 1
%76 = load i8*, i8** %75
%77 = call i64 @strlen(i8* %76)
%78 = add nsw i64 %73, %77
br label %79
79: ; preds = %66, %53
%80 = phi i64 [ %65, %53 ], [ %78, %66 ]
br label %86
81: ; preds = %21
%82 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 3
%83 = getelementptr inbounds [10 x i8*], [10 x i8*]* %82, i64 0, i64 0
%84 = load i8*, i8** %83
%85 = call i64 @strlen(i8* %84)
br label %86
86: ; preds = %81, %79
%87 = phi i64 [ %80, %79 ], [ %85, %81 ]
%88 = load i32, i32* %8
%89 = sext i32 %88 to i64
%90 = add nsw i64 %89, %87
%91 = trunc i64 %90 to i32
store i32 %91, i32* %8
%92 = load i32, i32* %12
%93 = srem i32 %92, 100
store i32 %93, i32* %12
%94 = load i32, i32* %12
%95 = sdiv i32 %94, 10
%96 = icmp sgt i32 %95, 0
br i1 %96, label %97, label %129
97: ; preds = %86
%98 = load i32, i32* %12
%99 = sdiv i32 %98, 10
%100 = icmp eq i32 %99, 1
br i1 %100, label %101, label %109
101: ; preds = %97
%102 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 1
%103 = load i32, i32* %12
%104 = srem i32 %103, 10
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds [10 x i8*], [10 x i8*]* %102, i64 0, i64 %105
%107 = load i8*, i8** %106
%108 = call i64 @strlen(i8* %107)
br label %127
109: ; preds = %97
%110 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 2
%111 = load i32, i32* %12
%112 = sdiv i32 %111, 10
%113 = load i32, i32* %9
%114 = sub nsw i32 %112, %113
%115 = sext i32 %114 to i64
%116 = getelementptr inbounds [10 x i8*], [10 x i8*]* %110, i64 0, i64 %115
%117 = load i8*, i8** %116
%118 = call i64 @strlen(i8* %117)
%119 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 0
%120 = load i32, i32* %12
%121 = srem i32 %120, 10
%122 = sext i32 %121 to i64
%123 = getelementptr inbounds [10 x i8*], [10 x i8*]* %119, i64 0, i64 %122
%124 = load i8*, i8** %123
%125 = call i64 @strlen(i8* %124)
%126 = add nsw i64 %118, %125
br label %127
127: ; preds = %109, %101
%128 = phi i64 [ %108, %101 ], [ %126, %109 ]
br label %137
129: ; preds = %86
%130 = getelementptr inbounds [5 x [10 x i8*]], [5 x [10 x i8*]]* %10, i64 0, i64 0
%131 = load i32, i32* %12
%132 = srem i32 %131, 10
%133 = sext i32 %132 to i64
%134 = getelementptr inbounds [10 x i8*], [10 x i8*]* %130, i64 0, i64 %133
%135 = load i8*, i8** %134
%136 = call i64 @strlen(i8* %135)
br label %137
137: ; preds = %129, %127
%138 = phi i64 [ %128, %127 ], [ %136, %129 ]
%139 = load i32, i32* %8
%140 = sext i32 %139 to i64
%141 = add nsw i64 %140, %138
%142 = trunc i64 %141 to i32
store i32 %142, i32* %8
br label %143
143: ; preds = %137
%144 = load i32, i32* %11
%145 = add nsw i32 %144, 1
store i32 %145, i32* %11
%146 = load i32, i32* %11
store i32 %146, i32* %12
br label %17
147: ; preds = %17
%148 = call float (...) @timeit()
store float %148, float* %13
%149 = load i32, i32* %8
%150 = sitofp i32 %149 to float
%151 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.31, i64 0, i64 0), float %150)
%152 = load float, float* %13
%153 = load float, float* %6
%154 = fsub float %152, %153
%155 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.32, i64 0, i64 0), float %154)
ret i32 0
}

LLVM IR (-O2):
@.str = [1 x i8] zeroinitializer
@.str.1 = [4 x i8] c"one\00"
@.str.2 = [4 x i8] c"two\00"
@.str.3 = [6 x i8] c"three\00"
@.str.4 = [5 x i8] c"four\00"
@.str.5 = [5 x i8] c"five\00"
@.str.6 = [4 x i8] c"six\00"
@.str.7 = [6 x i8] c"seven\00"
@.str.8 = [6 x i8] c"eight\00"
@.str.9 = [5 x i8] c"nine\00"
@.str.10 = [4 x i8] c"ten\00"
@.str.11 = [7 x i8] c"eleven\00"
@.str.12 = [7 x i8] c"twelve\00"
@.str.13 = [9 x i8] c"thirteen\00"
@.str.14 = [9 x i8] c"fourteen\00"
@.str.15 = [8 x i8] c"fifteen\00"
@.str.16 = [8 x i8] c"sixteen\00"
@.str.17 = [10 x i8] c"seventeen\00"
@.str.18 = [9 x i8] c"eighteen\00"
@.str.19 = [9 x i8] c"nineteen\00"
@.str.20 = [7 x i8] c"twenty\00"
@.str.21 = [7 x i8] c"thirty\00"
@.str.22 = [6 x i8] c"forty\00"
@.str.23 = [6 x i8] c"fifty\00"
@.str.24 = [6 x i8] c"sixty\00"
@.str.25 = [8 x i8] c"seventy\00"
@.str.26 = [7 x i8] c"eighty\00"
@.str.27 = [7 x i8] c"ninety\00"
@.str.28 = [8 x i8] c"hundred\00"
@.str.29 = [11 x i8] c"hundredand\00"
@.str.30 = [9 x i8] c"thousand\00"
@__const.main.number_words = <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }> <{ [10 x i8*] [i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i32 0, i32 0)], [10 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.11, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.13, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.14, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.15, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.16, i32 0, i32 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.17, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.19, i32 0, i32 0)], [10 x i8*] [i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.20, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.21, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.22, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.23, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.24, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.25, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.26, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.27, i32 0, i32 0), i8* null, i8* null], [10 x i8*] [i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.28, i32 0, i32 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.29, i32 0, i32 0), i8* null, i8* null, i8* null, i8* null, i8* null, i8* null, i8* null], <{ i8*, i8*, [8 x i8*] }> <{ i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.30, i32 0, i32 0), [8 x i8*] zeroinitializer }> }>
@.str.31 = [12 x i8] c"Answer: %d\0A\00"
@.str.32 = [10 x i8] c"Time: %f\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call float (...) @timeit()
br label %4
4: ; preds = %2, %79
%5 = phi i32 [ 0, %2 ], [ %83, %79 ]
%6 = phi i32 [ 1, %2 ], [ %84, %79 ]
%7 = trunc i32 %6 to i16
%8 = udiv i16 %7, 1000
%9 = zext i16 %8 to i64
%10 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 0, i64 %9
%11 = load i8*, i8** %10
%12 = tail call i64 @strlen(i8* dereferenceable(1) %11)
%13 = trunc i64 %12 to i32
%14 = add i32 %5, %13
%15 = getelementptr inbounds i8*, i8** getelementptr inbounds (<{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 4, i32 0), i64 %9
%16 = load i8*, i8** %15
%17 = tail call i64 @strlen(i8* dereferenceable(1) %16)
%18 = trunc i64 %17 to i32
%19 = add i32 %14, %18
%20 = urem i16 %7, 1000
%21 = icmp ult i16 %20, 100
br i1 %21, label %22, label %26
22: ; preds = %4
%23 = trunc i16 %20 to i8
%24 = urem i8 %23, 100
%25 = zext i8 %24 to i16
br label %40
26: ; preds = %4
%27 = udiv i16 %20, 100
%28 = urem i16 %20, 100
%29 = icmp eq i16 %28, 0
%30 = zext i16 %27 to i64
%31 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 0, i64 %30
%32 = load i8*, i8** %31
%33 = tail call i64 @strlen(i8* dereferenceable(1) %32)
br i1 %29, label %36, label %34
34: ; preds = %26
%35 = add nsw i64 %33, 10
br label %40
36: ; preds = %26
%37 = trunc i64 %33 to i32
%38 = add i32 %37, 7
%39 = add i32 %19, %38
br label %71
40: ; preds = %22, %34
%41 = phi i16 [ %25, %22 ], [ %28, %34 ]
%42 = phi i64 [ 0, %22 ], [ %35, %34 ]
%43 = trunc i64 %42 to i32
%44 = add i32 %19, %43
%45 = trunc i16 %41 to i8
%46 = udiv i8 %45, 10
%47 = urem i8 %45, 10
%48 = zext i8 %46 to i64
%49 = icmp ult i16 %41, 10
br i1 %49, label %71, label %50
50: ; preds = %40
%51 = zext i16 %41 to i32
%52 = add nsw i32 %51, -10
%53 = icmp ult i32 %52, 10
br i1 %53, label %54, label %60
54: ; preds = %50
%55 = urem i8 %45, 10
%56 = zext i8 %55 to i64
%57 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 1, i64 %56
%58 = load i8*, i8** %57
%59 = tail call i64 @strlen(i8* dereferenceable(1) %58)
br label %79
60: ; preds = %50
%61 = add nuw nsw i64 %48, 4294967294
%62 = and i64 %61, 4294967295
%63 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 2, i64 %62
%64 = load i8*, i8** %63
%65 = tail call i64 @strlen(i8* dereferenceable(1) %64)
%66 = zext i8 %47 to i64
%67 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 0, i64 %66
%68 = load i8*, i8** %67
%69 = tail call i64 @strlen(i8* dereferenceable(1) %68)
%70 = add nsw i64 %69, %65
br label %79
71: ; preds = %36, %40
%72 = phi i8 [ 0, %36 ], [ %45, %40 ]
%73 = phi i32 [ %39, %36 ], [ %44, %40 ]
%74 = urem i8 %72, 10
%75 = zext i8 %74 to i64
%76 = getelementptr inbounds <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>, <{ [10 x i8*], [10 x i8*], [10 x i8*], [10 x i8*], <{ i8*, i8*, [8 x i8*] }> }>* @__const.main.number_words, i64 0, i32 0, i64 %75
%77 = load i8*, i8** %76
%78 = tail call i64 @strlen(i8* dereferenceable(1) %77)
br label %79
79: ; preds = %54, %60, %71
%80 = phi i32 [ %73, %71 ], [ %44, %54 ], [ %44, %60 ]
%81 = phi i64 [ %78, %71 ], [ %59, %54 ], [ %70, %60 ]
%82 = trunc i64 %81 to i32
%83 = add i32 %80, %82
%84 = add nuw nsw i32 %6, 1
%85 = icmp eq i32 %84, 1001
br i1 %85, label %86, label %4
86: ; preds = %79
%87 = tail call float (...) @timeit()
%88 = sitofp i32 %83 to float
%89 = tail call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.31, i64 0, i64 0), float %88)
%90 = fsub float %87, %3
%91 = tail call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.32, i64 0, i64 0), float %90)
ret i32 0
}