// File: sisong[P]ApkDiffPatch/src/patch/Zipper.cpp
// Function: Zipper_by_multi_thread
void Zipper_by_multi_thread(Zipper* self,int threadNum){
    assert(self->_fileEntryCount==0);
    assert(self->_threadNum<=1);
    assert(self->_threadWorks==0);
#if (_IS_USED_MULTITHREAD)
    threadNum=(threadNum<=self->_fileEntryMaxCount)?threadNum:self->_fileEntryMaxCount;
    self->_threadNum=(threadNum>=1)?threadNum:1;
    if (isUsedMT(self)){
        try {
            self->_threadWorks=new TZipThreadWorks(self,self->_threadNum-1);
            self->_threadWorks->start_threads(self->_threadNum-1,TZipThreadWorks::run,self->_threadWorks,false);
        } catch (...) {
            self->_threadNum=1; //close multi-thread
            if (self->_threadWorks){
                delete self->_threadWorks;
                self->_threadWorks=0;
            } 
        }
    }
#else
    self->_threadNum=1;
#endif
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x60(%rax)
jne 0x8138b
jmp 0x813aa
leaq 0x32adb(%rip), %rdi     # 0xb3e6d
leaq 0x325f1(%rip), %rsi     # 0xb398a
movl $0x3b1, %edx            # imm = 0x3B1
leaq 0x32ae1(%rip), %rcx     # 0xb3e86
callq 0x4270
movq -0x8(%rbp), %rax
cmpl $0x1, 0x154(%rax)
jg 0x813b9
jmp 0x813d8
leaq 0x32af1(%rip), %rdi     # 0xb3eb1
leaq 0x325c3(%rip), %rsi     # 0xb398a
movl $0x3b2, %edx            # imm = 0x3B2
leaq 0x32ab3(%rip), %rcx     # 0xb3e86
callq 0x4270
movq -0x8(%rbp), %rax
cmpq $0x0, 0x158(%rax)
jne 0x813e8
jmp 0x81407
leaq 0x32ad6(%rip), %rdi     # 0xb3ec5
leaq 0x32594(%rip), %rsi     # 0xb398a
movl $0x3b3, %edx            # imm = 0x3B3
leaq 0x32a84(%rip), %rcx     # 0xb3e86
callq 0x4270
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x5c(%rcx), %eax
jg 0x8141b
movl -0xc(%rbp), %eax
movl %eax, -0x20(%rbp)
jmp 0x81425
movq -0x8(%rbp), %rax
movl 0x5c(%rax), %eax
movl %eax, -0x20(%rbp)
movl -0x20(%rbp), %eax
movl %eax, -0xc(%rbp)
cmpl $0x1, -0xc(%rbp)
jl 0x81439
movl -0xc(%rbp), %eax
movl %eax, -0x24(%rbp)
jmp 0x81443
movl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x81443
movl -0x24(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x154(%rax)
movq -0x8(%rbp), %rax
cmpl $0x1, 0x154(%rax)
jle 0x81552
movl $0x40, %edi
callq 0x43a0
movq %rax, -0x30(%rbp)
jmp 0x81471
movq -0x30(%rbp), %rdi
movq -0x8(%rbp), %rsi
movl 0x154(%rsi), %edx
decl %edx
callq 0x855c0
jmp 0x81488
movq -0x30(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x158(%rax)
movq -0x8(%rbp), %rax
movq 0x158(%rax), %rcx
movl 0x154(%rax), %esi
decl %esi
leaq 0x415f(%rip), %rdx      # 0x85610
xorl %r8d, %r8d
movq %rcx, %rdi
callq 0x81560
jmp 0x814be
jmp 0x81550
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x814eb
movq -0x30(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
movl $0x40, %esi
callq 0x43b0
movq -0x18(%rbp), %rdi
callq 0x4150
movq -0x8(%rbp), %rax
movl $0x1, 0x154(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x158(%rax)
je 0x8154b
movq -0x8(%rbp), %rax
movq 0x158(%rax), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
je 0x8153c
movq -0x38(%rbp), %rdi
callq 0x855a0
movq -0x38(%rbp), %rdi
movl $0x40, %esi
callq 0x43b0
movq -0x8(%rbp), %rax
movq $0x0, 0x158(%rax)
callq 0x45d0
jmp 0x81552
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)