// File: /workspace/github_cpp_makefile_star2_O3/WeiqiangZhou[P]BIRD/source/predict_main.cpp
// Function: main
int main(int argc, char *argv[])
{
	char infile[255];
	char outfile[255];
    char outfile_expr[255];
	char libfile[255]="./model_file.bin";
	int write_flag = 0;
    int log_flag = 0;
	int locus_model = 0;
	double up_bound = 14;
	int opt;
    int match_mode = 0;
    std::string sep_str = ".";

	if(argc == 1)
	{
		help_info();
		return 1;
	}

	while ((opt = getopt(argc,argv,"b:i:o:u:wthle")) != EOF)
	{
		switch(opt)
		{
			case 'b':
				strcpy(libfile, optarg);
				break;
			case 'i':
				strcpy(infile, optarg);
				break;
			case 'o':
				strcpy(outfile, optarg);
				break;
			case 'u':
				up_bound = atof(optarg);
				break;
			case 'w':
				write_flag = 1;
				break;
            case 't':
                log_flag = 1;
                break;
			case 'h':
				help_info();
				return 1;
			case 'l':
				locus_model = 1;
				break;
            case 'e':
                match_mode = 1;
                break;
			case '?':
				std::cout << "Please input the correct parameters." << std::endl;
				std::cout << "Standard output: BIRD_predict -b model_file.bin -i input_file.txt -o output_file.txt" << std::endl;
				std::cout << "WIG output: BIRD_predict -b model_file.bin -i input_file.txt -o output_name -w" << std::endl;
				return 1;
			default:
				abort();
		}
	}

	//output parameters
	std::cout << "Using model file: " << libfile << std::endl;
	std::cout << "Input file name: " << infile << std::endl;
	std::cout << "Output file name: " << outfile << std::endl;
	std::cout << "Using upper bound: " << up_bound << std::endl;
	if(write_flag)
	{
		std::cout << "Output mode: wig file" << std::endl;
	}
	else
	{
		std::cout << "Output mode: data matrix" << std::endl;
	}

	if(locus_model)
	{
		std::cout << "Prediction mode: locus-level model" << std::endl;
	}
	else
	{
		std::cout << "Prediction mode: full model" << std::endl;
	}

	Exondata exonin;
	Exondata *indata = &exonin;
	int predictor_size, sample_size, cluster_size, var_size, loci_size, bin_size, DH_num1, DH_num2, DH_num3;

	if (ReadPar(libfile, loci_size, predictor_size, cluster_size, bin_size, var_size, DH_num1, DH_num2, DH_num3))
	{
		return 1;
	}

	double *quantile_in = new double[predictor_size];
	int *cluster_idx = new int[predictor_size];
	double *exon_mean = new double[predictor_size];
	double *exon_sd = new double[predictor_size];
	double *DNase_mean = new double[loci_size];
	double *DNase_sd = new double[loci_size];

	double **coef = new double *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		coef[j] = new double[loci_size]();
	}

	int **pre_idx = new int *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		pre_idx[j] = new int[loci_size]();
	}

	char **select_loci = new char *[loci_size];
	for (int j = 0; j < loci_size; j++)
	{
		select_loci[j] = new char[30];
	}

	char **TC_id = new char *[predictor_size];
	for (int j = 0; j < predictor_size; j++)
	{
		TC_id[j] = new char[30];
	}

	//DH cluster model
	double **dis_matrix = new double *[3];
	for (int j = 0; j < 3; j++)
	{
		dis_matrix[j] = new double[loci_size]();
	}

	int **DH_cluster = new int *[3];
	for (int j = 0; j < 3; j++)
	{
		DH_cluster[j] = new int[loci_size]();
	}

	double **DH_coef1 = new double *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_coef1[j] = new double[DH_num1]();
	}

	double **DH_coef2 = new double *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_coef2[j] = new double[DH_num2]();
	}

	double **DH_coef3 = new double *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_coef3[j] = new double[DH_num3]();
	}

	int **DH_pre_idx1 = new int *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_pre_idx1[j] = new int[DH_num1]();
	}

	int **DH_pre_idx2 = new int *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_pre_idx2[j] = new int[DH_num2]();
	}

	int **DH_pre_idx3 = new int *[var_size];
	for (int j = 0; j < var_size; j++)
	{
		DH_pre_idx3[j] = new int[DH_num3]();
	}

	//read in modle file
	if (ReadinModel(libfile, quantile_in, exon_mean, exon_sd, coef, DNase_mean, DNase_sd, pre_idx, TC_id, cluster_idx, select_loci, predictor_size, var_size, loci_size, dis_matrix, DH_cluster, DH_coef1, DH_coef2, DH_coef3, DH_pre_idx1, DH_pre_idx2, DH_pre_idx3, DH_num1, DH_num2, DH_num3))
	{
		return 1;
	}
	//read in gene expression data
	if (ReadinExon(infile, indata))
	{
		return 1;
	}

    int *match_idx = new int[predictor_size];
    
    //match and check gene expression data
    std::cout << "Matching the input gene expression data." << std::endl;
    if(match_mode == 1)
    {
        //use exact match
        if (MatchExon(TC_id, indata, predictor_size, match_idx))
        {
            std::cout << "Gene expression data format incorrect: No gene id matches the library file." << std::endl;
            std::cout << "Please check sample input file for reference." << std::endl;
            return 1;
        }
    }
    else
    {
        //match id before separate character
        if (MatchExon_sep(TC_id, indata, predictor_size, match_idx, sep_str))
        {
            std::cout << "Gene expression data format incorrect: No gene id matches the library file." << std::endl;
            std::cout << "Please check sample input file for reference." << std::endl;
            return 1;
        }
    }
    
    std::cout << "Processing data..." << std::endl;
    
	sample_size = (int)exonin.sample_name.size();

	double ** data_norm = new double *[sample_size];
	double ** data_mean = new double *[sample_size];
	double ** output = new double *[sample_size];
	double ** DH_pre1 = new double *[sample_size];
	double ** DH_pre2 = new double *[sample_size];
	double ** DH_pre3 = new double *[sample_size];

	for (int i = 0; i < sample_size; i++)
	{
		data_norm[i] = new double[predictor_size]();
		data_mean[i] = new double[cluster_size]();
		output[i] = new double[loci_size]();
		DH_pre1[i] = new double[DH_num1]();
		DH_pre2[i] = new double[DH_num2]();
		DH_pre3[i] = new double[DH_num3]();
	}

	for (int i = 0; i < sample_size; i++)
	{
		for (int j = 0; j < predictor_size; j++)
		{
            if(match_idx[j] != -1)
            {
                data_norm[i][j] = log2(exonin.data[match_idx[j]][i] + 1);
            }
            else
            {
                data_norm[i][j] = 0;
            }
		}
	}
    
    strcpy(outfile_expr, infile);
    strcat(outfile_expr, ".match.txt");
    WriteExpr(data_norm, exonin.sample_name, TC_id, outfile_expr, predictor_size, sample_size);
    
    for (int i = 0; i < sample_size; i++)
    {
        QuantileNorm(data_norm[i], quantile_in, predictor_size);
    }

	StandardizeRow(data_norm, exon_mean, exon_sd, predictor_size, sample_size); //standardize gene expression data
	ClusterMean(data_norm, data_mean, cluster_idx, predictor_size, cluster_size, sample_size); //get gene expression cluster mean;

	if(locus_model != 1)
	{
		//Locus level prediction
		Regression(data_mean, output, coef, pre_idx, var_size, loci_size, sample_size);

		//DH cluster level prediction
		Regression(data_mean, DH_pre1, DH_coef1, DH_pre_idx1, var_size, DH_num1, sample_size);
		Regression(data_mean, DH_pre2, DH_coef2, DH_pre_idx2, var_size, DH_num2, sample_size);
		Regression(data_mean, DH_pre3, DH_coef3, DH_pre_idx3, var_size, DH_num3, sample_size);

		//Combine result from locus level and DH cluster level
		ModelAverage(output, DH_pre1, DH_pre2, DH_pre3, dis_matrix, DH_cluster, loci_size, sample_size);
		std::cout << "Using full model for prediction." << std::endl;
	}
	else
	{
		//Locus level prediction
		Regression(data_mean, output, coef, pre_idx, var_size, loci_size, sample_size);
		std::cout << "Using locus-level model for prediction." << std::endl;
	}

  	//convert predicted value back to original scale
	StandardizeRow_r(output, DNase_mean, DNase_sd, loci_size, sample_size);

  	//write output file
	std::cout << "Writing output file..." << std::endl;
	if (WriteWIG(output, select_loci, exonin.sample_name, outfile, bin_size, loci_size, sample_size, write_flag, up_bound, log_flag))
	{
		return 1;
	}

	//release memory.
	ReleaseExondata(exonin);
	delete[] quantile_in;
	delete[] cluster_idx;
	for (int i = 0; i < sample_size; i++)
	{
		delete[] data_norm[i];
		delete[] data_mean[i];
		delete[] output[i];
		delete[] DH_pre1[i];
		delete[] DH_pre2[i];
		delete[] DH_pre3[i];
	}
	for (int i = 0; i < var_size; i++)
	{
		delete[] coef[i];
		delete[] pre_idx[i];
		delete[] DH_coef1[i];
		delete[] DH_coef2[i];
		delete[] DH_coef3[i];
		delete[] DH_pre_idx1[i];
		delete[] DH_pre_idx2[i];
		delete[] DH_pre_idx3[i];
	}
	for (int i = 0; i < 3; i++)
	{
		delete[] dis_matrix[i];
		delete[] DH_cluster[i];
	}
	for (int i = 0; i < predictor_size; i++)
	{
		delete[] TC_id[i];
	}
	for (int i = 0; i < loci_size; i++)
	{
		delete[] select_loci[i];
	}
	delete[] data_norm;
	delete[] data_mean;
	delete[] output;
	delete[] DH_pre1;
	delete[] DH_pre2;
	delete[] DH_pre3;
	delete[] coef;
	delete[] pre_idx;
	delete[] DH_coef1;
	delete[] DH_coef2;
	delete[] DH_coef3;
	delete[] DH_pre_idx1;
	delete[] DH_pre_idx2;
	delete[] DH_pre_idx3;
	delete[] TC_id;
	delete[] select_loci;
	delete[] dis_matrix;
	delete[] DH_cluster;
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x648, %rsp            # imm = 0x648
movq %rsi, %rbx
movl %edi, %r14d
leaq 0x5a33(%rip), %rsi      # 0x8080
leaq -0x370(%rbp), %rdi
movl $0xff, %edx
callq 0x2190
leaq -0x1c8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x6142(%rip), %rsi      # 0x87b2
leaq 0x613c(%rip), %rdx      # 0x87b3
leaq -0x1d8(%rbp), %rdi
callq 0x3fe2
cmpl $0x1, %r14d
jne 0x26c2
movl $0x1, -0x5c(%rbp)
callq 0x631e
movq -0x1d8(%rbp), %rdi
leaq -0x1c8(%rbp), %rax
cmpq %rax, %rdi
je 0x26ad
callq 0x21d0
movl -0x5c(%rbp), %eax
addq $0x648, %rsp            # imm = 0x648
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movsd 0x593e(%rip), %xmm0     # 0x8008
movsd %xmm0, -0x120(%rbp)
movl $0x0, -0xf8(%rbp)
leaq 0x5a9c(%rip), %r15      # 0x817f
leaq 0x5936(%rip), %r13      # 0x8020
movl $0x0, -0x84(%rbp)
movq $0x0, -0x160(%rbp)
xorl %eax, %eax
movl %eax, %r12d
movl %r14d, %edi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x2080
leal -0x62(%rax), %ecx
cmpl $0x15, %ecx
ja 0x27bf
movl $0x1, %eax
movslq (%r13,%rcx,4), %rcx
addq %r13, %rcx
jmpq *%rcx
movq 0x9894(%rip), %rax      # 0xbfc8
movq (%rax), %rsi
leaq -0x370(%rbp), %rdi
jmp 0x2793
movl $0x1, -0xf8(%rbp)
movl %r12d, %eax
jmp 0x2701
movl $0x1, -0x84(%rbp)
movl %r12d, %eax
jmp 0x2701
movl $0x1, %eax
movq %rax, -0x160(%rbp)
movl %r12d, %eax
jmp 0x2701
movq 0x9852(%rip), %rax      # 0xbfc8
movq (%rax), %rsi
leaq -0x670(%rbp), %rdi
jmp 0x2793
movq 0x983f(%rip), %rax      # 0xbfc8
movq (%rax), %rsi
leaq -0x570(%rbp), %rdi
callq 0x21c0
movl %r12d, %eax
jmp 0x2701
movq 0x9821(%rip), %rax      # 0xbfc8
movq (%rax), %rdi
callq 0x2260
movsd %xmm0, -0x120(%rbp)
movl %r12d, %eax
jmp 0x2701
cmpl $-0x1, %eax
je 0x28af
cmpl $0x3f, %eax
jne 0x3ab7
movq 0x9800(%rip), %rbx      # 0xbfd8
leaq 0x59ae(%rip), %rsi      # 0x818d
movl $0x24, %edx
movq %rbx, %rdi
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x97ce(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
movq 0x97ba(%rip), %rbx      # 0xbfd8
leaq 0x598d(%rip), %rsi      # 0x81b2
movl $0x54, %edx
movq %rbx, %rdi
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x9788(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
movq 0x9774(%rip), %rbx      # 0xbfd8
leaq 0x599c(%rip), %rsi      # 0x8207
movl $0x4e, %edx
movq %rbx, %rdi
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x9742(%rip), %rdi      # 0xbfd8
callq 0x2040
movl $0x1, -0x5c(%rbp)
movq %rax, %rdi
callq 0x2150
jmp 0x2695
movq 0x9722(%rip), %rdi      # 0xbfd8
leaq 0x5999(%rip), %rsi      # 0x8256
movl $0x12, %edx
callq 0x2230
leaq -0x370(%rbp), %r14
movq %r14, %rdi
callq 0x2100
movq 0x96fb(%rip), %rbx      # 0xbfd8
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x96cf(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
movq 0x96bb(%rip), %rdi      # 0xbfd8
leaq 0x5945(%rip), %rsi      # 0x8269
movl $0x11, %edx
callq 0x2230
leaq -0x570(%rbp), %r14
movq %r14, %rdi
callq 0x2100
movq 0x9694(%rip), %rbx      # 0xbfd8
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x9668(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
movq 0x9654(%rip), %rdi      # 0xbfd8
leaq 0x58f0(%rip), %rsi      # 0x827b
movl $0x12, %edx
callq 0x2230
leaq -0x670(%rbp), %r14
movq %r14, %rdi
callq 0x2100
movq 0x962d(%rip), %rbx      # 0xbfd8
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x9601(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
movq 0x95ed(%rip), %rdi      # 0xbfd8
leaq 0x589c(%rip), %rsi      # 0x828e
movl $0x13, %edx
callq 0x2230
movq 0x95d5(%rip), %rdi      # 0xbfd8
movsd -0x120(%rbp), %xmm0
callq 0x2320
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2150
xorl %eax, %eax
testl %r12d, %r12d
sete %al
leaq 0x586f(%rip), %rcx      # 0x82b8
leaq 0x5852(%rip), %rsi      # 0x82a2
cmoveq %rcx, %rsi
leaq 0x15(%rax,%rax,2), %rdx
movq 0x9578(%rip), %rbx      # 0xbfd8
movq %rbx, %rdi
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x9552(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
cmpl $0x0, -0x84(%rbp)
leaq 0x5853(%rip), %rax      # 0x82f4
leaq 0x5829(%rip), %rsi      # 0x82d1
cmoveq %rax, %rsi
movl $0x1b, %eax
movl $0x22, %edx
cmoveq %rax, %rdx
movq 0x9517(%rip), %rbx      # 0xbfd8
movq %rbx, %rdi
callq 0x2230
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x21e0
movsbl %al, %esi
movq 0x94f1(%rip), %rdi      # 0xbfd8
callq 0x2040
movq %rax, %rdi
callq 0x2150
xorpd %xmm0, %xmm0
movapd %xmm0, -0x180(%rbp)
movapd %xmm0, -0x190(%rbp)
movapd %xmm0, -0x1a0(%rbp)
movapd %xmm0, -0x1b0(%rbp)
movq $0x0, -0x170(%rbp)
subq $0x8, %rsp
leaq -0x60(%rbp), %rax
leaq -0x4c(%rbp), %r10
leaq -0x50(%rbp), %r11
leaq -0x370(%rbp), %rdi
leaq -0x3c(%rbp), %rsi
leaq -0x2c(%rbp), %rdx
leaq -0xfc(%rbp), %rcx
leaq -0x124(%rbp), %r8
leaq -0x40(%rbp), %r9
pushq %rax
pushq %r10
pushq %r11
callq 0x563b
addq $0x20, %rsp
movl $0x1, -0x5c(%rbp)
testl %eax, %eax
jne 0x3a8e
movslq -0x2c(%rbp), %r14
leaq (,%r14,8), %rdi
testq %r14, %r14
movq $-0x1, %rbx
cmovsq %rbx, %rdi
movq %rdi, -0x78(%rbp)
callq 0x2030
movq %rax, -0x118(%rbp)
leaq (,%r14,4), %rdi
movq %r14, -0xa0(%rbp)
testl %r14d, %r14d
cmovsq %rbx, %rdi
callq 0x2030
movq %rax, -0x110(%rbp)
movq -0x78(%rbp), %rbx
movq %rbx, %rdi
callq 0x2030
movq %rax, -0x148(%rbp)
movq %rbx, %rdi
callq 0x2030
movq %rax, -0x140(%rbp)
movslq -0x3c(%rbp), %rcx
leaq (,%rcx,8), %rax
movq %rcx, -0x70(%rbp)
testq %rcx, %rcx
movq $-0x1, %r14
cmovnsq %rax, %r14
movq %r14, %rdi
callq 0x2030
movq %rax, -0x138(%rbp)
movq %r14, %rdi
callq 0x2030
movq %rax, -0x130(%rbp)
movslq -0x40(%rbp), %rbx
leaq (,%rbx,8), %rax
testq %rbx, %rbx
movq $-0x1, %rdi
cmovnsq %rax, %rdi
movq %rdi, -0x48(%rbp)
callq 0x2030
movq %rax, -0x98(%rbp)
movq %rbx, -0x38(%rbp)
testl %ebx, %ebx
jle 0x2c7b
xorl %ebx, %ebx
movq %r14, %rdi
callq 0x2030
movq %rax, %r13
movq %rax, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x2130
movq -0x98(%rbp), %rax
movq %r13, (%rax,%rbx,8)
incq %rbx
cmpq %rbx, -0x38(%rbp)
jne 0x2c4f
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0x90(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2cd9
movq -0x70(%rbp), %rcx
leaq (,%rcx,4), %rax
testl %ecx, %ecx
movq $-0x1, %r13
cmovnsq %rax, %r13
xorl %r15d, %r15d
movq %r13, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x2130
movq -0x90(%rbp), %rax
movq %rbx, (%rax,%r15,8)
incq %r15
cmpq %r15, -0x38(%rbp)
jne 0x2cad
movq %r14, %rdi
callq 0x2030
movq %rax, -0xe8(%rbp)
cmpl $0x0, -0x70(%rbp)
jle 0x2d0e
xorl %ebx, %ebx
movl $0x1e, %edi
callq 0x2030
movq -0xe8(%rbp), %rcx
movq %rax, (%rcx,%rbx,8)
incq %rbx
cmpq %rbx, -0x70(%rbp)
jne 0x2cf0
movq -0x78(%rbp), %rdi
callq 0x2030
movq %rax, -0x80(%rbp)
cmpl $0x0, -0xa0(%rbp)
jle 0x2d44
xorl %ebx, %ebx
movl $0x1e, %edi
callq 0x2030
movq -0x80(%rbp), %rcx
movq %rax, (%rcx,%rbx,8)
incq %rbx
cmpq %rbx, -0xa0(%rbp)
jne 0x2d26
movl $0x18, %edi
callq 0x2030
movq %rax, -0x78(%rbp)
xorl %r15d, %r15d
movq %r14, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r14, %rdx
callq 0x2130
movq -0x78(%rbp), %rax
movq %rbx, (%rax,%r15,8)
incq %r15
cmpq $0x3, %r15
jne 0x2d55
movl $0x18, %edi
callq 0x2030
movq %rax, -0xf0(%rbp)
movq -0x70(%rbp), %rcx
leaq (,%rcx,4), %rax
testl %ecx, %ecx
movq $-0x1, %r15
cmovnsq %rax, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xf0(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq $0x3, %r13
jne 0x2dab
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0xe0(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2e36
movslq -0x50(%rbp), %rax
leaq (,%rax,8), %rcx
testq %rax, %rax
movq $-0x1, %r15
cmovnsq %rcx, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xe0(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x38(%rbp)
jne 0x2e0a
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0xd8(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2e95
movslq -0x4c(%rbp), %rax
leaq (,%rax,8), %rcx
testq %rax, %rax
movq $-0x1, %r15
cmovnsq %rcx, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xd8(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x38(%rbp)
jne 0x2e69
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0xd0(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2ef4
movslq -0x60(%rbp), %rax
leaq (,%rax,8), %rcx
testq %rax, %rax
movq $-0x1, %r15
cmovnsq %rcx, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xd0(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x38(%rbp)
jne 0x2ec8
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0xc8(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2f53
movslq -0x50(%rbp), %rax
leaq (,%rax,4), %rcx
testq %rax, %rax
movq $-0x1, %r15
cmovnsq %rcx, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xc8(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x38(%rbp)
jne 0x2f27
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0xc0(%rbp)
cmpl $0x0, -0x38(%rbp)
jle 0x2fb2
movslq -0x4c(%rbp), %rax
leaq (,%rax,4), %rcx
testq %rax, %rax
movq $-0x1, %r15
cmovnsq %rcx, %r15
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0xc0(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x38(%rbp)
jne 0x2f86
movq -0x48(%rbp), %rdi
callq 0x2030
movq %rax, -0x48(%rbp)
movslq -0x60(%rbp), %r13
cmpl $0x0, -0x38(%rbp)
jle 0x300b
leaq (,%r13,4), %rax
testl %r13d, %r13d
movq $-0x1, %r15
cmovnsq %rax, %r15
xorl %r14d, %r14d
movq %r15, %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x2130
movq -0x48(%rbp), %rax
movq %rbx, (%rax,%r14,8)
incq %r14
cmpq %r14, -0x38(%rbp)
jne 0x2fe2
movl -0x50(%rbp), %eax
movl -0x4c(%rbp), %r10d
subq $0x8, %rsp
leaq -0x370(%rbp), %rdi
movq -0x118(%rbp), %rsi
movq -0x148(%rbp), %rdx
movq -0x140(%rbp), %rcx
movq -0x98(%rbp), %r8
movq -0x138(%rbp), %r9
pushq %r13
pushq %r10
pushq %rax
pushq -0x48(%rbp)
pushq -0xc0(%rbp)
pushq -0xc8(%rbp)
pushq -0xd0(%rbp)
pushq -0xd8(%rbp)
pushq -0xe0(%rbp)
pushq -0xf0(%rbp)
pushq -0x78(%rbp)
pushq -0x70(%rbp)
pushq -0x38(%rbp)
pushq -0xa0(%rbp)
pushq -0xe8(%rbp)
pushq -0x110(%rbp)
pushq -0x80(%rbp)
pushq -0x90(%rbp)
pushq -0x130(%rbp)
callq 0x51c7
addq $0xa0, %rsp
testl %eax, %eax
jne 0x3a8e
leaq -0x570(%rbp), %rdi
leaq -0x1b0(%rbp), %rsi
callq 0x48af
testl %eax, %eax
jne 0x3a8e
movslq -0x2c(%rbp), %rax
leaq (,%rax,4), %rcx
testq %rax, %rax
movq $-0x1, %rdi
cmovnsq %rcx, %rdi
callq 0x2030
movq %rax, %r15
movq 0x8eea(%rip), %rdi      # 0xbfd8
leaq 0x521b(%rip), %rsi      # 0x8310
movl $0x28, %edx
callq 0x2230
movq 0x8ed2(%rip), %rdi      # 0xbfd8
callq 0x2110
movl -0x2c(%rbp), %ebx
cmpl $0x0, -0xf8(%rbp)
je 0x3181
leaq -0x1b0(%rbp), %rsi
movq -0x80(%rbp), %rdi
movl %ebx, %edx
movq %r15, %rcx
callq 0x451c
testl %eax, %eax
je 0x31e0
movq 0x8e9d(%rip), %rdi      # 0xbfd8
leaq 0x51f7(%rip), %rsi      # 0x8339
movl $0x4b, %edx
callq 0x2230
movq 0x8e85(%rip), %rdi      # 0xbfd8
callq 0x2110
movq 0x8e79(%rip), %rdi      # 0xbfd8
leaq 0x521f(%rip), %rsi      # 0x8385
movl $0x2d, %edx
callq 0x2230
movq 0x8e61(%rip), %rdi      # 0xbfd8
callq 0x2110
jmp 0x3a8e
leaq -0x218(%rbp), %r13
movq %r13, -0x10(%r13)
movq -0x1d8(%rbp), %rsi
movq -0x1d0(%rbp), %rdx
addq %rsi, %rdx
leaq -0x228(%rbp), %rdi
callq 0x3f44
leaq -0x1b0(%rbp), %rsi
leaq -0x228(%rbp), %r8
movq -0x80(%rbp), %rdi
movl %ebx, %edx
movq %r15, %rcx
callq 0x425a
movl %eax, %ebx
movq -0x228(%rbp), %rdi
cmpq %r13, %rdi
je 0x31d8
callq 0x21d0
testl %ebx, %ebx
jne 0x3134
movq 0x8df1(%rip), %rdi      # 0xbfd8
leaq 0x51c5(%rip), %rsi      # 0x83b3
movl $0x12, %edx
callq 0x2230
movq 0x8dd9(%rip), %rdi      # 0xbfd8
callq 0x2110
movq -0x1a8(%rbp), %rbx
subq -0x1b0(%rbp), %rbx
movq %rbx, %rax
shlq $0x1b, %rax
movq %rax, %rcx
sarq $0x1d, %rcx
testq %rax, %rax
movq $-0x1, %r13
cmovnsq %rcx, %r13
movq %r13, %rdi
callq 0x2030
movq %rax, %r14
movq %r13, %rdi
callq 0x2030
movq %rax, -0x58(%rbp)
movq %r13, %rdi
callq 0x2030
movq %rax, -0x68(%rbp)
movq %r13, %rdi
callq 0x2030
movq %rax, -0xb8(%rbp)
movq %r13, %rdi
callq 0x2030
movq %rax, -0xb0(%rbp)
movq %r13, %rdi
callq 0x2030
movq %rax, -0xa8(%rbp)
shrq $0x5, %rbx
movq %rbx, -0x108(%rbp)
testl %ebx, %ebx
jle 0x34bf
movslq -0x2c(%rbp), %rax
leaq (,%rax,8), %rcx
testq %rax, %rax
movq $-0x1, %rax
cmovsq %rax, %rcx
movq %rcx, -0x38(%rbp)
movslq -0xfc(%rbp), %rcx
leaq (,%rcx,8), %rdx
testq %rcx, %rcx
cmovsq %rax, %rdx
movq %rdx, -0xf8(%rbp)
movslq -0x3c(%rbp), %rcx
leaq (,%rcx,8), %rdx
testq %rcx, %rcx
cmovsq %rax, %rdx
movq %rdx, -0x70(%rbp)
movslq -0x50(%rbp), %rcx
leaq (,%rcx,8), %rdx
testq %rcx, %rcx
cmovsq %rax, %rdx
movq %rdx, -0xa0(%rbp)
movslq -0x4c(%rbp), %rcx
leaq (,%rcx,8), %rdx
testq %rcx, %rcx
cmovsq %rax, %rdx
movq %rdx, -0x158(%rbp)
movslq -0x60(%rbp), %rcx
leaq (,%rcx,8), %rdx
testq %rcx, %rcx
cmovsq %rax, %rdx
movq %rdx, -0x150(%rbp)
movq -0x108(%rbp), %rax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, -0x1b8(%rbp)
xorl %r13d, %r13d
movq -0x38(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0x38(%rbp), %rdx
callq 0x2130
movq %rbx, (%r14,%r13,8)
movq -0xf8(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0xf8(%rbp), %rdx
callq 0x2130
movq -0x58(%rbp), %rax
movq %rbx, (%rax,%r13,8)
movq -0x70(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0x70(%rbp), %rdx
callq 0x2130
movq -0x68(%rbp), %rax
movq %rbx, (%rax,%r13,8)
movq -0xa0(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0xa0(%rbp), %rdx
callq 0x2130
movq -0xb8(%rbp), %rax
movq %rbx, (%rax,%r13,8)
movq -0x158(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0x158(%rbp), %rdx
callq 0x2130
movq -0xb0(%rbp), %rax
movq %rbx, (%rax,%r13,8)
movq -0x150(%rbp), %rdi
callq 0x2030
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movq -0x150(%rbp), %rdx
callq 0x2130
movq -0xa8(%rbp), %rax
movq %rbx, (%rax,%r13,8)
incq %r13
cmpq %r13, -0x1b8(%rbp)
jne 0x3347
cmpl $0x0, -0x108(%rbp)
jle 0x34bf
movq -0x108(%rbp), %rax
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movq %rax, -0x38(%rbp)
movl -0x2c(%rbp), %eax
xorl %r13d, %r13d
testl %eax, %eax
jle 0x34b6
xorl %ebx, %ebx
movslq (%r15,%rbx,4), %rcx
cmpq $-0x1, %rcx
je 0x349f
movq -0x180(%rbp), %rax
leaq (%rcx,%rcx,2), %rcx
movq (%rax,%rcx,8), %rax
movsd (%rax,%r13,8), %xmm0
addsd 0x4b84(%rip), %xmm0     # 0x8010
callq 0x23a0
movq (%r14,%r13,8), %rax
movsd %xmm0, (%rax,%rbx,8)
movl -0x2c(%rbp), %eax
jmp 0x34ab
movq (%r14,%r13,8), %rcx
movq $0x0, (%rcx,%rbx,8)
incq %rbx
movslq %eax, %rcx
cmpq %rcx, %rbx
jl 0x3465
incq %r13
cmpq -0x38(%rbp), %r13
jne 0x345f
leaq -0x470(%rbp), %rbx
leaq -0x570(%rbp), %rsi
movq %rbx, %rdi
callq 0x21c0
movq %rbx, %rdi
callq 0x2100
movabsq $0x742e686374616d2e, %rcx # imm = 0x742E686374616D2E
movq %rcx, -0x470(%rbp,%rax)
movl $0x747874, -0x469(%rbp,%rax) # imm = 0x747874
leaq -0x208(%rbp), %rdi
leaq -0x1b0(%rbp), %rsi
callq 0x3b86
movq -0x108(%rbp), %r13
movl -0x2c(%rbp), %r8d
leaq -0x208(%rbp), %rsi
leaq -0x470(%rbp), %rcx
movq %r14, %r15
movq %r14, %rdi
movq -0x80(%rbp), %rdx
movl %r13d, %r9d
callq 0x46a5
leaq -0x208(%rbp), %rdi
callq 0x3c14
testl %r13d, %r13d
jle 0x3570
movl %r13d, %ebx
andl $0x7fffffff, %ebx       # imm = 0x7FFFFFFF
xorl %r14d, %r14d
movq (%r15,%r14,8), %rdi
movl -0x2c(%rbp), %edx
movq -0x118(%rbp), %rsi
callq 0x4e8a
incq %r14
cmpq %r14, %rbx
jne 0x3555
movl -0x2c(%rbp), %ecx
movq %r15, %r14
movq %r15, %rdi
movq -0x148(%rbp), %rsi
movq -0x140(%rbp), %rdx
movl %r13d, %r8d
callq 0x4fdc
movl -0x2c(%rbp), %ecx
movl -0xfc(%rbp), %r8d
movq %r14, %rdi
movq -0x58(%rbp), %rsi
movq -0x110(%rbp), %rdx
movl %r13d, %r9d
callq 0x5098
movl -0x40(%rbp), %r8d
movl -0x3c(%rbp), %r9d
cmpl $0x0, -0x84(%rbp)
je 0x35f6
subq $0x8, %rsp
movq -0x58(%rbp), %rdi
movq -0x68(%rbp), %rsi
movq -0x98(%rbp), %rdx
movq -0x90(%rbp), %rcx
pushq %r13
callq 0x57cb
addq $0x10, %rsp
movl $0x27, %edx
leaq 0x4e01(%rip), %rsi      # 0x83f2
jmp 0x36e7
subq $0x8, %rsp
movq -0x58(%rbp), %rdi
movq -0x68(%rbp), %rsi
movq -0x98(%rbp), %rdx
movq -0x90(%rbp), %rcx
pushq %r13
callq 0x57cb
addq $0x10, %rsp
movl -0x40(%rbp), %r8d
movl -0x50(%rbp), %r9d
subq $0x8, %rsp
movq -0x58(%rbp), %rdi
movq -0xb8(%rbp), %rsi
movq -0xe0(%rbp), %rdx
movq -0xc8(%rbp), %rcx
pushq %r13
callq 0x57cb
addq $0x10, %rsp
movl -0x40(%rbp), %r8d
movl -0x4c(%rbp), %r9d
subq $0x8, %rsp
movq -0x58(%rbp), %rdi
movq -0xb0(%rbp), %rsi
movq -0xd8(%rbp), %rdx
movq -0xc0(%rbp), %rcx
pushq %r13
callq 0x57cb
addq $0x10, %rsp
movl -0x40(%rbp), %r8d
movl -0x60(%rbp), %r9d
subq $0x8, %rsp
movq -0x58(%rbp), %rdi
movq -0xa8(%rbp), %rsi
movq -0xd0(%rbp), %rdx
movq -0x48(%rbp), %rcx
pushq %r13
callq 0x57cb
addq $0x10, %rsp
movl -0x3c(%rbp), %eax
movq -0x68(%rbp), %rdi
movq -0xb8(%rbp), %rsi
movq -0xb0(%rbp), %rdx
movq -0xa8(%rbp), %rcx
movq -0x78(%rbp), %r8
movq -0xf0(%rbp), %r9
pushq %r13
pushq %rax
callq 0x5857
addq $0x10, %rsp
movl $0x20, %edx
leaq 0x4cea(%rip), %rsi      # 0x83d1
movq 0x88ea(%rip), %rdi      # 0xbfd8
callq 0x2230
movq 0x88de(%rip), %rdi      # 0xbfd8
callq 0x2110
movl -0x3c(%rbp), %ecx
movq -0x68(%rbp), %rdi
movq -0x138(%rbp), %rsi
movq -0x130(%rbp), %rdx
movl %r13d, %r8d
callq 0x5052
movq 0x88b5(%rip), %rdi      # 0xbfd8
leaq 0x4cf0(%rip), %rsi      # 0x841a
movl $0x16, %edx
callq 0x2230
movq 0x889d(%rip), %rdi      # 0xbfd8
callq 0x2110
leaq -0x1f0(%rbp), %rdi
leaq -0x1b0(%rbp), %rsi
callq 0x3b86
movl -0x124(%rbp), %r8d
movl -0x3c(%rbp), %r9d
subq $0x8, %rsp
leaq -0x1f0(%rbp), %rdx
leaq -0x670(%rbp), %rcx
movq -0x68(%rbp), %rdi
movq -0xe8(%rbp), %rsi
movsd -0x120(%rbp), %xmm0
pushq -0x160(%rbp)
pushq %r12
pushq %r13
callq 0x5941
addq $0x20, %rsp
movl %eax, %ebx
leaq -0x1f0(%rbp), %rdi
callq 0x3c14
testl %ebx, %ebx
jne 0x3a8e
leaq -0x270(%rbp), %rdi
leaq -0x1b0(%rbp), %rsi
callq 0x3c6c
leaq -0x270(%rbp), %rdi
callq 0x414c
leaq -0x270(%rbp), %rdi
callq 0x3ccc
movq -0x118(%rbp), %rdi
callq 0x2270
movq -0x110(%rbp), %rdi
callq 0x2270
testl %r13d, %r13d
jle 0x387a
andl $0x7fffffff, %r13d      # imm = 0x7FFFFFFF
xorl %ebx, %ebx
movq (%r14,%rbx,8), %rdi
testq %rdi, %rdi
je 0x380f
callq 0x2270
movq -0x58(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3821
callq 0x2270
movq -0x68(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3833
callq 0x2270
movq -0xb8(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3848
callq 0x2270
movq -0xb0(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x385d
callq 0x2270
movq -0xa8(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3872
callq 0x2270
incq %rbx
cmpq %rbx, %r13
jne 0x3801
cmpl $0x0, -0x40(%rbp)
jle 0x393b
xorl %ebx, %ebx
movq -0x98(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x389b
callq 0x2270
movq -0x90(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x38b0
callq 0x2270
movq -0xe0(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x38c5
callq 0x2270
movq -0xd8(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x38da
callq 0x2270
movq -0xd0(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x38ef
callq 0x2270
movq -0xc8(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3904
callq 0x2270
movq -0xc0(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3919
callq 0x2270
movq -0x48(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x392b
callq 0x2270
incq %rbx
movslq -0x40(%rbp), %rax
cmpq %rax, %rbx
jl 0x3886
xorl %ebx, %ebx
movq -0x78(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x394f
callq 0x2270
movq -0xf0(%rbp), %rax
movq (%rax,%rbx,8), %rdi
testq %rdi, %rdi
je 0x3964
callq 0x2270
incq %rbx
cmpq $0x3, %rbx
jne 0x393d
movl -0x2c(%rbp), %eax
testl %eax, %eax
jle 0x3996
xorl %ebx, %ebx
movq -0x80(%rbp), %rcx
movq (%rcx,%rbx,8), %rdi
testq %rdi, %rdi
je 0x398b
callq 0x2270
movl -0x2c(%rbp), %eax
incq %rbx
movslq %eax, %rcx
cmpq %rcx, %rbx
jl 0x3976
movl -0x3c(%rbp), %eax
testl %eax, %eax
jle 0x39c2
xorl %ebx, %ebx
movq -0xe8(%rbp), %rcx
movq (%rcx,%rbx,8), %rdi
testq %rdi, %rdi
je 0x39b7
callq 0x2270
movl -0x3c(%rbp), %eax
incq %rbx
movslq %eax, %rcx
cmpq %rcx, %rbx
jl 0x399f
movq %r14, %rdi
callq 0x2270
movq -0x58(%rbp), %rdi
callq 0x2270
movq -0x68(%rbp), %rdi
callq 0x2270
movq -0xb8(%rbp), %rdi
callq 0x2270
movq -0xb0(%rbp), %rdi
callq 0x2270
movq -0xa8(%rbp), %rdi
callq 0x2270
movq -0x98(%rbp), %rdi
callq 0x2270
movq -0x90(%rbp), %rdi
callq 0x2270
movq -0xe0(%rbp), %rdi
callq 0x2270
movq -0xd8(%rbp), %rdi
callq 0x2270
movq -0xd0(%rbp), %rdi
callq 0x2270
movq -0xc8(%rbp), %rdi
callq 0x2270
movq -0xc0(%rbp), %rdi
callq 0x2270
movq -0x48(%rbp), %rdi
callq 0x2270
movq -0x80(%rbp), %rdi
callq 0x2270
movq -0xe8(%rbp), %rdi
callq 0x2270
movq -0x78(%rbp), %rdi
callq 0x2270
movq -0xf0(%rbp), %rdi
callq 0x2270
movl $0x0, -0x5c(%rbp)
leaq -0x180(%rbp), %rdi
callq 0x3ef0
leaq -0x198(%rbp), %rdi
callq 0x3c14
leaq -0x1b0(%rbp), %rdi
callq 0x3c14
jmp 0x2695
callq 0x2140
movq %rax, %rbx
leaq -0x270(%rbp), %rdi
callq 0x3ccc
jmp 0x3b54
movq %rax, %rbx
leaq -0x1f0(%rbp), %rdi
jmp 0x3ae6
movq %rax, %rbx
leaq -0x208(%rbp), %rdi
callq 0x3c14
jmp 0x3b54
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
movq %rax, %rbx
movq -0x228(%rbp), %rdi
cmpq %r13, %rdi
je 0x3b54
callq 0x21d0
jmp 0x3b54
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
jmp 0x3b51
movq %rax, %rbx
leaq -0x1b0(%rbp), %rdi
callq 0x3ccc
jmp 0x3b65
movq %rax, %rbx
movq -0x1d8(%rbp), %rdi
leaq -0x1c8(%rbp), %rax
cmpq %rax, %rdi
je 0x3b7d
callq 0x21d0
movq %rbx, %rdi
callq 0x2380
nop