LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/prettyprint.hpp
// Function: std::ostream& std::operator<<<std::vector<int, std::allocator<int>>>(std::ostream&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)
ostream& operator<<(ostream& os, const std::vector<T>& v) {
        os << "[";
        if(!v.empty()) {
            os << v[0];
        }
        for(int i=1; i < int(v.size()); ++i) {
            os << ", " << v[i];
        }
        os << "]";
        return os;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8c33(%rip), %rsi      # 0xc54e
movl $0x1, %edx
callq 0x21a0
movq (%r14), %rsi
cmpq 0x8(%r14), %rsi
je 0x393f
movq %rbx, %rdi
callq 0x39c5
movq (%r14), %rsi
movq 0x8(%r14), %rax
jmp 0x3942
movq %rsi, %rax
subq %rsi, %rax
shrq $0x3, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cmpl $0x2, %eax
jl 0x39a4
movl $0x1, %r12d
movl $0x18, %r13d
leaq 0x8800(%rip), %r15      # 0xc167
movl $0x2, %edx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x21a0
movq (%r14), %rsi
addq %r13, %rsi
movq %rbx, %rdi
callq 0x39c5
incq %r12
movq 0x8(%r14), %rax
subq (%r14), %rax
shrq $0x3, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
cltq
addq $0x18, %r13
cmpq %rax, %r12
jl 0x3967
leaq 0x8acd(%rip), %rsi      # 0xc478
movl $0x1, %edx
movq %rbx, %rdi
callq 0x21a0
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/network_grow.cpp
// Function: Network::hgrow(GraphGen&, int)
void Network::hgrow(GraphGen& graph_gen, int seed) {
    rng_t rng(seed);
    ivec leaves(depthwise.back().begin(), depthwise.back().end());
    for(int u: leaves) {
        if(!is_virtual(u)) {
            expand_node(u, graph_gen, rng());
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %edx, %ebp
movq %rsi, %rbx
movq %rdi, %r14
movq 0xb0(%rdi), %rax
movq -0x18(%rax), %rsi
movq -0x10(%rax), %rdx
leaq 0x10(%rsp), %r12
leaq 0xf(%rsp), %rcx
movq %r12, %rdi
callq 0x576a
movq (%r12), %r15
movq 0x8(%r12), %r13
cmpq %r13, %r15
je 0x4e02
movslq %ebp, %rcx
movabsq $0x200000005, %rbp      # imm = 0x200000005
movq %rcx, %rax
mulq %rbp
movq %rcx, %r12
subq %rdx, %r12
shrq %r12
addq %rdx, %r12
shrq $0x1e, %r12
movq %r12, %rax
shlq $0x1f, %rax
subq %rax, %r12
leaq (%rcx,%r12), %rax
cmpq $0x1, %rax
adcq %rcx, %r12
movslq (%r15), %rsi
movq 0x18(%r14), %rax
cmpl $0x0, (%rax,%rsi,4)
jg 0x4df4
imulq $0xbc8f, %r12, %rcx     # imm = 0xBC8F
movq %rcx, %rax
mulq %rbp
movq %rcx, %r12
subq %rdx, %r12
shrq %r12
addq %rdx, %r12
shrq $0x1e, %r12
movq %r12, %rax
shlq $0x1f, %rax
subq %rax, %r12
addq %rcx, %r12
movq %r14, %rdi
movq %rbx, %rdx
movl %r12d, %ecx
callq 0x4798
addq $0x4, %r15
cmpq %r13, %r15
jne 0x4daf
movq 0x10(%rsp), %r15
testq %r15, %r15
je 0x4e0f
movq %r15, %rdi
callq 0x2150
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x4e30
callq 0x2150
movq %rbx, %rdi
callq 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/network.hpp
// Function: Network::reserve(int)
void reserve(int n) {
        nid.reserve(n);
        netsize.reserve(n);
        depth.reserve(n);
        in_nbrs.reserve(n);
        side_nbrs.reserve(n);
        up_nbrs.reserve(n);
        down_nbrs.reserve(n);
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movslq %esi, %rbx
movq %rbx, %rsi
callq 0x57a4
leaq 0x18(%r14), %rdi
movq %rbx, %rsi
callq 0x57a4
leaq 0x30(%r14), %rdi
movq %rbx, %rsi
callq 0x57a4
leaq 0x48(%r14), %rdi
movq %rbx, %rsi
callq 0x5bde
leaq 0x60(%r14), %rdi
movq %rbx, %rsi
callq 0x5bde
leaq 0x78(%r14), %rdi
movq %rbx, %rsi
callq 0x5bde
addq $0x90, %r14
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x5bde
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/sample.hpp
// Function: weighed_sample(std::vector<int, std::allocator<int>> const&, std::vector<int, std::allocator<int>> const&, std::linear_congruential_engine<unsigned long, 48271ul, 0ul, 2147483647ul>&)
inline int weighed_sample(const ivec& v, const ivec& weights, rng_t& rng) {
    if(weights.size() != v.size()) {
        fprintf(stderr, "weighed_sample: container and weights have different sizes\n");
    }
    if(weights.empty()) {
        fprintf(stderr, "weighed_sample: nothing_to_sample\n");
    }
    ivec cum_weights(1, 0);
    cum_weights.reserve(v.size()+1);
    for(auto weight: weights) {
        cum_weights.push_back(weight + cum_weights.back());
    }

    int i = iunidist(0, cum_weights.back() - 1, rng);
    int j = std::upper_bound(cum_weights.begin(), cum_weights.end(), i) - cum_weights.begin() - 1;
    return v[j];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq (%rsi), %rax
movq 0x8(%rsi), %rcx
movq %rcx, %rdx
subq %rax, %rdx
movq 0x8(%rdi), %rsi
subq (%rdi), %rsi
cmpq %rsi, %rdx
jne 0x5a01
cmpq %rcx, %rax
je 0x5a2d
movl $0x4, %edi
callq 0x2170
leaq 0x8(%rsp), %rdi
movq %rax, (%rdi)
leaq 0x4(%rax), %rcx
movq %rcx, 0x10(%rdi)
movl $0x0, (%rax)
movq %rcx, 0x8(%rdi)
movq 0x8(%rbx), %rsi
subq (%rbx), %rsi
sarq $0x2, %rsi
incq %rsi
callq 0x57a4
movq (%r15), %r13
movq 0x8(%r15), %rbp
cmpq %rbp, %r13
je 0x595f
leaq 0x8(%rsp), %r15
leaq 0x20(%rsp), %r12
movl (%r13), %eax
movq 0x10(%rsp), %rsi
addl -0x4(%rsi), %eax
movl %eax, 0x20(%rsp)
cmpq 0x18(%rsp), %rsi
je 0x594b
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x10(%rsp)
jmp 0x5956
movq %r15, %rdi
movq %r12, %rdx
callq 0x3e5c
addq $0x4, %r13
cmpq %rbp, %r13
jne 0x5927
movq 0x10(%rsp), %rax
movl -0x4(%rax), %eax
decl %eax
leaq 0x20(%rsp), %rdi
movl $0x0, (%rdi)
movl %eax, 0x4(%rdi)
movq %r14, %rsi
movq %rdi, %rdx
callq 0x5a56
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rdx
subq %rdi, %rdx
sarq $0x2, %rdx
movq %rdi, %rcx
testq %rdx, %rdx
jle 0x59c8
movq %rcx, %rsi
movq %rdx, %r8
shrq %r8
movq %r8, %r9
notq %r9
addq %rdx, %r9
leaq (%rcx,%r8,4), %rcx
addq $0x4, %rcx
cmpl -0x4(%rcx), %eax
cmovlq %rsi, %rcx
cmovlq %r8, %r9
movq %r9, %rdx
testq %r9, %r9
jg 0x599b
subq %rdi, %rcx
shlq $0x1e, %rcx
movabsq $-0x100000000, %rax     # imm = 0xFFFFFFFF00000000
addq %rcx, %rax
movq (%rbx), %rcx
sarq $0x1e, %rax
movl (%rcx,%rax), %ebx
testq %rdi, %rdi
je 0x59f0
callq 0x2150
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0xb5c8(%rip), %rax      # 0x10fd0
movq (%rax), %rcx
leaq 0x6b6f(%rip), %rdi      # 0xc581
movl $0x3b, %esi
movl $0x1, %edx
callq 0x2240
movq (%r15), %rax
movq 0x8(%r15), %rcx
jmp 0x58d1
callq 0x2312
jmp 0x58da
jmp 0x5a3b
jmp 0x5a3b
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x5a4d
callq 0x2150
movq %rbx, %rdi
callq 0x2220
nop
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/graph_gen.cpp
// Function: make_cycle_graph(int, std::vector<std::pair<int, int>, std::allocator<std::pair<int, int>>>&)
void make_cycle_graph(int n, ipvec& l) {
    // iipair st_graph[] = {{0, 1}, {1, 2}, {2, 3}, {3, 0}, {3, 4}, {0, 5}};
    l.emplace_back(n-1, 0);
    for(int i=1; i<n; ++i) {
        l.emplace_back(i-1, i);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %r14d
leal -0x1(%r14), %eax
movq %rsp, %r15
movl %eax, (%r15)
leaq 0x4(%rsp), %rdx
movl $0x0, (%rdx)
movq %rsi, %rdi
movq %r15, %rsi
callq 0x66f4
movl $0x1, (%r15)
cmpl $0x2, %r14d
jl 0x60f1
xorl %eax, %eax
leaq 0x4(%rsp), %r15
movq %rsp, %r12
movl %eax, 0x4(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x671a
movl (%rsp), %eax
leal 0x1(%rax), %ecx
movl %ecx, (%rsp)
cmpl %r14d, %ecx
jl 0x60d1
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/dsu.hpp
// Function: DisjointSets::find(int)
int find(int x) {
        if(parent[x] == x) {
            return x;
        }
        else {
            int p = find(parent[x]);
            parent[x] = p;
            return p;
        }
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %eax
movslq %esi, %r14
movq 0x20(%rdi), %rcx
movl (%rcx,%r14,4), %esi
cmpl %r14d, %esi
je 0x6ad2
movq %rdi, %rbx
callq 0x6aac
movq 0x20(%rbx), %rcx
movl %eax, (%rcx,%r14,4)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/dsu.hpp
// Function: DisjointSets::unite(int, int)
void unite(int x, int y) {
        x = find(x);
        y = find(y);
        if(subsize[x] > subsize[y]) {
            std::swap(x, y);
        }
        parent[x] = y;
        subsize[y] += subsize[x];
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movq %rdi, %r14
callq 0x6aac
movl %eax, %ebp
movq %r14, %rdi
movl %ebx, %esi
callq 0x6aac
movslq %ebp, %rcx
movq 0x8(%r14), %rdx
movl (%rdx,%rcx,4), %esi
cltq
cmpl (%rdx,%rax,4), %esi
movl %ecx, %esi
cmovgl %eax, %esi
cmovgl %ecx, %eax
movq 0x20(%r14), %rcx
movslq %esi, %rsi
movl %eax, (%rcx,%rsi,4)
movl (%rdx,%rsi,4), %ecx
cltq
addl %ecx, (%rdx,%rax,4)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/dsu.hpp
// Function: DisjointSets::init(int)
void init(int _n) {
        n = _n;
        subsize.resize(n);
        parent.resize(n);
        for(int i=0; i<n; ++i) {
            parent[i] = i;
            subsize[i] = 1;
        }
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl %esi, (%rdi)
leaq 0x8(%rdi), %r14
movslq %esi, %rsi
movq %r14, %rdi
callq 0x6b96
leaq 0x20(%rbx), %r15
movslq (%rbx), %rsi
movq %r15, %rdi
callq 0x6b96
cmpl $0x0, (%rbx)
jle 0x6b90
movq (%r15), %rax
movq (%r14), %rcx
xorl %edx, %edx
movl %edx, (%rax,%rdx,4)
movl $0x1, (%rcx,%rdx,4)
incq %rdx
movslq (%rbx), %rsi
cmpq %rsi, %rdx
jl 0x6b7b
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/attack.cpp
// Function: normalize_edge_weights(int&, int&)
void normalize_edge_weights(int& in_weight, int& side_weight) {
    if(in_weight < 0) {
        fprintf(stderr, "in_weight = %d\n", in_weight);
    }
    if(side_weight < 0) {
        fprintf(stderr, "side_weight = %d\n", side_weight);
    }
    if(in_weight == 0) {
        if(side_weight == 0) {
            in_weight = side_weight = 1;
        }
        else {
            in_weight = 1;
            side_weight = -1;
        }
    }
    else if(side_weight == 0) {
        side_weight = 1;
        in_weight = -1;
    }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl (%rdi), %edx
testl %edx, %edx
js 0x79d3
movl (%r14), %edx
testl %edx, %edx
js 0x79ed
cmpl $0x0, (%rbx)
movl (%r14), %eax
je 0x79ae
testl %eax, %eax
jne 0x79cb
movl $0x1, (%r14)
movl $0xffffffff, (%rbx)     # imm = 0xFFFFFFFF
jmp 0x79cb
testl %eax, %eax
je 0x79c1
movl $0x1, (%rbx)
movl $0xffffffff, (%r14)     # imm = 0xFFFFFFFF
jmp 0x79cb
movl $0x1, %eax
movl %eax, (%r14)
movl %eax, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq 0x95f6(%rip), %rax      # 0x10fd0
movq (%rax), %rdi
leaq 0x4c5c(%rip), %rsi      # 0xc640
xorl %eax, %eax
callq 0x21b0
jmp 0x798c
movq 0x95dc(%rip), %rax      # 0x10fd0
movq (%rax), %rdi
leaq 0x4c52(%rip), %rsi      # 0xc650
xorl %eax, %eax
callq 0x21b0
jmp 0x7993
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/place_victims.cpp
// Function: place_victims_randomly(Network const&, int, std::vector<int, std::allocator<int>>&, int)
void place_victims_randomly(const Network& network, int n, ivec& victims, int seed) {
    victims.reserve(network.depthwise.back().size());
    for(int u: network.depthwise.back()) {
        if(network.netsize[u] == 0) {
            victims.push_back(u);
        }
    }
    n = std::min<int>(n, victims.size());
    std::shuffle(victims.begin(), victims.end(), rng_t(seed));
    victims.resize(n);
    victims.shrink_to_fit();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, 0x8(%rsp)
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r15
movq 0xb0(%rdi), %rax
movq -0x10(%rax), %rsi
subq -0x18(%rax), %rsi
sarq $0x2, %rsi
movq %rdx, %rdi
callq 0x57a4
movq 0xb0(%r15), %rax
movq -0x18(%rax), %r13
movq -0x10(%rax), %r14
cmpq %r14, %r13
je 0x8dd6
leaq 0xc(%rsp), %r12
movslq (%r13), %rax
movl %eax, 0xc(%rsp)
movq 0x18(%r15), %rcx
cmpl $0x0, (%rcx,%rax,4)
jne 0x8dcd
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0x8dc2
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0x8dcd
movq %rbx, %rdi
movq %r12, %rdx
callq 0x3d28
addq $0x4, %r13
cmpq %r14, %r13
jne 0x8d9a
movq (%rbx), %rdi
movq 0x8(%rbx), %rsi
movq %rsi, %rax
subq %rdi, %rax
shrq $0x2, %rax
cmpl %ebp, %eax
cmovll %eax, %ebp
movslq 0x8(%rsp), %rcx
movabsq $0x200000005, %rdx      # imm = 0x200000005
movq %rcx, %rax
mulq %rdx
movq %rcx, %rax
subq %rdx, %rax
shrq %rax
addq %rdx, %rax
shrq $0x1e, %rax
movq %rax, %rdx
shlq $0x1f, %rdx
subq %rdx, %rax
leaq (%rcx,%rax), %rdx
cmpq $0x1, %rdx
adcq %rcx, %rax
leaq 0x10(%rsp), %rdx
movq %rax, (%rdx)
callq 0xa1dc
movslq %ebp, %rsi
movq %rbx, %rdi
callq 0x6b96
movq 0x10(%rbx), %rax
cmpq 0x8(%rbx), %rax
je 0x8e50
movq %rbx, %rdi
callq 0xaa08
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/place_victims.cpp
// Function: make_network_dag(Network const&, Graph&)
void make_network_dag(const Network& network, Graph& graph2) {
    Graph graph(network.size());
    for(int d=network.height(); d>=0; --d) {
        for(int v: network.depthwise[d]) {
            int u = network.nid[v];
            if(u < 0 || network.depth[u] != d) {
                if(d > 0) {
                    for(int u: network.up_nbrs[v]) {
                        graph.add_edge(u, v);
                    }
                }
            }
            else {
                graph.add_edge(u, v);
            }
        }
    }
    graph2.swap(graph);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rsi, 0x8(%rsp)
movq %rdi, %r14
movq 0x20(%rdi), %rsi
subq 0x18(%rdi), %rsi
shrq $0x2, %rsi
leaq 0x20(%rsp), %rdi
callq 0xa34e
movq 0xb0(%r14), %rax
subq 0xa8(%r14), %rax
shrq $0x3, %rax
imull $0xaaaaaaab, %eax, %eax # imm = 0xAAAAAAAB
decl %eax
js 0x8f4c
movl %eax, %edx
leaq 0x20(%rsp), %r15
movq 0xa8(%r14), %rax
leaq (%rdx,%rdx,2), %rcx
movq (%rax,%rcx,8), %rbp
movq 0x8(%rax,%rcx,8), %rax
movq %rax, 0x18(%rsp)
cmpq %rax, %rbp
je 0x8f3c
movq %rdx, 0x10(%rsp)
movslq (%rbp), %r12
movq (%r14), %rax
movslq (%rax,%r12,4), %rsi
testq %rsi, %rsi
js 0x8efe
movq 0x30(%r14), %rax
movl (%rax,%rsi,4), %eax
cmpq %rax, %rdx
jne 0x8efe
movq %r15, %rdi
movl %r12d, %edx
callq 0xa3a4
jmp 0x8f2c
testq %rdx, %rdx
je 0x8f2c
movq 0x78(%r14), %rax
leaq (%r12,%r12,2), %rcx
movq (%rax,%rcx,8), %rbx
movq 0x8(%rax,%rcx,8), %r13
cmpq %r13, %rbx
je 0x8f2c
movl (%rbx), %esi
movq %r15, %rdi
movl %r12d, %edx
callq 0xa3a4
addq $0x4, %rbx
jmp 0x8f14
addq $0x4, %rbp
cmpq 0x18(%rsp), %rbp
movq 0x10(%rsp), %rdx
jne 0x8ed5
leaq -0x1(%rdx), %rax
testq %rdx, %rdx
movq %rax, %rdx
jg 0x8eb2
movq 0x8(%rsp), %rdx
movl (%rdx), %eax
leaq 0x28(%rsp), %r14
movl -0x8(%r14), %ecx
movl %ecx, (%rdx)
movl %eax, -0x8(%r14)
movups (%r14), %xmm0
movups 0x8(%rdx), %xmm1
movups %xmm0, 0x8(%rdx)
movups %xmm1, (%r14)
leaq 0x40(%rsp), %rdi
movups -0x8(%rdi), %xmm0
movups 0x8(%rdi), %xmm1
movups 0x18(%rdx), %xmm2
movups %xmm0, 0x18(%rdx)
movups %xmm2, -0x8(%rdi)
movups 0x28(%rdx), %xmm0
movups %xmm1, 0x28(%rdx)
movups %xmm0, 0x8(%rdi)
callq 0xa7ec
movq %r14, %rdi
callq 0xa7ec
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x8fb5
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0xa7ec
leaq 0x28(%rsp), %rdi
callq 0xa7ec
movq %rbx, %rdi
callq 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/lib/sample.cpp
// Function: multi_sample(std::vector<double, std::allocator<double>> const&, int, std::vector<int, std::allocator<int>>&, std::linear_congruential_engine<unsigned long, 48271ul, 0ul, 2147483647ul>&)
void multi_sample(const vector<double>& weights, int m, ivec& indices, rng_t& rng) {
    int n = weights.size();
    indices.clear();
    if(m >= n) {
        for(int i=0; i<n; ++i) {
            indices.push_back(i);
        }
        return;
    }

    std::uniform_real_distribution<double> rdist;
    indices.reserve(m);
    SegTree segtree(weights);
    for(int i=0; i<m; ++i) {
        int index = segtree.cumsum_search(segtree.get_root() * rdist(rng));
        indices.push_back(index);
        segtree.update(index, 0.0);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movq %rcx, %r14
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r15
movq 0x8(%rdi), %r12
subq (%rdi), %r12
shrq $0x3, %r12
movq (%rdx), %rax
cmpq %rax, 0x8(%rdx)
je 0xbb37
movq %rax, 0x8(%rbx)
cmpl %ebp, %r12d
jle 0xbc02
movslq %ebp, %rsi
movq %rbx, %rdi
callq 0x57a4
leaq 0x8(%rsp), %rdi
movq %r15, %rsi
callq 0xbc6e
testl %ebp, %ebp
jle 0xbbf1
leaq 0x8(%rsp), %r15
leaq 0x4(%rsp), %r12
movq 0x10(%rsp), %rax
movsd (%rax), %xmm0
movsd %xmm0, 0x28(%rsp)
movq %r14, %rdi
callq 0x5daa
addsd 0x937(%rip), %xmm0      # 0xc4c0
movsd 0x28(%rsp), %xmm1
mulsd %xmm0, %xmm1
movl 0x8(%rsp), %ecx
decl %ecx
movq %r15, %rdi
xorl %esi, %esi
xorl %edx, %edx
movapd %xmm1, %xmm0
callq 0xbaa6
movl %eax, 0x4(%rsp)
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0xbbc3
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0xbbce
movq %rbx, %rdi
movq %r12, %rdx
callq 0x3d28
movl 0x4(%rsp), %r8d
movl 0x8(%rsp), %ecx
decl %ecx
xorpd %xmm0, %xmm0
movq %r15, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xb9e8
decl %ebp
jne 0xbb6a
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xbc46
callq 0x2150
jmp 0xbc46
movl $0x0, 0x8(%rsp)
testl %r12d, %r12d
jle 0xbc46
xorl %eax, %eax
leaq 0x8(%rsp), %r14
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0xbc2c
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0xbc37
movq %rbx, %rdi
movq %r14, %rdx
callq 0x3d28
movl 0x8(%rsp), %eax
incl %eax
movl %eax, 0x8(%rsp)
cmpl %r12d, %eax
jl 0xbc16
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xbc65
callq 0x2150
movq %rbx, %rdi
callq 0x2220
nop
// File: /workspace/github_cpp_makefile_star2_O3/sharmaeklavya2[P]ddos-on-anycast/src/graph_gen.cpp
// Function: main
int main(int argc, char* argv[]) {
    char args_str[] = "n m seed";
    int n, m, seed=-1;
    if(argc <= 2 || argc >= 5) {
        fprintf(stderr, "usage: %s %s\n", argv[0], args_str);
        return 2;
    }
    else {
        n = atoi(argv[1]);
        m = atoi(argv[2]);
        if(argc == 4) {
            seed = atoi(argv[3]);
        }
    }
    if(seed == -1) {
        seed = int(time(nullptr));
    }

    ipvec l;

    make_random_connected_graph(n, m, l, seed);
    for(int i=0; i<n; ++i) {
        printf("%d\n", i);
    }

    for(const iipair& p: l) {
        int u = p.first, v = p.second;
        printf("%d %d\n", u, v);
    }
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movl %edi, %r15d
movabsq $0x64656573206d206e, %rax # imm = 0x64656573206D206E
movq %rax, (%rsp)
movb $0x0, 0x8(%rsp)
leal -0x5(%r15), %eax
cmpl $-0x3, %eax
jbe 0xbe53
movq 0x8(%r14), %rdi
callq 0x21e0
movl %eax, %ebx
movq 0x10(%r14), %rdi
callq 0x21e0
movl %eax, %ebp
cmpl $0x4, %r15d
jne 0xbdc2
movq 0x18(%r14), %rdi
callq 0x21e0
cmpl $-0x1, %eax
jne 0xbdc9
xorl %edi, %edi
callq 0x2140
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rdx
movaps %xmm0, (%rdx)
movq $0x0, 0x10(%rdx)
movl %ebx, %edi
movl %ebp, %esi
movl %eax, %ecx
callq 0x6161
testl %ebx, %ebx
jle 0xbe06
leaq 0x8e0(%rip), %r14       # 0xc6d2
xorl %ebp, %ebp
movq %r14, %rdi
movl %ebp, %esi
xorl %eax, %eax
callq 0x2040
incl %ebp
cmpl %ebp, %ebx
jne 0xbdf4
movq 0x10(%rsp), %rbx
movq 0x18(%rsp), %r15
cmpq %r15, %rbx
je 0xbe39
leaq 0x940(%rip), %r14       # 0xc75c
movl (%rbx), %esi
movl 0x4(%rbx), %edx
movq %r14, %rdi
xorl %eax, %eax
callq 0x2040
addq $0x8, %rbx
cmpq %r15, %rbx
jne 0xbe1c
movq 0x10(%rsp), %rbx
testq %rbx, %rbx
je 0xbe46
movq %rbx, %rdi
callq 0x2150
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x5176(%rip), %rax      # 0x10fd0
movq (%rax), %rdi
movq (%r14), %rdx
leaq 0x8e7(%rip), %rsi       # 0xc74e
movq %rsp, %rcx
xorl %eax, %eax
callq 0x21b0
movl $0x2, %eax
jmp 0xbe48
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xbe8a
callq 0x2150
movq %rbx, %rdi
callq 0x2220
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: utils::def_chainp::operator()()
char operator() () {
			if(unget_) {
				unget_ = false;
			} else {
				if(str_ == nullptr) {
					char ch;
					if(read(STDIN_FILENO, &ch, 1) == 1) {
						if(ch == '\n') ch = 0;
						last_ = ch;
					} else {
						last_ = 0;
					}
				} else {
					last_ = *str_;
					if(last_ != 0) { ++str_; }
				}
			}
			return last_;
		}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
cmpb $0x1, 0x9(%rdi)
jne 0xe16c
movb $0x0, 0x9(%rbx)
movb 0x8(%rbx), %al
jmp 0xe1b5
movq (%rbx), %rcx
testq %rcx, %rcx
je 0xe185
movb (%rcx), %al
movb %al, 0x8(%rbx)
testb %al, %al
je 0xe1b3
incq %rcx
movq %rcx, (%rbx)
jmp 0xe1b5
xorl %ebp, %ebp
leaq 0xf(%rsp), %r14
movl $0x1, %edx
xorl %edi, %edi
movq %r14, %rsi
callq 0x42a0
movq %rax, %rcx
movzbl (%r14), %eax
cmpb $0xa, %al
cmovel %ebp, %eax
cmpq $0x1, %rcx
cmovnel %ebp, %eax
movb %al, 0x8(%rbx)
jmp 0xe1b5
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: unsigned int utils::basic_input<utils::def_chainp>::nb_dec_<unsigned int>()
T nb_dec_() noexcept
		{
			typedef typename std::make_unsigned<T>::type U;
			typedef typename std::make_signed<T>::type S;

			auto nbc = nbc_;
			auto neg = neg_();
			if(nbc > 0 && nbc_ == 0) {
				error_ = error::not_integer;
				return 0;
			}

			auto sign = std::is_signed<T>::value;
			T v = 0;
			switch(mode_) {
			case mode::BIN:
				v = bin_<U>();
				break;
			case mode::OCT:
				v = oct_<U>();
				break;
			case mode::DEC:
				if(!sign) {
					if(neg) {  // 符号無しにマイナス符号を付けた場合
						error_ = error::sign_type;
						return 0;
					}
				}
				v = dec_<T>();
				break;
			case mode::HEX:
				v = hex_<U>();
				break;
			case mode::AUTO:
				v = auto_num_<T>();
				break;
			default:
				error_ = error::not_integer;
				break;
			}
			if(error_ == error::none) {
				if(nbc == 0) {
					inp_.unget();
				}
				next_();
			}
			if(neg) {
				return -static_cast<S>(v);
			} else {
				return static_cast<S>(v);
			}
		}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movb 0x1a(%rdi), %r15b
callq 0xe26c
movl %eax, %ebp
testb %r15b, %r15b
je 0xea93
cmpb $0x0, 0x1a(%rbx)
jne 0xea93
movb $0x4, 0x19(%rbx)
xorl %eax, %eax
jmp 0xeb19
movzbl 0x18(%rbx), %eax
addl $-0x2, %eax
cmpl $0x5, %eax
ja 0xeab9
leaq 0x1762(%rip), %rcx      # 0x10208
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq %rbx, %rdi
callq 0xe2a2
jmp 0xeaf3
movb $0x4, 0x19(%rbx)
xorl %r14d, %r14d
jmp 0xeaf6
testb %bpl, %bpl
je 0xeaeb
movb $0x5, 0x19(%rbx)
jmp 0xea8c
movq %rbx, %rdi
callq 0xe30e
jmp 0xeaf3
movq %rbx, %rdi
callq 0xe3e8
jmp 0xeaf3
movq %rbx, %rdi
callq 0xeb98
jmp 0xeaf3
movq %rbx, %rdi
callq 0xeb24
movl %eax, %r14d
cmpb $0x0, 0x19(%rbx)
jne 0xeb0d
testb %r15b, %r15b
jne 0xeb05
movb $0x1, 0x11(%rbx)
movq %rbx, %rdi
callq 0xdfe4
movl %r14d, %eax
negl %eax
testb %bpl, %bpl
cmovel %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: utils::basic_input<utils::def_chainp>::neg_()
bool neg_() noexcept {
			bool neg = false;
			auto s = inp_();
			if(s == '-') {
				neg = true;
				if(nbc_ > 0) nbc_--;
			} else if(s == '+') {
				neg = false;
				if(nbc_ > 0) nbc_--;
			} else {
				inp_.unget();
			}
			return neg;
		}

// Assembly:
pushq %rbx
movq %rdi, %rbx
addq $0x8, %rdi
callq 0xe152
cmpb $0x2d, %al
je 0xe281
cmpb $0x2b, %al
jne 0xe28f
movb 0x1a(%rbx), %cl
testb %cl, %cl
je 0xe293
decb %cl
movb %cl, 0x1a(%rbx)
jmp 0xe293
movb $0x1, 0x11(%rbx)
cmpb $0x2d, %al
sete %al
popq %rbx
retq
movq %rax, %rdi
callq 0x9baf
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: unsigned short utils::basic_input<utils::def_chainp>::bin_<unsigned short>()
T bin_() noexcept {
			T a = 0;
			constexpr auto lim = static_cast<T>(1) << (sizeof(T) * 8 - 1);
			char ch;
			while((ch = inp_()) != 0) {
				if(ch >= '0' && ch <= '1') {
					if((a & lim) != 0) {
						ovf_ = true;
					}
					if(!ovf_) {
						a <<= 1;
						a += ch - '0';
					}
				} else if(nbc_ != 0 && ch == ' ') {
					// 文字数指定がある場合「スペース」は '0' と同等に扱う
				} else {
					break;
				}
				if(nbc_ > 0) {
					nbc_--;
					if(nbc_ == 0) break;
				}
			}
			return a;
		}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
leaq 0x8(%rdi), %r15
xorl %ebx, %ebx
movq %r15, %rdi
callq 0xe152
testb %al, %al
je 0xf310
movl %eax, %ecx
andb $-0x2, %cl
cmpb $0x30, %cl
jne 0xf2ed
testw %bx, %bx
js 0xf2fb
testb $0x1, 0x1b(%r14)
jne 0xf300
addl %ebx, %ebx
addb $-0x30, %al
movzbl %al, %eax
orl %ebx, %eax
movl %eax, %ebx
jmp 0xf300
cmpb $0x20, %al
jne 0xf310
movb 0x1a(%r14), %al
testb %al, %al
jne 0xf308
jmp 0xf310
movb $0x1, 0x1b(%r14)
movb 0x1a(%r14), %al
testb %al, %al
je 0xf2be
decb %al
movb %al, 0x1a(%r14)
jne 0xf2be
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0x9baf
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: unsigned short utils::basic_input<utils::def_chainp>::oct_<unsigned short>()
T oct_() noexcept {
			T a = 0;
			constexpr auto lim = static_cast<T>(0b111) << (sizeof(T) * 8 - 4);
			char ch;
			while((ch = inp_()) != 0) {
				if(ch >= '0' && ch <= '7') {
					if((a & lim) != 0) {
						ovf_ = true;
					}
					if(!ovf_) {
						a <<= 3;
						a += ch - '0';
					}
				} else if(nbc_ != 0 && ch == ' ') {
					// 文字数指定がある場合「スペース」は '0' と同等に扱う
				} else {
					break;
				}
				if(nbc_ > 0) {
					nbc_--;
					if(nbc_ == 0) break;
				}
			}
			return a;
		}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
leaq 0x8(%rdi), %r15
xorl %ebx, %ebx
movq %r15, %rdi
callq 0xe152
testb %al, %al
je 0xf384
movl %eax, %ecx
andb $-0x8, %cl
cmpb $0x30, %cl
jne 0xf353
testl $0x7000, %ebx           # imm = 0x7000
je 0xf361
movb $0x1, 0x1b(%r14)
jmp 0xf374
cmpb $0x20, %al
jne 0xf384
movb 0x1a(%r14), %al
testb %al, %al
jne 0xf37c
jmp 0xf384
testb $0x1, 0x1b(%r14)
jne 0xf374
shll $0x3, %ebx
addb $-0x30, %al
movzbl %al, %eax
orl %ebx, %eax
movl %eax, %ebx
movb 0x1a(%r14), %al
testb %al, %al
je 0xf32e
decb %al
movb %al, 0x1a(%r14)
jne 0xf32e
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0x9baf
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: int utils::basic_input<utils::def_chainp>::dec_<int>()
T dec_() noexcept {
			T a = 0;
			char ch;
			while((ch = inp_()) != 0) {
				if(!ovf_ && ch >= '0' && ch <= '9') {
					if constexpr (std::is_signed<T>::value) {
						a *= 10;
						a += ch - '0';
						if(a < 0) {
							ovf_ = true;
						}
					} else {
						auto b = a;
						a *= 10;
						a += ch - '0';
						if(b > a) {
							ovf_ = true;
						}
					}
				} else if(nbc_ != 0 && ch == ' ') {
					// 文字数指定がある場合「スペース」は '0' と同等に扱う
				} else {
					break;
				}
				if(nbc_ > 0) {
					nbc_--;
					if(nbc_ == 0) break;
				}
			}
			return a;
		}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
leaq 0x8(%rdi), %r15
xorl %ebx, %ebx
movq %r15, %rdi
callq 0xe152
testb %al, %al
je 0xe3d8
leal -0x3a(%rax), %ecx
cmpb $-0xa, %cl
jb 0xe3c4
cmpb $0x0, 0x1b(%r14)
jne 0xe3c4
leal (%rbx,%rbx,4), %ecx
addl %ecx, %ecx
addb $-0x30, %al
movzbl %al, %ebx
addl %ecx, %ebx
jns 0xe3ba
movb $0x1, 0x1b(%r14)
movb 0x1a(%r14), %al
testb %al, %al
jne 0xe3d0
jmp 0xe38c
cmpb $0x20, %al
jne 0xe3d8
movb 0x1a(%r14), %al
testb %al, %al
je 0xe3d8
decb %al
movb %al, 0x1a(%r14)
jne 0xe38c
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0x9baf
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: unsigned int utils::basic_input<utils::def_chainp>::hex_<unsigned int>()
T hex_() noexcept {
			T a = 0;
			constexpr auto lim = static_cast<T>(0b1111) << (sizeof(T) * 8 - 4);
			char ch;
			while((ch = inp_()) != 0) {
				auto ovf = (a & lim) != 0;
				if(ch >= 'a') { ch -= 0x20; }
				if(ch >= '0' && ch <= '9') {
					if(ovf) { ovf_ = true; }
					if(!ovf_) {
						a <<= 4;
						a += ch - '0';
					}
				} else if(ch >= 'A' && ch <= 'F') {
					if(ovf) { ovf_ = true; }
					if(!ovf_) {
						a <<= 4;
						a += ch - 'A' + 10;
					}
				} else if(nbc_ != 0 && ch == ' ') {
					// 文字数指定がある場合「スペース」は '0' と同等に扱う
				} else {
					break;
				}
				if(nbc_ > 0) {
					nbc_--;
					if(nbc_ == 0) break;
				}
			}
			return a;
		}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
leaq 0x8(%rdi), %r15
xorl %ebx, %ebx
movq %r15, %rdi
callq 0xe152
testb %al, %al
je 0xe47d
leal -0x20(%rax), %ecx
cmpb $0x61, %al
movzbl %al, %eax
movzbl %cl, %ecx
cmovll %eax, %ecx
movsbl %cl, %eax
leal -0x30(%rax), %edx
cmpb $0x9, %dl
ja 0xe434
cmpl $0x10000000, %ebx       # imm = 0x10000000
jae 0xe455
testb $0x1, 0x1b(%r14)
jne 0xe45a
shll $0x4, %ebx
addl %eax, %ebx
addl $-0x30, %ebx
jmp 0xe45a
leal -0x41(%rcx), %edx
cmpb $0x5, %dl
ja 0xe464
cmpl $0x10000000, %ebx       # imm = 0x10000000
jae 0xe455
testb $0x1, 0x1b(%r14)
jne 0xe45a
shll $0x4, %ebx
addl %eax, %ebx
addl $-0x37, %ebx
jmp 0xe45a
movb $0x1, 0x1b(%r14)
movb 0x1a(%r14), %al
testb %al, %al
jne 0xe471
jmp 0xe3f6
cmpb $0x20, %cl
jne 0xe47d
movb 0x1a(%r14), %al
testb %al, %al
je 0xe47d
decb %al
movb %al, 0x1a(%r14)
jne 0xe3f6
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rdi
callq 0x9baf
nop
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: short utils::basic_input<utils::def_chainp>::auto_num_<short>()
T auto_num_() noexcept
		{
			enum class TYPE : uint8_t {
				dec,
				bin,
				oct,
				hex,
			};

			typedef typename std::make_unsigned<T>::type U;

			char ch = inp_();
			if(ch != '0') {  // 最初に０がある場合無視
				inp_.unget();
			}
			ch = inp_();
			if(ch >= 0x60) { ch -= 0x20; }
			T v = 0;
			TYPE t(TYPE::dec);
			if(ch == 'B') {
				t = TYPE::bin;
			} else if(ch == 'X') {
				t = TYPE::hex;
			} else if(ch == 'O') {
				t = TYPE::oct;
			} else {
				inp_.unget();
			}
			switch(t) {
			case TYPE::bin:
				v = bin_<U>();
				break;
			case TYPE::oct:
				v = oct_<U>();
				break;
			case TYPE::hex:
				v = hex_<U>();
				break;
			default:
				v = dec_<T>();
				break;
			}
			return v;
		}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x8(%rdi), %r14
movq %r14, %rdi
callq 0xe152
cmpb $0x30, %al
je 0xf4cb
movb $0x1, 0x11(%rbx)
movq %r14, %rdi
callq 0xe152
leal -0x20(%rax), %ecx
cmpb $0x60, %al
movzbl %al, %edx
movzbl %cl, %eax
cmovll %edx, %eax
cmpb $0x58, %al
je 0xf506
movzbl %al, %eax
cmpl $0x4f, %eax
je 0xf4fc
cmpl $0x42, %eax
jne 0xf516
movq %rbx, %rdi
callq 0xf2b0
jmp 0xf50e
movq %rbx, %rdi
callq 0xf320
jmp 0xf50e
movq %rbx, %rdi
callq 0xf400
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movb $0x1, 0x11(%rbx)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xf394
movq %rax, %rdi
callq 0x9baf
// File: /workspace/github_cpp_makefile_star2_O3/hirakuni45[P]input_class/./input.hpp
// Function: float utils::basic_input<utils::def_chainp>::nb_real_<float>()
T nb_real_() noexcept
		{
			bool neg = neg_();

			T v = 0.0f;
			switch(mode_) {
			case mode::REAL:
			case mode::AUTO:
				v = real_<T>();
				break;
			default:
				error_ = error::not_float;
				break;
			}
			if(error_ == error::none) {
				inp_.unget();
				next_();
			}
			if(neg) return -v;
			else return v;			
		}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %r14
callq 0xe26c
movl %eax, %ebx
movb 0x18(%r14), %al
andb $-0x2, %al
cmpb $0x6, %al
jne 0xe5f5
movq %r14, %rdi
callq 0xe610
cmpb $0x0, 0x19(%r14)
jne 0xe5fd
movb $0x1, 0x11(%r14)
movq %r14, %rdi
movaps %xmm0, (%rsp)
callq 0xdfe4
movaps (%rsp), %xmm0
jmp 0xe5fd
movb $0x6, 0x19(%r14)
xorps %xmm0, %xmm0
testb %bl, %bl
je 0xe608
xorps 0x1a58(%rip), %xmm0     # 0x10060
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/awbrenn[P]robot-controller/Client.cpp
// Function: initalizeMiddleware()
void initalizeMiddleware()
{
// Create socket for sending/receiving datagrams 
   if ((sock = socket(PF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
      cout << "socket() failed" << endl;

   // Construct local address structure 
   memset(&servAddr, 0, sizeof(servAddr));   // Zero out structure 
   servAddr.sin_family = AF_INET;                  // Internet address family 
   servAddr.sin_addr.s_addr = htonl(INADDR_ANY);   // Any incoming interface 
   servAddr.sin_port = htons(port);       // Local port    
   
   // If user gave a dotted decimal address, we need to resolve it  
   if (servAddr.sin_addr.s_addr == -1) {
      thehost = gethostbyname(ip);
      servAddr.sin_addr.s_addr = *((unsigned long *) thehost->h_addr_list[0]);
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl $0x2, %edi
movl $0x2, %esi
movl $0x11, %edx
callq 0x2080
movl %eax, 0x4009(%rip)      # 0x7218
testl %eax, %eax
jns 0x3255
movq 0x3db6(%rip), %rbx      # 0x6fd0
leaq 0x1f26(%rip), %rsi      # 0x5147
movl $0xf, %edx
movq %rbx, %rdi
callq 0x21f0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21b0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2140
movq $0x0, 0x3fc4(%rip) # 0x7224
movw $0x2, 0x3fb3(%rip)      # 0x721c
movl $0x0, 0x3fad(%rip)      # 0x7220
movzwl 0x3fd2(%rip), %eax      # 0x724c
rolw $0x8, %ax
movw %ax, 0x3f99(%rip)       # 0x721e
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/awbrenn[P]robot-controller/Client.cpp
// Function: convertHeaderInfoToString[abi:cxx11](unsigned int)
string convertHeaderInfoToString(uint32_t header_info) 
{
    string header_info_string;
    char uint4_chunk;
    int size_of_uint32_t = 4;
    int bits_in_a_byte = 8;

    cout << "HEADER INFO:" << header_info << endl;

    for (int i = 0; i < size_of_uint32_t; ++i) {
        uint4_chunk = (char) ((header_info << (i * bits_in_a_byte)) >> (3 * bits_in_a_byte));
        cout << "step " << i << ": " << header_info << ", " << (uint32_t) uint4_chunk << endl;
        header_info_string.push_back(uint4_chunk);
    }

    return header_info_string;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %esi, -0x2c(%rbp)
leaq 0x10(%rdi), %rax
movq %rax, -0x40(%rbp)
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movq %rdi, -0x38(%rbp)
movb $0x0, 0x10(%rdi)
movq 0x3953(%rip), %rdi      # 0x6fd0
leaq 0x1ad3(%rip), %rsi      # 0x5157
movl $0xc, %edx
callq 0x21f0
movl -0x2c(%rbp), %esi
movq 0x3938(%rip), %rdi      # 0x6fd0
movq %rsi, -0x48(%rbp)
callq 0x2130
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x21b0
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2140
xorl %r12d, %r12d
movq 0x38fb(%rip), %r13      # 0x6fd0
xorl %r14d, %r14d
movl -0x2c(%rbp), %r15d
movl %r12d, %ecx
shll %cl, %r15d
movl $0x5, %edx
movq %r13, %rdi
leaq 0x1a73(%rip), %rsi      # 0x5164
callq 0x21f0
movq %r13, %rdi
movl %r14d, %esi
callq 0x22d0
movq %rax, %rbx
movl $0x2, %edx
movq %rax, %rdi
leaq 0x1ab1(%rip), %rsi      # 0x51c4
callq 0x21f0
movq %rbx, %rdi
movq -0x48(%rbp), %rsi
callq 0x2130
movq %rax, %rbx
movl $0x2, %edx
movq %rax, %rdi
leaq 0x1a34(%rip), %rsi      # 0x516a
callq 0x21f0
movl %r15d, %esi
sarl $0x18, %esi
movq %rbx, %rdi
callq 0x2130
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21b0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2140
shrl $0x18, %r15d
movsbl %r15b, %esi
movq -0x38(%rbp), %rdi
callq 0x2190
incl %r14d
addl $0x8, %r12d
cmpl $0x4, %r14d
jne 0x36d8
movq -0x38(%rbp), %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x37aa
movq %rax, %r14
movq -0x38(%rbp), %rax
movq (%rax), %rdi
movq -0x40(%rbp), %rax
cmpq %rax, %rdi
je 0x37c8
movq (%rax), %rsi
incq %rsi
callq 0x21e0
movq %r14, %rdi
callq 0x22f0
// File: /workspace/github_cpp_makefile_star2_O3/tomfunkhouser[P]gaps/apps/gapsview/gapsview.cpp
// Function: GLUTSpecial(int, int, int)
static void
GLUTSpecial(int key, int x, int y)
{
  // Invert y coordinate
  y = GLUTwindow_height - y;

  // Process keyboard button event 
  switch (key) {
  case GLUT_KEY_DOWN:
    grid_thresholds[selected_model_index] -= 0.025 * grid_ranges[selected_model_index].Diameter();
    if (grid_thresholds[selected_model_index] < grid_ranges[selected_model_index].Min() + 1E-20) 
      grid_thresholds[selected_model_index] = grid_ranges[selected_model_index].Min() + 1E-20;
    break;

  case GLUT_KEY_UP:
    grid_thresholds[selected_model_index] += 0.025 * grid_ranges[selected_model_index].Diameter();
    if (grid_thresholds[selected_model_index] > grid_ranges[selected_model_index].Max() - 1E-20)
      grid_thresholds[selected_model_index] = grid_ranges[selected_model_index].Max() - 1E-20;
    break;
      
  case GLUT_KEY_PAGE_UP:
    if (++selected_model_index > nmodels-1) selected_model_index = nmodels - 1;
    break;

  case GLUT_KEY_PAGE_DOWN:
    if (--selected_model_index < 0) selected_model_index = 0;
    break;
  }

  // Remember mouse position 
  GLUTmouse[0] = x;
  GLUTmouse[1] = y;

  // Remember modifiers 
  GLUTmodifiers = glutGetModifiers();

  // Redraw
  glutPostRedisplay();
}

// Assembly:
movl 0x1a79d3(%rip), %eax    # 0x1d59f4
addl $-0x65, %edi
cmpl $0x4, %edi
ja 0x2e11f
leaq 0x11e2e0(%rip), %rcx    # 0x14c314
movslq (%rcx,%rdi,4), %rdi
addq %rcx, %rdi
jmpq *%rdi
movslq 0x1ad140(%rip), %rcx    # 0x1db184
movq %rcx, %rdi
shlq $0x4, %rdi
leaq 0x1acd0e(%rip), %r8     # 0x1dad60
movsd 0x8(%rdi,%r8), %xmm0
movapd %xmm0, %xmm1
subsd (%rdi,%r8), %xmm1
mulsd 0x11dfe5(%rip), %xmm1   # 0x14c050
leaq 0x1ad12e(%rip), %rdi    # 0x1db1a0
addsd (%rdi,%rcx,8), %xmm1
movsd %xmm1, (%rdi,%rcx,8)
addsd 0x11dfd4(%rip), %xmm0   # 0x14c058
ucomisd %xmm0, %xmm1
ja 0x2e0ff
jmp 0x2e11f
movl 0x1ad0ef(%rip), %ecx    # 0x1db184
leal 0x1(%rcx), %edi
movl 0x1ad325(%rip), %r8d    # 0x1db3c4
decl %r8d
cmpl %r8d, %ecx
cmovll %edi, %r8d
movl %r8d, 0x1ad0d4(%rip)    # 0x1db184
jmp 0x2e11f
movslq 0x1ad0cb(%rip), %rcx    # 0x1db184
movq %rcx, %rdi
shlq $0x4, %rdi
leaq 0x1acc99(%rip), %r8     # 0x1dad60
movsd (%rdi,%r8), %xmm0
movsd 0x8(%rdi,%r8), %xmm1
subsd %xmm0, %xmm1
mulsd 0x11df80(%rip), %xmm1   # 0x14c060
leaq 0x1ad0b9(%rip), %rdi    # 0x1db1a0
addsd (%rdi,%rcx,8), %xmm1
movsd %xmm1, (%rdi,%rcx,8)
addsd 0x11df6f(%rip), %xmm0   # 0x14c068
ucomisd %xmm1, %xmm0
jbe 0x2e11f
movsd %xmm0, (%rdi,%rcx,8)
jmp 0x2e11f
movl 0x1ad078(%rip), %ecx    # 0x1db184
cmpl $0x2, %ecx
movl $0x1, %edi
cmovgel %ecx, %edi
decl %edi
movl %edi, 0x1ad065(%rip)    # 0x1db184
pushq %rax
subl %edx, %eax
movl %esi, 0x1ad2a0(%rip)    # 0x1db3c8
movl %eax, 0x1ad29e(%rip)    # 0x1db3cc
callq 0x113de1
popq %rax
jmp 0x10ef28
// File: /workspace/github_cpp_makefile_star2_O3/tomfunkhouser[P]gaps/apps/gapsview/gapsview.cpp
// Function: GLUTMotion(int, int)
static void
GLUTMotion(int x, int y)
{
  // Invert y coordinate
  y = GLUTwindow_height - y;

  // Compute mouse movement
  int dx = x - GLUTmouse[0];
  int dy = y - GLUTmouse[1];
  
  // World in hand navigation 
  if (GLUTbutton[0]) viewer->RotateWorld(1.0, world_origin, x, y, dx, dy);
  else if (GLUTbutton[1]) viewer->ScaleWorld(1.0, world_origin, x, y, dx, dy);
  else if (GLUTbutton[2]) viewer->TranslateWorld(1.0, world_origin, x, y, dx, dy);
  if (GLUTbutton[0] || GLUTbutton[1] || GLUTbutton[2]) glutPostRedisplay();

  // Remember mouse position 
  GLUTmouse[0] = x;
  GLUTmouse[1] = y;

  // Update mouse drag movement
  GLUTmouse_drag_distance_squared += dx*dx + dy*dy;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %r15d
movl 0x1a74ec(%rip), %r14d   # 0x1d59f4
subl %esi, %r14d
movl %edi, %ebx
subl 0x1aceb5(%rip), %ebx    # 0x1db3c8
movl %r14d, %ebp
movl $0x58, %eax
subl 0x1aceab(%rip), %ebp    # 0x1db3cc
cmpl $0x0, 0x1aceac(%rip)    # 0x1db3d4
jne 0x2e546
movl $0x50, %eax
cmpl $0x0, 0x1acea2(%rip)    # 0x1db3d8
jne 0x2e546
movl $0x48, %eax
cmpl $0x0, 0x1ace98(%rip)    # 0x1db3dc
je 0x2e56f
movq 0x1acc23(%rip), %rdi    # 0x1db170
movq (%rdi), %r10
leaq 0x1ac7d9(%rip), %rsi    # 0x1dad30
movsd 0x11db19(%rip), %xmm0   # 0x14c078
movl %r15d, %edx
movl %r14d, %ecx
movl %ebx, %r8d
movl %ebp, %r9d
callq *(%r10,%rax)
cmpl $0x0, 0x1ace5e(%rip)    # 0x1db3d4
jne 0x2e58a
cmpl $0x0, 0x1ace59(%rip)    # 0x1db3d8
jne 0x2e58a
cmpl $0x0, 0x1ace54(%rip)    # 0x1db3dc
je 0x2e58f
callq 0x10ef28
movl %r15d, 0x1ace32(%rip)   # 0x1db3c8
movl %r14d, 0x1ace2f(%rip)   # 0x1db3cc
imull %ebx, %ebx
imull %ebp, %ebp
addl %ebx, %ebp
addl %ebp, 0x1ace25(%rip)    # 0x1db3d0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/tomfunkhouser[P]gaps/apps/gapsview/gapsview.cpp
// Function: LoadColorValue(double)
static void 
LoadColorValue(double value) 
{
  // Initialize color
  unsigned char color[3];
  
  // Compute rgb based on blue-green-red heatmap
  if (value <= 0) {
    color[0] = 0;
    color[1] = 0;
    color[2] = 255;
  }
  else if (value < 0.1) {
    value *= 10 * 255;
    color[0] = 0;
    color[1] = value;
    color[2] = 255;
  }
  else if (value < 0.5) {
    value = (value - 0.1) * 2.5 * 255;
    color[0] = 0;
    color[1] = 255;
    color[2] = 255 - value;
  }
  else if (value < 0.9) {
    value = (value - 0.5) * 2.5 * 255;
    color[0] = value;
    color[1] = 255;
    color[2] = 0;
  }
  else if (value < 1) {
    value = (value - 0.9) * 10 * 255;
    color[0] = 255;
    color[1] = 255 - value;
    color[2] = 0;
  }
  else {
    color[0] = 255;
    color[1] = 0;
    color[2] = 0;
  }

  // Load color
  RNLoadRgb(color);
}

// Assembly:
pushq %rax
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
jae 0x31125
movsd 0x11afa0(%rip), %xmm1   # 0x14c0a8
ucomisd %xmm0, %xmm1
jbe 0x3113d
mulsd 0x11afea(%rip), %xmm0   # 0x14c100
movb $0x0, 0x5(%rsp)
cvttsd2si %xmm0, %eax
movb %al, 0x6(%rsp)
jmp 0x3112c
movw $0x0, 0x5(%rsp)
movb $-0x1, %al
leaq 0x5(%rsp), %rdi
movb %al, 0x2(%rdi)
callq 0x27c20
popq %rax
retq
movsd 0x11aecb(%rip), %xmm1   # 0x14c010
ucomisd %xmm0, %xmm1
jbe 0x31178
addsd 0x11af9d(%rip), %xmm0   # 0x14c0f0
mulsd 0x11af9d(%rip), %xmm0   # 0x14c0f8
movsd 0x11af55(%rip), %xmm1   # 0x14c0b8
mulsd %xmm1, %xmm0
movw $0xff00, 0x5(%rsp)      # imm = 0xFF00
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
jmp 0x3112e
movsd 0x11af50(%rip), %xmm1   # 0x14c0d0
ucomisd %xmm0, %xmm1
jbe 0x311ad
addsd 0x11af5a(%rip), %xmm0   # 0x14c0e8
mulsd 0x11ae82(%rip), %xmm0   # 0x14c018
mulsd 0x11af1a(%rip), %xmm0   # 0x14c0b8
cvttsd2si %xmm0, %eax
movb %al, 0x5(%rsp)
movb $-0x1, 0x6(%rsp)
jmp 0x311f1
movsd 0x11aec3(%rip), %xmm1   # 0x14c078
ucomisd %xmm0, %xmm1
jbe 0x311ea
addsd 0x11af15(%rip), %xmm0   # 0x14c0d8
mulsd 0x11af15(%rip), %xmm0   # 0x14c0e0
movsd 0x11aee5(%rip), %xmm1   # 0x14c0b8
mulsd %xmm1, %xmm0
movb $-0x1, 0x5(%rsp)
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movb %al, 0x6(%rsp)
jmp 0x311f1
movw $0xff, 0x5(%rsp)
xorl %eax, %eax
jmp 0x3112e
// File: /workspace/github_cpp_makefile_star2_O3/tomfunkhouser[P]gaps/apps/gapsview/gapsview.cpp
// Function: DrawDotOnImageInset(ImageData*, double, double, double, gaps::R2Point const&)
static void
DrawDotOnImageInset(ImageData *data,
  double x, double y, double scale,
  const R2Point& image_position)
{
  // Check if drawing image insets
  if (!show_image_insets) return;

  // Get convenient variables
  double w = scale * data->image_width;
  double h = scale * data->image_height;
  if ((w == 0) || (h == 0)) return;

  // Set viewport
  glViewport(x, y, w, h);

  // Set viewing transformation
  glMatrixMode(GL_PROJECTION);  
  glPushMatrix();
  glLoadIdentity();
  glOrtho(0, data->image_width, 0, data->image_height, 0, 1);
  glMatrixMode(GL_MODELVIEW);
  glPushMatrix();
  glLoadIdentity();

  // Draw dot
  RNLoadRgb(1, 0, 0);
  glPointSize(5);
  RNGrfxBegin(RN_GRFX_POINTS);
  R3LoadPoint(image_position.X(), image_position.Y(), -0.25);
  RNGrfxEnd();
  glPointSize(1);

  // Restore viewing transformation
  glMatrixMode(GL_PROJECTION);  
  glPopMatrix();
  glMatrixMode(GL_MODELVIEW);  
  glPopMatrix();

  // Resore viewport
  viewer->Viewport().Load();
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
cmpl $0x0, 0x1a9fe3(%rip)    # 0x1db3ac
je 0x313ef
movq %rdi, %r14
cvtdq2pd 0x768(%rdi), %xmm1
mulpd 0x11afa2(%rip), %xmm1   # 0x14c380
xorpd %xmm2, %xmm2
cmpeqpd %xmm1, %xmm2
movmskpd %xmm2, %eax
testl %eax, %eax
je 0x313f7
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rsi, %rbx
cvttsd2si %xmm0, %edi
cvttsd2si %xmm1, %edx
unpckhpd %xmm1, %xmm1            # xmm1 = xmm1[1,1]
cvttsd2si %xmm1, %ecx
xorl %esi, %esi
callq 0x27210
movl $0x1701, %edi           # imm = 0x1701
callq 0x27d30
callq 0x27fe0
callq 0x27cc0
xorps %xmm1, %xmm1
cvtsi2sdl 0x768(%r14), %xmm1
cvtsi2sdl 0x76c(%r14), %xmm3
movsd 0x11ac36(%rip), %xmm5   # 0x14c078
xorpd %xmm0, %xmm0
xorpd %xmm2, %xmm2
xorps %xmm4, %xmm4
callq 0x28270
movl $0x1700, %edi           # imm = 0x1700
callq 0x27d30
callq 0x27fe0
callq 0x27cc0
movss 0x11acbe(%rip), %xmm0   # 0x14c12c
xorpd %xmm1, %xmm1
xorpd %xmm2, %xmm2
callq 0x28380
movss 0x11acb9(%rip), %xmm0   # 0x14c13c
callq 0x270a0
xorl %edi, %edi
callq 0x271a0
movsd (%rbx), %xmm0
movsd 0x8(%rbx), %xmm1
movsd 0x11ac68(%rip), %xmm2   # 0x14c108
callq 0x27ee0
callq 0x27cd0
movss 0x11ac7a(%rip), %xmm0   # 0x14c12c
callq 0x270a0
movl $0x1701, %edi           # imm = 0x1701
callq 0x27d30
callq 0x28250
movl $0x1700, %edi           # imm = 0x1700
callq 0x27d30
callq 0x28250
movq 0x1a9c94(%rip), %rax    # 0x1db170
movl 0x98(%rax), %edi
movl 0x9c(%rax), %esi
movl 0xa0(%rax), %edx
addl %edi, %edx
movl 0xa4(%rax), %ecx
addl %esi, %ecx
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x27210