// File: /workspace/github_c_makefile_star2_O0/videolan[P]bitstream/examples/./bitstream/dvb/si/desc_64.h
// Function: desc64_print
static inline void desc64_print(const uint8_t *p_desc,
                                f_print pf_print, void *print_opaque,
                                f_iconv pf_iconv, void *iconv_opaque,
                                print_type_t i_print_type)
{
    uint8_t i_selector_byte_length, i_text_length, i;
    const uint8_t *p_selector_byte = desc64_get_selector_byte(p_desc, &i_selector_byte_length);

    const uint8_t *p_text = desc64_get_text(p_desc, &i_text_length);
    char *psz_text = dvb_string_get(p_text, i_text_length, pf_iconv, iconv_opaque);

    char psz_selector_byte[2 * 255 + 1];
    char psz_selector_byte_txt[255 + 1];

    for (i = 0; i < i_selector_byte_length; i++) {
        sprintf(psz_selector_byte + 2 * i, "%02x", p_selector_byte[i]);
        if (p_selector_byte[i] >= 32 && p_selector_byte[i] <= 127 && p_selector_byte[i] != '"')
            psz_selector_byte_txt[i] = p_selector_byte[i];
        else
            psz_selector_byte_txt[i] = '.';
    }
    psz_selector_byte[2 * i] = '\0';
    psz_selector_byte_txt[i] = '\0';

    switch (i_print_type) {
    case PRINT_XML:
        psz_text = dvb_string_xml_escape(psz_text);
        pf_print(print_opaque,
                 "<DATA_BROADCAST_DESC broadcast_id=\"0x%04x\" component_tag=\"%u\""
                 " selector_byte=\"%s\" lang=\"%3.3s\""
                 " text=\"%s\"/>",
                 desc64_get_broadcast_id(p_desc),
                 desc64_get_component_tag(p_desc),
                 psz_selector_byte,
                 (char *)desc64_get_lang(p_desc),
                 psz_text);
        break;
    default:
        pf_print(print_opaque,
                 "    - desc 64 data_broadcast broadcast_id=0x%04x component_tag=%u"
                 " selector_byte=\"%s\" selector_byte_txt=\"%s\" lang=%3.3s"
                 " text=\"%s\"",
                 desc64_get_broadcast_id(p_desc),
                 desc64_get_component_tag(p_desc),
                 psz_selector_byte,
                 psz_selector_byte_txt,
                 (char *)desc64_get_lang(p_desc),
                 psz_text);
    }
    free(psz_text);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x3b0, %rsp            # imm = 0x3B0
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movl %r9d, -0x2c(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x2d(%rbp), %rsi
callq 0x1a040
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x2e(%rbp), %rsi
callq 0x1a070
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rdi
movzbl -0x2e(%rbp), %eax
movl %eax, %esi
movq -0x20(%rbp), %rdx
movq -0x28(%rbp), %rcx
callq 0x16a70
movq %rax, -0x48(%rbp)
movb $0x0, -0x2f(%rbp)
movzbl -0x2f(%rbp), %eax
movzbl -0x2d(%rbp), %ecx
cmpl %ecx, %eax
jge 0xff36
leaq -0x250(%rbp), %rdi
movzbl -0x2f(%rbp), %eax
shll %eax
cltq
addq %rax, %rdi
movq -0x38(%rbp), %rax
movzbl -0x2f(%rbp), %ecx
movzbl (%rax,%rcx), %edx
leaq 0x152b7(%rip), %rsi     # 0x25180
movb $0x0, %al
callq 0x21e0
movq -0x38(%rbp), %rax
movzbl -0x2f(%rbp), %ecx
movzbl (%rax,%rcx), %eax
cmpl $0x20, %eax
jl 0xff1b
movq -0x38(%rbp), %rax
movzbl -0x2f(%rbp), %ecx
movzbl (%rax,%rcx), %eax
cmpl $0x7f, %eax
jg 0xff1b
movq -0x38(%rbp), %rax
movzbl -0x2f(%rbp), %ecx
movzbl (%rax,%rcx), %eax
cmpl $0x22, %eax
je 0xff1b
movq -0x38(%rbp), %rax
movzbl -0x2f(%rbp), %ecx
movb (%rax,%rcx), %cl
movzbl -0x2f(%rbp), %eax
movb %cl, -0x350(%rbp,%rax)
jmp 0xff27
movzbl -0x2f(%rbp), %eax
movb $0x2e, -0x350(%rbp,%rax)
jmp 0xff29
movb -0x2f(%rbp), %al
addb $0x1, %al
movb %al, -0x2f(%rbp)
jmp 0xfe94
movzbl -0x2f(%rbp), %eax
movb $0x0, -0x250(%rbp,%rax,2)
movzbl -0x2f(%rbp), %eax
movb $0x0, -0x350(%rbp,%rax)
movl -0x2c(%rbp), %eax
subl $0x1, %eax
jne 0xfff7
jmp 0xff5c
movq -0x48(%rbp), %rdi
callq 0x16ab0
movq %rax, -0x48(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x358(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x370(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a0d0
movzwl %ax, %eax
movl %eax, -0x368(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a0f0
movzbl %al, %eax
movl %eax, -0x364(%rbp)
leaq -0x250(%rbp), %rax
movq %rax, -0x360(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a110
movq -0x370(%rbp), %rdi
movl -0x368(%rbp), %edx
movl -0x364(%rbp), %ecx
movq -0x360(%rbp), %r8
movq -0x358(%rbp), %r10
movq %rax, %r9
movq -0x48(%rbp), %rax
leaq 0x18d01(%rip), %rsi     # 0x28cea
movq %rax, (%rsp)
movb $0x0, %al
callq *%r10
jmp 0x1009a
movq -0x10(%rbp), %rax
movq %rax, -0x378(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x398(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a0d0
movzwl %ax, %eax
movl %eax, -0x390(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a0f0
movzbl %al, %eax
movl %eax, -0x38c(%rbp)
leaq -0x250(%rbp), %rax
movq %rax, -0x388(%rbp)
leaq -0x350(%rbp), %rax
movq %rax, -0x380(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1a110
movq -0x398(%rbp), %rdi
movl -0x390(%rbp), %edx
movl -0x38c(%rbp), %ecx
movq -0x388(%rbp), %r8
movq -0x380(%rbp), %r9
movq -0x378(%rbp), %r10
movq %rax, %r11
movq -0x48(%rbp), %rax
leaq 0x18cc8(%rip), %rsi     # 0x28d54
movq %r11, (%rsp)
movq %rax, 0x8(%rsp)
movb $0x0, %al
callq *%r10
movq -0x48(%rbp), %rdi
callq 0x2030
addq $0x3b0, %rsp            # imm = 0x3B0
popq %rbp
retq
nopl (%rax)