// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/cram/cram_io.c
// Function: cram_free_compression_header
void cram_free_compression_header(cram_block_compression_hdr *hdr) {
    int i;

    if (hdr->landmark)
	free(hdr->landmark);

    if (hdr->preservation_map)
	kh_destroy(map, hdr->preservation_map);

    for (i = 0; i < CRAM_MAP_HASH; i++) {
	cram_map *m, *m2;
	for (m = hdr->rec_encoding_map[i]; m; m = m2) {
	    m2 = m->next;
	    if (m->codec)
		m->codec->free(m->codec);
	    free(m);
	}
    }

    for (i = 0; i < CRAM_MAP_HASH; i++) {
	cram_map *m, *m2;
	for (m = hdr->tag_encoding_map[i]; m; m = m2) {
	    m2 = m->next;
	    if (m->codec)
		m->codec->free(m->codec);
	    free(m);
	}
    }

    for (i = 0; i < DS_END; i++) {
	if (hdr->codecs[i])
	    hdr->codecs[i]->free(hdr->codecs[i]);
    }

    if (hdr->TL)
	free(hdr->TL);
    if (hdr->TD_blk)
	cram_free_block(hdr->TD_blk);
    if (hdr->TD_hash)
	kh_destroy(m_s2i, hdr->TD_hash);
    if (hdr->TD_keys)
	string_pool_destroy(hdr->TD_keys);

    free(hdr);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x18(%rax)
je 0x83ce4
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rax
cmpq $0x0, 0x78(%rax)
je 0x83cfc
movq -0x8(%rbp), %rax
movq 0x78(%rax), %rdi
callq 0x87bc0
movl $0x0, -0xc(%rbp)
cmpl $0x20, -0xc(%rbp)
jge 0x83d71
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq 0x80(%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x83d64
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x83d51
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq -0x18(%rbp), %rcx
movq 0x10(%rcx), %rdi
callq *%rax
movq -0x18(%rbp), %rdi
callq 0x6880
movq -0x20(%rbp), %rax
movq %rax, -0x18(%rbp)
jmp 0x83d1d
jmp 0x83d66
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x83d03
movl $0x0, -0xc(%rbp)
cmpl $0x20, -0xc(%rbp)
jge 0x83de6
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq 0x180(%rax,%rcx,8), %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x83dd9
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x83dc6
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movq 0x10(%rcx), %rdi
callq *%rax
movq -0x28(%rbp), %rdi
callq 0x6880
movq -0x30(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x83d92
jmp 0x83ddb
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x83d78
movl $0x0, -0xc(%rbp)
cmpl $0x2f, -0xc(%rbp)
jge 0x83e39
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
cmpq $0x0, 0x280(%rax,%rcx,8)
je 0x83e2c
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movq 0x280(%rax,%rcx,8), %rax
movq 0x10(%rax), %rax
movq -0x8(%rbp), %rcx
movslq -0xc(%rbp), %rdx
movq 0x280(%rcx,%rdx,8), %rdi
callq *%rax
jmp 0x83e2e
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x83ded
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0x83e51
movq -0x8(%rbp), %rax
movq 0x60(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rax
cmpq $0x0, 0x50(%rax)
je 0x83e69
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rdi
callq 0x7f750
movq -0x8(%rbp), %rax
cmpq $0x0, 0x68(%rax)
je 0x83e81
movq -0x8(%rbp), %rax
movq 0x68(%rax), %rdi
callq 0x87b70
movq -0x8(%rbp), %rax
cmpq $0x0, 0x70(%rax)
je 0x83e99
movq -0x8(%rbp), %rax
movq 0x70(%rax), %rdi
callq 0x97f90
movq -0x8(%rbp), %rdi
callq 0x6880
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)