// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/test/hts_endian.c
// Function: t16_bit
static int t16_bit(int verbose) {
    uint8_t buf[9];
    size_t i;
    int errors = 0;

    for (i = 0; i < NELE(tests_16_bit); i++) {
        uint16_t u16;
        int16_t  i16;

        if (verbose) {
            fprintf(stderr, "%s %6"PRId16" %6"PRId16"\n",
                    to_hex(tests_16_bit[i].u8, 2),
                    tests_16_bit[i].i16, tests_16_bit[i].u16);
        }

        u16 = le_to_u16(tests_16_bit[i].u8);
        if (u16 != tests_16_bit[i].u16) {
            fprintf(stderr, "Failed %s => %"PRIu16"; expected %"PRIu16"\n",
                    to_hex(tests_16_bit[i].u8, 2), u16, tests_16_bit[i].u16);
            errors++;
        }

        i16 = le_to_i16(tests_16_bit[i].u8);
        if (i16 != tests_16_bit[i].i16) {
            fprintf(stderr, "Failed %s => %"PRId16"; expected %"PRId16"\n",
                    to_hex(tests_16_bit[i].u8, 2), i16, tests_16_bit[i].i16);
            errors++;
        }

        u16 = le_to_u16(tests_16_bit[i].u8_unaligned + 1);
        if (u16 != tests_16_bit[i].u16) {
            fprintf(stderr,
                    "Failed unaligned %s => %"PRIu16"; expected %"PRIu16"\n",
                    to_hex(tests_16_bit[i].u8_unaligned + 1, 2),
                    u16, tests_16_bit[i].u16);
            errors++;
        }

        i16 = le_to_i16(tests_16_bit[i].u8_unaligned + 1);
        if (i16 != tests_16_bit[i].i16) {
            fprintf(stderr,
                    "Failed unaligned %s => %"PRId16"; expected %"PRId16"\n",
                    to_hex(tests_16_bit[i].u8_unaligned + 1, 2),
                    i16, tests_16_bit[i].i16);
            errors++;
        }

        u16_to_le(tests_16_bit[i].u16, buf);
        if (memcmp(buf, tests_16_bit[i].u8, 2) != 0) {
            fprintf(stderr, "Failed %"PRIu16" => %s; expected %s\n",
                    tests_16_bit[i].u16,
                    to_hex(buf, 2), to_hex(tests_16_bit[i].u8, 2));
            errors++;
        }

        i16_to_le(tests_16_bit[i].i16, buf);
        if (memcmp(buf, tests_16_bit[i].u8, 2) != 0) {
            fprintf(stderr, "Failed %"PRId16" => %s; expected %s\n",
                    tests_16_bit[i].i16,
                    to_hex(buf, 2), to_hex(tests_16_bit[i].u8, 2));
            errors++;
        }

        u16_to_le(tests_16_bit[i].u16, buf + 1);
        if (memcmp(buf + 1, tests_16_bit[i].u8, 2) != 0) {
            fprintf(stderr, "Failed unaligned %"PRIu16" => %s; expected %s\n",
                    tests_16_bit[i].u16,
                    to_hex(buf + 1, 2), to_hex(tests_16_bit[i].u8, 2));
            errors++;
        }

        i16_to_le(tests_16_bit[i].i16, buf + 1);
        if (memcmp(buf + 1, tests_16_bit[i].u8, 2) != 0) {
            fprintf(stderr, "Failed unaligned %"PRId16" => %s; expected %s\n",
                    tests_16_bit[i].i16,
                    to_hex(buf + 1, 2), to_hex(tests_16_bit[i].u8, 2));
            errors++;
        }
    }

    return errors;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movl %edi, -0x4(%rbp)
movl $0x0, -0x1c(%rbp)
movq $0x0, -0x18(%rbp)
cmpq $0x6, -0x18(%rbp)
jae 0x20ba
cmpl $0x0, -0x4(%rbp)
je 0x1b21
movq 0x351b(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x28(%rbp)
leaq 0x356d(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x28(%rbp), %rdi
movq %rax, %rdx
leaq 0x354d(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movswl 0x6(%rax), %ecx
leaq 0x353a(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rsi
addq %rsi, %rax
movzwl 0x8(%rax), %r8d
leaq 0x1639(%rip), %rsi      # 0x3153
movb $0x0, %al
callq 0x1040
leaq 0x3518(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
callq 0x2d80
movw %ax, -0x1e(%rbp)
movzwl -0x1e(%rbp), %eax
leaq 0x34fc(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movzwl 0x8(%rcx), %ecx
cmpl %ecx, %eax
je 0x1bb1
movq 0x3485(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x30(%rbp)
leaq 0x34d7(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x30(%rbp), %rdi
movq %rax, %rdx
movzwl -0x1e(%rbp), %ecx
leaq 0x34b3(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rsi
addq %rsi, %rax
movzwl 0x8(%rax), %r8d
leaq 0x15be(%rip), %rsi      # 0x315f
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x3488(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
callq 0x2da0
movw %ax, -0x20(%rbp)
movswl -0x20(%rbp), %eax
leaq 0x346c(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movswl 0x6(%rcx), %ecx
cmpl %ecx, %eax
je 0x1c41
movq 0x33f5(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x38(%rbp)
leaq 0x3447(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x38(%rbp), %rdi
movq %rax, %rdx
movswl -0x20(%rbp), %ecx
leaq 0x3423(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rsi
addq %rsi, %rax
movswl 0x6(%rax), %r8d
leaq 0x154c(%rip), %rsi      # 0x317d
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x33f8(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
addq $0x2, %rdi
addq $0x1, %rdi
callq 0x2d80
movw %ax, -0x1e(%rbp)
movzwl -0x1e(%rbp), %eax
leaq 0x33d4(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movzwl 0x8(%rcx), %ecx
cmpl %ecx, %eax
je 0x1ce1
movq 0x335d(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x40(%rbp)
leaq 0x33af(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
addq $0x2, %rdi
addq $0x1, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x40(%rbp), %rdi
movq %rax, %rdx
movzwl -0x1e(%rbp), %ecx
leaq 0x3383(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rsi
addq %rsi, %rax
movzwl 0x8(%rax), %r8d
leaq 0x14ca(%rip), %rsi      # 0x319b
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x3358(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
addq $0x2, %rdi
addq $0x1, %rdi
callq 0x2da0
movw %ax, -0x20(%rbp)
movswl -0x20(%rbp), %eax
leaq 0x3334(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movswl 0x6(%rcx), %ecx
cmpl %ecx, %eax
je 0x1d81
movq 0x32bd(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x48(%rbp)
leaq 0x330f(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
addq $0x2, %rdi
addq $0x1, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x48(%rbp), %rdi
movq %rax, %rdx
movswl -0x20(%rbp), %ecx
leaq 0x32e3(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rsi
addq %rsi, %rax
movswl 0x6(%rax), %r8d
leaq 0x1452(%rip), %rsi      # 0x31c3
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x32b8(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movw 0x8(%rax), %ax
leaq -0xd(%rbp), %rsi
movzwl %ax, %edi
callq 0x2df0
leaq -0xd(%rbp), %rax
leaq 0x3295(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movw (%rcx), %cx
movw (%rax), %ax
subw %cx, %ax
setne %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x1e3b
movq 0x3212(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x60(%rbp)
leaq 0x3264(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movzwl 0x8(%rax), %eax
movl %eax, -0x54(%rbp)
leaq -0xd(%rbp), %rdi
movl $0x2, %esi
callq 0x1500
movq %rax, -0x50(%rbp)
leaq 0x323c(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x60(%rbp), %rdi
movl -0x54(%rbp), %edx
movq -0x50(%rbp), %rcx
movq %rax, %r8
leaq 0x13c0(%rip), %rsi      # 0x31eb
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x31fe(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movw 0x6(%rax), %ax
leaq -0xd(%rbp), %rsi
movswl %ax, %edi
callq 0x2e10
leaq -0xd(%rbp), %rax
leaq 0x31db(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movw (%rcx), %cx
movw (%rax), %ax
subw %cx, %ax
setne %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x1ef5
movq 0x3158(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x78(%rbp)
leaq 0x31aa(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movswl 0x6(%rax), %eax
movl %eax, -0x6c(%rbp)
leaq -0xd(%rbp), %rdi
movl $0x2, %esi
callq 0x1500
movq %rax, -0x68(%rbp)
leaq 0x3182(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x78(%rbp), %rdi
movl -0x6c(%rbp), %edx
movq -0x68(%rbp), %rcx
movq %rax, %r8
leaq 0x1324(%rip), %rsi      # 0x3209
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x3144(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movw 0x8(%rax), %ax
leaq -0xd(%rbp), %rsi
addq $0x1, %rsi
movzwl %ax, %edi
callq 0x2df0
leaq -0xd(%rbp), %rax
addq $0x1, %rax
leaq 0x3119(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movw (%rcx), %cx
movw (%rax), %ax
subw %cx, %ax
setne %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x1fcb
movq 0x3092(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0x90(%rbp)
leaq 0x30e1(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movzwl 0x8(%rax), %eax
movl %eax, -0x84(%rbp)
leaq -0xd(%rbp), %rdi
addq $0x1, %rdi
movl $0x2, %esi
callq 0x1500
movq %rax, -0x80(%rbp)
leaq 0x30b2(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0x90(%rbp), %rdi
movl -0x84(%rbp), %edx
movq -0x80(%rbp), %rcx
movq %rax, %r8
leaq 0x126c(%rip), %rsi      # 0x3227
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
leaq 0x306e(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movw 0x6(%rax), %ax
leaq -0xd(%rbp), %rsi
addq $0x1, %rsi
movswl %ax, %edi
callq 0x2e10
leaq -0xd(%rbp), %rax
addq $0x1, %rax
leaq 0x3043(%rip), %rcx      # 0x5040
imulq $0xa, -0x18(%rbp), %rdx
addq %rdx, %rcx
movw (%rcx), %cx
movw (%rax), %ax
subw %cx, %ax
setne %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x20a7
movq 0x2fbc(%rip), %rax      # 0x4fe0
movq (%rax), %rax
movq %rax, -0xa8(%rbp)
leaq 0x300b(%rip), %rax      # 0x5040
imulq $0xa, -0x18(%rbp), %rcx
addq %rcx, %rax
movswl 0x6(%rax), %eax
movl %eax, -0x9c(%rbp)
leaq -0xd(%rbp), %rdi
addq $0x1, %rdi
movl $0x2, %esi
callq 0x1500
movq %rax, -0x98(%rbp)
leaq 0x2fd9(%rip), %rdi      # 0x5040
imulq $0xa, -0x18(%rbp), %rax
addq %rax, %rdi
movl $0x2, %esi
callq 0x1500
movq -0xa8(%rbp), %rdi
movl -0x9c(%rbp), %edx
movq -0x98(%rbp), %rcx
movq %rax, %r8
leaq 0x11b8(%rip), %rsi      # 0x324f
movb $0x0, %al
callq 0x1040
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x20a9
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x1aad
movl -0x1c(%rbp), %eax
addq $0xb0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)