#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 */
typedef int /*<<< orphan*/ TS_ACCURACY;
typedef int /*<<< orphan*/ BIO;
typedef int /*<<< orphan*/ ASN1_INTEGER;

/* Variables and functions */
int /*<<< orphan*/ BIO_printf(int /*<<< orphan*/ *, char *);
int /*<<< orphan*/ *TS_ACCURACY_get_micros(int /*<<< orphan*/ const *);
int /*<<< orphan*/ *TS_ACCURACY_get_millis(int /*<<< orphan*/ const *);
int /*<<< orphan*/ *TS_ACCURACY_get_seconds(int /*<<< orphan*/ const *);
int /*<<< orphan*/ TS_ASN1_INTEGER_print_bio(int /*<<< orphan*/ *,
                                             int /*<<< orphan*/ const *);
int TS_ACCURACY_print_bio(BIO *bio, const TS_ACCURACY *accuracy) {
  const ASN1_INTEGER *seconds = TS_ACCURACY_get_seconds(accuracy);
  const ASN1_INTEGER *millis = TS_ACCURACY_get_millis(accuracy);
  const ASN1_INTEGER *micros = TS_ACCURACY_get_micros(accuracy);
  if (seconds != NULL)
    TS_ASN1_INTEGER_print_bio(bio, seconds);
  else
    BIO_printf(bio, "unspecified");
  BIO_printf(bio, " seconds, ");
  if (millis != NULL)
    TS_ASN1_INTEGER_print_bio(bio, millis);
  else
    BIO_printf(bio, "unspecified");
  BIO_printf(bio, " millis, ");
  if (micros != NULL)
    TS_ASN1_INTEGER_print_bio(bio, micros);
  else
    BIO_printf(bio, "unspecified");
  BIO_printf(bio, " micros");
  return 1;
}


x86 assembly (clang, -O0):
<TS_ACCURACY_print_bio>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
call   1060 <TS_ACCURACY_get_seconds@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
call   1040 <TS_ACCURACY_get_millis@plt>
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rdi
call   1070 <TS_ACCURACY_get_micros@plt>
mov    %rax,-0x28(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     11a4 <TS_ACCURACY_print_bio+0x54>
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    11b4 <TS_ACCURACY_print_bio+0x64>
mov    -0x8(%rbp),%rdi
lea    0xe51(%rip),%rsi
call   1030 <BIO_printf@plt>
mov    -0x8(%rbp),%rdi
lea    0xe4d(%rip),%rsi
call   1030 <BIO_printf@plt>
cmpq   $0x0,-0x20(%rbp)
je     11e1 <TS_ACCURACY_print_bio+0x91>
mov    -0x8(%rbp),%rdi
mov    -0x20(%rbp),%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    11f1 <TS_ACCURACY_print_bio+0xa1>
mov    -0x8(%rbp),%rdi
lea    0xe14(%rip),%rsi
call   1030 <BIO_printf@plt>
mov    -0x8(%rbp),%rdi
lea    0xe1b(%rip),%rsi
call   1030 <BIO_printf@plt>
cmpq   $0x0,-0x28(%rbp)
je     121e <TS_ACCURACY_print_bio+0xce>
mov    -0x8(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    122e <TS_ACCURACY_print_bio+0xde>
mov    -0x8(%rbp),%rdi
lea    0xdd7(%rip),%rsi
call   1030 <BIO_printf@plt>
mov    -0x8(%rbp),%rdi
lea    0xde8(%rip),%rsi
call   1030 <BIO_printf@plt>
mov    $0x1,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<TS_ACCURACY_print_bio>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
mov    %rsi,%rbx
mov    %rdi,%r13
mov    %rsi,%rdi
call   1060 <TS_ACCURACY_get_seconds@plt>
mov    %rax,%r12
mov    %rbx,%rdi
call   1040 <TS_ACCURACY_get_millis@plt>
mov    %rax,%r15
mov    %rbx,%rdi
call   1070 <TS_ACCURACY_get_micros@plt>
mov    %rax,%r14
test   %r12,%r12
je     1192 <TS_ACCURACY_print_bio+0x42>
mov    %r13,%rdi
mov    %r12,%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    11a1 <TS_ACCURACY_print_bio+0x51>
lea    0xe67(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
lea    0xe64(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
test   %r15,%r15
je     11c2 <TS_ACCURACY_print_bio+0x72>
mov    %r13,%rdi
mov    %r15,%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    11d1 <TS_ACCURACY_print_bio+0x81>
lea    0xe37(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
lea    0xe3f(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
test   %r14,%r14
je     11f2 <TS_ACCURACY_print_bio+0xa2>
mov    %r13,%rdi
mov    %r14,%rsi
call   1050 <TS_ASN1_INTEGER_print_bio@plt>
jmp    1201 <TS_ACCURACY_print_bio+0xb1>
lea    0xe07(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
lea    0xe19(%rip),%rsi
mov    %r13,%rdi
call   1030 <BIO_printf@plt>
mov    $0x1,%eax
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [12 x i8] c"unspecified\00"
@.str.1 = [11 x i8] c" seconds, \00"
@.str.2 = [10 x i8] c" millis, \00"
@.str.3 = [8 x i8] c" micros\00"
define i32 @TS_ACCURACY_print_bio(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
%5 = alloca i32*
%6 = alloca i32*
%7 = alloca i32*
store i32* %0, i32** %3
store i32* %1, i32** %4
%8 = load i32*, i32** %4
%9 = call i32* @TS_ACCURACY_get_seconds(i32* %8)
store i32* %9, i32** %5
%10 = load i32*, i32** %4
%11 = call i32* @TS_ACCURACY_get_millis(i32* %10)
store i32* %11, i32** %6
%12 = load i32*, i32** %4
%13 = call i32* @TS_ACCURACY_get_micros(i32* %12)
store i32* %13, i32** %7
%14 = load i32*, i32** %5
%15 = icmp ne i32* %14, null
br i1 %15, label %16, label %20
16: ; preds = %2
%17 = load i32*, i32** %3
%18 = load i32*, i32** %5
%19 = call i32 @TS_ASN1_INTEGER_print_bio(i32* %17, i32* %18)
br label %23
20: ; preds = %2
%21 = load i32*, i32** %3
%22 = call i32 @BIO_printf(i32* %21, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %23
23: ; preds = %20, %16
%24 = load i32*, i32** %3
%25 = call i32 @BIO_printf(i32* %24, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%26 = load i32*, i32** %6
%27 = icmp ne i32* %26, null
br i1 %27, label %28, label %32
28: ; preds = %23
%29 = load i32*, i32** %3
%30 = load i32*, i32** %6
%31 = call i32 @TS_ASN1_INTEGER_print_bio(i32* %29, i32* %30)
br label %35
32: ; preds = %23
%33 = load i32*, i32** %3
%34 = call i32 @BIO_printf(i32* %33, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %35
35: ; preds = %32, %28
%36 = load i32*, i32** %3
%37 = call i32 @BIO_printf(i32* %36, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.2, i64 0, i64 0))
%38 = load i32*, i32** %7
%39 = icmp ne i32* %38, null
br i1 %39, label %40, label %44
40: ; preds = %35
%41 = load i32*, i32** %3
%42 = load i32*, i32** %7
%43 = call i32 @TS_ASN1_INTEGER_print_bio(i32* %41, i32* %42)
br label %47
44: ; preds = %35
%45 = load i32*, i32** %3
%46 = call i32 @BIO_printf(i32* %45, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %47
47: ; preds = %44, %40
%48 = load i32*, i32** %3
%49 = call i32 @BIO_printf(i32* %48, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
ret i32 1
}

LLVM IR (-O2):
@.str = [12 x i8] c"unspecified\00"
@.str.1 = [11 x i8] c" seconds, \00"
@.str.2 = [10 x i8] c" millis, \00"
@.str.3 = [8 x i8] c" micros\00"
define i32 @TS_ACCURACY_print_bio(i32* %0, i32* %1) {
%3 = tail call i32* @TS_ACCURACY_get_seconds(i32* %1)
%4 = tail call i32* @TS_ACCURACY_get_millis(i32* %1)
%5 = tail call i32* @TS_ACCURACY_get_micros(i32* %1)
%6 = icmp eq i32* %3, null
br i1 %6, label %9, label %7
7: ; preds = %2
%8 = tail call i32 @TS_ASN1_INTEGER_print_bio(i32* %0, i32* %3)
br label %11
9: ; preds = %2
%10 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %11
11: ; preds = %9, %7
%12 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%13 = icmp eq i32* %4, null
br i1 %13, label %16, label %14
14: ; preds = %11
%15 = tail call i32 @TS_ASN1_INTEGER_print_bio(i32* %0, i32* %4)
br label %18
16: ; preds = %11
%17 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %18
18: ; preds = %16, %14
%19 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.2, i64 0, i64 0))
%20 = icmp eq i32* %5, null
br i1 %20, label %23, label %21
21: ; preds = %18
%22 = tail call i32 @TS_ASN1_INTEGER_print_bio(i32* %0, i32* %5)
br label %25
23: ; preds = %18
%24 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %25
25: ; preds = %23, %21
%26 = tail call i32 @BIO_printf(i32* %0, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
ret i32 1
}