void month_Word(int month, char monthConvert[]) {
  int i;
  char monthWords[12][10] = {"January",   "February", "March",    "April",
                             "May",       "June",     "July",     "August",
                             "September", "October",  "November", "December"};
  for (i = 0; i < 12; i++) {
    if (month == i + 1) {
      strcpy(monthConvert, monthWords[i]);
      i = 12;
    }
  }
}


x86 assembly (clang, -O0):
<month_Word>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
lea    -0x90(%rbp),%rdi
lea    0xec0(%rip),%rsi
mov    $0x78,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x14(%rbp)
cmpl   $0xc,-0x14(%rbp)
jge    11a1 <month_Word+0x81>
mov    -0x4(%rbp),%eax
mov    -0x14(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jne    118e <month_Word+0x6e>
mov    -0x10(%rbp),%rdi
movslq -0x14(%rbp),%rax
lea    -0x90(%rbp),%rsi
imul   $0xa,%rax,%rax
add    %rax,%rsi
call   1030 <strcpy@plt>
movl   $0xc,-0x14(%rbp)
jmp    1193 <month_Word+0x73>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1151 <month_Word+0x31>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<month_Word>:
sub    $0x78,%rsp
mov    0xf85(%rip),%rax
mov    %rax,0x70(%rsp)
movaps 0xf69(%rip),%xmm0
movaps %xmm0,0x60(%rsp)
movaps 0xf4d(%rip),%xmm0
movaps %xmm0,0x50(%rsp)
movaps 0xf31(%rip),%xmm0
movaps %xmm0,0x40(%rsp)
movaps 0xf15(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
movaps 0xef9(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movaps 0xedd(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xec1(%rip),%xmm0
movaps %xmm0,(%rsp)
add    $0xffffffff,%edi
cmp    $0xb,%edi
ja     11eb <month_Word+0xdb>
xor    %eax,%eax
lea    0xe7c(%rip),%rcx
movslq (%rcx,%rdi,4),%rdx
add    %rcx,%rdx
jmp    *%rdx
mov    $0x1,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x2,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x3,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x4,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x5,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x6,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x7,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x8,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0x9,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0xa,%eax
jmp    11d8 <month_Word+0xc8>
mov    $0xb,%eax
lea    (%rax,%rax,4),%rax
lea    (%rsp,%rax,2),%rax
mov    %rsi,%rdi
mov    %rax,%rsi
call   1030 <strcpy@plt>
add    $0x78,%rsp
ret

LLVM IR (-O0):
@__const.month_Word.monthWords = [12 x [10 x i8]] [[10 x i8] c"January\00\00\00", [10 x i8] c"February\00\00", [10 x i8] c"March\00\00\00\00\00", [10 x i8] c"April\00\00\00\00\00", [10 x i8] c"May\00\00\00\00\00\00\00", [10 x i8] c"June\00\00\00\00\00\00", [10 x i8] c"July\00\00\00\00\00\00", [10 x i8] c"August\00\00\00\00", [10 x i8] c"September\00", [10 x i8] c"October\00\00\00", [10 x i8] c"November\00\00", [10 x i8] c"December\00\00"]
define void @month_Word(i32 %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
%5 = alloca i32
%6 = alloca [12 x [10 x i8]]
store i32 %0, i32* %3
store i8* %1, i8** %4
%7 = bitcast [12 x [10 x i8]]* %6 to i8*
store i32 0, i32* %5
br label %8
8: ; preds = %24, %2
%9 = load i32, i32* %5
%10 = icmp slt i32 %9, 12
br i1 %10, label %11, label %27
11: ; preds = %8
%12 = load i32, i32* %3
%13 = load i32, i32* %5
%14 = add nsw i32 %13, 1
%15 = icmp eq i32 %12, %14
br i1 %15, label %16, label %23
16: ; preds = %11
%17 = load i8*, i8** %4
%18 = load i32, i32* %5
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds [12 x [10 x i8]], [12 x [10 x i8]]* %6, i64 0, i64 %19
%21 = getelementptr inbounds [10 x i8], [10 x i8]* %20, i64 0, i64 0
%22 = call i8* @strcpy(i8* %17, i8* %21)
store i32 12, i32* %5
br label %23
23: ; preds = %16, %11
br label %24
24: ; preds = %23
%25 = load i32, i32* %5
%26 = add nsw i32 %25, 1
store i32 %26, i32* %5
br label %8
27: ; preds = %8
ret void
}

LLVM IR (-O2):
@__const.month_Word.monthWords = [12 x [10 x i8]] [[10 x i8] c"January\00\00\00", [10 x i8] c"February\00\00", [10 x i8] c"March\00\00\00\00\00", [10 x i8] c"April\00\00\00\00\00", [10 x i8] c"May\00\00\00\00\00\00\00", [10 x i8] c"June\00\00\00\00\00\00", [10 x i8] c"July\00\00\00\00\00\00", [10 x i8] c"August\00\00\00\00", [10 x i8] c"September\00", [10 x i8] c"October\00\00\00", [10 x i8] c"November\00\00", [10 x i8] c"December\00\00"]
define void @month_Word(i32 %0, i8* %1) {
%3 = alloca [12 x [10 x i8]]
%4 = getelementptr inbounds [12 x [10 x i8]], [12 x [10 x i8]]* %3, i64 0, i64 0, i64 0
switch i32 %0, label %20 [
i32 1, label %16
i32 2, label %5
i32 3, label %6
i32 4, label %7
i32 5, label %8
i32 6, label %9
i32 7, label %10
i32 8, label %11
i32 9, label %12
i32 10, label %13
i32 11, label %14
i32 12, label %15
]
5: ; preds = %2
br label %16
6: ; preds = %2
br label %16
7: ; preds = %2
br label %16
8: ; preds = %2
br label %16
9: ; preds = %2
br label %16
10: ; preds = %2
br label %16
11: ; preds = %2
br label %16
12: ; preds = %2
br label %16
13: ; preds = %2
br label %16
14: ; preds = %2
br label %16
15: ; preds = %2
br label %16
16: ; preds = %2, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6, %5
%17 = phi i64 [ 0, %2 ], [ 1, %5 ], [ 2, %6 ], [ 3, %7 ], [ 4, %8 ], [ 5, %9 ], [ 6, %10 ], [ 7, %11 ], [ 8, %12 ], [ 9, %13 ], [ 10, %14 ], [ 11, %15 ]
%18 = getelementptr inbounds [12 x [10 x i8]], [12 x [10 x i8]]* %3, i64 0, i64 %17, i64 0
%19 = call i8* @strcpy(i8* dereferenceable(1) %1, i8* %18)
br label %20
20: ; preds = %2, %16
ret void
}