// File: /workspace/github_cpp_makefile_star2_O1/sisong[P]ApkDiffPatch/HDiffPatch/libHDiffPatch/HDiff/private_diff/limit_mem_diff/stream_serialize.cpp
// Function: hdiff_private::TStepStream::_flush_step_code()
void TStepStream::_flush_step_code() {
    step_bufRle.finishAppend();
    const size_t curStepMemSize=step_bufCover_size+step_bufRle.fixed_code.size();
    if (curMaxStepMemSize<curStepMemSize)
        curMaxStepMemSize=curStepMemSize;
    if (isInInit){
        assert(step_buf.empty());
        sumBufSize_forInit+=hpatch_packUInt_size(step_bufCover_size) +
                            hpatch_packUInt_size(step_bufRle.curCodeSize())+
                            curStepMemSize + step_dataDiff.streamSize;
    }else{
        //step head
        assert(step_bufCover_size==step_bufCover.size());
        packUInt(step_buf,step_bufCover.size());
        packUInt(step_buf,step_bufRle.curCodeSize());
        //step cache data
        pushBack(step_buf,step_bufCover);            
        pushBack(step_buf,step_bufRle.fixed_code);
    }
    step_bufCover_size=0;
    step_bufCover.clear();
    step_bufRle.clear();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
leaq 0x170(%rdi), %r14
movq %r14, %rdi
callq 0x1b926
movq 0x178(%rbx), %r15
subq 0x170(%rbx), %r15
movq 0x240(%rbx), %rdi
addq %rdi, %r15
cmpq %r15, 0x138(%rbx)
jae 0x25480
movq %r15, 0x138(%rbx)
cmpb $0x1, 0x230(%rbx)
jne 0x254d4
movq 0x248(%rbx), %rax
cmpq 0x250(%rbx), %rax
jne 0x25620
xorl %esi, %esi
callq 0x43897
movl %eax, %ebp
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1b1a0
movq %rax, %rdi
xorl %esi, %esi
callq 0x43897
addl %ebp, %eax
addq 0x268(%rbx), %r15
addq %rax, %r15
addq %r15, 0x238(%rbx)
jmp 0x255b6
movq 0x160(%rbx), %rdx
subq 0x158(%rbx), %rdx
cmpq %rdx, %rdi
jne 0x2563f
leaq 0x5(%rsp), %rax
leaq 0x10(%rsp), %rdi
movq %rax, (%rdi)
leaq 0x10(%rsp), %rsi
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x437d8
testl %eax, %eax
je 0x2565e
leaq 0x248(%rbx), %r15
movq 0x250(%rbx), %rsi
leaq 0x10(%rsp), %r12
movq (%r12), %rcx
leaq 0x5(%rsp), %r13
movq %r15, %rdi
movq %r13, %rdx
callq 0x9e84
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1b1a0
movq %r13, (%r12)
leaq 0x10(%rsp), %rsi
movq %r12, %rdi
movq %rax, %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x437d8
testl %eax, %eax
je 0x2567c
movq 0x250(%rbx), %rsi
movq 0x10(%rsp), %rcx
leaq 0x5(%rsp), %rdx
movq %r15, %rdi
callq 0x9e84
movq 0x250(%rbx), %rsi
movq 0x158(%rbx), %rdx
movq 0x160(%rbx), %rcx
movq %r15, %rdi
callq 0xa244
movq 0x250(%rbx), %rsi
movq 0x170(%rbx), %rdx
movq 0x178(%rbx), %rcx
movq %r15, %rdi
callq 0xa244
movq $0x0, 0x240(%rbx)
movq 0x158(%rbx), %rax
cmpq %rax, 0x160(%rbx)
je 0x255d8
movq %rax, 0x160(%rbx)
movq 0x170(%rbx), %rax
cmpq %rax, 0x178(%rbx)
je 0x255ef
movq %rax, 0x178(%rbx)
movq 0x188(%rbx), %rax
cmpq %rax, 0x190(%rbx)
je 0x25606
movq %rax, 0x190(%rbx)
movq $0x0, 0x1a0(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x38340(%rip), %rdi     # 0x5d967
leaq 0x37c53(%rip), %rsi     # 0x5d281
leaq 0x38343(%rip), %rcx     # 0x5d978
movl $0x2ad, %edx            # imm = 0x2AD
callq 0x4200
leaq 0x38366(%rip), %rdi     # 0x5d9ac
leaq 0x37c34(%rip), %rsi     # 0x5d281
leaq 0x38324(%rip), %rcx     # 0x5d978
movl $0x2b3, %edx            # imm = 0x2B3
callq 0x4200
movl $0x10, %edi
callq 0x4190
movq %rax, %rbx
leaq 0x34d8e(%rip), %rsi     # 0x5a400
movq %rax, %rdi
callq 0x4110
jmp 0x25698
movl $0x10, %edi
callq 0x4190
movq %rax, %rbx
leaq 0x34d70(%rip), %rsi     # 0x5a400
movq %rax, %rdi
callq 0x4110
movq 0x56949(%rip), %rsi     # 0x7bfe8
movq 0x56912(%rip), %rdx     # 0x7bfb8
movq %rbx, %rdi
callq 0x4590
jmp 0x256b0
movq %rax, %r14
movq %rbx, %rdi
callq 0x4260
movq %r14, %rdi
callq 0x45e0
nop