// File: sharmaeklavya2[P]ctmeans/src/lib/ctmeans.cpp
// Function: CTMeans::step(bool, bool, bool, int*, int*)
double CTMeans::step(bool use_kd, bool update_centroids, bool store_u, int* p_sigc, int* p_heap_ops) {
    using std::vector;

    double obj = 0.0;
    int sigc = 0;
    NNIterSort nniter;
    NNIterKD nniter_kd;
    int heap_ops = 0;
    double mexp = 1/(1-m);

    if(use_kd) {
        nniter_kd.init(C);
    }
    else {
        nniter.init(C);
    }
    const Matrix& nniter_C(use_kd? nniter_kd.C: nniter.C);

    vector<double> usum;    // usum[j] = sum(U(i, j)^m for i in range(n))
    if(update_centroids) {
        usum.resize(c, 0);
        C.set_to_zero();
    }
    if(store_u) {
        U.clear();
        U.resize(n);
    }
    vector<double> norms, us;
        // norms[j] = norm of x from jth nearest centroid (norms.size() = t)
        // us[j] = membership value of x_i with c_j
    vector<int> indices;
        // indices[j] = index of jth nearest centroid (indices.size() = t)
    norms.reserve(c);
    for(int i=0; i<n; ++i) {
        us.reserve(c); indices.reserve(c);
        double norms2sum=0, norm12;
            // norms2sum = denominator of all U(i, j)
            // norm12 = norm2 of a point to the nearest cluster
        if(use_kd) {
            nniter_kd.set_point(X.begin_row(i));
        }
        else {
            nniter.set_point(X.begin_row(i));
        }

        // get the first t norms and corresponding membership values
        for(int j=0; j<max_t; ++j) {
            double norm; int index;
            std::pair<double, int> norm_index;
            if(use_kd) {
                norm_index = nniter_kd.get_neighbor();
            }
            else {
                norm_index = nniter.get_neighbor();
            }
            norm = norm_index.first;
            index = norm_index.second;

            if(index < 0 || index >= c) {
                fprintf(stderr, "step: i=%d, j=%d, index=%d\n", i, j, index);
            }
            if(norm == 0.0 || norm == -0.0) {
                norms.clear();
                indices.clear();
                us.clear();
                norms.push_back(0);
                indices.push_back(index);
                us.push_back(1);
                norms2sum = 1;
                // fprintf(stderr, "saw 0 norm\n");
                break;
            }
            double norm2 = std::pow(norm, mexp);
            if(j == 0) {norm12 = norm2;}
            if(eps_t > 0.0) {
                double den_u = norms2sum + norm2;
                double u_j = norm2 / den_u;
                double u_1 = norm12 / den_u;
                double v_1 = norm12 / (den_u + (c-j)*norm2);
                if((u_1 - v_1 < eps_t) && u_j < eps_t) {
                    break;
                }
            }
            norms.push_back(norm);
            indices.push_back(index);
            us.push_back(norm2);
            norms2sum += norm2;
        }
        /*
        if(i == 0) {
            for(int j=0; j<norms.size(); ++j) {
                fprintf(stderr, "%lg ", norms[j]);
            }
            fprintf(stderr, "\n");
        }
        */
        sigc += us.size();
        if(use_kd) {
            heap_ops += nniter_kd.get_heap_ops();
        }
        for(unsigned i2=0; i2 < us.size(); ++i2) {
            us[i2] /= norms2sum;
        }

        // calculate objective
        for(unsigned i2=0; i2<norms.size(); ++i2) {
            obj += norms[i2] * us[i2];
        }

        // update centroids
        if(update_centroids) {
            for(unsigned i2=0; i2<norms.size(); ++i2) {
                int j = indices[i2];
                double uij_m = std::pow(us[i2], m);
                usum[j] += uij_m;
                for(int k=0; k<d; ++k) {
                    C(j, k) += uij_m * X(i, k);
                }
            }
        }

        // store membership values
        norms.clear();
        if(store_u) {
            std::swap(us, U[i].first);
            std::swap(indices, U[i].second);
        }
        else {
            us.clear(); indices.clear();
        }
    }

    if(update_centroids) {
        for(int j=0; j<c; ++j) {
            if(usum[j] == 0) {
                for(int k=0; k<d; ++k) {
                    C(j, k) = nniter_C(j, k);
                }
            }
            else {
                for(int k=0; k<d; ++k) {
                    C(j, k) /= usum[j];
                }
            }
        }
    }

    if(p_sigc != nullptr) {
        *p_sigc = sigc;
    }
    if(use_kd) {
        if(p_heap_ops != nullptr) {
            *p_heap_ops = heap_ops;
        }
    }
    return obj;
}

// Assembly:
subq $0x308, %rsp            # imm = 0x308
movb %cl, %al
movb %dl, %cl
movb %sil, %dl
movq %rdi, 0x300(%rsp)
andb $0x1, %dl
movb %dl, 0x2ff(%rsp)
andb $0x1, %cl
movb %cl, 0x2fe(%rsp)
andb $0x1, %al
movb %al, 0x2fd(%rsp)
movq %r8, 0x2f0(%rsp)
movq %r9, 0x2e8(%rsp)
movq 0x300(%rsp), %rax
movq %rax, 0xd0(%rsp)
movq $0x0, 0x2e0(%rsp)
movl $0x0, 0x2dc(%rsp)
leaq 0x290(%rsp), %rdi
callq 0x3ae0
leaq 0x240(%rsp), %rdi
callq 0x3b30
jmp 0x2546
movq 0xd0(%rsp), %rax
movl $0x0, 0x230(%rsp)
movl $0x1, %ecx
subl 0x4(%rax), %ecx
movl $0x1, %eax
cltd
idivl %ecx
cvtsi2sd %eax, %xmm0
movsd %xmm0, 0x228(%rsp)
testb $0x1, 0x2ff(%rsp)
je 0x25cf
movq 0xd0(%rsp), %rsi
addq $0x28, %rsi
leaq 0x240(%rsp), %rdi
callq 0x3ba0
jmp 0x259b
jmp 0x25ec
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x238(%rsp)
movl %eax, 0x234(%rsp)
jmp 0x326f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x238(%rsp)
movl %eax, 0x234(%rsp)
jmp 0x3262
movq 0xd0(%rsp), %rsi
addq $0x28, %rsi
leaq 0x290(%rsp), %rdi
callq 0x3bf0
jmp 0x25ea
jmp 0x25ec
testb $0x1, 0x2ff(%rsp)
je 0x260c
leaq 0x240(%rsp), %rax
addq $0x28, %rax
movq %rax, 0xc8(%rsp)
jmp 0x2620
leaq 0x290(%rsp), %rax
addq $0x10, %rax
movq %rax, 0xc8(%rsp)
movq 0xc8(%rsp), %rax
movq %rax, 0x220(%rsp)
leaq 0x208(%rsp), %rdi
callq 0x3c50
testb $0x1, 0x2fe(%rsp)
je 0x26a3
movq 0xd0(%rsp), %rax
movslq (%rax), %rsi
movq $0x0, 0x200(%rsp)
leaq 0x208(%rsp), %rdi
leaq 0x200(%rsp), %rdx
callq 0x3c60
jmp 0x2675
movq 0xd0(%rsp), %rdi
addq $0x28, %rdi
callq 0x3d20
jmp 0x2688
jmp 0x26a3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x238(%rsp)
movl %eax, 0x234(%rsp)
jmp 0x3255
testb $0x1, 0x2fd(%rsp)
je 0x26e3
movq 0xd0(%rsp), %rdi
addq $0x58, %rdi
movq %rdi, 0xc0(%rsp)
callq 0x3d60
movq 0xd0(%rsp), %rax
movq 0xc0(%rsp), %rdi
movslq 0xc(%rax), %rsi
callq 0x3d80
jmp 0x26e1
jmp 0x26e3
leaq 0x1e8(%rsp), %rdi
movq %rdi, 0xb8(%rsp)
callq 0x3c50
leaq 0x1d0(%rsp), %rdi
callq 0x3c50
leaq 0x1b8(%rsp), %rdi
callq 0x3e20
movq 0xd0(%rsp), %rax
movq 0xb8(%rsp), %rdi
movslq (%rax), %rsi
callq 0x3e30
jmp 0x272c
movl $0x0, 0x1b4(%rsp)
movq 0xd0(%rsp), %rcx
movl 0x1b4(%rsp), %eax
cmpl 0xc(%rcx), %eax
jge 0x3010
movq 0xd0(%rsp), %rax
movslq (%rax), %rsi
leaq 0x1d0(%rsp), %rdi
callq 0x3e30
jmp 0x2769
movq 0xd0(%rsp), %rax
movslq (%rax), %rsi
leaq 0x1b8(%rsp), %rdi
callq 0x3f40
jmp 0x2783
xorps %xmm0, %xmm0
movsd %xmm0, 0x1a8(%rsp)
testb $0x1, 0x2ff(%rsp)
je 0x2814
movq 0xd0(%rsp), %rax
movq 0x20(%rax), %rdi
movl 0x1b4(%rsp), %esi
callq 0x3ab0
movq %rax, 0xb0(%rsp)
jmp 0x27bb
movq 0xb0(%rsp), %rsi
leaq 0x240(%rsp), %rdi
callq 0x4050
jmp 0x27d2
jmp 0x284f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x238(%rsp)
movl %eax, 0x234(%rsp)
leaq 0x1b8(%rsp), %rdi
callq 0x43f0
leaq 0x1d0(%rsp), %rdi
callq 0x4450
leaq 0x1e8(%rsp), %rdi
callq 0x4450
jmp 0x3255
movq 0xd0(%rsp), %rax
movq 0x20(%rax), %rdi
movl 0x1b4(%rsp), %esi
callq 0x3ab0
movq %rax, 0xa8(%rsp)
jmp 0x2836
movq 0xa8(%rsp), %rsi
leaq 0x290(%rsp), %rdi
callq 0xfe00
jmp 0x284d
jmp 0x284f
movl $0x0, 0x19c(%rsp)
movq 0xd0(%rsp), %rcx
movl 0x19c(%rsp), %eax
cmpl 0x8(%rcx), %eax
jge 0x2c5a
leaq 0x178(%rsp), %rdi
callq 0x40d0
jmp 0x2881
testb $0x1, 0x2ff(%rsp)
je 0x28ff
leaq 0x240(%rsp), %rdi
callq 0x10cc0
movl %eax, 0x9c(%rsp)
movsd %xmm0, 0xa0(%rsp)
jmp 0x28aa
movl 0x9c(%rsp), %eax
movsd 0xa0(%rsp), %xmm0
movsd %xmm0, 0x158(%rsp)
movl %eax, 0x160(%rsp)
movq 0x158(%rsp), %rax
movq %rax, 0x168(%rsp)
movl 0x160(%rsp), %eax
movl %eax, 0x170(%rsp)
leaq 0x178(%rsp), %rdi
leaq 0x168(%rsp), %rsi
callq 0x40f0
jmp 0x2971
leaq 0x290(%rsp), %rdi
callq 0xffa0
movl %eax, 0x8c(%rsp)
movsd %xmm0, 0x90(%rsp)
jmp 0x291e
movl 0x8c(%rsp), %eax
movsd 0x90(%rsp), %xmm0
movsd %xmm0, 0x138(%rsp)
movl %eax, 0x140(%rsp)
movq 0x138(%rsp), %rax
movq %rax, 0x148(%rsp)
movl 0x140(%rsp), %eax
movl %eax, 0x150(%rsp)
leaq 0x178(%rsp), %rdi
leaq 0x148(%rsp), %rsi
callq 0x40f0
movsd 0x178(%rsp), %xmm0
movsd %xmm0, 0x190(%rsp)
movl 0x180(%rsp), %eax
movl %eax, 0x18c(%rsp)
cmpl $0x0, 0x18c(%rsp)
jl 0x29ae
movq 0xd0(%rsp), %rcx
movl 0x18c(%rsp), %eax
cmpl (%rcx), %eax
jl 0x29dc
movq 0x19623(%rip), %rax     # 0x1bfd8
movq (%rax), %rdi
movl 0x1b4(%rsp), %edx
movl 0x19c(%rsp), %ecx
movl 0x18c(%rsp), %r8d
leaq 0x1164b(%rip), %rsi     # 0x14020
movb $0x0, %al
callq 0x2220
movsd 0x190(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x29f2
jp 0x29f2
jmp 0x2a13
movsd 0x190(%rsp), %xmm0
movsd 0x11605(%rip), %xmm1    # 0x14008
ucomisd %xmm1, %xmm0
jne 0x2abb
jp 0x2abb
leaq 0x1e8(%rsp), %rdi
movq %rdi, 0x80(%rsp)
callq 0x4120
leaq 0x1b8(%rsp), %rdi
callq 0x4140
leaq 0x1d0(%rsp), %rdi
callq 0x4120
movq 0x80(%rsp), %rdi
movq $0x0, 0x130(%rsp)
leaq 0x130(%rsp), %rsi
callq 0x4160
jmp 0x2a65
leaq 0x1b8(%rsp), %rdi
leaq 0x18c(%rsp), %rsi
callq 0x4190
jmp 0x2a7c
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x128(%rsp)
leaq 0x1d0(%rsp), %rdi
leaq 0x128(%rsp), %rsi
callq 0x4160
jmp 0x2aa5
movsd 0x11563(%rip), %xmm0    # 0x14010
movsd %xmm0, 0x1a8(%rsp)
jmp 0x2c5a
movsd 0x190(%rsp), %xmm0
movsd 0x228(%rsp), %xmm1
callq 0x2290
movsd %xmm0, 0x120(%rsp)
cmpl $0x0, 0x19c(%rsp)
jne 0x2af7
movsd 0x120(%rsp), %xmm0
movsd %xmm0, 0x1a0(%rsp)
movq 0xd0(%rsp), %rax
movsd 0x18(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x2be4
movq 0xd0(%rsp), %rax
movsd 0x1a8(%rsp), %xmm0
addsd 0x120(%rsp), %xmm0
movsd %xmm0, 0x118(%rsp)
movsd 0x120(%rsp), %xmm0
divsd 0x118(%rsp), %xmm0
movsd %xmm0, 0x110(%rsp)
movsd 0x1a0(%rsp), %xmm0
divsd 0x118(%rsp), %xmm0
movsd %xmm0, 0x108(%rsp)
movsd 0x1a0(%rsp), %xmm0
movsd 0x118(%rsp), %xmm2
movl (%rax), %ecx
subl 0x19c(%rsp), %ecx
cvtsi2sd %ecx, %xmm1
movsd 0x120(%rsp), %xmm3
mulsd %xmm3, %xmm1
addsd %xmm2, %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, 0x100(%rsp)
movsd 0x108(%rsp), %xmm1
subsd 0x100(%rsp), %xmm1
movsd 0x18(%rax), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x2be2
movq 0xd0(%rsp), %rax
movsd 0x110(%rsp), %xmm1
movsd 0x18(%rax), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x2be2
jmp 0x2c5a
jmp 0x2be4
leaq 0x1e8(%rsp), %rdi
leaq 0x190(%rsp), %rsi
callq 0x4200
jmp 0x2bfb
leaq 0x1b8(%rsp), %rdi
leaq 0x18c(%rsp), %rsi
callq 0x4190
jmp 0x2c12
leaq 0x1d0(%rsp), %rdi
leaq 0x120(%rsp), %rsi
callq 0x4200
jmp 0x2c29
movsd 0x120(%rsp), %xmm0
addsd 0x1a8(%rsp), %xmm0
movsd %xmm0, 0x1a8(%rsp)
movl 0x19c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x19c(%rsp)
jmp 0x285a
leaq 0x1d0(%rsp), %rdi
callq 0x4270
movq %rax, %rcx
movslq 0x2dc(%rsp), %rax
addq %rcx, %rax
movl %eax, 0x2dc(%rsp)
testb $0x1, 0x2ff(%rsp)
je 0x2cab
leaq 0x240(%rsp), %rdi
callq 0x4290
movl %eax, 0x7c(%rsp)
jmp 0x2c99
movl 0x7c(%rsp), %eax
addl 0x230(%rsp), %eax
movl %eax, 0x230(%rsp)
movl $0x0, 0xfc(%rsp)
movl 0xfc(%rsp), %eax
movq %rax, 0x70(%rsp)
leaq 0x1d0(%rsp), %rdi
callq 0x4270
movq %rax, %rcx
movq 0x70(%rsp), %rax
cmpq %rcx, %rax
jae 0x2d26
movsd 0x1a8(%rsp), %xmm0
movsd %xmm0, 0x68(%rsp)
movl 0xfc(%rsp), %eax
movl %eax, %esi
leaq 0x1d0(%rsp), %rdi
callq 0x42a0
movsd 0x68(%rsp), %xmm1
movsd (%rax), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rax)
movl 0xfc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xfc(%rsp)
jmp 0x2cb6
movl $0x0, 0xf8(%rsp)
movl 0xf8(%rsp), %eax
movq %rax, 0x60(%rsp)
leaq 0x1e8(%rsp), %rdi
callq 0x4270
movq %rax, %rcx
movq 0x60(%rsp), %rax
cmpq %rcx, %rax
jae 0x2dc7
movl 0xf8(%rsp), %eax
movl %eax, %esi
leaq 0x1e8(%rsp), %rdi
callq 0x42a0
movsd (%rax), %xmm0
movsd %xmm0, 0x58(%rsp)
movl 0xf8(%rsp), %eax
movl %eax, %esi
leaq 0x1d0(%rsp), %rdi
callq 0x42a0
movsd 0x58(%rsp), %xmm0
movsd (%rax), %xmm2
movsd 0x2e0(%rsp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, 0x2e0(%rsp)
movl 0xf8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xf8(%rsp)
jmp 0x2d31
testb $0x1, 0x2fe(%rsp)
je 0x2f6f
movl $0x0, 0xf4(%rsp)
movl 0xf4(%rsp), %eax
movq %rax, 0x50(%rsp)
leaq 0x1e8(%rsp), %rdi
callq 0x4270
movq %rax, %rcx
movq 0x50(%rsp), %rax
cmpq %rcx, %rax
jae 0x2f6d
movl 0xf4(%rsp), %eax
movl %eax, %esi
leaq 0x1b8(%rsp), %rdi
callq 0x42c0
movl (%rax), %eax
movl %eax, 0xf0(%rsp)
movl 0xf4(%rsp), %eax
movl %eax, %esi
leaq 0x1d0(%rsp), %rdi
callq 0x42a0
movq %rax, %rcx
movq 0xd0(%rsp), %rax
movsd (%rcx), %xmm0
movl 0x4(%rax), %edi
callq 0x42e0
movsd %xmm0, 0x48(%rsp)
jmp 0x2e5e
movsd 0x48(%rsp), %xmm0
movsd %xmm0, 0xe8(%rsp)
movsd 0xe8(%rsp), %xmm0
movsd %xmm0, 0x40(%rsp)
movslq 0xf0(%rsp), %rsi
leaq 0x208(%rsp), %rdi
callq 0x42a0
movsd 0x40(%rsp), %xmm0
addsd (%rax), %xmm0
movsd %xmm0, (%rax)
movl $0x0, 0xe4(%rsp)
movq 0xd0(%rsp), %rcx
movl 0xe4(%rsp), %eax
cmpl 0x10(%rcx), %eax
jge 0x2f55
movq 0xd0(%rsp), %rax
movsd 0xe8(%rsp), %xmm0
movsd %xmm0, 0x30(%rsp)
movq 0x20(%rax), %rdi
movl 0x1b4(%rsp), %esi
movl 0xe4(%rsp), %edx
callq 0x4310
movsd %xmm0, 0x38(%rsp)
jmp 0x2ef8
movq 0xd0(%rsp), %rdi
addq $0x28, %rdi
movl 0xf0(%rsp), %esi
movl 0xe4(%rsp), %edx
callq 0x4340
movq %rax, 0x28(%rsp)
jmp 0x2f1e
movq 0x28(%rsp), %rax
movsd 0x38(%rsp), %xmm2
movsd 0x30(%rsp), %xmm0
movsd (%rax), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, (%rax)
movl 0xe4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xe4(%rsp)
jmp 0x2eaa
jmp 0x2f57
movl 0xf4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xf4(%rsp)
jmp 0x2de0
jmp 0x2f6f
leaq 0x1e8(%rsp), %rdi
callq 0x4120
testb $0x1, 0x2fd(%rsp)
je 0x2fde
movq 0xd0(%rsp), %rdi
addq $0x58, %rdi
movslq 0x1b4(%rsp), %rsi
callq 0x43a0
movq %rax, %rsi
leaq 0x1d0(%rsp), %rdi
callq 0x4370
movq 0xd0(%rsp), %rdi
addq $0x58, %rdi
movslq 0x1b4(%rsp), %rsi
callq 0x43a0
movq %rax, %rsi
addq $0x18, %rsi
leaq 0x1b8(%rsp), %rdi
callq 0x43c0
jmp 0x2ff8
leaq 0x1d0(%rsp), %rdi
callq 0x4120
leaq 0x1b8(%rsp), %rdi
callq 0x4140
jmp 0x2ffa
movl 0x1b4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1b4(%rsp)
jmp 0x2737
testb $0x1, 0x2fe(%rsp)
je 0x31a8
movl $0x0, 0xe0(%rsp)
movq 0xd0(%rsp), %rcx
movl 0xe0(%rsp), %eax
cmpl (%rcx), %eax
jge 0x31a6
movslq 0xe0(%rsp), %rsi
leaq 0x208(%rsp), %rdi
callq 0x42a0
movsd (%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x30fb
jp 0x30fb
movl $0x0, 0xdc(%rsp)
movq 0xd0(%rsp), %rcx
movl 0xdc(%rsp), %eax
cmpl 0x10(%rcx), %eax
jge 0x30f6
movq 0x220(%rsp), %rdi
movl 0xe0(%rsp), %esi
movl 0xdc(%rsp), %edx
callq 0x4310
movsd %xmm0, 0x20(%rsp)
jmp 0x30ae
movq 0xd0(%rsp), %rdi
addq $0x28, %rdi
movl 0xe0(%rsp), %esi
movl 0xdc(%rsp), %edx
callq 0x4340
movq %rax, 0x18(%rsp)
jmp 0x30d4
movq 0x18(%rsp), %rax
movsd 0x20(%rsp), %xmm0
movsd %xmm0, (%rax)
movl 0xdc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xdc(%rsp)
jmp 0x3077
jmp 0x318e
movl $0x0, 0xd8(%rsp)
movq 0xd0(%rsp), %rcx
movl 0xd8(%rsp), %eax
cmpl 0x10(%rcx), %eax
jge 0x318c
movslq 0xe0(%rsp), %rsi
leaq 0x208(%rsp), %rdi
callq 0x42a0
movq 0xd0(%rsp), %rdi
movsd (%rax), %xmm0
movsd %xmm0, 0x8(%rsp)
addq $0x28, %rdi
movl 0xe0(%rsp), %esi
movl 0xd8(%rsp), %edx
callq 0x4340
movq %rax, 0x10(%rsp)
jmp 0x315f
movq 0x10(%rsp), %rax
movsd 0x8(%rsp), %xmm1
movsd (%rax), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rax)
movl 0xd8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xd8(%rsp)
jmp 0x3106
jmp 0x318e
jmp 0x3190
movl 0xe0(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xe0(%rsp)
jmp 0x3029
jmp 0x31a8
cmpq $0x0, 0x2f0(%rsp)
je 0x31c4
movl 0x2dc(%rsp), %ecx
movq 0x2f0(%rsp), %rax
movl %ecx, (%rax)
testb $0x1, 0x2ff(%rsp)
je 0x31ec
cmpq $0x0, 0x2e8(%rsp)
je 0x31ea
movl 0x230(%rsp), %ecx
movq 0x2e8(%rsp), %rax
movl %ecx, (%rax)
jmp 0x31ec
movsd 0x2e0(%rsp), %xmm0
movsd %xmm0, (%rsp)
leaq 0x1b8(%rsp), %rdi
callq 0x43f0
leaq 0x1d0(%rsp), %rdi
callq 0x4450
leaq 0x1e8(%rsp), %rdi
callq 0x4450
leaq 0x208(%rsp), %rdi
callq 0x4450
leaq 0x240(%rsp), %rdi
callq 0x44b0
leaq 0x290(%rsp), %rdi
callq 0x4510
movsd (%rsp), %xmm0
addq $0x308, %rsp            # imm = 0x308
retq
leaq 0x208(%rsp), %rdi
callq 0x4450
leaq 0x240(%rsp), %rdi
callq 0x44b0
leaq 0x290(%rsp), %rdi
callq 0x4510
movq 0x238(%rsp), %rdi
callq 0x22a0
nopl (%rax)