// File: /workspace/github_c_makefile_star2_O0/videolan[P]bitstream/examples/dvb_gen_si.c
// Function: build_desc4e
static void build_desc4e(uint8_t *desc) {
    uint8_t k = 0;
    uint8_t *item_n;
    char *item1_desc = "Director";
    char *item1_text = "Famous director";
    char *item2_desc = "Year";
    char *item2_text = "2011";
    char *item3_desc = "Rating";
    char *item3_text = "***++";
    char *text = "Wow, what an event!";

    desc4e_init(desc);
    desc_set_length(desc, 255);

    desc4e_set_desc_number(desc, 0);
    desc4e_set_last_desc_number(desc, 0);
    desc4e_set_lang(desc, (uint8_t *)"eng");
    desc4e_set_items_length(desc, 0);

    {
        desc4e_set_items_length(desc, 255);
        uint8_t *first_item = desc4e_get_item(desc, 0);

        item_n = desc4e_get_item(desc, k++);
        desc4en_set_item_description(item_n, (uint8_t *)item1_desc, strlen(item1_desc));
        desc4en_set_item_text(item_n, (uint8_t *)item1_text, strlen(item1_text));

        item_n = desc4e_get_item(desc, k++);
        desc4en_set_item_description(item_n, (uint8_t *)item2_desc, strlen(item2_desc));
        desc4en_set_item_text(item_n, (uint8_t *)item2_text, strlen(item2_text));

        item_n = desc4e_get_item(desc, k++);
        desc4en_set_item_description(item_n, (uint8_t *)item3_desc, strlen(item3_desc));
        desc4en_set_item_text(item_n, (uint8_t *)item3_text, strlen(item3_text));

        item_n = desc4e_get_item(desc, k);
        desc4e_set_items_length(desc, item_n - first_item);
    }

    desc4e_set_text(desc, (uint8_t *)text, strlen(text));
    desc4e_set_length(desc);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0x8(%rbp)
movb $0x0, -0x9(%rbp)
leaq 0xbafd(%rip), %rax      # 0x17527
movq %rax, -0x20(%rbp)
leaq 0xbafb(%rip), %rax      # 0x17530
movq %rax, -0x28(%rbp)
leaq 0xbb00(%rip), %rax      # 0x17540
movq %rax, -0x30(%rbp)
leaq 0xbafa(%rip), %rax      # 0x17545
movq %rax, -0x38(%rbp)
leaq 0xbaf4(%rip), %rax      # 0x1754a
movq %rax, -0x40(%rbp)
leaq 0xbaf0(%rip), %rax      # 0x17551
movq %rax, -0x48(%rbp)
leaq 0xbaeb(%rip), %rax      # 0x17557
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0xc8e0
movq -0x8(%rbp), %rdi
movl $0xff, %esi
callq 0x5ca0
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xc900
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xc930
movq -0x8(%rbp), %rdi
leaq 0xb9c5(%rip), %rsi      # 0x1746d
callq 0xc960
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xc9a0
movq -0x8(%rbp), %rdi
movl $0xff, %esi
callq 0xc9a0
movq -0x8(%rbp), %rdi
xorl %esi, %esi
leaq 0xeed(%rip), %rdx       # 0xc9c0
callq 0x59c0
movq %rax, -0x58(%rbp)
movq -0x8(%rbp), %rdi
movb -0x9(%rbp), %al
movb %al, %cl
addb $0x1, %cl
movb %cl, -0x9(%rbp)
leaq 0xece(%rip), %rdx       # 0xc9c0
movzbl %al, %esi
callq 0x59c0
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0xc8(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0xc0(%rbp)
movq -0x20(%rbp), %rdi
callq 0x1050
movq -0xc8(%rbp), %rdi
movq -0xc0(%rbp), %rsi
movzbl %al, %edx
callq 0xca30
movq -0x18(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x28(%rbp), %rdi
callq 0x1050
movq -0xb8(%rbp), %rdi
movq -0xb0(%rbp), %rsi
movzbl %al, %edx
callq 0xca70
movq -0x8(%rbp), %rdi
movb -0x9(%rbp), %al
movb %al, %cl
addb $0x1, %cl
movb %cl, -0x9(%rbp)
leaq 0xe42(%rip), %rdx       # 0xc9c0
movzbl %al, %esi
callq 0x59c0
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0xa0(%rbp)
movq -0x30(%rbp), %rdi
callq 0x1050
movq -0xa8(%rbp), %rdi
movq -0xa0(%rbp), %rsi
movzbl %al, %edx
callq 0xca30
movq -0x18(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x38(%rbp), %rdi
callq 0x1050
movq -0x98(%rbp), %rdi
movq -0x90(%rbp), %rsi
movzbl %al, %edx
callq 0xca70
movq -0x8(%rbp), %rdi
movb -0x9(%rbp), %al
movb %al, %cl
addb $0x1, %cl
movb %cl, -0x9(%rbp)
leaq 0xdb6(%rip), %rdx       # 0xc9c0
movzbl %al, %esi
callq 0x59c0
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x40(%rbp), %rdi
callq 0x1050
movq -0x88(%rbp), %rdi
movq -0x80(%rbp), %rsi
movzbl %al, %edx
callq 0xca30
movq -0x18(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x48(%rbp), %rdi
callq 0x1050
movq -0x78(%rbp), %rdi
movq -0x70(%rbp), %rsi
movzbl %al, %edx
callq 0xca70
movq -0x8(%rbp), %rdi
leaq 0xd47(%rip), %rdx       # 0xc9c0
movzbl -0x9(%rbp), %esi
callq 0x59c0
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movq -0x58(%rbp), %rcx
subq %rcx, %rax
movzbl %al, %esi
callq 0xc9a0
movq -0x8(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x50(%rbp), %rdi
callq 0x1050
movq -0x68(%rbp), %rdi
movq -0x60(%rbp), %rsi
movzbl %al, %edx
callq 0xcad0
movq -0x8(%rbp), %rdi
callq 0xcb40
addq $0xd0, %rsp
popq %rbp
retq
nopl (%rax,%rax)