// File: cybozu[P]yrmcds/src/memcache/memcache.cpp
// Function: yrmcds::memcache::text_request::parse_incdec(char const*, char const*)
inline void
text_request::parse_incdec(const char* b, const char* e) noexcept {
    while( *b == SP ) ++b;
    if( b == e ) return;
    const char* key_end = cfind(b, SP, e-b);
    if( key_end == nullptr ) return;
    m_key = item(b, key_end-b);
    b = key_end;

    while( *b == SP ) ++b;
    if( b == e ) return;
    const char* value_end = cfind(b, SP, e-b);
    if( value_end == nullptr ) value_end = e;
    bool result;
    m_value = to_uint<std::uint64_t>(b, result);
    if( ! result ) return;
    b = value_end;

    while( *b == SP ) ++b;
    if( b != e ) {
        // noreply ?
        const char* we = cfind(b, SP, e-b);
        std::size_t noreply_len = (we != nullptr) ? (we - b) : (e - b);
        if( noreply_len != 7 ) return;
        if( std::memcmp(b, "noreply", 7) != 0 ) return;
        m_no_reply = true;
        b = (we != nullptr) ? we : e;
    }

    while( *b == SP ) ++b;
    if( b != e ) return; // garbage left

    m_valid = true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x76456
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x7643c
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
jne 0x76465
jmp 0x76639
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x10(%rbp), %rax
subq %rax, %rdx
movl $0x20, %esi
callq 0x63090
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x7648e
jmp 0x76639
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x38(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x10(%rbp), %rsi
leaq -0x38(%rbp), %rdx
callq 0x524d0
movq -0x60(%rbp), %rdi
addq $0x20, %rdi
leaq -0x30(%rbp), %rsi
callq 0x51450
movq -0x20(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x764e1
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x764c7
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
jne 0x764f0
jmp 0x76639
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x10(%rbp), %rax
subq %rax, %rdx
movl $0x20, %esi
callq 0x63090
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
jne 0x7651c
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rdi
leaq -0x41(%rbp), %rsi
callq 0x74f10
movq %rax, %rcx
movq -0x60(%rbp), %rax
movq %rcx, 0x58(%rax)
testb $0x1, -0x41(%rbp)
jne 0x7653f
jmp 0x76639
movq -0x40(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x76561
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x76547
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
je 0x76609
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x10(%rbp), %rax
subq %rax, %rdx
movl $0x20, %esi
callq 0x63090
movq %rax, -0x50(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x765a4
movq -0x50(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x68(%rbp)
jmp 0x765b3
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x58(%rbp)
cmpq $0x7, -0x58(%rbp)
je 0x765c4
jmp 0x76639
movq -0x10(%rbp), %rdi
leaq 0x7ada(%rip), %rsi      # 0x7e0a9
movl $0x7, %edx
callq 0x8280
cmpl $0x0, %eax
je 0x765e0
jmp 0x76639
movq -0x60(%rbp), %rax
movb $0x1, 0x1d(%rax)
cmpq $0x0, -0x50(%rbp)
je 0x765f9
movq -0x50(%rbp), %rax
movq %rax, -0x70(%rbp)
jmp 0x76601
movq -0x18(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x7660b
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x76625
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x7660b
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
je 0x76631
jmp 0x76639
movq -0x60(%rbp), %rax
movb $0x1, 0x1c(%rax)
addq $0x70, %rsp
popq %rbp
retq
nop