const char *nodm_strerror(int code) {
  switch (code) {
  case 0:
    return "success";
  case 1:
    return "permission denied";
  case 2:
    return "invalid command syntax";
  case 3:
    return "invalid argument to option";
  case 14:
    return "not found password file";
  case 15:
    return "not found shadow password file";
  case 16:
    return "not found group file";
  case 17:
    return "not found shadow group file";
  case 126:
    return "can't run command/shell";
  case 127:
    return "can't find command/shell to run";
  case 200:
    return "programming error";
  case 201:
    return "something wrong talking with PAM";
  case 202:
    return "something wrong talking with the Operating System";
  case 203:
    return "Xlib error";
  case 210:
    return "server died";
  case 211:
    return "server not ready before timeout";
  case 212:
    return "could not connect to X server";
  case 220:
    return "X session died";
  case 221:
    return "quit requested";
  default:
    return "unknown error";
  }
}


x86 assembly (clang, -O0):
<nodm_strerror>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
test   %eax,%eax
je     125e <nodm_strerror+0x15e>
jmp    111a <nodm_strerror+0x1a>
mov    -0x10(%rbp),%eax
sub    $0x1,%eax
je     126e <nodm_strerror+0x16e>
jmp    112b <nodm_strerror+0x2b>
mov    -0x10(%rbp),%eax
sub    $0x2,%eax
je     127e <nodm_strerror+0x17e>
jmp    113c <nodm_strerror+0x3c>
mov    -0x10(%rbp),%eax
sub    $0x3,%eax
je     128e <nodm_strerror+0x18e>
jmp    114d <nodm_strerror+0x4d>
mov    -0x10(%rbp),%eax
sub    $0xe,%eax
je     129e <nodm_strerror+0x19e>
jmp    115e <nodm_strerror+0x5e>
mov    -0x10(%rbp),%eax
sub    $0xf,%eax
je     12ae <nodm_strerror+0x1ae>
jmp    116f <nodm_strerror+0x6f>
mov    -0x10(%rbp),%eax
sub    $0x10,%eax
je     12be <nodm_strerror+0x1be>
jmp    1180 <nodm_strerror+0x80>
mov    -0x10(%rbp),%eax
sub    $0x11,%eax
je     12ce <nodm_strerror+0x1ce>
jmp    1191 <nodm_strerror+0x91>
mov    -0x10(%rbp),%eax
sub    $0x7e,%eax
je     12de <nodm_strerror+0x1de>
jmp    11a2 <nodm_strerror+0xa2>
mov    -0x10(%rbp),%eax
sub    $0x7f,%eax
je     12ee <nodm_strerror+0x1ee>
jmp    11b3 <nodm_strerror+0xb3>
mov    -0x10(%rbp),%eax
sub    $0xc8,%eax
je     12fe <nodm_strerror+0x1fe>
jmp    11c6 <nodm_strerror+0xc6>
mov    -0x10(%rbp),%eax
sub    $0xc9,%eax
je     130e <nodm_strerror+0x20e>
jmp    11d9 <nodm_strerror+0xd9>
mov    -0x10(%rbp),%eax
sub    $0xca,%eax
je     131e <nodm_strerror+0x21e>
jmp    11ec <nodm_strerror+0xec>
mov    -0x10(%rbp),%eax
sub    $0xcb,%eax
je     132e <nodm_strerror+0x22e>
jmp    11ff <nodm_strerror+0xff>
mov    -0x10(%rbp),%eax
sub    $0xd2,%eax
je     133e <nodm_strerror+0x23e>
jmp    1212 <nodm_strerror+0x112>
mov    -0x10(%rbp),%eax
sub    $0xd3,%eax
je     134e <nodm_strerror+0x24e>
jmp    1225 <nodm_strerror+0x125>
mov    -0x10(%rbp),%eax
sub    $0xd4,%eax
je     135e <nodm_strerror+0x25e>
jmp    1238 <nodm_strerror+0x138>
mov    -0x10(%rbp),%eax
sub    $0xdc,%eax
je     136e <nodm_strerror+0x26e>
jmp    124b <nodm_strerror+0x14b>
mov    -0x10(%rbp),%eax
sub    $0xdd,%eax
je     137e <nodm_strerror+0x27e>
jmp    138e <nodm_strerror+0x28e>
lea    0xd9b(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xd93(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xd95(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xd9c(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xda7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdaf(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdbe(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdc3(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdcf(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdd7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xde7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xde9(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xdfa(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe1c(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe17(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe13(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe23(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe31(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe30(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1399 <nodm_strerror+0x299>
lea    0xe2f(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<nodm_strerror>:
lea    -0x7e(%rdi),%eax
cmp    $0x5f,%eax
ja     1120 <nodm_strerror+0x20>
lea    0xf39(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0x115d(%rip),%rax
ret
cmp    $0x11,%edi
ja     11aa <nodm_strerror+0xaa>
lea    0x1098(%rip),%rax
mov    %edi,%ecx
lea    0xec7(%rip),%rdx
movslq (%rdx,%rcx,4),%rcx
add    %rdx,%rcx
jmp    *%rcx
lea    0x1087(%rip),%rax
ret
lea    0x1143(%rip),%rax
ret
lea    0x115b(%rip),%rax
ret
lea    0x1165(%rip),%rax
ret
lea    0x117e(%rip),%rax
ret
lea    0x11a8(%rip),%rax
ret
lea    0x11ab(%rip),%rax
ret
lea    0x11af(%rip),%rax
ret
lea    0x11c7(%rip),%rax
ret
lea    0x11dd(%rip),%rax
ret
lea    0x11e4(%rip),%rax
ret
lea    0x1041(%rip),%rax
ret
lea    0x1050(%rip),%rax
ret
lea    0x11db(%rip),%rax
ret
lea    0x105b(%rip),%rax
ret
lea    0x106b(%rip),%rax
ret
lea    0x1082(%rip),%rax
ret
lea    0x108f(%rip),%rax
ret

LLVM IR (-O0):
@.str = [8 x i8] c"success\00"
@.str.1 = [18 x i8] c"permission denied\00"
@.str.2 = [23 x i8] c"invalid command syntax\00"
@.str.3 = [27 x i8] c"invalid argument to option\00"
@.str.4 = [24 x i8] c"not found password file\00"
@.str.5 = [31 x i8] c"not found shadow password file\00"
@.str.6 = [21 x i8] c"not found group file\00"
@.str.7 = [28 x i8] c"not found shadow group file\00"
@.str.8 = [24 x i8] c"can't run command/shell\00"
@.str.9 = [32 x i8] c"can't find command/shell to run\00"
@.str.10 = [18 x i8] c"programming error\00"
@.str.11 = [33 x i8] c"something wrong talking with PAM\00"
@.str.12 = [50 x i8] c"something wrong talking with the Operating System\00"
@.str.13 = [11 x i8] c"Xlib error\00"
@.str.14 = [12 x i8] c"server died\00"
@.str.15 = [32 x i8] c"server not ready before timeout\00"
@.str.16 = [30 x i8] c"could not connect to X server\00"
@.str.17 = [15 x i8] c"X session died\00"
@.str.18 = [15 x i8] c"quit requested\00"
@.str.19 = [14 x i8] c"unknown error\00"
define i8* @nodm_strerror(i32 %0) {
%2 = alloca i8*
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %24 [
i32 0, label %5
i32 1, label %6
i32 2, label %7
i32 3, label %8
i32 14, label %9
i32 15, label %10
i32 16, label %11
i32 17, label %12
i32 126, label %13
i32 127, label %14
i32 200, label %15
i32 201, label %16
i32 202, label %17
i32 203, label %18
i32 210, label %19
i32 211, label %20
i32 212, label %21
i32 220, label %22
i32 221, label %23
]
5: ; preds = %1
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8** %2
br label %25
6: ; preds = %1
store i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %25
7: ; preds = %1
store i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), i8** %2
br label %25
8: ; preds = %1
store i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %25
9: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), i8** %2
br label %25
10: ; preds = %1
store i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i8** %2
br label %25
11: ; preds = %1
store i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.6, i64 0, i64 0), i8** %2
br label %25
12: ; preds = %1
store i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.7, i64 0, i64 0), i8** %2
br label %25
13: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.8, i64 0, i64 0), i8** %2
br label %25
14: ; preds = %1
store i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.9, i64 0, i64 0), i8** %2
br label %25
15: ; preds = %1
store i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.10, i64 0, i64 0), i8** %2
br label %25
16: ; preds = %1
store i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.11, i64 0, i64 0), i8** %2
br label %25
17: ; preds = %1
store i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.12, i64 0, i64 0), i8** %2
br label %25
18: ; preds = %1
store i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.13, i64 0, i64 0), i8** %2
br label %25
19: ; preds = %1
store i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.14, i64 0, i64 0), i8** %2
br label %25
20: ; preds = %1
store i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.15, i64 0, i64 0), i8** %2
br label %25
21: ; preds = %1
store i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.16, i64 0, i64 0), i8** %2
br label %25
22: ; preds = %1
store i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.17, i64 0, i64 0), i8** %2
br label %25
23: ; preds = %1
store i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.18, i64 0, i64 0), i8** %2
br label %25
24: ; preds = %1
store i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.19, i64 0, i64 0), i8** %2
br label %25
25: ; preds = %24, %23, %22, %21, %20, %19, %18, %17, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6, %5
%26 = load i8*, i8** %2
ret i8* %26
}

LLVM IR (-O2):
@.str = [8 x i8] c"success\00"
@.str.1 = [18 x i8] c"permission denied\00"
@.str.2 = [23 x i8] c"invalid command syntax\00"
@.str.3 = [27 x i8] c"invalid argument to option\00"
@.str.4 = [24 x i8] c"not found password file\00"
@.str.5 = [31 x i8] c"not found shadow password file\00"
@.str.6 = [21 x i8] c"not found group file\00"
@.str.7 = [28 x i8] c"not found shadow group file\00"
@.str.8 = [24 x i8] c"can't run command/shell\00"
@.str.9 = [32 x i8] c"can't find command/shell to run\00"
@.str.10 = [18 x i8] c"programming error\00"
@.str.11 = [33 x i8] c"something wrong talking with PAM\00"
@.str.12 = [50 x i8] c"something wrong talking with the Operating System\00"
@.str.13 = [11 x i8] c"Xlib error\00"
@.str.14 = [12 x i8] c"server died\00"
@.str.15 = [32 x i8] c"server not ready before timeout\00"
@.str.16 = [30 x i8] c"could not connect to X server\00"
@.str.17 = [15 x i8] c"X session died\00"
@.str.18 = [15 x i8] c"quit requested\00"
@.str.19 = [14 x i8] c"unknown error\00"
define i8* @nodm_strerror(i32 %0) {
switch i32 %0, label %20 [
i32 0, label %21
i32 1, label %2
i32 2, label %3
i32 3, label %4
i32 14, label %5
i32 15, label %6
i32 16, label %7
i32 17, label %8
i32 126, label %9
i32 127, label %10
i32 200, label %11
i32 201, label %12
i32 202, label %13
i32 203, label %14
i32 210, label %15
i32 211, label %16
i32 212, label %17
i32 220, label %18
i32 221, label %19
]
2: ; preds = %1
br label %21
3: ; preds = %1
br label %21
4: ; preds = %1
br label %21
5: ; preds = %1
br label %21
6: ; preds = %1
br label %21
7: ; preds = %1
br label %21
8: ; preds = %1
br label %21
9: ; preds = %1
br label %21
10: ; preds = %1
br label %21
11: ; preds = %1
br label %21
12: ; preds = %1
br label %21
13: ; preds = %1
br label %21
14: ; preds = %1
br label %21
15: ; preds = %1
br label %21
16: ; preds = %1
br label %21
17: ; preds = %1
br label %21
18: ; preds = %1
br label %21
19: ; preds = %1
br label %21
20: ; preds = %1
br label %21
21: ; preds = %1, %20, %19, %18, %17, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6, %5, %4, %3, %2
%22 = phi i8* [ getelementptr inbounds ([14 x i8], [14 x i8]* @.str.19, i64 0, i64 0), %20 ], [ getelementptr inbounds ([15 x i8], [15 x i8]* @.str.18, i64 0, i64 0), %19 ], [ getelementptr inbounds ([15 x i8], [15 x i8]* @.str.17, i64 0, i64 0), %18 ], [ getelementptr inbounds ([30 x i8], [30 x i8]* @.str.16, i64 0, i64 0), %17 ], [ getelementptr inbounds ([32 x i8], [32 x i8]* @.str.15, i64 0, i64 0), %16 ], [ getelementptr inbounds ([12 x i8], [12 x i8]* @.str.14, i64 0, i64 0), %15 ], [ getelementptr inbounds ([11 x i8], [11 x i8]* @.str.13, i64 0, i64 0), %14 ], [ getelementptr inbounds ([50 x i8], [50 x i8]* @.str.12, i64 0, i64 0), %13 ], [ getelementptr inbounds ([33 x i8], [33 x i8]* @.str.11, i64 0, i64 0), %12 ], [ getelementptr inbounds ([18 x i8], [18 x i8]* @.str.10, i64 0, i64 0), %11 ], [ getelementptr inbounds ([32 x i8], [32 x i8]* @.str.9, i64 0, i64 0), %10 ], [ getelementptr inbounds ([24 x i8], [24 x i8]* @.str.8, i64 0, i64 0), %9 ], [ getelementptr inbounds ([28 x i8], [28 x i8]* @.str.7, i64 0, i64 0), %8 ], [ getelementptr inbounds ([21 x i8], [21 x i8]* @.str.6, i64 0, i64 0), %7 ], [ getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), %6 ], [ getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), %5 ], [ getelementptr inbounds ([27 x i8], [27 x i8]* @.str.3, i64 0, i64 0), %4 ], [ getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), %3 ], [ getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), %2 ], [ getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), %1 ]
ret i8* %22
}