const char *srs_strerror(int code) {
  switch (code) {
  case (0):
    return "Success";
  case (1):
    return "Not an SRS address.";
  case (0x1000 | 1):
    return "No secrets in SRS configuration.";
  case (0x1000 | 2):
    return "Invalid separator suggested.";
  case (0x2000 | 1):
    return "No at sign in sender address";
  case (0x2000 | 2):
    return "Buffer too small.";
  case (0x4000 | 1):
    return "No host in SRS0 address.";
  case (0x4000 | 2):
    return "No user in SRS0 address.";
  case (0x4000 | 3):
    return "No hash in SRS0 address.";
  case (0x4000 | 4):
    return "No timestamp in SRS0 address.";
  case (0x4000 | 5):
    return "No host in SRS1 address.";
  case (0x4000 | 6):
    return "No user in SRS1 address.";
  case (0x4000 | 7):
    return "No hash in SRS1 address.";
  case (0x4000 | 8):
    return "Bad base32 character in timestamp.";
  case (0x4000 | 9):
    return "Hash too short in SRS address.";
  case (0x8000 | 1):
    return "Time stamp out of date.";
  case (0x8000 | 2):
    return "Hash invalid in SRS address.";
  default:
    return "Unknown error in SRS library.";
  }
}


x86 assembly (clang, -O0):
<srs_strerror>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
test   %eax,%eax
je     1248 <srs_strerror+0x148>
jmp    111a <srs_strerror+0x1a>
mov    -0x10(%rbp),%eax
sub    $0x1,%eax
je     1258 <srs_strerror+0x158>
jmp    112b <srs_strerror+0x2b>
mov    -0x10(%rbp),%eax
sub    $0x1001,%eax
je     1268 <srs_strerror+0x168>
jmp    113e <srs_strerror+0x3e>
mov    -0x10(%rbp),%eax
sub    $0x1002,%eax
je     1278 <srs_strerror+0x178>
jmp    1151 <srs_strerror+0x51>
mov    -0x10(%rbp),%eax
sub    $0x2001,%eax
je     1288 <srs_strerror+0x188>
jmp    1164 <srs_strerror+0x64>
mov    -0x10(%rbp),%eax
sub    $0x2002,%eax
je     1298 <srs_strerror+0x198>
jmp    1177 <srs_strerror+0x77>
mov    -0x10(%rbp),%eax
sub    $0x4001,%eax
je     12a8 <srs_strerror+0x1a8>
jmp    118a <srs_strerror+0x8a>
mov    -0x10(%rbp),%eax
sub    $0x4002,%eax
je     12b8 <srs_strerror+0x1b8>
jmp    119d <srs_strerror+0x9d>
mov    -0x10(%rbp),%eax
sub    $0x4003,%eax
je     12c8 <srs_strerror+0x1c8>
jmp    11b0 <srs_strerror+0xb0>
mov    -0x10(%rbp),%eax
sub    $0x4004,%eax
je     12d8 <srs_strerror+0x1d8>
jmp    11c3 <srs_strerror+0xc3>
mov    -0x10(%rbp),%eax
sub    $0x4005,%eax
je     12e8 <srs_strerror+0x1e8>
jmp    11d6 <srs_strerror+0xd6>
mov    -0x10(%rbp),%eax
sub    $0x4006,%eax
je     12f8 <srs_strerror+0x1f8>
jmp    11e9 <srs_strerror+0xe9>
mov    -0x10(%rbp),%eax
sub    $0x4007,%eax
je     1308 <srs_strerror+0x208>
jmp    11fc <srs_strerror+0xfc>
mov    -0x10(%rbp),%eax
sub    $0x4008,%eax
je     1318 <srs_strerror+0x218>
jmp    120f <srs_strerror+0x10f>
mov    -0x10(%rbp),%eax
sub    $0x4009,%eax
je     1328 <srs_strerror+0x228>
jmp    1222 <srs_strerror+0x122>
mov    -0x10(%rbp),%eax
sub    $0x8001,%eax
je     1338 <srs_strerror+0x238>
jmp    1235 <srs_strerror+0x135>
mov    -0x10(%rbp),%eax
sub    $0x8002,%eax
je     1348 <srs_strerror+0x248>
jmp    1358 <srs_strerror+0x258>
lea    0xdb1(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xda9(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdad(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdbe(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdcb(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdd8(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdda(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xde3(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdec(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xdf5(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe03(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe0c(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe15(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe1e(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe31(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe40(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe48(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1363 <srs_strerror+0x263>
lea    0xe55(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<srs_strerror>:
cmp    $0x4000,%edi
jle    112b <srs_strerror+0x2b>
lea    -0x4001(%rdi),%eax
cmp    $0x8,%eax
ja     1184 <srs_strerror+0x84>
lea    0xee6(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xf83(%rip),%rax
ret
cmp    $0x1001,%edi
jg     1158 <srs_strerror+0x58>
test   %edi,%edi
je     11dc <srs_strerror+0xdc>
cmp    $0x1,%edi
je     11e4 <srs_strerror+0xe4>
cmp    $0x1001,%edi
jne    1204 <srs_strerror+0x104>
lea    0xee9(%rip),%rax
ret
cmp    $0x1002,%edi
je     11ec <srs_strerror+0xec>
cmp    $0x2001,%edi
je     11f4 <srs_strerror+0xf4>
cmp    $0x2002,%edi
jne    1204 <srs_strerror+0x104>
lea    0xf18(%rip),%rax
ret
cmp    $0x8001,%edi
je     11fc <srs_strerror+0xfc>
cmp    $0x8002,%edi
jne    1204 <srs_strerror+0x104>
lea    0x1020(%rip),%rax
ret
lea    0xf23(%rip),%rax
ret
lea    0xf34(%rip),%rax
ret
lea    0xf45(%rip),%rax
ret
lea    0xf5b(%rip),%rax
ret
lea    0xf6c(%rip),%rax
ret
lea    0xf7d(%rip),%rax
ret
lea    0xf8e(%rip),%rax
ret
lea    0xfa9(%rip),%rax
ret
lea    0xe41(%rip),%rax
ret
lea    0xe41(%rip),%rax
ret
lea    0xe6e(%rip),%rax
ret
lea    0xe83(%rip),%rax
ret
lea    0xfa0(%rip),%rax
ret
lea    0xfcd(%rip),%rax
ret

LLVM IR (-O0):
@.str = [8 x i8] c"Success\00"
@.str.1 = [20 x i8] c"Not an SRS address.\00"
@.str.2 = [33 x i8] c"No secrets in SRS configuration.\00"
@.str.3 = [29 x i8] c"Invalid separator suggested.\00"
@.str.4 = [29 x i8] c"No at sign in sender address\00"
@.str.5 = [18 x i8] c"Buffer too small.\00"
@.str.6 = [25 x i8] c"No host in SRS0 address.\00"
@.str.7 = [25 x i8] c"No user in SRS0 address.\00"
@.str.8 = [25 x i8] c"No hash in SRS0 address.\00"
@.str.9 = [30 x i8] c"No timestamp in SRS0 address.\00"
@.str.10 = [25 x i8] c"No host in SRS1 address.\00"
@.str.11 = [25 x i8] c"No user in SRS1 address.\00"
@.str.12 = [25 x i8] c"No hash in SRS1 address.\00"
@.str.13 = [35 x i8] c"Bad base32 character in timestamp.\00"
@.str.14 = [31 x i8] c"Hash too short in SRS address.\00"
@.str.15 = [24 x i8] c"Time stamp out of date.\00"
@.str.16 = [29 x i8] c"Hash invalid in SRS address.\00"
@.str.17 = [30 x i8] c"Unknown error in SRS library.\00"
define i8* @srs_strerror(i32 %0) {
%2 = alloca i8*
%3 = alloca i32
store i32 %0, i32* %3
%4 = load i32, i32* %3
switch i32 %4, label %22 [
i32 0, label %5
i32 1, label %6
i32 4097, label %7
i32 4098, label %8
i32 8193, label %9
i32 8194, label %10
i32 16385, label %11
i32 16386, label %12
i32 16387, label %13
i32 16388, label %14
i32 16389, label %15
i32 16390, label %16
i32 16391, label %17
i32 16392, label %18
i32 16393, label %19
i32 32769, label %20
i32 32770, label %21
]
5: ; preds = %1
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8** %2
br label %23
6: ; preds = %1
store i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %23
7: ; preds = %1
store i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.2, i64 0, i64 0), i8** %2
br label %23
8: ; preds = %1
store i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %23
9: ; preds = %1
store i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0), i8** %2
br label %23
10: ; preds = %1
store i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.5, i64 0, i64 0), i8** %2
br label %23
11: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.6, i64 0, i64 0), i8** %2
br label %23
12: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.7, i64 0, i64 0), i8** %2
br label %23
13: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.8, i64 0, i64 0), i8** %2
br label %23
14: ; preds = %1
store i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.9, i64 0, i64 0), i8** %2
br label %23
15: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.10, i64 0, i64 0), i8** %2
br label %23
16: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.11, i64 0, i64 0), i8** %2
br label %23
17: ; preds = %1
store i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.12, i64 0, i64 0), i8** %2
br label %23
18: ; preds = %1
store i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.13, i64 0, i64 0), i8** %2
br label %23
19: ; preds = %1
store i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), i8** %2
br label %23
20: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.15, i64 0, i64 0), i8** %2
br label %23
21: ; preds = %1
store i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.16, i64 0, i64 0), i8** %2
br label %23
22: ; preds = %1
store i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.17, i64 0, i64 0), i8** %2
br label %23
23: ; preds = %22, %21, %20, %19, %18, %17, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6, %5
%24 = load i8*, i8** %2
ret i8* %24
}

LLVM IR (-O2):
@.str = [8 x i8] c"Success\00"
@.str.1 = [20 x i8] c"Not an SRS address.\00"
@.str.2 = [33 x i8] c"No secrets in SRS configuration.\00"
@.str.3 = [29 x i8] c"Invalid separator suggested.\00"
@.str.4 = [29 x i8] c"No at sign in sender address\00"
@.str.5 = [18 x i8] c"Buffer too small.\00"
@.str.6 = [25 x i8] c"No host in SRS0 address.\00"
@.str.7 = [25 x i8] c"No user in SRS0 address.\00"
@.str.8 = [25 x i8] c"No hash in SRS0 address.\00"
@.str.9 = [30 x i8] c"No timestamp in SRS0 address.\00"
@.str.10 = [25 x i8] c"No host in SRS1 address.\00"
@.str.11 = [25 x i8] c"No user in SRS1 address.\00"
@.str.12 = [25 x i8] c"No hash in SRS1 address.\00"
@.str.13 = [35 x i8] c"Bad base32 character in timestamp.\00"
@.str.14 = [31 x i8] c"Hash too short in SRS address.\00"
@.str.15 = [24 x i8] c"Time stamp out of date.\00"
@.str.16 = [29 x i8] c"Hash invalid in SRS address.\00"
@.str.17 = [30 x i8] c"Unknown error in SRS library.\00"
define i8* @srs_strerror(i32 %0) {
switch i32 %0, label %18 [
i32 0, label %19
i32 1, label %2
i32 4097, label %3
i32 4098, label %4
i32 8193, label %5
i32 8194, label %6
i32 16385, label %7
i32 16386, label %8
i32 16387, label %9
i32 16388, label %10
i32 16389, label %11
i32 16390, label %12
i32 16391, label %13
i32 16392, label %14
i32 16393, label %15
i32 32769, label %16
i32 32770, label %17
]
2: ; preds = %1
br label %19
3: ; preds = %1
br label %19
4: ; preds = %1
br label %19
5: ; preds = %1
br label %19
6: ; preds = %1
br label %19
7: ; preds = %1
br label %19
8: ; preds = %1
br label %19
9: ; preds = %1
br label %19
10: ; preds = %1
br label %19
11: ; preds = %1
br label %19
12: ; preds = %1
br label %19
13: ; preds = %1
br label %19
14: ; preds = %1
br label %19
15: ; preds = %1
br label %19
16: ; preds = %1
br label %19
17: ; preds = %1
br label %19
18: ; preds = %1
br label %19
19: ; preds = %1, %18, %17, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6, %5, %4, %3, %2
%20 = phi i8* [ getelementptr inbounds ([30 x i8], [30 x i8]* @.str.17, i64 0, i64 0), %18 ], [ getelementptr inbounds ([29 x i8], [29 x i8]* @.str.16, i64 0, i64 0), %17 ], [ getelementptr inbounds ([24 x i8], [24 x i8]* @.str.15, i64 0, i64 0), %16 ], [ getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), %15 ], [ getelementptr inbounds ([35 x i8], [35 x i8]* @.str.13, i64 0, i64 0), %14 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.12, i64 0, i64 0), %13 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.11, i64 0, i64 0), %12 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.10, i64 0, i64 0), %11 ], [ getelementptr inbounds ([30 x i8], [30 x i8]* @.str.9, i64 0, i64 0), %10 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.8, i64 0, i64 0), %9 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.7, i64 0, i64 0), %8 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.6, i64 0, i64 0), %7 ], [ getelementptr inbounds ([18 x i8], [18 x i8]* @.str.5, i64 0, i64 0), %6 ], [ getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0), %5 ], [ getelementptr inbounds ([29 x i8], [29 x i8]* @.str.3, i64 0, i64 0), %4 ], [ getelementptr inbounds ([33 x i8], [33 x i8]* @.str.2, i64 0, i64 0), %3 ], [ getelementptr inbounds ([20 x i8], [20 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* %20
}