// File: jimmiebergmann[P]fbx-file/miniz.c
// Function: mz_zip_writer_create_local_dir_header(mz_zip_archive*, unsigned char*, unsigned short, unsigned short, unsigned long, unsigned long, unsigned int, unsigned short, unsigned short, unsigned short, unsigned short)
static mz_bool mz_zip_writer_create_local_dir_header(mz_zip_archive *pZip, mz_uint8 *pDst, mz_uint16 filename_size, mz_uint16 extra_size, mz_uint64 uncomp_size, mz_uint64 comp_size, mz_uint32 uncomp_crc32, mz_uint16 method, mz_uint16 bit_flags, mz_uint16 dos_time, mz_uint16 dos_date)
{
    (void)pZip;
    memset(pDst, 0, MZ_ZIP_LOCAL_DIR_HEADER_SIZE);
    MZ_WRITE_LE32(pDst + MZ_ZIP_LDH_SIG_OFS, MZ_ZIP_LOCAL_DIR_HEADER_SIG);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_VERSION_NEEDED_OFS, method ? 20 : 0);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_BIT_FLAG_OFS, bit_flags);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_METHOD_OFS, method);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_FILE_TIME_OFS, dos_time);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_FILE_DATE_OFS, dos_date);
    MZ_WRITE_LE32(pDst + MZ_ZIP_LDH_CRC32_OFS, uncomp_crc32);
    MZ_WRITE_LE32(pDst + MZ_ZIP_LDH_COMPRESSED_SIZE_OFS, MZ_MIN(comp_size, MZ_UINT32_MAX));
    MZ_WRITE_LE32(pDst + MZ_ZIP_LDH_DECOMPRESSED_SIZE_OFS, MZ_MIN(uncomp_size, MZ_UINT32_MAX));
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_FILENAME_LEN_OFS, filename_size);
    MZ_WRITE_LE16(pDst + MZ_ZIP_LDH_EXTRA_LEN_OFS, extra_size);
    return MZ_TRUE;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x100, %rsp            # imm = 0x100
movw %cx, %ax
movw %dx, %cx
movw 0x30(%rbp), %dx
movw 0x28(%rbp), %dx
movw 0x20(%rbp), %dx
movw 0x18(%rbp), %dx
movl 0x10(%rbp), %edx
movq %rdi, -0xb8(%rbp)
movq %rsi, -0xc0(%rbp)
movw %cx, -0xc2(%rbp)
movw %ax, -0xc4(%rbp)
movq %r8, -0xd0(%rbp)
movq %r9, -0xd8(%rbp)
movq -0xc0(%rbp), %rdi
xorl %esi, %esi
movl $0x1e, %edx
callq 0x3190
movq -0xc0(%rbp), %rax
movq %rax, -0x78(%rbp)
movl $0x4034b50, -0x7c(%rbp) # imm = 0x4034B50
movl -0x7c(%rbp), %eax
movb %al, %cl
movq -0x78(%rbp), %rax
movb %cl, (%rax)
movl -0x7c(%rbp), %eax
shrl $0x8, %eax
movb %al, %cl
movq -0x78(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0x7c(%rbp), %eax
shrl $0x10, %eax
movb %al, %cl
movq -0x78(%rbp), %rax
movb %cl, 0x2(%rax)
movl -0x7c(%rbp), %eax
shrl $0x18, %eax
movb %al, %cl
movq -0x78(%rbp), %rax
movb %cl, 0x3(%rax)
movq -0xc0(%rbp), %rcx
addq $0x4, %rcx
movw 0x18(%rbp), %si
xorl %eax, %eax
movl $0x14, %edx
cmpw $0x0, %si
cmovnel %edx, %eax
movq %rcx, -0x8(%rbp)
movw %ax, -0xa(%rbp)
movw -0xa(%rbp), %ax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, (%rax)
movzwl -0xa(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0x6, %rcx
movw 0x20(%rbp), %ax
movq %rcx, -0x18(%rbp)
movw %ax, -0x1a(%rbp)
movw -0x1a(%rbp), %ax
movb %al, %cl
movq -0x18(%rbp), %rax
movb %cl, (%rax)
movzwl -0x1a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x18(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0x8, %rcx
movw 0x18(%rbp), %ax
movq %rcx, -0x28(%rbp)
movw %ax, -0x2a(%rbp)
movw -0x2a(%rbp), %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, (%rax)
movzwl -0x2a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0xa, %rcx
movw 0x28(%rbp), %ax
movq %rcx, -0x38(%rbp)
movw %ax, -0x3a(%rbp)
movw -0x3a(%rbp), %ax
movb %al, %cl
movq -0x38(%rbp), %rax
movb %cl, (%rax)
movzwl -0x3a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x38(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0xc, %rcx
movw 0x30(%rbp), %ax
movq %rcx, -0x48(%rbp)
movw %ax, -0x4a(%rbp)
movw -0x4a(%rbp), %ax
movb %al, %cl
movq -0x48(%rbp), %rax
movb %cl, (%rax)
movzwl -0x4a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x48(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0xe, %rcx
movl 0x10(%rbp), %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
movb %al, %cl
movq -0x88(%rbp), %rax
movb %cl, (%rax)
movl -0x8c(%rbp), %eax
shrl $0x8, %eax
movb %al, %cl
movq -0x88(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0x8c(%rbp), %eax
shrl $0x10, %eax
movb %al, %cl
movq -0x88(%rbp), %rax
movb %cl, 0x2(%rax)
movl -0x8c(%rbp), %eax
shrl $0x18, %eax
movb %al, %cl
movq -0x88(%rbp), %rax
movb %cl, 0x3(%rax)
movq -0xc0(%rbp), %rax
addq $0x12, %rax
movq %rax, -0xe0(%rbp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, -0xd8(%rbp)
jae 0x15b03
movq -0xd8(%rbp), %rax
movq %rax, -0xe8(%rbp)
jmp 0x15b11
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movq %rax, -0xe8(%rbp)
jmp 0x15b11
movq -0xe0(%rbp), %rcx
movq -0xe8(%rbp), %rax
movq %rcx, -0x98(%rbp)
movl %eax, -0x9c(%rbp)
movl -0x9c(%rbp), %eax
movb %al, %cl
movq -0x98(%rbp), %rax
movb %cl, (%rax)
movl -0x9c(%rbp), %eax
shrl $0x8, %eax
movb %al, %cl
movq -0x98(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0x9c(%rbp), %eax
shrl $0x10, %eax
movb %al, %cl
movq -0x98(%rbp), %rax
movb %cl, 0x2(%rax)
movl -0x9c(%rbp), %eax
shrl $0x18, %eax
movb %al, %cl
movq -0x98(%rbp), %rax
movb %cl, 0x3(%rax)
movq -0xc0(%rbp), %rax
addq $0x16, %rax
movq %rax, -0xf0(%rbp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, -0xd0(%rbp)
jae 0x15bac
movq -0xd0(%rbp), %rax
movq %rax, -0xf8(%rbp)
jmp 0x15bba
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movq %rax, -0xf8(%rbp)
jmp 0x15bba
movq -0xf0(%rbp), %rcx
movq -0xf8(%rbp), %rax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
movl -0xac(%rbp), %eax
movb %al, %cl
movq -0xa8(%rbp), %rax
movb %cl, (%rax)
movl -0xac(%rbp), %eax
shrl $0x8, %eax
movb %al, %cl
movq -0xa8(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0xac(%rbp), %eax
shrl $0x10, %eax
movb %al, %cl
movq -0xa8(%rbp), %rax
movb %cl, 0x2(%rax)
movl -0xac(%rbp), %eax
shrl $0x18, %eax
movb %al, %cl
movq -0xa8(%rbp), %rax
movb %cl, 0x3(%rax)
movq -0xc0(%rbp), %rcx
addq $0x1a, %rcx
movw -0xc2(%rbp), %ax
movq %rcx, -0x58(%rbp)
movw %ax, -0x5a(%rbp)
movw -0x5a(%rbp), %ax
movb %al, %cl
movq -0x58(%rbp), %rax
movb %cl, (%rax)
movzwl -0x5a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x58(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0xc0(%rbp), %rcx
addq $0x1c, %rcx
movw -0xc4(%rbp), %ax
movq %rcx, -0x68(%rbp)
movw %ax, -0x6a(%rbp)
movw -0x6a(%rbp), %ax
movb %al, %cl
movq -0x68(%rbp), %rax
movb %cl, (%rax)
movzwl -0x6a(%rbp), %eax
sarl $0x8, %eax
movb %al, %cl
movq -0x68(%rbp), %rax
movb %cl, 0x1(%rax)
movl $0x1, %eax
addq $0x100, %rsp            # imm = 0x100
popq %rbp
retq
nop