LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/credis.cpp
// Function: Redis::hgetall(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>&)
bool Redis::hgetall(const std::string& key, std::map<std::string, std::string>& value)
{
    if(_context == NULL) 
    {
        return false;
    }

    value.clear();
    redisReply* _reply = (redisReply*)::redisCommand(_context, "HGETALL %s", key.c_str());
    if (!isError(_reply)) 
    {
        if (_reply->type == REDIS_REPLY_ERROR) 
        {
            freeReply(_reply);
            return false;
        }
        if (_reply->type == REDIS_REPLY_ARRAY) 
        {
            for (size_t i = 0; i < _reply->elements; i = i+2) 
            {
                std::string key(_reply->element[i]->str, _reply->element[i]->len);
                std::string val(_reply->element[i+1]->str, _reply->element[i+1]->len);
                value[key] = val;
            }
            freeReply(_reply);
            return true;
        }
    }
    freeReply(_reply);
    return false;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
cmpq $0x0, 0x8(%rdi)
je 0x9a38
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0xae64
movq 0x8(%r15), %rdi
movq (%r14), %rdx
leaq 0xa899(%rip), %rsi      # 0x141e9
xorl %ebp, %ebp
xorl %eax, %eax
callq 0xe1b0
testq %rax, %rax
je 0x9a3a
movq %rax, %r14
movl (%rax), %eax
cmpl $0x6, %eax
je 0x9a30
cmpl $0x2, %eax
jne 0x9a30
cmpq $0x0, 0x20(%r14)
je 0x9a23
leaq 0x38(%rsp), %rbp
xorl %r13d, %r13d
leaq 0x8(%rsp), %r15
leaq 0x28(%rsp), %r12
movq 0x28(%r14), %rax
movq (%rax,%r13,8), %rax
movq 0x18(%rax), %rsi
movq 0x10(%rax), %rdx
addq %rsi, %rdx
leaq 0x18(%rsp), %rax
movq %rax, 0x8(%rsp)
movq %r15, %rdi
callq 0x42ba
movq 0x28(%r14), %rax
movq 0x8(%rax,%r13,8), %rax
movq 0x18(%rax), %rsi
movq 0x10(%rax), %rdx
addq %rsi, %rdx
movq %rbp, 0x28(%rsp)
movq %r12, %rdi
callq 0x42ba
movq %rbx, %rdi
movq %r15, %rsi
callq 0xab6e
movq %rax, %rdi
movq %r12, %rsi
callq 0x3200
movq 0x28(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9a01
callq 0x3350
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x9a15
callq 0x3350
addq $0x2, %r13
cmpq 0x20(%r14), %r13
jb 0x9996
movq %r14, %rdi
callq 0xbb00
movb $0x1, %bpl
jmp 0x9a3a
movq %r14, %rdi
callq 0xbb00
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x9a62
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9a62
callq 0x3350
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x9a76
callq 0x3350
movq %rbx, %rdi
callq 0x35b0
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/./credis.h
// Function: int Redis::str2num<int>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
T str2num(const std::string& str)
    {
        std::stringstream ss;
        T num;
        ss << str;
        ss >> num;
        return num;
    }

// Assembly:
pushq %rbx
subq $0x190, %rsp            # imm = 0x190
movq %rsi, %rbx
leaq 0x8(%rsp), %rdi
callq 0x32a0
leaq 0x18(%rsp), %rdi
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
callq 0x33f0
leaq 0x8(%rsp), %rdi
leaq 0x4(%rsp), %rsi
callq 0x3250
movl 0x4(%rsp), %ebx
movq 0xf694(%rip), %rsi      # 0x19fb8
leaq 0x8(%rsp), %rdi
callq 0x32c0
leaq 0x88(%rsp), %rdi
callq 0x3130
movl %ebx, %eax
addq $0x190, %rsp            # imm = 0x190
popq %rbx
retq
movq %rax, %rbx
movq 0xf668(%rip), %rsi      # 0x19fb8
leaq 0x8(%rsp), %rdi
callq 0x32c0
leaq 0x88(%rsp), %rdi
callq 0x3130
movq %rbx, %rdi
callq 0x35b0
nop
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::~RedisConnectPool()
RedisConnectPool::~RedisConnectPool()
{
    {
	MutexGuard guard(&_mutex);
	list<redisContext*>::iterator it = _connectPool.begin();
	list<redisContext*>::iterator itEnd = _connectPool.end();
	for (; it != itEnd; ++it)
	{
	    //if(*it != NULL)
            {
                redisFree(*it);
                *it = NULL;
            }
	}
	_connectPool.clear();
    }

	pthread_mutex_destroy(&_mutex);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x68(%rdi), %r14
movq %r14, %rdi
callq 0x34b0
leaq 0x50(%rbx), %r12
movq 0x50(%rbx), %r15
cmpq %r12, %r15
je 0xb4ee
movq 0x10(%r15), %rdi
callq 0xd3f0
movq $0x0, 0x10(%r15)
movq (%r15), %r15
cmpq %r12, %r15
jne 0xb4d1
movq (%r12), %r15
cmpq %r12, %r15
je 0xb506
movq (%r15), %r13
movq %r15, %rdi
callq 0x3350
movq %r13, %r15
cmpq %r12, %r13
jne 0xb4f3
movq %r12, 0x58(%rbx)
movq %r12, 0x50(%rbx)
movq $0x0, 0x60(%rbx)
movq %r14, %rdi
callq 0x32e0
movq %r14, %rdi
callq 0x3410
movq 0x50(%rbx), %rdi
cmpq %r12, %rdi
je 0xb53f
movq (%rdi), %r14
callq 0x3350
movq %r14, %rdi
cmpq %r12, %r14
jne 0xb52f
movq 0x28(%rbx), %rdi
leaq 0x38(%rbx), %rax
cmpq %rax, %rdi
je 0xb551
callq 0x3350
movq 0x8(%rbx), %rdi
addq $0x18, %rbx
cmpq %rbx, %rdi
je 0xb56c
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x3350
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0xa641
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::initConnectPool()
bool RedisConnectPool::initConnectPool()
{
	for (int i = 0; i < _iPoolSize; ++i)
	{
	    redisContext *redisConn = connect();
            if(redisConn)
            {
    	        _connectPool.push_back(redisConn);
            }
        }
	
	return true;
}

// Assembly:
cmpl $0x0, (%rdi)
jle 0xb658
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x50(%rdi), %r14
xorl %ebp, %ebp
movq %rbx, %rdi
callq 0xb65c
testq %rax, %rax
je 0xb648
movq %rax, %r15
movl $0x18, %edi
callq 0x3380
movq %r15, 0x10(%rax)
movq %rax, %rdi
movq %r14, %rsi
callq 0x3070
incq 0x60(%rbx)
incl %ebp
cmpl (%rbx), %ebp
jl 0xb61b
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
movb $0x1, %al
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::reConnect(redisContext*&)
bool RedisConnectPool::reConnect(redisContext* &redisConn)
{
    if(redisConn)
    {
	redisFree(redisConn);
        redisConn = NULL;
    }
	redisConn = connect();
    if(redisConn == NULL)
        return false;
    
	return true;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq (%rsi), %rdi
testq %rdi, %rdi
je 0xb84c
callq 0xd3f0
movq $0x0, (%rbx)
movq %r14, %rdi
callq 0xb65c
movq %rax, (%rbx)
testq %rax, %rax
setne %al
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::getConnect()
redisContext * RedisConnectPool::getConnect()
{
	redisContext *retConn = NULL;
	MutexGuard guard(&_mutex);    
	{
		if (_connectPool.empty())
		{
			return retConn;
		}
		else
		{
		    retConn = _connectPool.front();
		    _connectPool.pop_front();
                    _iUsedCount++;
		}
	}

	if (retConn == NULL)
	{
		reConnect(retConn);
	}

	return retConn;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r15
leaq 0x68(%rdi), %rbx
movq %rbx, %rdi
callq 0x34b0
leaq 0x50(%r15), %rax
movq 0x50(%r15), %r12
cmpq %rax, %r12
je 0xb8b9
movq 0x10(%r12), %r14
decq 0x60(%r15)
movq %r12, %rdi
callq 0x3540
movq %r12, %rdi
callq 0x3350
incl 0x4(%r15)
testq %r14, %r14
jne 0xb8bc
movq %r15, %rdi
callq 0xb65c
movq %rax, %r14
jmp 0xb8bc
xorl %r14d, %r14d
movq %rbx, %rdi
callq 0x32e0
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x32e0
movq %r14, %rdi
callq 0x35b0
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::getConnect(int)
redisContext * RedisConnectPool::getConnect(int retry)
{
    redisContext * context = getConnect();
    while(context == NULL && retry-->0)
    {
        context = getConnect();
    }
    if(context == NULL)
    {
        return NULL;
    }

    return context;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
callq 0xb866
testq %rax, %rax
setne %cl
testl %r14d, %r14d
setle %dl
orb %cl, %dl
jne 0xb91f
movq %rbx, %rdi
callq 0xb866
testq %rax, %rax
jne 0xb91f
leal -0x1(%r14), %ecx
cmpl $0x1, %r14d
movl %ecx, %r14d
ja 0xb905
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::releaseConnect(redisContext*)
void RedisConnectPool::releaseConnect(redisContext *redisConn)
{
    if(redisConn == NULL)
        return ;
    if(find(_connectPool.begin(), _connectPool.end(), redisConn) != _connectPool.end())
    {
        return;
    }
    MutexGuard guard(&_mutex);    
	if(redisConn != NULL)
    {
            if(redisConn->err)
            {
                if (!reConnect(redisConn)) 
                {
                    return;
                }
            }
        if(isUseful(redisConn))
        {
	        _connectPool.push_back(redisConn);
            _iUsedCount--;
        }
	}

	return;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, (%rsp)
testq %rsi, %rsi
je 0xb95c
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x50(%rdi), %r14
movq 0x50(%rdi), %rax
cmpq %r14, %rax
je 0xb968
cmpq %r15, 0x10(%rax)
je 0xb957
movq (%rax), %rax
jmp 0xb947
cmpq %r14, %rax
je 0xb968
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x68(%rbx), %r12
movq %r12, %rdi
callq 0x34b0
cmpl $0x0, (%r15)
je 0xb996
movq %r15, %rdi
callq 0xd3f0
movq %rbx, %rdi
callq 0xb65c
movq %rax, %r15
movq %rax, (%rsp)
testq %rax, %rax
je 0xb9c2
movq %rsp, %rsi
callq 0xb9e8
testb %al, %al
je 0xb9c2
movl $0x18, %edi
callq 0x3380
movq %r15, 0x10(%rax)
movq %rax, %rdi
movq %r14, %rsi
callq 0x3070
incq 0x60(%rbx)
decl 0x4(%rbx)
movq %r12, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x32e0
movq %rax, %rbx
movq %r12, %rdi
callq 0x32e0
movq %rbx, %rdi
callq 0x35b0
// File: /workspace/github_cpp_makefile_star2_O3/Sherhang[P]redis-for-cpp/redis_connect_pool.cpp
// Function: RedisConnectPool::isUseful(redisContext*&)
bool RedisConnectPool::isUseful(redisContext* &redisConn)
{
	if (NULL == redisConn)
	{
		return false;
	}
    
	bool bPingRet = true;
	string command = "PING";
	redisReply *reply = (redisReply*)redisCommand(redisConn, command.c_str());
	if (reply == NULL && redisConn->err != 0)
	{
		bPingRet = false;
	}

	if (reply->type == REDIS_REPLY_STATUS)
	{
		string strRet = reply->str;
		if (strRet.find("PONG") != string::npos)
		{
			freeReplyObject(reply);
            reply = NULL;
		}
	}
    if(reply)
    {
	    freeReplyObject(reply);
        reply = NULL;
    }
	
	return bPingRet;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
cmpq $0x0, (%rsi)
je 0xbab8
movq %rsi, %r15
leaq 0x38(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x86ab(%rip), %rsi      # 0x140bc
leaq 0x86a8(%rip), %rdx      # 0x140c0
leaq 0x28(%rsp), %rbx
movq %rbx, %rdi
callq 0x42ba
movq (%r15), %rdi
movq (%rbx), %rsi
xorl %eax, %eax
callq 0xe1b0
movq %rax, %r14
movb $0x1, %bl
testq %rax, %rax
jne 0xba45
movq (%r15), %rax
cmpl $0x0, (%rax)
sete %bl
cmpl $0x5, (%r14)
jne 0xba9f
movq 0x18(%r14), %rsi
leaq 0x8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x3170
leaq 0x865c(%rip), %rsi      # 0x140c1
leaq 0x8(%rsp), %rdi
movl $0x4, %ecx
xorl %edx, %edx
callq 0x35a0
cmpq $-0x1, %rax
je 0xba87
movq %r14, %rdi
callq 0xbb00
xorl %r14d, %r14d
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xba9a
callq 0x3350
testq %r14, %r14
je 0xbaa7
movq %r14, %rdi
callq 0xbb00
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0xbaba
callq 0x3350
jmp 0xbaba
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbae5
callq 0x3350
jmp 0xbae5
jmp 0xbae2
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0xbaf4
callq 0x3350
movq %rbx, %rdi
callq 0x35b0
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/machine-connection.cc
// Function: OpenTCPSocket(char const*)
int OpenTCPSocket(const char *host) {
    char *host_copy = NULL;
    const char *port = "8888";
    const char *colon_pos;
    if ((colon_pos = strchr(host, ':')) != NULL) {
        port = colon_pos + 1;
        host_copy = strdup(host);
        host_copy[colon_pos - host] = '\0';
        host = host_copy;
    }
    struct addrinfo addr_hints = {};
    addr_hints.ai_family = AF_INET;
    addr_hints.ai_socktype = SOCK_STREAM;

    struct addrinfo *addr_result = NULL;
    int rc;
    if ((rc = getaddrinfo(host, port, &addr_hints, &addr_result)) != 0) {
        // We're in OpenTCPSocket(), because opening as a tty failed before,
        // so make reference of that in this error message.
        fprintf(stderr,
                "Not a tty and "
                "can't resolve as TCP endpoint '%s' (port %s): %s\n",
                host, port, gai_strerror(rc));
        free(host_copy);
        return -1;
    }
    free(host_copy);
    if (addr_result == NULL) return -1;
    int fd = socket(addr_result->ai_family, addr_result->ai_socktype,
                    addr_result->ai_protocol);
    if (fd >= 0 &&
        connect(fd, addr_result->ai_addr, addr_result->ai_addrlen) < 0) {
        perror("TCP connect()");
        close(fd);
        fd = -1;
    }

    freeaddrinfo(addr_result);
    return fd;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
movl $0x3a, %esi
callq 0x20e0
testq %rax, %rax
je 0x2f43
movq %rax, %r12
leaq 0x1(%rax), %r15
movq %rbx, %rdi
callq 0x2300
movq %rax, %r14
subq %rbx, %r12
movb $0x0, (%rax,%r12)
movq %rax, %rbx
jmp 0x2f4d
leaq 0x1a8b(%rip), %r15      # 0x49d5
xorl %r14d, %r14d
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdx
movaps %xmm0, (%rdx)
movaps %xmm0, 0x20(%rdx)
movaps %xmm0, 0x10(%rdx)
movabsq $0x100000002, %rax      # imm = 0x100000002
movq %rax, 0x4(%rdx)
leaq 0x8(%rsp), %rcx
movq $0x0, (%rcx)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x21f0
testl %eax, %eax
jne 0x2fd2
movq %r14, %rdi
callq 0x21d0
movq 0x8(%rsp), %rax
testq %rax, %rax
je 0x3005
movl 0x4(%rax), %edi
movl 0x8(%rax), %esi
movl 0xc(%rax), %edx
callq 0x2080
movl %eax, %ebx
testl %eax, %eax
js 0x2fc6
movq 0x8(%rsp), %rax
movq 0x18(%rax), %rsi
movl 0x10(%rax), %edx
movl %ebx, %edi
callq 0x2160
testl %eax, %eax
js 0x3018
movq 0x8(%rsp), %rdi
callq 0x2220
jmp 0x300a
movq 0x3fff(%rip), %rcx      # 0x6fd8
movq (%rcx), %r12
movl %eax, %edi
callq 0x2230
leaq 0x19f0(%rip), %rsi      # 0x49da
movq %r12, %rdi
movq %rbx, %rdx
movq %r15, %rcx
movq %rax, %r8
xorl %eax, %eax
callq 0x2270
movq %r14, %rdi
callq 0x21d0
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x19fb(%rip), %rdi      # 0x4a1a
callq 0x2170
movl %ebx, %edi
callq 0x2320
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x2fc6
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/machine-connection.cc
// Function: MachineConnection::DiscardPendingInput(int, _IO_FILE*)
int MachineConnection::DiscardPendingInput(int timeout_ms,
                                           FILE *echo_discarded) {
    if (input_fd_ < 0) return 0;
    int total_bytes = 0;
    char buf[128];
    while (AwaitReadReady(input_fd_, timeout_ms) > 0) {
        int r = read(input_fd_, buf, sizeof(buf));
        if (r < 0) {
            perror("reading trouble");
            return -1;
        }
        total_bytes += r;
        if (r > 0 && echo_discarded) {
            fwrite(buf, r, 1, echo_discarded);
        }
    }
    return total_bytes;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp            # imm = 0x118
movq %rdi, %r14
movl 0x4(%rdi), %edi
testl %edi, %edi
js 0x3580
movq %rdx, %rbx
movslq %esi, %rax
imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x26, %rcx
addl %edx, %ecx
movslq %ecx, %r13
imull $0x3e8, %r13d, %ecx     # imm = 0x3E8
subl %ecx, %eax
imull $0x3e8, %eax, %eax      # imm = 0x3E8
movslq %eax, %rbp
xorl %r15d, %r15d
xorps %xmm0, %xmm0
movaps %xmm0, 0x80(%rsp)
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x60(%rsp)
movaps %xmm0, 0x50(%rsp)
movaps %xmm0, 0x40(%rsp)
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
leal 0x3f(%rdi), %eax
testl %edi, %edi
cmovnsl %edi, %eax
movl %eax, %edx
andl $-0x40, %edx
movl %edi, %ecx
subl %edx, %ecx
movl $0x1, %edx
shlq %cl, %rdx
sarl $0x6, %eax
cltq
orq %rdx, 0x10(%rsp,%rax,8)
movq %r13, (%rsp)
movq %rbp, 0x8(%rsp)
incl %edi
leaq 0x10(%rsp), %rsi
xorl %edx, %edx
xorl %ecx, %ecx
movq %rsp, %r8
callq 0x2180
testl %eax, %eax
js 0x3583
movabsq $0x20c49ba5e353f7cf, %rax # imm = 0x20C49BA5E353F7CF
imulq 0x8(%rsp)
movq %rdx, %rax
shrq $0x3f, %rax
shrq $0x7, %rdx
addl %eax, %edx
testl %edx, %edx
jle 0x3583
movl 0x4(%r14), %edi
movl $0x80, %edx
leaq 0x90(%rsp), %rsi
callq 0x2280
movq %rax, %r12
testl %r12d, %r12d
js 0x3598
testq %rbx, %rbx
sete %al
testl %r12d, %r12d
sete %cl
orb %al, %cl
jne 0x3574
movl %r12d, %esi
andl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
movl $0x1, %edx
leaq 0x90(%rsp), %rdi
movq %rbx, %rcx
callq 0x2310
addl %r12d, %r15d
movl 0x4(%r14), %edi
jmp 0x3497
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x118, %rsp            # imm = 0x118
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1489(%rip), %rdi      # 0x4a28
callq 0x2170
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
jmp 0x3583
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/machine-connection.cc
// Function: MachineConnection::WriteBlocks(char*, std::vector<std::basic_string_view<char, std::char_traits<char>>, std::allocator<std::basic_string_view<char, std::char_traits<char>>>> const&)
bool MachineConnection::WriteBlocks(
    char *scratch_buffer, const std::vector<std::string_view> &blocks) {
    // Note: not using writev(), as snippets can be a lot and writev() has a
    // bunch of limitations (e.g. UIO_MAXIOV == 1024). Thus simply
    // reassmbling into buffer.
    char *pos = scratch_buffer;
    for (auto block : blocks) {
        memcpy(pos, block.data(), block.size());
        pos += block.size();
    }
    return reliable_write(output_fd_, scratch_buffer, pos - scratch_buffer);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r15
movq (%rdx), %r13
movq 0x8(%rdx), %rbp
movq %rsi, %r14
cmpq %rbp, %r13
je 0x35ee
movq %rbx, %r14
movq (%r13), %r12
movq 0x8(%r13), %rsi
movq %r14, %rdi
movq %r12, %rdx
callq 0x2150
addq %r12, %r14
addq $0x10, %r13
cmpq %rbp, %r13
jne 0x35cf
movl (%r15), %ebp
subl %ebx, %r14d
movl %r14d, %r15d
testl %r14d, %r14d
je 0x361e
movslq %r15d, %rdx
movl %ebp, %edi
movq %rbx, %rsi
callq 0x20c0
movl %r15d, %r14d
subl %eax, %r14d
movl %eax, %ecx
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
addq %rcx, %rbx
testl %eax, %eax
jns 0x35f4
testl %r15d, %r15d
sete %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/buffered-line-reader.cc
// Function: BufferedLineReader::Refill()
bool BufferedLineReader::Refill() {
    data_begin_ = buffer_;
    data_end_ = data_begin_;
    if (eof_) return false;
    if (!remainder_.empty()) {
        // get remainder to the beginning of the buffer.
        memmove(data_begin_, remainder_.data(), remainder_.size());
        data_end_ += remainder_.size();
    }
    const ssize_t r = read(fd_, data_end_, buffer_size_ - remainder_.size());
    if (r > 0) {
        data_end_ += r;
    } else {
        eof_ = true;
        if (r < 0) perror("Reading input");
        if (!remainder_.empty()) {
            // Close remainder with a newline
            *data_end_++ = '\n';
        }
    }
    remainder_ = {};
    return data_end_ > data_begin_;
}

// Assembly:
movq 0x10(%rdi), %rsi
movq %rsi, 0x20(%rdi)
movq %rsi, 0x28(%rdi)
cmpb $0x0, 0x19(%rdi)
je 0x392b
xorl %eax, %eax
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x30(%rdi), %rdx
testq %rdx, %rdx
je 0x395b
movq 0x38(%rbx), %rax
movq %rsi, %rdi
movq %rax, %rsi
callq 0x22c0
movq 0x30(%rbx), %rax
movq 0x28(%rbx), %rsi
addq %rax, %rsi
movq %rsi, 0x28(%rbx)
jmp 0x395d
xorl %eax, %eax
leaq 0x30(%rbx), %r14
movl (%rbx), %edi
movq 0x8(%rbx), %rdx
subq %rax, %rdx
callq 0x2280
testq %rax, %rax
jle 0x397e
addq 0x28(%rbx), %rax
movq %rax, 0x28(%rbx)
jmp 0x399e
movb $0x1, 0x19(%rbx)
js 0x39b4
cmpq $0x0, 0x30(%rbx)
movq 0x28(%rbx), %rax
je 0x399e
leaq 0x1(%rax), %rcx
movq %rcx, 0x28(%rbx)
movb $0xa, (%rax)
movq 0x28(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%r14)
cmpq 0x20(%rbx), %rax
seta %al
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x1173(%rip), %rdi      # 0x4b2e
callq 0x2170
jmp 0x3984
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/buffered-line-reader.cc
// Function: BufferedLineReader::ReadNextLines(unsigned long)
std::vector<std::string_view> BufferedLineReader::ReadNextLines(size_t n) {
    std::vector<std::string_view> result;
    result.reserve(n);
    if (data_begin_ >= data_end_ && !Refill()) {
        return result;
    }
    char *end_line;
    while ((end_line = std::find_if(data_begin_, data_end_, [](char c) {
                return c == '\n' || c == '\r';
            })) != data_end_) {
        auto line = MakeCommentFreeLine(data_begin_, end_line);
        if (!line.empty()) result.push_back(line);
        data_begin_ = end_line + 1;
        if (result.size() >= n) {
            return result;
        }
    }
    remainder_ = std::string_view(data_begin_, data_end_ - data_begin_);
    data_begin_ = data_end_;  // consume all.
    return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq %rdx, %rsi
callq 0x3ccc
movq 0x20(%r14), %rsi
cmpq 0x28(%r14), %rsi
jb 0x3a0c
movq %r14, %rdi
callq 0x3916
testb %al, %al
je 0x3b79
movq 0x20(%r14), %rsi
movq %rsp, %r12
movq 0x28(%r14), %rax
movq %rax, %rcx
subq %rsi, %rcx
movq %rcx, %rdi
sarq $0x2, %rdi
testq %rdi, %rdi
jle 0x3a9c
movq %rcx, %r13
andq $-0x4, %r13
addq %rsi, %r13
incq %rdi
leaq 0x3(%rsi), %rdx
movzbl -0x3(%rdx), %r8d
cmpl $0xa, %r8d
je 0x3af0
cmpl $0xd, %r8d
je 0x3af0
movzbl -0x2(%rdx), %r8d
cmpl $0xa, %r8d
je 0x3af6
cmpl $0xd, %r8d
je 0x3af6
movzbl -0x1(%rdx), %r8d
cmpl $0xa, %r8d
je 0x3afc
cmpl $0xd, %r8d
je 0x3afc
movzbl (%rdx), %r8d
cmpl $0xa, %r8d
je 0x3aff
cmpl $0xd, %r8d
je 0x3aff
decq %rdi
addq $0x4, %rdx
cmpq $0x1, %rdi
jg 0x3a36
jmp 0x3a9f
movq %rsi, %r13
movq %rax, %rdx
subq %r13, %rdx
cmpq $0x1, %rdx
je 0x3adf
cmpq $0x2, %rdx
je 0x3acd
cmpq $0x3, %rdx
jne 0x3b6d
movzbl (%r13), %edx
cmpl $0xa, %edx
je 0x3b02
cmpl $0xd, %edx
je 0x3b02
incq %r13
movzbl (%r13), %edx
cmpl $0xa, %edx
je 0x3b02
cmpl $0xd, %edx
je 0x3b02
incq %r13
movzbl (%r13), %edx
cmpl $0xa, %edx
je 0x3b02
cmpl $0xd, %edx
je 0x3b02
jmp 0x3b6d
addq $-0x3, %rdx
jmp 0x3aff
addq $-0x2, %rdx
jmp 0x3aff
decq %rdx
movq %rdx, %r13
cmpq %rax, %r13
je 0x3b6d
movq %r14, %rdi
movq %r13, %rdx
callq 0x3bac
movq %rax, (%rsp)
movq %rdx, 0x8(%rsp)
movq 0x8(%rbx), %rcx
testq %rax, %rax
je 0x3b51
cmpq 0x10(%rbx), %rcx
je 0x3b3f
movups (%rsp), %xmm0
movups %xmm0, (%rcx)
movq 0x8(%rbx), %rcx
addq $0x10, %rcx
movq %rcx, 0x8(%rbx)
jmp 0x3b51
movq %rbx, %rdi
movq %rcx, %rsi
movq %r12, %rdx
callq 0x3d90
movq 0x8(%rbx), %rcx
incq %r13
movq %r13, 0x20(%r14)
subq (%rbx), %rcx
sarq $0x4, %rcx
movq %r13, %rsi
cmpq %r15, %rcx
jb 0x3a0f
jmp 0x3b79
movq %rcx, 0x30(%r14)
movq %rsi, 0x38(%r14)
movq %rax, 0x20(%r14)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x3b8c
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x3ba3
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x21a0
movq %r14, %rdi
callq 0x22e0
nop
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/buffered-line-reader.cc
// Function: BufferedLineReader::MakeCommentFreeLine(char*, char*)
std::string_view BufferedLineReader::MakeCommentFreeLine(char *first,
                                                         char *last) {
    if (remove_comments_) {
        char *start_of_comment = (char *)memchr(first, ';', last - first + 1);
        if (start_of_comment) last = start_of_comment - 1;
    }
    while (first <= last && isspace(*first)) first++;
    while (last >= first && isspace(*last)) last--;  // also removing newline
    if (last < first) return {};
    *++last = '\n';  // Fresh newline behind resulting new last.
    return std::string_view(first, last - first + 1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %rbx
cmpb $0x1, 0x18(%rdi)
jne 0x3be1
movq %r14, %rdx
subq %rbx, %rdx
incq %rdx
movq %rbx, %rdi
movl $0x3b, %esi
callq 0x21b0
leaq -0x1(%rax), %rcx
testq %rax, %rax
cmovneq %rcx, %r14
cmpq %rbx, %r14
jb 0x3bfa
movsbl (%rbx), %edi
callq 0x2060
testl %eax, %eax
je 0x3bfa
incq %rbx
cmpq %r14, %rbx
jbe 0x3be6
xorl %r15d, %r15d
movq %r14, %rax
movl $0x0, %r12d
subq %rbx, %rax
jb 0x3c3a
addq $0x2, %rax
xorl %r12d, %r12d
movq %rax, %r15
movsbl (%r14), %edi
callq 0x2060
testl %eax, %eax
je 0x3c32
decq %r14
decq %r15
cmpq %rbx, %r14
jae 0x3c15
xorl %r15d, %r15d
jmp 0x3c3a
movb $0xa, 0x1(%r14)
movq %rbx, %r12
movq %r15, %rax
movq %r12, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/hzeller[P]gcode-cli/buffered-line-reader.cc
// Function: BufferedLineReader::ReadLine()
std::string_view BufferedLineReader::ReadLine() {
    while (!is_eof()) {
        auto lines = ReadNextLines(1);
        if (lines.empty()) continue;  // could happen at buffer switchover
        return lines[0];
    }
    return {};
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
xorl %ebx, %ebx
cmpb $0x0, 0x19(%rdi)
movl $0x0, %r15d
jne 0x3cbb
movq %rdi, %r14
leaq 0x8(%rsp), %r15
xorl %ebx, %ebx
movl $0x1, %edx
movq %r15, %rdi
movq %r14, %rsi
callq 0x39c2
movq 0x8(%rsp), %rdi
cmpq 0x10(%rsp), %rdi
jne 0x3ca7
testq %rdi, %rdi
je 0x3c9b
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x21a0
cmpb $0x1, 0x19(%r14)
jne 0x3c6d
xorl %r15d, %r15d
jmp 0x3cbb
movq (%rdi), %rbx
movq 0x8(%rdi), %r15
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x21a0
movq %rbx, %rax
movq %r15, %rdx
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::area()
double Polygon::area()
{
  double res=0;
  for(int i=0;i<size();++i)
    res+=(poly[i].second.x()-poly[i].first.x())*(poly[i].first.y()+poly[i].second.y());
  return fabs(res)/2.0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
subq %rax, %rcx
shrq $0x4, %rcx
testl %ecx, %ecx
jle 0x15cb
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
shlq $0x4, %rcx
xorpd %xmm0, %xmm0
xorl %edx, %edx
movss 0x8(%rax,%rdx), %xmm1
subss (%rax,%rdx), %xmm1
movss 0x4(%rax,%rdx), %xmm2
addss 0xc(%rax,%rdx), %xmm2
mulss %xmm1, %xmm2
xorps %xmm1, %xmm1
cvtss2sd %xmm2, %xmm1
addsd %xmm1, %xmm0
addq $0x10, %rdx
cmpq %rdx, %rcx
jne 0x159a
jmp 0x15cf
xorpd %xmm0, %xmm0
andpd 0x2a39(%rip), %xmm0     # 0x4010
mulsd 0x2a61(%rip), %xmm0     # 0x4040
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::diameter()
double Polygon::diameter()
{
  double res=0;
  for(int i=0;i<size();++i)
    res=MAXI(res,sqrt((poly[i].second.x() - poly[i].first.x())*(poly[i].second.x() - poly[i].first.x()) + (poly[i].second.y() - poly[i].first.y())*(poly[i].second.y() - poly[i].first.y())));

  return res;
}

// Assembly:
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
subq %rax, %rcx
shrq $0x4, %rcx
testl %ecx, %ecx
jle 0x1642
pushq %rbp
movq %rsp, %rbp
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
shlq $0x4, %rcx
xorpd %xmm0, %xmm0
xorl %edx, %edx
movss 0x8(%rax,%rdx), %xmm1
movss 0xc(%rax,%rdx), %xmm2
subss (%rax,%rdx), %xmm1
subss 0x4(%rax,%rdx), %xmm2
mulss %xmm2, %xmm2
mulss %xmm1, %xmm1
addss %xmm2, %xmm1
cvtss2sd %xmm1, %xmm1
sqrtsd %xmm1, %xmm1
maxsd %xmm1, %xmm0
addq $0x10, %rdx
cmpq %rdx, %rcx
jne 0x1608
popq %rbp
retq
xorps %xmm0, %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::width()
double Polygon::width()
{
  double res=100000000; // the power of infinity
  for(int i=0;i<size();++i)
    res=MINI(res,sqrt((poly[i].second.x() - poly[i].first.x())*(poly[i].second.x() - poly[i].first.x()) + (poly[i].second.y() - poly[i].first.y())*(poly[i].second.y() - poly[i].first.y())));
  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
subq %rax, %rcx
shrq $0x4, %rcx
testl %ecx, %ecx
jle 0x16aa
andl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
shlq $0x4, %rcx
movsd 0x29da(%rip), %xmm0     # 0x4048
xorl %edx, %edx
movss 0x8(%rax,%rdx), %xmm1
movss 0xc(%rax,%rdx), %xmm2
subss (%rax,%rdx), %xmm1
subss 0x4(%rax,%rdx), %xmm2
mulss %xmm2, %xmm2
mulss %xmm1, %xmm1
addss %xmm2, %xmm1
cvtss2sd %xmm1, %xmm1
sqrtsd %xmm1, %xmm1
minsd %xmm1, %xmm0
addq $0x10, %rdx
cmpq %rdx, %rcx
jne 0x1670
jmp 0x16b2
movsd 0x2996(%rip), %xmm0     # 0x4048
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::isClosed()
bool Polygon::isClosed()
{
  bool res=true;
  for(int i=0;i<size()-1;++i)
    res &= (poly[i].second == poly[i+1].first);
  res &= (poly[size()-1].second == poly[0].first);
  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rax
movq 0x8(%rdi), %rsi
subq %rax, %rsi
shrq $0x4, %rsi
leal -0x1(%rsi), %edx
movb $0x1, %cl
cmpl $0x2, %esi
jl 0x1705
movl %edx, %esi
leaq 0x14(%rax), %rdi
movss -0x8(%rdi), %xmm0
movss (%rdi), %xmm1
movss -0x4(%rdi), %xmm2
movss -0xc(%rdi), %xmm3
cmpeqps %xmm2, %xmm3
cmpeqps %xmm0, %xmm1
andps %xmm3, %xmm1
movd %xmm1, %r8d
andb %r8b, %cl
addq $0x10, %rdi
decq %rsi
jne 0x16d6
movslq %edx, %rdx
shlq $0x4, %rdx
movss 0xc(%rax,%rdx), %xmm0
movss 0x4(%rax), %xmm1
movss 0x8(%rax,%rdx), %xmm2
movss (%rax), %xmm3
cmpeqps %xmm2, %xmm3
cmpeqps %xmm0, %xmm1
andps %xmm3, %xmm1
movd %xmm1, %eax
andb %cl, %al
andb $0x1, %al
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::isAcceptable(double)
bool Polygon::isAcceptable(double x)
{
  //return (area()/perimeter() > x); // notgood
  bool res;
  double w=width();
  if(w==0)
    res=false;
  else
  {
    res = (diameter()/w < x);
//    if(res)
//      std::cerr << diameter()/w << std::endl;
  }
  return res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x18, %rsp
movsd %xmm0, -0x18(%rbp)
movq %rdi, %rbx
callq 0x1646
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x175c
jp 0x175c
xorl %eax, %eax
jmp 0x177a
movq %rbx, %rdi
movsd %xmm0, -0x10(%rbp)
callq 0x15e2
divsd -0x10(%rbp), %xmm0
movsd -0x18(%rbp), %xmm1
ucomisd %xmm0, %xmm1
seta %al
addq $0x18, %rsp
popq %rbx
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: Polygon::getBary()
Point Polygon::getBary()
{
  Point res(0,0);
  
  for(int i=0;i<size();++i)
  {
    res.x(res.x() + poly[i].first.x());
    res.y(res.y() + poly[i].first.y());
  }
  
  res.x(res.x()/size());
  res.y(res.y()/size());

  return res;
}

// Assembly:
movq %rdi, %rax
movq (%rsi), %rdx
movq 0x8(%rsi), %rcx
subq %rdx, %rcx
shrq $0x4, %rcx
testl %ecx, %ecx
jle 0x17c6
pushq %rbp
movq %rsp, %rbp
movl %ecx, %esi
andl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
shlq $0x4, %rsi
xorps %xmm1, %xmm1
xorl %edi, %edi
xorps %xmm0, %xmm0
addss (%rdx,%rdi), %xmm1
addss 0x4(%rdx,%rdi), %xmm0
addq $0x10, %rdi
cmpq %rdi, %rsi
jne 0x17af
popq %rbp
jmp 0x17cc
xorps %xmm0, %xmm0
xorps %xmm1, %xmm1
cvtsi2ss %ecx, %xmm2
divss %xmm2, %xmm1
movss %xmm1, (%rax)
divss %xmm2, %xmm0
movss %xmm0, 0x4(%rax)
retq
// File: /workspace/github_cpp_makefile_star2_O3/Hybryd[P]HyRoadGenerator/Polygon.cpp
// Function: operator<<(std::ostream&, Polygon&)
std::ostream & operator<<(std::ostream & out, Polygon & p)
{
  //gnuplotstyle
  for(int i=0;i<p.size();++i)
  {
    Point f=p[i].first;
    Point s=p[i].second;
    out << f << std::endl << s << std::endl << std::endl;
  }
  
  return out;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq (%rsi), %rax
movq 0x8(%rsi), %rcx
subq %rax, %rcx
shrq $0x4, %rcx
testl %ecx, %ecx
jle 0x1fa0
movq %rsi, %r14
movl $0xc, %r15d
xorl %r12d, %r12d
movq -0xc(%rax,%r15), %rcx
movq %rcx, -0x38(%rbp)
movq -0x4(%rax,%r15), %rax
movq %rax, -0x30(%rbp)
movq %rbx, %rdi
leaq -0x38(%rbp), %rsi
callq 0x137c
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x10e0
movsbl %al, %esi
movq %r13, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1090
movq %rax, %rdi
leaq -0x30(%rbp), %rsi
callq 0x137c
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x10e0
movsbl %al, %esi
movq %r13, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1090
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x10e0
movsbl %al, %esi
movq %r13, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1090
incq %r12
movq (%r14), %rax
movq 0x8(%r14), %rcx
subq %rax, %rcx
shrq $0x4, %rcx
movslq %ecx, %rcx
addq $0x10, %r15
cmpq %rcx, %r12
jl 0x1ed7
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/demo.new.cpp
// Function: main
int main()
{
	std::cout << std::unitbuf; // set no buffer for stdout
	test_constructors();
	test_json_node_values();
	test_assignments();
	test_append();
	test_parser();
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq 0xb829(%rip), %rax      # 0x13fd8
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
orl $0x2000, 0x18(%rax,%rcx) # imm = 0x2000
callq 0x26cc
callq 0x4273
callq 0x47d7
callq 0x5f57
callq 0x7f34
xorl %eax, %eax
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: int yll::json::as_number<int>() const
T as_number() const {
			assert(type_ == type::number);
			std::istringstream ss(text_);
			T v;
			ss >> v;
			return v;
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x188, %rsp            # imm = 0x188
cmpl $0x2, (%rdi)
jne 0x9048
movq %rdi, %rsi
addq $0x8, %rsi
leaq -0x190(%rbp), %rbx
movq %rbx, %rdi
movl $0x8, %edx
callq 0x2350
leaq -0xc(%rbp), %rsi
movq %rbx, %rdi
callq 0x2100
movl -0xc(%rbp), %ebx
movq 0xafac(%rip), %rsi      # 0x13fd0
leaq -0x190(%rbp), %rdi
callq 0x22c0
leaq -0x118(%rbp), %rdi
callq 0x20a0
movl %ebx, %eax
addq $0x188, %rsp            # imm = 0x188
popq %rbx
popq %rbp
retq
leaq 0x6bf1(%rip), %rdi      # 0xfc40
leaq 0x69e6(%rip), %rsi      # 0xfa3c
leaq 0x6bf9(%rip), %rcx      # 0xfc56
movl $0x45, %edx
callq 0x2130
movq %rax, %rbx
movq 0xaf5f(%rip), %rsi      # 0x13fd0
leaq -0x190(%rbp), %rdi
callq 0x22c0
leaq -0x118(%rbp), %rdi
callq 0x20a0
movq %rbx, %rdi
callq 0x2370
nop
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::parse(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long*, bool)
bool parse(const std::string& text, size_t* pos = nullptr, bool strict = true) {
			const char* p = text.c_str();
			if (!parse_value(p, *this, strict)) {
				if (pos) *pos = p - text.c_str();
				return false;
			}
			skip_spaces(p);
			if (pos) *pos = p - text.c_str();
			return (!*p);
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %rsi
movq (%r14), %rax
leaq -0x20(%rbp), %rdi
movq %rax, (%rdi)
movl %ecx, %edx
callq 0xd1ae
testb %al, %al
je 0x9da7
leaq -0x20(%rbp), %r15
movq %r15, %rdi
callq 0xd4d4
movq (%r15), %rax
testq %rbx, %rbx
je 0x9d9f
movq %rax, %rcx
subq (%r14), %rcx
movq %rcx, (%rbx)
cmpb $0x0, (%rax)
sete %al
jmp 0x9db8
testq %rbx, %rbx
je 0x9db6
movq -0x20(%rbp), %rax
subq (%r14), %rax
movq %rax, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::trim0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
static std::string trim0(std::string s) {
			if (s.find('.') != std::string::npos) {
				s.erase(s.find_last_not_of('0') + 1, std::string::npos);
				s.erase(s.find_last_not_of('.') + 1, std::string::npos);
			}
			return s;
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
movl $0x2e, %esi
xorl %edx, %edx
callq 0x22b0
cmpq $-0x1, %rax
je 0xb340
movq %r14, %rdi
movl $0x30, %esi
movq $-0x1, %rdx
callq 0x2160
incq %rax
movq 0x8(%r14), %rcx
cmpq %rax, %rcx
jb 0xb385
movq %rax, 0x8(%r14)
movq (%r14), %rcx
movb $0x0, (%rcx,%rax)
movq %r14, %rdi
movl $0x2e, %esi
movq $-0x1, %rdx
callq 0x2160
incq %rax
movq 0x8(%r14), %rcx
cmpq %rax, %rcx
jb 0xb385
movq %rax, 0x8(%r14)
movq (%r14), %rcx
movb $0x0, (%rcx,%rax)
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%r14), %rdx
leaq 0x10(%r14), %rax
cmpq %rax, %rdx
je 0xb35f
movq %rdx, (%rbx)
movq (%rax), %rcx
movq %rcx, 0x10(%rbx)
jmp 0xb365
movups (%rax), %xmm0
movups %xmm0, (%rcx)
movq 0x8(%r14), %rcx
movq %rcx, 0x8(%rbx)
movq %rax, (%r14)
movq $0x0, 0x8(%r14)
movb $0x0, 0x10(%r14)
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x4721(%rip), %rdi      # 0xfaad
leaq 0x4798(%rip), %rsi      # 0xfb2b
movq %rax, %rdx
xorl %eax, %eax
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::clear(yll::json::type, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void clear(type t = type::null, const std::string s = "") {
			type_ = t;
			text_ = s;
			array_.clear();
			object_.clear();
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl %esi, (%rdi)
addq $0x8, %rdi
movq %rdx, %rsi
callq 0x20f0
leaq 0x28(%rbx), %rdi
movq 0x28(%rbx), %rsi
callq 0xcb68
addq $0x40, %rbx
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0xcbca
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::skip_spaces(char const*&)
static void skip_spaces(const char*& s) {
			while (*s) {
				if (isspace(*s)) {
					++s;
				} else if (*s == '/' && *(s + 1) == '*') { // Skip comments
					s += 2;
					while (*s) {
						if (*s == '*' && *(s + 1) == '/') {
							s += 2;
							break;
						}
						++s;
					}
				} else {
					break;
				}
			}
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %r14
movb (%r14), %r15b
testb %r15b, %r15b
je 0xd53c
movq %rdi, %rbx
movsbl %r15b, %edi
callq 0x2050
testl %eax, %eax
je 0xd4fe
incq %r14
jmp 0xd531
cmpb $0x2f, %r15b
jne 0xd53c
cmpb $0x2a, 0x1(%r14)
jne 0xd53c
addq $0x2, %r14
movq %r14, (%rbx)
movzbl (%r14), %eax
cmpl $0x2a, %eax
je 0xd521
testl %eax, %eax
jne 0xd528
jmp 0xd53c
cmpb $0x2f, 0x1(%r14)
je 0xd52d
incq %r14
jmp 0xd50f
addq $0x2, %r14
movq %r14, (%rbx)
movb (%r14), %r15b
testb %r15b, %r15b
jne 0xd4ec
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::parse_number(char const*&, yll::json&)
static bool parse_number(const char*& s, json& v) {
			const char* s0 = s;
			skip_spaces(s);
			if (*s == '-' || *s == '+') ++s;
			if (!isdigit(*s) && *s != '.') return false; else ++s;
			while (isdigit(*s)) ++s;
			if (*s == '.') {
				++s;
				while (isdigit(*s)) ++s;
			}
			if (*s == 'e' || *s == 'E') {
				++s;
				if (*s == '+' || *s == '-') ++s;
				if (!isdigit(*s)) return false; else ++s;
				while (isdigit(*s)) ++s;
			}
			v.clear(type::number, std::string(s0, s));
			return true;
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rsi, %rbx
movq %rdi, %r15
movq (%rdi), %r14
callq 0xd4d4
movq (%r15), %rdx
movzbl (%rdx), %eax
cmpl $0x2d, %eax
je 0xd88f
cmpl $0x2b, %eax
jne 0xd89c
leaq 0x1(%rdx), %rcx
movq %rcx, (%r15)
movb 0x1(%rdx), %al
movq %rcx, %rdx
cmpb $0x2e, %al
je 0xd8af
movsbl %al, %eax
addl $-0x30, %eax
cmpl $0x9, %eax
ja 0xd96b
incq %rdx
movq %rdx, (%r15)
movsbl (%rdx), %eax
leal -0x30(%rax), %ecx
incq %rdx
cmpl $0xa, %ecx
jb 0xd8b2
cmpb $0x2e, %al
jne 0xd8d8
movq %rdx, (%r15)
movsbl (%rdx), %eax
leal -0x30(%rax), %ecx
incq %rdx
cmpl $0xa, %ecx
jb 0xd8c7
decq %rdx
movzbl %al, %eax
orl $0x20, %eax
cmpl $0x65, %eax
jne 0xd92a
leaq 0x1(%rdx), %rax
movq %rax, (%r15)
movzbl 0x1(%rdx), %ecx
cmpl $0x2d, %ecx
je 0xd8fb
cmpl $0x2b, %ecx
jne 0xd905
leaq 0x2(%rdx), %rax
movq %rax, (%r15)
movb 0x2(%rdx), %cl
movsbl %cl, %ecx
addl $-0x30, %ecx
cmpl $0x9, %ecx
ja 0xd96b
incq %rax
movq %rax, (%r15)
movsbl (%rax), %ecx
addl $-0x30, %ecx
incq %rax
cmpl $0xa, %ecx
jb 0xd913
decq %rax
movq %rax, %rdx
leaq -0x30(%rbp), %r12
movq %r12, -0x10(%r12)
leaq -0x40(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0xdf96
movq %rbx, %rdi
movl $0x2, %esi
movq %r15, %rdx
callq 0xcab2
movq -0x40(%rbp), %rdi
movb $0x1, %bl
cmpq %r12, %rdi
je 0xd96d
movq -0x30(%rbp), %rsi
incq %rsi
callq 0x2220
jmp 0xd96d
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x40(%rbp), %rdi
cmpq %r12, %rdi
je 0xd994
movq -0x30(%rbp), %rsi
incq %rsi
callq 0x2220
movq %rbx, %rdi
callq 0x2370
// File: /workspace/github_cpp_makefile_star2_O3/yanlinlin82[P]jsonxx/./json.hpp
// Function: yll::json::parse_array(char const*&, yll::json&, bool)
static bool parse_array(const char*& s, json& v, bool strict) {
			skip_spaces(s);
			if (*s != '[') return false; else ++s;
			skip_spaces(s);
			v.clear(type::array);
			if (*s != ']') {
				for (;;) {
					if (!strict) {
						skip_spaces(s);
						if (*s == ',') {
							++s;
							continue;
						} else if (*s == ']') {
							break;
						}
					}
					json o;
					if (!parse_value(s, o, strict)) return false;
					skip_spaces(s);
					v.append(o);
					if (*s == ']') break;
					if (*s == '}') return false;
					if (*s == ',') {
						++s;
					} else {
						if (strict) return false;
					}
				}
			}
			++s;
			return true;
		}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movl %edx, %r14d
movq %rsi, %r13
movq %rdi, %rbx
callq 0xd4d4
movq (%rbx), %rax
cmpb $0x5b, (%rax)
jne 0xdf43
incq %rax
movq %rax, (%rbx)
movq %rbx, %rdi
callq 0xd4d4
leaq -0x48(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x1e6f(%rip), %rdx      # 0xfc3f
leaq -0x58(%rbp), %r15
movq %r15, %rdi
movq %rdx, %rsi
callq 0xdf96
movq %r13, %rdi
movl $0x4, %esi
movq %r15, %rdx
callq 0xcab2
movq -0x58(%rbp), %rdi
cmpq %r12, %rdi
je 0xde04
movq -0x48(%rbp), %rsi
incq %rsi
callq 0x2220
movq (%rbx), %rax
cmpb $0x5d, (%rax)
je 0xdf4a
movq %r13, -0x38(%rbp)
leaq -0xa0(%rbp), %r12
xorl %r15d, %r15d
movzbl %r14b, %eax
movl %eax, -0x2c(%rbp)
testb %r14b, %r14b
jne 0xde4a
movq %rbx, %rdi
callq 0xd4d4
movq (%rbx), %rax
movzbl (%rax), %ecx
cmpl $0x2c, %ecx
je 0xdee2
cmpl $0x5d, %ecx
je 0xdf4a
movl %r15d, -0xc8(%rbp)
leaq -0xb0(%rbp), %rax
movq %rax, -0xc0(%rbp)
movq %r15, -0xb8(%rbp)
movb $0x0, -0xb0(%rbp)
movq %r15, 0x10(%r12)
xorps %xmm0, %xmm0
movups %xmm0, (%r12)
movl %r15d, -0x80(%rbp)
movq %r15, -0x78(%rbp)
leaq -0x80(%rbp), %rax
movq %rax, -0x70(%rbp)
movq %rax, -0x68(%rbp)
movq %r15, -0x60(%rbp)
movq %rbx, %rdi
leaq -0xc8(%rbp), %rsi
movl -0x2c(%rbp), %edx
callq 0xd1ae
movl $0x1, %r13d
testb %al, %al
je 0xdefe
movq %rbx, %rdi
callq 0xd4d4
movq -0x38(%rbp), %rdi
leaq -0xc8(%rbp), %rsi
callq 0x919e
movq (%rbx), %rcx
movzbl (%rcx), %eax
cmpl $0x2c, %eax
je 0xdef5
cmpl $0x5d, %eax
je 0xdeed
cmpl $0x7d, %eax
je 0xdefe
testb %r14b, %r14b
je 0xdefb
jmp 0xdefe
incq %rax
movq %rax, (%rbx)
jmp 0xde25
movl $0x2, %r13d
jmp 0xdefe
incq %rcx
movq %rcx, (%rbx)
xorl %r13d, %r13d
leaq -0x88(%rbp), %rdi
callq 0xb8d2
movq %r12, %rdi
callq 0xabb6
movq -0xc0(%rbp), %rdi
leaq -0xb0(%rbp), %rax
cmpq %rax, %rdi
je 0xdf34
movq -0xb0(%rbp), %rsi
incq %rsi
callq 0x2220
testl %r13d, %r13d
je 0xde25
cmpl $0x1, %r13d
jne 0xdf47
xorl %eax, %eax
jmp 0xdf52
movq (%rbx), %rax
incq %rax
movq %rax, (%rbx)
movb $0x1, %al
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x58(%rbp), %rdi
cmpq %r12, %rdi
je 0xdf8d
movq -0x48(%rbp), %rsi
incq %rsi
callq 0x2220
jmp 0xdf8d
movq %rax, %rbx
leaq -0xc8(%rbp), %rdi
callq 0x8fa2
movq %rbx, %rdi
callq 0x2370
nop
// File: /workspace/github_cpp_makefile_star2_O3/ambersun1234[P]AVL_Tree/./src/unit_test.cpp
// Function: avlTest_left_rotation_Test::TestBody()
TEST_F( avlTest , left_rotation ) {
	avl_tree_int.insertHelper( 66 );
	avl_tree_int.insertHelper( 76 );
	avl_tree_int.insertHelper( 86 );

	oss_level.str( string() );
	avl_tree_int.levelorderTraversalHelper( display );
	assert( oss_level && oss_level.str() == "   76,2   66,1   86,1" );
	oss_level.str( string() );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r14
leaq 0x10(%rdi), %rbx
movq 0x10(%rdi), %r15
movl $0x20, %edi
callq 0x7450
movl $0x42, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movl $0x1, %ebp
movl %ebp, 0x18(%rax)
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xd7aa
movq %rax, %r15
movq %rax, 0x10(%r14)
movl $0x20, %edi
callq 0x7450
movl $0x4c, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movl %ebp, 0x18(%rax)
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xd7aa
movq %rax, %r15
movq %rax, 0x10(%r14)
movl $0x20, %edi
callq 0x7450
movl $0x56, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movl %ebp, 0x18(%rax)
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xd7aa
movq %rax, 0x10(%r14)
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq $0x0, -0x8(%r14)
movb $0x0, (%r14)
leaq 0x3e108(%rip), %rdi     # 0x49578
leaq 0x8(%rsp), %rsi
callq 0x77f0
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0xb491
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x7480
movq (%rbx), %rsi
leaq 0x819(%rip), %rdx       # 0xbcb4
movq %rbx, %rdi
callq 0xdc52
leaq 0x3e0c6(%rip), %rax     # 0x49570
movq 0x3e0bf(%rip), %rcx     # 0x49570
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rcx,%rax)
jne 0xb540
leaq 0x3e0b1(%rip), %rsi     # 0x49578
leaq 0x8(%rsp), %rbx
movq %rbx, %rdi
callq 0x7880
leaq 0x28ed3(%rip), %rsi     # 0x343ae
movq %rbx, %rdi
callq 0x7140
testl %eax, %eax
jne 0xb540
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0xb4fe
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x7480
leaq 0x8(%rsp), %rsi
movq %r14, (%rsi)
movq $0x0, 0x8(%rsi)
movb $0x0, 0x10(%rsi)
leaq 0x3e05f(%rip), %rdi     # 0x49578
callq 0x77f0
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0xb535
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x7480
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x28e7d(%rip), %rdi     # 0x343c4
leaq 0x28ae3(%rip), %rsi     # 0x34031
leaq 0x28ea7(%rip), %rcx     # 0x343fc
movl $0xae, %edx
callq 0x72e0
jmp 0xb561
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0xb57b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x7480
movq %rbx, %rdi
callq 0x7960
nop