#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*/ BIO_snprintf(char *, int, char *, long);
#define X509_V_ERR_AKID_ISSUER_SERIAL_MISMATCH 172
#define X509_V_ERR_AKID_SKID_MISMATCH 171
#define X509_V_ERR_APPLICATION_VERIFICATION 170
#define X509_V_ERR_CERT_CHAIN_TOO_LONG 169
#define X509_V_ERR_CERT_HAS_EXPIRED 168
#define X509_V_ERR_CERT_NOT_YET_VALID 167
#define X509_V_ERR_CERT_REJECTED 166
#define X509_V_ERR_CERT_REVOKED 165
#define X509_V_ERR_CERT_SIGNATURE_FAILURE 164
#define X509_V_ERR_CERT_UNTRUSTED 163
#define X509_V_ERR_CRL_HAS_EXPIRED 162
#define X509_V_ERR_CRL_NOT_YET_VALID 161
#define X509_V_ERR_CRL_SIGNATURE_FAILURE 160
#define X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT 159
#define X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD 158
#define X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD 157
#define X509_V_ERR_ERROR_IN_CRL_LAST_UPDATE_FIELD 156
#define X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD 155
#define X509_V_ERR_INVALID_CA 154
#define X509_V_ERR_INVALID_EXTENSION 153
#define X509_V_ERR_INVALID_NON_CA 152
#define X509_V_ERR_INVALID_POLICY_EXTENSION 151
#define X509_V_ERR_INVALID_PURPOSE 150
#define X509_V_ERR_KEYUSAGE_NO_CERTSIGN 149
#define X509_V_ERR_KEYUSAGE_NO_CRL_SIGN 148
#define X509_V_ERR_KEYUSAGE_NO_DIGITAL_SIGNATURE 147
#define X509_V_ERR_NO_EXPLICIT_POLICY 146
#define X509_V_ERR_OUT_OF_MEM 145
#define X509_V_ERR_PATH_LENGTH_EXCEEDED 144
#define X509_V_ERR_PROXY_CERTIFICATES_NOT_ALLOWED 143
#define X509_V_ERR_PROXY_PATH_LENGTH_EXCEEDED 142
#define X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN 141
#define X509_V_ERR_SUBJECT_ISSUER_MISMATCH 140
#define X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY 139
#define X509_V_ERR_UNABLE_TO_DECRYPT_CERT_SIGNATURE 138
#define X509_V_ERR_UNABLE_TO_DECRYPT_CRL_SIGNATURE 137
#define X509_V_ERR_UNABLE_TO_GET_CRL 136
#define X509_V_ERR_UNABLE_TO_GET_CRL_ISSUER 135
#define X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT 134
#define X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY 133
#define X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE 132
#define X509_V_ERR_UNHANDLED_CRITICAL_CRL_EXTENSION 131
#define X509_V_ERR_UNHANDLED_CRITICAL_EXTENSION 130
#define X509_V_ERR_UNNESTED_RESOURCE 129
#define X509_V_OK 128
const char *X509_verify_cert_error_string(long n) {
  static char buf[100];
  switch ((int)n) {
  case X509_V_OK:
    return ("ok");
  case X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT:
    return ("unable to get issuer certificate");
  case X509_V_ERR_UNABLE_TO_GET_CRL:
    return ("unable to get certificate CRL");
  case X509_V_ERR_UNABLE_TO_DECRYPT_CERT_SIGNATURE:
    return ("unable to decrypt certificate's signature");
  case X509_V_ERR_UNABLE_TO_DECRYPT_CRL_SIGNATURE:
    return ("unable to decrypt CRL's signature");
  case X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY:
    return ("unable to decode issuer public key");
  case X509_V_ERR_CERT_SIGNATURE_FAILURE:
    return ("certificate signature failure");
  case X509_V_ERR_CRL_SIGNATURE_FAILURE:
    return ("CRL signature failure");
  case X509_V_ERR_CERT_NOT_YET_VALID:
    return ("certificate is not yet valid");
  case X509_V_ERR_CRL_NOT_YET_VALID:
    return ("CRL is not yet valid");
  case X509_V_ERR_CERT_HAS_EXPIRED:
    return ("certificate has expired");
  case X509_V_ERR_CRL_HAS_EXPIRED:
    return ("CRL has expired");
  case X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD:
    return ("format error in certificate's notBefore field");
  case X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD:
    return ("format error in certificate's notAfter field");
  case X509_V_ERR_ERROR_IN_CRL_LAST_UPDATE_FIELD:
    return ("format error in CRL's lastUpdate field");
  case X509_V_ERR_ERROR_IN_CRL_NEXT_UPDATE_FIELD:
    return ("format error in CRL's nextUpdate field");
  case X509_V_ERR_OUT_OF_MEM:
    return ("out of memory");
  case X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT:
    return ("self signed certificate");
  case X509_V_ERR_SELF_SIGNED_CERT_IN_CHAIN:
    return ("self signed certificate in certificate chain");
  case X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT_LOCALLY:
    return ("unable to get local issuer certificate");
  case X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE:
    return ("unable to verify the first certificate");
  case X509_V_ERR_CERT_CHAIN_TOO_LONG:
    return ("certificate chain too long");
  case X509_V_ERR_CERT_REVOKED:
    return ("certificate revoked");
  case X509_V_ERR_INVALID_CA:
    return ("invalid CA certificate");
  case X509_V_ERR_INVALID_NON_CA:
    return ("invalid non-CA certificate (has CA markings)");
  case X509_V_ERR_PATH_LENGTH_EXCEEDED:
    return ("path length constraint exceeded");
  case X509_V_ERR_PROXY_PATH_LENGTH_EXCEEDED:
    return ("proxy path length constraint exceeded");
  case X509_V_ERR_PROXY_CERTIFICATES_NOT_ALLOWED:
    return ("proxy certificates not allowed, please set the appropriate flag");
  case X509_V_ERR_INVALID_PURPOSE:
    return ("unsupported certificate purpose");
  case X509_V_ERR_CERT_UNTRUSTED:
    return ("certificate not trusted");
  case X509_V_ERR_CERT_REJECTED:
    return ("certificate rejected");
  case X509_V_ERR_APPLICATION_VERIFICATION:
    return ("application verification failure");
  case X509_V_ERR_SUBJECT_ISSUER_MISMATCH:
    return ("subject issuer mismatch");
  case X509_V_ERR_AKID_SKID_MISMATCH:
    return ("authority and subject key identifier mismatch");
  case X509_V_ERR_AKID_ISSUER_SERIAL_MISMATCH:
    return ("authority and issuer serial number mismatch");
  case X509_V_ERR_KEYUSAGE_NO_CERTSIGN:
    return ("key usage does not include certificate signing");
  case X509_V_ERR_UNABLE_TO_GET_CRL_ISSUER:
    return ("unable to get CRL issuer certificate");
  case X509_V_ERR_UNHANDLED_CRITICAL_EXTENSION:
    return ("unhandled critical extension");
  case X509_V_ERR_KEYUSAGE_NO_CRL_SIGN:
    return ("key usage does not include CRL signing");
  case X509_V_ERR_KEYUSAGE_NO_DIGITAL_SIGNATURE:
    return ("key usage does not include digital signature");
  case X509_V_ERR_UNHANDLED_CRITICAL_CRL_EXTENSION:
    return ("unhandled critical CRL extension");
  case X509_V_ERR_INVALID_EXTENSION:
    return ("invalid or inconsistent certificate extension");
  case X509_V_ERR_INVALID_POLICY_EXTENSION:
    return ("invalid or inconsistent certificate policy extension");
  case X509_V_ERR_NO_EXPLICIT_POLICY:
    return ("no explicit policy");
  case X509_V_ERR_UNNESTED_RESOURCE:
    return ("RFC 3779 resource not subset of parent's resources");
  default:
    BIO_snprintf(buf, sizeof buf, "error number %ld", n);
    return (buf);
  }
}


x86 assembly (clang, -O0):
<X509_verify_cert_error_string>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%eax
add    $0xffffff80,%eax
mov    %eax,%ecx
mov    %rcx,-0x18(%rbp)
sub    $0x2c,%eax
ja     1415 <X509_verify_cert_error_string+0x305>
mov    -0x18(%rbp),%rax
lea    0xec4(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xf68(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xf5b(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xf6c(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xf7a(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xf94(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfa6(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfb9(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfc7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfcd(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfda(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfdf(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfe7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0xfe7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1005(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1022(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1039(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1050(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x104e(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1056(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1073(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x108a(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10a1(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10ac(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10b0(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10b7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10da(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10c4(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x10da(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x110a(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x111a(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1122(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1127(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1138(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1140(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x115e(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x117a(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1199(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x11ae(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x11bb(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x11d2(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x11ef(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1200(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x121e(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1243(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
lea    0x1246(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    143c <X509_verify_cert_error_string+0x32c>
mov    -0x10(%rbp),%rcx
lea    0x2c20(%rip),%rdi
mov    $0x64,%esi
lea    0x1259(%rip),%rdx
call   1030 <BIO_snprintf@plt>
lea    0x2c08(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<X509_verify_cert_error_string>:
push   %rbx
lea    -0x80(%rdi),%eax
cmp    $0x2d,%eax
jae    112b <X509_verify_cert_error_string+0x1b>
cltq
lea    0x14c2(%rip),%rcx
movslq (%rcx,%rax,4),%rbx
add    %rcx,%rbx
jmp    1149 <X509_verify_cert_error_string+0x39>
mov    %rdi,%rcx
lea    0x2f0b(%rip),%rbx
lea    0x1495(%rip),%rdx
mov    %rbx,%rdi
mov    $0x64,%esi
call   1030 <BIO_snprintf@plt>
mov    %rbx,%rax
pop    %rbx
ret

LLVM IR (-O0):
@X509_verify_cert_error_string.buf = internal global [100 x i8] zeroinitializer
@.str = [3 x i8] c"ok\00"
@.str.1 = [33 x i8] c"unable to get issuer certificate\00"
@.str.2 = [30 x i8] c"unable to get certificate CRL\00"
@.str.3 = [42 x i8] c"unable to decrypt certificate's signature\00"
@.str.4 = [34 x i8] c"unable to decrypt CRL's signature\00"
@.str.5 = [35 x i8] c"unable to decode issuer public key\00"
@.str.6 = [30 x i8] c"certificate signature failure\00"
@.str.7 = [22 x i8] c"CRL signature failure\00"
@.str.8 = [29 x i8] c"certificate is not yet valid\00"
@.str.9 = [21 x i8] c"CRL is not yet valid\00"
@.str.10 = [24 x i8] c"certificate has expired\00"
@.str.11 = [16 x i8] c"CRL has expired\00"
@.str.12 = [46 x i8] c"format error in certificate's notBefore field\00"
@.str.13 = [45 x i8] c"format error in certificate's notAfter field\00"
@.str.14 = [39 x i8] c"format error in CRL's lastUpdate field\00"
@.str.15 = [39 x i8] c"format error in CRL's nextUpdate field\00"
@.str.16 = [14 x i8] c"out of memory\00"
@.str.17 = [24 x i8] c"self signed certificate\00"
@.str.18 = [45 x i8] c"self signed certificate in certificate chain\00"
@.str.19 = [39 x i8] c"unable to get local issuer certificate\00"
@.str.20 = [39 x i8] c"unable to verify the first certificate\00"
@.str.21 = [27 x i8] c"certificate chain too long\00"
@.str.22 = [20 x i8] c"certificate revoked\00"
@.str.23 = [23 x i8] c"invalid CA certificate\00"
@.str.24 = [45 x i8] c"invalid non-CA certificate (has CA markings)\00"
@.str.25 = [32 x i8] c"path length constraint exceeded\00"
@.str.26 = [38 x i8] c"proxy path length constraint exceeded\00"
@.str.27 = [64 x i8] c"proxy certificates not allowed, please set the appropriate flag\00"
@.str.28 = [32 x i8] c"unsupported certificate purpose\00"
@.str.29 = [24 x i8] c"certificate not trusted\00"
@.str.30 = [21 x i8] c"certificate rejected\00"
@.str.31 = [33 x i8] c"application verification failure\00"
@.str.32 = [24 x i8] c"subject issuer mismatch\00"
@.str.33 = [46 x i8] c"authority and subject key identifier mismatch\00"
@.str.34 = [44 x i8] c"authority and issuer serial number mismatch\00"
@.str.35 = [47 x i8] c"key usage does not include certificate signing\00"
@.str.36 = [37 x i8] c"unable to get CRL issuer certificate\00"
@.str.37 = [29 x i8] c"unhandled critical extension\00"
@.str.38 = [39 x i8] c"key usage does not include CRL signing\00"
@.str.39 = [45 x i8] c"key usage does not include digital signature\00"
@.str.40 = [33 x i8] c"unhandled critical CRL extension\00"
@.str.41 = [46 x i8] c"invalid or inconsistent certificate extension\00"
@.str.42 = [53 x i8] c"invalid or inconsistent certificate policy extension\00"
@.str.43 = [19 x i8] c"no explicit policy\00"
@.str.44 = [51 x i8] c"RFC 3779 resource not subset of parent's resources\00"
@.str.45 = [17 x i8] c"error number %ld\00"
define i8* @X509_verify_cert_error_string(i64 %0) {
%2 = alloca i8*
%3 = alloca i64
store i64 %0, i64* %3
%4 = load i64, i64* %3
%5 = trunc i64 %4 to i32
switch i32 %5, label %51 [
i32 128, label %6
i32 134, label %7
i32 136, label %8
i32 138, label %9
i32 137, label %10
i32 139, label %11
i32 164, label %12
i32 160, label %13
i32 167, label %14
i32 161, label %15
i32 168, label %16
i32 162, label %17
i32 157, label %18
i32 158, label %19
i32 156, label %20
i32 155, label %21
i32 145, label %22
i32 159, label %23
i32 141, label %24
i32 133, label %25
i32 132, label %26
i32 169, label %27
i32 165, label %28
i32 154, label %29
i32 152, label %30
i32 144, label %31
i32 142, label %32
i32 143, label %33
i32 150, label %34
i32 163, label %35
i32 166, label %36
i32 170, label %37
i32 140, label %38
i32 171, label %39
i32 172, label %40
i32 149, label %41
i32 135, label %42
i32 130, label %43
i32 148, label %44
i32 147, label %45
i32 131, label %46
i32 153, label %47
i32 151, label %48
i32 146, label %49
i32 129, label %50
]
6: ; preds = %1
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8** %2
br label %54
7: ; preds = %1
store i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %54
8: ; preds = %1
store i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.2, i64 0, i64 0), i8** %2
br label %54
9: ; preds = %1
store i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %54
10: ; preds = %1
store i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.4, i64 0, i64 0), i8** %2
br label %54
11: ; preds = %1
store i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.5, i64 0, i64 0), i8** %2
br label %54
12: ; preds = %1
store i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.6, i64 0, i64 0), i8** %2
br label %54
13: ; preds = %1
store i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.7, i64 0, i64 0), i8** %2
br label %54
14: ; preds = %1
store i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.8, i64 0, i64 0), i8** %2
br label %54
15: ; preds = %1
store i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.9, i64 0, i64 0), i8** %2
br label %54
16: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.10, i64 0, i64 0), i8** %2
br label %54
17: ; preds = %1
store i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.11, i64 0, i64 0), i8** %2
br label %54
18: ; preds = %1
store i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.12, i64 0, i64 0), i8** %2
br label %54
19: ; preds = %1
store i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.13, i64 0, i64 0), i8** %2
br label %54
20: ; preds = %1
store i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.14, i64 0, i64 0), i8** %2
br label %54
21: ; preds = %1
store i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.15, i64 0, i64 0), i8** %2
br label %54
22: ; preds = %1
store i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.16, i64 0, i64 0), i8** %2
br label %54
23: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.17, i64 0, i64 0), i8** %2
br label %54
24: ; preds = %1
store i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.18, i64 0, i64 0), i8** %2
br label %54
25: ; preds = %1
store i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.19, i64 0, i64 0), i8** %2
br label %54
26: ; preds = %1
store i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.20, i64 0, i64 0), i8** %2
br label %54
27: ; preds = %1
store i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.21, i64 0, i64 0), i8** %2
br label %54
28: ; preds = %1
store i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.22, i64 0, i64 0), i8** %2
br label %54
29: ; preds = %1
store i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.23, i64 0, i64 0), i8** %2
br label %54
30: ; preds = %1
store i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.24, i64 0, i64 0), i8** %2
br label %54
31: ; preds = %1
store i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.25, i64 0, i64 0), i8** %2
br label %54
32: ; preds = %1
store i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.26, i64 0, i64 0), i8** %2
br label %54
33: ; preds = %1
store i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.27, i64 0, i64 0), i8** %2
br label %54
34: ; preds = %1
store i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.28, i64 0, i64 0), i8** %2
br label %54
35: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.29, i64 0, i64 0), i8** %2
br label %54
36: ; preds = %1
store i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.30, i64 0, i64 0), i8** %2
br label %54
37: ; preds = %1
store i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.31, i64 0, i64 0), i8** %2
br label %54
38: ; preds = %1
store i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.32, i64 0, i64 0), i8** %2
br label %54
39: ; preds = %1
store i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.33, i64 0, i64 0), i8** %2
br label %54
40: ; preds = %1
store i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.34, i64 0, i64 0), i8** %2
br label %54
41: ; preds = %1
store i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.35, i64 0, i64 0), i8** %2
br label %54
42: ; preds = %1
store i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.36, i64 0, i64 0), i8** %2
br label %54
43: ; preds = %1
store i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.37, i64 0, i64 0), i8** %2
br label %54
44: ; preds = %1
store i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.38, i64 0, i64 0), i8** %2
br label %54
45: ; preds = %1
store i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.39, i64 0, i64 0), i8** %2
br label %54
46: ; preds = %1
store i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.40, i64 0, i64 0), i8** %2
br label %54
47: ; preds = %1
store i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.41, i64 0, i64 0), i8** %2
br label %54
48: ; preds = %1
store i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.42, i64 0, i64 0), i8** %2
br label %54
49: ; preds = %1
store i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.43, i64 0, i64 0), i8** %2
br label %54
50: ; preds = %1
store i8* getelementptr inbounds ([51 x i8], [51 x i8]* @.str.44, i64 0, i64 0), i8** %2
br label %54
51: ; preds = %1
%52 = load i64, i64* %3
%53 = call i32 @BIO_snprintf(i8* getelementptr inbounds ([100 x i8], [100 x i8]* @X509_verify_cert_error_string.buf, i64 0, i64 0), i32 100, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.45, i64 0, i64 0), i64 %52)
store i8* getelementptr inbounds ([100 x i8], [100 x i8]* @X509_verify_cert_error_string.buf, i64 0, i64 0), i8** %2
br label %54
54: ; preds = %51, %50, %49, %48, %47, %46, %45, %44, %43, %42, %41, %40, %39, %38, %37, %36, %35, %34, %33, %32, %31, %30, %29, %28, %27, %26, %25, %24, %23, %22, %21, %20, %19, %18, %17, %16, %15, %14, %13, %12, %11, %10, %9, %8, %7, %6
%55 = load i8*, i8** %2
ret i8* %55
}

LLVM IR (-O2):
@X509_verify_cert_error_string.buf = internal global [100 x i8] zeroinitializer
@.str = [3 x i8] c"ok\00"
@.str.1 = [33 x i8] c"unable to get issuer certificate\00"
@.str.2 = [30 x i8] c"unable to get certificate CRL\00"
@.str.3 = [42 x i8] c"unable to decrypt certificate's signature\00"
@.str.4 = [34 x i8] c"unable to decrypt CRL's signature\00"
@.str.5 = [35 x i8] c"unable to decode issuer public key\00"
@.str.6 = [30 x i8] c"certificate signature failure\00"
@.str.7 = [22 x i8] c"CRL signature failure\00"
@.str.8 = [29 x i8] c"certificate is not yet valid\00"
@.str.9 = [21 x i8] c"CRL is not yet valid\00"
@.str.10 = [24 x i8] c"certificate has expired\00"
@.str.11 = [16 x i8] c"CRL has expired\00"
@.str.12 = [46 x i8] c"format error in certificate's notBefore field\00"
@.str.13 = [45 x i8] c"format error in certificate's notAfter field\00"
@.str.14 = [39 x i8] c"format error in CRL's lastUpdate field\00"
@.str.15 = [39 x i8] c"format error in CRL's nextUpdate field\00"
@.str.16 = [14 x i8] c"out of memory\00"
@.str.17 = [24 x i8] c"self signed certificate\00"
@.str.18 = [45 x i8] c"self signed certificate in certificate chain\00"
@.str.19 = [39 x i8] c"unable to get local issuer certificate\00"
@.str.20 = [39 x i8] c"unable to verify the first certificate\00"
@.str.21 = [27 x i8] c"certificate chain too long\00"
@.str.22 = [20 x i8] c"certificate revoked\00"
@.str.23 = [23 x i8] c"invalid CA certificate\00"
@.str.24 = [45 x i8] c"invalid non-CA certificate (has CA markings)\00"
@.str.25 = [32 x i8] c"path length constraint exceeded\00"
@.str.26 = [38 x i8] c"proxy path length constraint exceeded\00"
@.str.27 = [64 x i8] c"proxy certificates not allowed, please set the appropriate flag\00"
@.str.28 = [32 x i8] c"unsupported certificate purpose\00"
@.str.29 = [24 x i8] c"certificate not trusted\00"
@.str.30 = [21 x i8] c"certificate rejected\00"
@.str.31 = [33 x i8] c"application verification failure\00"
@.str.32 = [24 x i8] c"subject issuer mismatch\00"
@.str.33 = [46 x i8] c"authority and subject key identifier mismatch\00"
@.str.34 = [44 x i8] c"authority and issuer serial number mismatch\00"
@.str.35 = [47 x i8] c"key usage does not include certificate signing\00"
@.str.36 = [37 x i8] c"unable to get CRL issuer certificate\00"
@.str.37 = [29 x i8] c"unhandled critical extension\00"
@.str.38 = [39 x i8] c"key usage does not include CRL signing\00"
@.str.39 = [45 x i8] c"key usage does not include digital signature\00"
@.str.40 = [33 x i8] c"unhandled critical CRL extension\00"
@.str.41 = [46 x i8] c"invalid or inconsistent certificate extension\00"
@.str.42 = [53 x i8] c"invalid or inconsistent certificate policy extension\00"
@.str.43 = [19 x i8] c"no explicit policy\00"
@.str.44 = [51 x i8] c"RFC 3779 resource not subset of parent's resources\00"
@.str.45 = [17 x i8] c"error number %ld\00"
@reltable.X509_verify_cert_error_string = [45 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([3 x i8]* @.str to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([51 x i8]* @.str.44 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([29 x i8]* @.str.37 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([33 x i8]* @.str.40 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([39 x i8]* @.str.20 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([39 x i8]* @.str.19 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([33 x i8]* @.str.1 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([37 x i8]* @.str.36 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([30 x i8]* @.str.2 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([34 x i8]* @.str.4 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([42 x i8]* @.str.3 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([35 x i8]* @.str.5 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([24 x i8]* @.str.32 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([45 x i8]* @.str.18 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([38 x i8]* @.str.26 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([64 x i8]* @.str.27 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([32 x i8]* @.str.25 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([14 x i8]* @.str.16 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([19 x i8]* @.str.43 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([45 x i8]* @.str.39 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([39 x i8]* @.str.38 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([47 x i8]* @.str.35 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([32 x i8]* @.str.28 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([53 x i8]* @.str.42 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([45 x i8]* @.str.24 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([46 x i8]* @.str.41 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([23 x i8]* @.str.23 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([39 x i8]* @.str.15 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([39 x i8]* @.str.14 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([46 x i8]* @.str.12 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([45 x i8]* @.str.13 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([24 x i8]* @.str.17 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([22 x i8]* @.str.7 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([21 x i8]* @.str.9 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([16 x i8]* @.str.11 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([24 x i8]* @.str.29 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([30 x i8]* @.str.6 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([20 x i8]* @.str.22 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([21 x i8]* @.str.30 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([29 x i8]* @.str.8 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([24 x i8]* @.str.10 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([27 x i8]* @.str.21 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([33 x i8]* @.str.31 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([46 x i8]* @.str.33 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([44 x i8]* @.str.34 to i64), i64 ptrtoint ([45 x i32]* @reltable.X509_verify_cert_error_string to i64)) to i32)]
define i8* @X509_verify_cert_error_string(i64 %0) {
%2 = trunc i64 %0 to i32
%3 = add i32 %2, -128
%4 = icmp ult i32 %3, 45
br i1 %4, label %7, label %5
5: ; preds = %1
%6 = tail call i32 @BIO_snprintf(i8* getelementptr inbounds ([100 x i8], [100 x i8]* @X509_verify_cert_error_string.buf, i64 0, i64 0), i32 100, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.45, i64 0, i64 0), i64 %0)
br label %11
7: ; preds = %1
%8 = sext i32 %3 to i64
%9 = shl i64 %8, 2
%10 = call i8* @llvm.load.relative.i64(i8* bitcast ([45 x i32]* @reltable.X509_verify_cert_error_string to i8*), i64 %9)
br label %11
11: ; preds = %7, %5
%12 = phi i8* [ getelementptr inbounds ([100 x i8], [100 x i8]* @X509_verify_cert_error_string.buf, i64 0, i64 0), %5 ], [ %10, %7 ]
ret i8* %12
}