// File: /workspace/github_cpp_makefile_star2_O2/logicx24[P]RayTracer/raytracer.cpp
// Function: parseSceneFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, float, int, int)
Scene* parseSceneFile(string fileName, float eps, int width, int height) {
    float sp;
    vec3 eye, ll, lr, ul, ur, ka, kd, ks, kr;

    mat4 currTrans = identity3D();

    Film film = Film(width, height);
    Camera pcam;
    Scene *scene;

    Material curMat;
    vector<Polygon*> sceneObjects;
    vector<Light*> sceneLights;
    vector<vec3> vertices;
    vector<mat4> transforms;
    transforms.push_back(identity3D());

    int index = 0;
    string argument;
    string curline;
    ifstream myfile (fileName);
    if (myfile.is_open()){
        while (getline (myfile, curline)) {
            istringstream iss;
            iss.str(curline);
            iss >> argument;

            if (curline.empty()){
                continue;
            } else if (argumentMatches(argument, "cam")) {
                float args[15];
                parseArgs(args, &iss, 15, "Incorrect number of arguments for camera");
                eye = vec3(args[0], args[1], args[2]);
                ll = vec3(args[3], args[4], args[5]);
                lr = vec3(args[6], args[7], args[8]);
                ul = vec3(args[9], args[10], args[11]);
                ur = vec3(args[12], args[13], args[14]);

                pcam = Camera(eye, ul, ur, ll, lr, width, height);
                scene = new Scene(pcam, film, eps, width, height);

            } else if (argumentMatches(argument, "mat")) {
                float args[13];
                parseArgs(args, &iss, 13, "Incorrect number of arguments for material.");
                ka = vec3(args[0],args[1],args[2]);
                kd = vec3(args[3],args[4],args[5]);
                ks = vec3(args[6],args[7],args[8]);
                sp = args[9];
                kr = vec3(args[10],args[11],args[12]);
                curMat = Material(ka,kd,ks, kr,sp);

            } else if (argumentMatches(argument, "sph")) {
                float args[4];
                parseArgs(args, &iss, 4, "Incorrect number of arguments for sphere.");
                vec3 sphereCenter = vec3(args[0],args[1],args[2]);
                mat4 currentTransform = reduceTransforms(&transforms);
                sceneObjects.push_back(new Sphere(sphereCenter, args[3], curMat, currentTransform));
            } else if (argumentMatches(argument, "tri")) {
                float args[9];
                parseArgs(args, &iss, 9, "Incorrect number of arguments for triangle.");
                vec3 v1 = vec3(args[0],args[1],args[2]);
                vec3 v2 = vec3(args[3],args[4],args[5]);
                vec3 v3 = vec3(args[6],args[7],args[8]);
                mat4 currentTransform = reduceTransforms(&transforms);
                sceneObjects.push_back(new Triangle(v1, v2, v3, curMat, currentTransform));
            } else if (argumentMatches(argument, "ltp")) {
                float args[6];
                int falloff = 0;
                string temp;
                int index = 0;
                while (iss >> temp){
                    if (index == 6){
                        falloff = atoi(temp.c_str());
                    } else {
                        args[index] = atof(temp.c_str());
                    }
                    index++;
                }
                if (index > 7 || index < 6){
                    cerr << "Incorrect number of arguments for point light." << endl;
                }
                vec3 color = vec3(args[3],args[4],args[5]);
                vec3 pos = vec3(args[0],args[1],args[2]);
                sceneLights.push_back(new Light(color, pos, falloff, true));

            } else if (argumentMatches(argument, "ltd")) {
                float args[6];
                parseArgs(args, &iss, 6, "Incorrect number of arguments for direct light.");
                vec3 color = vec3(args[3],args[4],args[5]);
                vec3 pos = vec3(args[0],args[1],args[2]);
                sceneLights.push_back(new Light(color, pos, 0, false));
            } else if (argumentMatches(argument, "lta")) {
                float args[3];
                parseArgs(args, &iss, 3, "Incorrect number of arguments for ambient light.");
                vec3 ambientColor = vec3(args[0], args[1], args[2]);
                Light ambientLight = Light(ambientColor);
                scene->addAmbientLight(ambientLight);
            } else if (argumentMatches(argument, "obj")) {
                string temp;
                iss >> temp;
                parseObj(temp.c_str(), &sceneObjects, &transforms, curMat);
            } else if (argumentMatches(argument, "xfs")) {
                float args[3];
                parseArgs(args, &iss, 3, "Incorrect number of arguments for scaling transformation.");
                vec3 transformation = vec3(args[0], args[1], args[2]);
                transforms.push_back(scaling3D(transformation));
            } else if (argumentMatches(argument, "xft")) {
                float args[3];
                parseArgs(args, &iss, 3, "Incorrect number of arguments for translation transformation.");
                vec3 transformation = vec3(args[0], args[1], args[2]);
                transforms.push_back(translation3D(transformation));
            } else if (argumentMatches(argument, "xfr")) {
                float args[3];
                parseArgs(args, &iss, 3, "Incorrect number of arguments for rotation transformation.");
                vec3 transformation = vec3(args[0], args[1], args[2]);
                transforms.push_back(rotation3D(transformation, magnitude(transformation)));
            } else if (argumentMatches(argument, "xfz")) {
                transforms.clear();
                transforms.push_back(identity3D());
            }
        }

        for (int i = 0; i < sceneObjects.size(); i++){
            scene->addObject(sceneObjects[i]);
        }
        for (int i = 0; i < sceneLights.size(); i++) {
            scene->addLight(sceneLights[i]);
        }

        myfile.close();

    } else {
        cerr << "No scene file found." << endl;
        exit(0);
    }
    return scene;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xad8, %rsp            # imm = 0xAD8
movl %edx, %r15d
movl %esi, %r14d
movss %xmm0, -0x154(%rbp)
movq %rdi, %rbx
leaq -0xaf8(%rbp), %rdi
callq 0x5576
leaq -0x330(%rbp), %rdi
movl %r14d, -0x84(%rbp)
movl %r14d, %esi
movq %r15, -0x178(%rbp)
movl %r15d, %edx
callq 0x5ee6
xorps %xmm0, %xmm0
movaps %xmm0, -0x1d0(%rbp)
movaps %xmm0, -0x1e0(%rbp)
movaps %xmm0, -0x1f0(%rbp)
movaps %xmm0, -0x200(%rbp)
movaps %xmm0, -0x210(%rbp)
movaps %xmm0, -0x220(%rbp)
andl $0x0, -0x1c0(%rbp)
movaps %xmm0, -0x170(%rbp)
andq $0x0, -0x160(%rbp)
movaps %xmm0, -0x190(%rbp)
andq $0x0, -0x180(%rbp)
movaps %xmm0, -0x260(%rbp)
andq $0x0, -0x250(%rbp)
movaps %xmm0, -0x130(%rbp)
andq $0x0, -0x120(%rbp)
leaq -0x8f8(%rbp), %rdi
callq 0x5576
leaq -0x130(%rbp), %rdi
leaq -0x8f8(%rbp), %rsi
callq 0x9476
leaq -0x140(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
xorl %ecx, %ecx
movb %cl, (%rax)
leaq -0x230(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb %cl, (%rax)
leaq -0x8f8(%rbp), %rdi
pushq $0x8
popq %rdx
movq %rbx, %rsi
callq 0x3380
leaq -0x880(%rbp), %rdi
callq 0x30a0
testb %al, %al
je 0x51ca
movl -0x84(%rbp), %eax
movq -0x178(%rbp), %rcx
shlq $0x20, %rcx
orq %rax, %rcx
movq %rcx, -0x198(%rbp)
leaq -0xa78(%rbp), %rbx
leaq -0x6d0(%rbp), %r13
leaq -0x8f8(%rbp), %rdi
leaq -0x240(%rbp), %rsi
callq 0x3060
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x50ef
movq %r13, %r14
movq %rbx, %rdi
callq 0x3180
leaq -0xa68(%rbp), %rdi
leaq -0x240(%rbp), %rsi
callq 0x3330
movq %rbx, %rdi
leaq -0x150(%rbp), %rsi
callq 0x3290
cmpq $0x0, -0x238(%rbp)
je 0x50df
leaq -0x6f0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x6f0(%rbp), %r13
movq %r13, %rdi
leaq 0xed86(%rip), %rsi      # 0x13158
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4567
movq %r14, %r13
movq %r14, %rdi
leaq 0xed64(%rip), %rsi      # 0x1315c
leaq -0x50(%rbp), %rdx
callq 0x5b12
leaq -0x110(%rbp), %rdi
movq %rbx, %rsi
pushq $0xf
popq %rdx
movq %r13, %rcx
callq 0x37b3
movq %r13, %rdi
callq 0x3100
cvtss2sd -0x110(%rbp), %xmm0
cvtss2sd -0x10c(%rbp), %xmm1
cvtss2sd -0x108(%rbp), %xmm2
cvtss2sd -0x104(%rbp), %xmm3
cvtss2sd -0x100(%rbp), %xmm4
cvtss2sd -0xfc(%rbp), %xmm5
cvtss2sd -0xf8(%rbp), %xmm6
cvtss2sd -0xf4(%rbp), %xmm7
cvtss2sd -0xf0(%rbp), %xmm8
cvtss2sd -0xec(%rbp), %xmm9
cvtss2sd -0xe8(%rbp), %xmm10
cvtss2sd -0xe4(%rbp), %xmm11
cvtss2sd -0xe0(%rbp), %xmm12
cvtss2sd -0xdc(%rbp), %xmm13
cvtss2sd -0xd8(%rbp), %xmm14
movsd %xmm0, -0x310(%rbp)
movsd %xmm1, -0x308(%rbp)
movsd %xmm2, -0x300(%rbp)
movsd %xmm9, -0x2f8(%rbp)
movsd %xmm10, -0x2f0(%rbp)
movsd %xmm11, -0x2e8(%rbp)
movsd %xmm12, -0x2e0(%rbp)
movsd %xmm13, -0x2d8(%rbp)
movsd %xmm14, -0x2d0(%rbp)
movsd %xmm3, -0x2c8(%rbp)
movsd %xmm4, -0x2c0(%rbp)
movsd %xmm5, -0x2b8(%rbp)
movsd %xmm6, -0x2b0(%rbp)
movsd %xmm7, -0x2a8(%rbp)
movsd %xmm8, -0x2a0(%rbp)
movq -0x198(%rbp), %rax
movq %rax, -0x298(%rbp)
movl $0x118, %edi            # imm = 0x118
callq 0x31f0
movq %rax, %r12
movq %rax, %rdi
leaq -0x310(%rbp), %rsi
leaq -0x330(%rbp), %rdx
movss -0x154(%rbp), %xmm0
movl -0x84(%rbp), %ecx
movq -0x178(%rbp), %r8
callq 0x5f60
jmp 0x50e2
leaq -0x6b0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x6b0(%rbp), %r13
movq %r13, %rdi
leaq 0xebfa(%rip), %rsi      # 0x13185
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x46bd
leaq -0x690(%rbp), %r15
movq %r15, %rdi
leaq 0xebd4(%rip), %rsi      # 0x13189
leaq -0x50(%rbp), %rdx
callq 0x5b12
leaq -0x110(%rbp), %rdi
movq %rbx, %rsi
pushq $0xd
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x110(%rbp), %xmm0
cvtss2sd -0x10c(%rbp), %xmm1
cvtss2sd -0x108(%rbp), %xmm2
cvtss2sd -0x104(%rbp), %xmm3
cvtss2sd -0x100(%rbp), %xmm4
cvtss2sd -0xfc(%rbp), %xmm5
cvtss2sd -0xf8(%rbp), %xmm6
cvtss2sd -0xf4(%rbp), %xmm7
cvtss2sd -0xf0(%rbp), %xmm8
cvtss2sd -0xe8(%rbp), %xmm9
cvtss2sd -0xe4(%rbp), %xmm10
movss -0xec(%rbp), %xmm11
cvtss2sd -0xe0(%rbp), %xmm12
movsd %xmm0, -0x220(%rbp)
movsd %xmm1, -0x218(%rbp)
movsd %xmm2, -0x210(%rbp)
movsd %xmm3, -0x208(%rbp)
movsd %xmm4, -0x200(%rbp)
movsd %xmm5, -0x1f8(%rbp)
movsd %xmm6, -0x1f0(%rbp)
movsd %xmm7, -0x1e8(%rbp)
movsd %xmm8, -0x1e0(%rbp)
movsd %xmm9, -0x1d8(%rbp)
movsd %xmm10, -0x1d0(%rbp)
movsd %xmm12, -0x1c8(%rbp)
movss %xmm11, -0x1c0(%rbp)
jmp 0x50e2
leaq -0x670(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x670(%rbp), %r13
movq %r13, %rdi
leaq 0xead4(%rip), %rsi      # 0x131b5
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4832
leaq -0x650(%rbp), %r15
movq %r15, %rdi
leaq 0xeaae(%rip), %rsi      # 0x131b9
leaq -0x110(%rbp), %rdx
callq 0x5b12
leaq -0x80(%rbp), %rdi
movq %rbx, %rsi
pushq $0x4
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x80(%rbp), %xmm0
cvtss2sd -0x7c(%rbp), %xmm1
cvtss2sd -0x78(%rbp), %xmm2
movsd %xmm0, -0x50(%rbp)
movsd %xmm1, -0x48(%rbp)
movsd %xmm2, -0x40(%rbp)
leaq -0x110(%rbp), %rdi
leaq -0x130(%rbp), %rsi
callq 0x3920
movl $0x210, %edi            # imm = 0x210
callq 0x31f0
movq %rax, %r15
movss -0x74(%rbp), %xmm0
movups -0x110(%rbp), %xmm1
movups -0x100(%rbp), %xmm2
movups -0xf0(%rbp), %xmm3
movups -0xe0(%rbp), %xmm4
movups %xmm1, -0x430(%rbp)
movups %xmm2, -0x420(%rbp)
movups %xmm3, -0x410(%rbp)
movups %xmm4, -0x400(%rbp)
movups -0xd0(%rbp), %xmm1
movups %xmm1, -0x3f0(%rbp)
movups -0xc0(%rbp), %xmm1
movups %xmm1, -0x3e0(%rbp)
movups -0xb0(%rbp), %xmm1
movups %xmm1, -0x3d0(%rbp)
movsd -0xa0(%rbp), %xmm1
movsd %xmm1, -0x3c0(%rbp)
movsd -0x98(%rbp), %xmm1
movsd %xmm1, -0x3b8(%rbp)
movq %rax, %rdi
leaq -0x50(%rbp), %rsi
leaq -0x220(%rbp), %rdx
leaq -0x430(%rbp), %rcx
callq 0x602e
movq %r15, -0x1b8(%rbp)
leaq -0x170(%rbp), %rdi
leaq -0x1b8(%rbp), %rsi
callq 0x932a
jmp 0x50e2
leaq -0x630(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x630(%rbp), %r13
movq %r13, %rdi
leaq 0xe98d(%rip), %rsi      # 0x131e3
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x49fe
leaq -0x610(%rbp), %r15
movq %r15, %rdi
leaq 0xe967(%rip), %rsi      # 0x131e7
leaq -0x110(%rbp), %rdx
callq 0x5b12
leaq -0x50(%rbp), %rdi
movq %rbx, %rsi
pushq $0x9
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x50(%rbp), %xmm0
cvtss2sd -0x4c(%rbp), %xmm1
cvtss2sd -0x48(%rbp), %xmm2
movsd %xmm0, -0x80(%rbp)
movsd %xmm1, -0x78(%rbp)
movsd %xmm2, -0x70(%rbp)
cvtss2sd -0x44(%rbp), %xmm0
cvtss2sd -0x40(%rbp), %xmm1
cvtss2sd -0x3c(%rbp), %xmm2
movsd %xmm0, -0x1b8(%rbp)
movsd %xmm1, -0x1b0(%rbp)
cvtss2sd -0x38(%rbp), %xmm0
cvtss2sd -0x34(%rbp), %xmm1
cvtss2sd -0x30(%rbp), %xmm3
movsd %xmm2, -0x1a8(%rbp)
movsd %xmm0, -0x290(%rbp)
movsd %xmm1, -0x288(%rbp)
movsd %xmm3, -0x280(%rbp)
leaq -0x110(%rbp), %rdi
leaq -0x130(%rbp), %rsi
callq 0x3920
movl $0x2b8, %edi            # imm = 0x2B8
callq 0x31f0
movq %rax, %r15
movsd -0x110(%rbp), %xmm0
movsd %xmm0, -0x3b0(%rbp)
movups -0x108(%rbp), %xmm0
movups %xmm0, -0x3a8(%rbp)
movups -0xf8(%rbp), %xmm0
movups %xmm0, -0x398(%rbp)
movups -0xe8(%rbp), %xmm0
movups %xmm0, -0x388(%rbp)
movups -0xd8(%rbp), %xmm0
movups %xmm0, -0x378(%rbp)
movups -0xc8(%rbp), %xmm0
movups %xmm0, -0x368(%rbp)
movups -0xb8(%rbp), %xmm0
movups %xmm0, -0x358(%rbp)
movups -0xa8(%rbp), %xmm0
movups %xmm0, -0x348(%rbp)
movsd -0x98(%rbp), %xmm0
movsd %xmm0, -0x338(%rbp)
movq %rax, %rdi
leaq -0x80(%rbp), %rsi
leaq -0x1b8(%rbp), %rdx
leaq -0x290(%rbp), %rcx
leaq -0x220(%rbp), %r8
leaq -0x3b0(%rbp), %r9
callq 0x5de0
movq %r15, -0x1a0(%rbp)
leaq -0x170(%rbp), %rdi
leaq -0x1a0(%rbp), %rsi
callq 0x932a
jmp 0x50e2
leaq -0x5f0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x5f0(%rbp), %r13
movq %r13, %rdi
leaq 0xe7f1(%rip), %rsi      # 0x13213
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4aa7
leaq -0x100(%rbp), %rax
movq %rax, -0x110(%rbp)
andq $0x0, -0x108(%rbp)
movb $0x0, -0x100(%rbp)
xorl %r13d, %r13d
xorl %r15d, %r15d
movq %rbx, %rdi
leaq -0x110(%rbp), %rsi
callq 0x3290
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x4bd0
movq -0x110(%rbp), %rdi
cmpq $0x6, %r13
jne 0x4a92
callq 0x3360
movl %eax, %r15d
jmp 0x4aa2
callq 0x3270
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x50(%rbp,%r13,4)
incq %r13
jmp 0x4a5a
leaq -0x5d0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x5d0(%rbp), %r13
movq %r13, %rdi
leaq 0xe77b(%rip), %rsi      # 0x13246
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4ca4
leaq -0x5b0(%rbp), %r15
movq %r15, %rdi
leaq 0xe755(%rip), %rsi      # 0x1324a
leaq -0x50(%rbp), %rdx
callq 0x5b12
leaq -0x110(%rbp), %rdi
movq %rbx, %rsi
pushq $0x6
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
movss -0x104(%rbp), %xmm0
movss %xmm0, -0x68(%rbp)
movss -0x100(%rbp), %xmm0
movss %xmm0, -0x64(%rbp)
movss -0xfc(%rbp), %xmm0
movss %xmm0, -0x60(%rbp)
movss -0x110(%rbp), %xmm0
movss %xmm0, -0x5c(%rbp)
movss -0x10c(%rbp), %xmm0
movss %xmm0, -0x58(%rbp)
movss -0x108(%rbp), %xmm0
movss %xmm0, -0x54(%rbp)
pushq $0x38
popq %rdi
callq 0x31f0
cvtss2sd -0x54(%rbp), %xmm0
cvtss2sd -0x58(%rbp), %xmm1
cvtss2sd -0x5c(%rbp), %xmm2
cvtss2sd -0x60(%rbp), %xmm3
cvtss2sd -0x64(%rbp), %xmm4
cvtss2sd -0x68(%rbp), %xmm5
movsd %xmm5, (%rax)
movsd %xmm4, 0x8(%rax)
movsd %xmm3, 0x10(%rax)
movsd %xmm2, 0x18(%rax)
movsd %xmm1, 0x20(%rax)
movsd %xmm0, 0x28(%rax)
andl $0x0, 0x30(%rax)
movb $0x0, 0x34(%rax)
movq %rax, -0x50(%rbp)
leaq -0x190(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x96a0
jmp 0x50e2
addl $-0x8, %r13d
cmpl $-0x3, %r13d
ja 0x4bf5
movq 0x1540f(%rip), %rdi     # 0x19ff0
leaq 0xe62f(%rip), %rsi      # 0x13217
callq 0x31d0
movq %rax, %rdi
callq 0x3120
movss -0x44(%rbp), %xmm0
movss %xmm0, -0x68(%rbp)
movss -0x40(%rbp), %xmm0
movss %xmm0, -0x64(%rbp)
movss -0x3c(%rbp), %xmm0
movss %xmm0, -0x60(%rbp)
movss -0x50(%rbp), %xmm0
movss %xmm0, -0x5c(%rbp)
movss -0x4c(%rbp), %xmm0
movss %xmm0, -0x58(%rbp)
movss -0x48(%rbp), %xmm0
movss %xmm0, -0x54(%rbp)
pushq $0x38
popq %rdi
callq 0x31f0
movq %r14, %r13
cvtss2sd -0x54(%rbp), %xmm0
cvtss2sd -0x58(%rbp), %xmm1
cvtss2sd -0x5c(%rbp), %xmm2
cvtss2sd -0x60(%rbp), %xmm3
cvtss2sd -0x64(%rbp), %xmm4
cvtss2sd -0x68(%rbp), %xmm5
movsd %xmm5, (%rax)
movsd %xmm4, 0x8(%rax)
movsd %xmm3, 0x10(%rax)
movsd %xmm2, 0x18(%rax)
movsd %xmm1, 0x20(%rax)
movsd %xmm0, 0x28(%rax)
movl %r15d, 0x30(%rax)
movb $0x1, 0x34(%rax)
movq %rax, -0x80(%rbp)
leaq -0x190(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x96a0
leaq -0x110(%rbp), %rdi
callq 0x3100
jmp 0x50e2
leaq -0x590(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x590(%rbp), %r13
movq %r13, %rdi
leaq 0xe5b2(%rip), %rsi      # 0x1327a
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4d6b
leaq -0x570(%rbp), %r15
movq %r15, %rdi
leaq 0xe58c(%rip), %rsi      # 0x1327e
leaq -0x50(%rbp), %rdx
callq 0x5b12
leaq -0x110(%rbp), %rdi
movq %rbx, %rsi
pushq $0x3
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x110(%rbp), %xmm0
cvtss2sd -0x10c(%rbp), %xmm1
cvtss2sd -0x108(%rbp), %xmm2
movsd %xmm0, 0xd0(%r12)
movsd %xmm1, 0xd8(%r12)
movsd %xmm2, 0xe0(%r12)
xorps %xmm0, %xmm0
movups %xmm0, 0xe8(%r12)
movups %xmm0, 0xf5(%r12)
jmp 0x50e2
leaq -0x550(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x550(%rbp), %r13
movq %r13, %rdi
leaq 0xe520(%rip), %rsi      # 0x132af
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4e17
leaq -0x100(%rbp), %rax
movq %rax, -0x110(%rbp)
andq $0x0, -0x108(%rbp)
movb $0x0, -0x100(%rbp)
movq %rbx, %rdi
leaq -0x110(%rbp), %rsi
callq 0x3290
movq -0x110(%rbp), %rsi
leaq -0x530(%rbp), %r15
movq %r15, %rdi
leaq -0x50(%rbp), %rdx
callq 0x5b12
movq %r14, %r13
movq %r15, %rdi
leaq -0x170(%rbp), %rsi
leaq -0x130(%rbp), %rdx
leaq -0x220(%rbp), %rcx
callq 0x3993
movq %r15, %rdi
callq 0x3100
jmp 0x4c93
leaq -0x510(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x510(%rbp), %r13
movq %r13, %rdi
leaq 0xe478(%rip), %rsi      # 0x132b3
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4ecf
leaq -0x4f0(%rbp), %r15
movq %r15, %rdi
leaq 0xe456(%rip), %rsi      # 0x132b7
leaq -0x110(%rbp), %rdx
callq 0x5b12
leaq -0x80(%rbp), %rdi
movq %rbx, %rsi
pushq $0x3
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x80(%rbp), %xmm0
cvtss2sd -0x7c(%rbp), %xmm1
cvtss2sd -0x78(%rbp), %xmm2
movsd %xmm0, -0x50(%rbp)
movsd %xmm1, -0x48(%rbp)
movsd %xmm2, -0x40(%rbp)
leaq -0x110(%rbp), %r14
movq %r14, %rdi
leaq -0x50(%rbp), %rsi
callq 0x6096
leaq -0x130(%rbp), %rdi
movq %r14, %rsi
callq 0x9476
jmp 0x50e2
leaq -0x4d0(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x4d0(%rbp), %r13
movq %r13, %rdi
leaq 0xe3fe(%rip), %rsi      # 0x132f1
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x4f87
leaq -0x4b0(%rbp), %r15
movq %r15, %rdi
leaq 0xe3dc(%rip), %rsi      # 0x132f5
leaq -0x110(%rbp), %rdx
callq 0x5b12
leaq -0x80(%rbp), %rdi
movq %rbx, %rsi
pushq $0x3
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x80(%rbp), %xmm0
cvtss2sd -0x7c(%rbp), %xmm1
cvtss2sd -0x78(%rbp), %xmm2
movsd %xmm0, -0x50(%rbp)
movsd %xmm1, -0x48(%rbp)
movsd %xmm2, -0x40(%rbp)
leaq -0x110(%rbp), %r14
movq %r14, %rdi
leaq -0x50(%rbp), %rsi
callq 0x611c
leaq -0x130(%rbp), %rdi
movq %r14, %rsi
callq 0x9476
jmp 0x50e2
leaq -0x490(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x490(%rbp), %r13
movq %r13, %rdi
leaq 0xe388(%rip), %rsi      # 0x13333
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x506c
leaq -0x470(%rbp), %r15
movq %r15, %rdi
leaq 0xe362(%rip), %rsi      # 0x13337
leaq -0x110(%rbp), %rdx
callq 0x5b12
leaq -0x50(%rbp), %rdi
movq %rbx, %rsi
pushq $0x3
popq %rdx
movq %r15, %rcx
callq 0x37b3
movq %r14, %r13
movq %r15, %rdi
callq 0x3100
cvtss2sd -0x50(%rbp), %xmm0
cvtss2sd -0x4c(%rbp), %xmm1
cvtss2sd -0x48(%rbp), %xmm2
movsd %xmm0, -0x278(%rbp)
movsd %xmm1, -0x270(%rbp)
movsd %xmm2, -0x268(%rbp)
mulsd %xmm1, %xmm1
mulsd %xmm0, %xmm0
addsd %xmm1, %xmm0
mulsd %xmm2, %xmm2
addsd %xmm0, %xmm2
sqrtsd %xmm2, %xmm0
cvtsd2ss %xmm0, %xmm0
cvtss2sd %xmm0, %xmm0
leaq -0x110(%rbp), %r14
movq %r14, %rdi
leaq -0x278(%rbp), %rsi
callq 0x61a8
leaq -0x130(%rbp), %rdi
movq %r14, %rsi
callq 0x9476
jmp 0x50e2
leaq -0x450(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x32d0
leaq -0x450(%rbp), %r13
movq %r13, %rdi
leaq 0xe2e2(%rip), %rsi      # 0x13372
callq 0x390d
movl %eax, %r15d
movq %r13, %rdi
callq 0x3100
testb %r15b, %r15b
je 0x50df
movq -0x130(%rbp), %rax
cmpq %rax, -0x128(%rbp)
movq %r14, %r13
je 0x50bf
movq %rax, -0x128(%rbp)
leaq -0x110(%rbp), %r14
movq %r14, %rdi
callq 0x5576
leaq -0x130(%rbp), %rdi
movq %r14, %rsi
callq 0x9476
jmp 0x50e2
movq %r14, %r13
movq %rbx, %rdi
callq 0x3110
jmp 0x434e
xorl %ebx, %ebx
movq -0x170(%rbp), %rax
movq -0x168(%rbp), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rbx, %rcx
jbe 0x511c
movq (%rax,%rbx,8), %rsi
movq %r12, %rdi
callq 0x633c
incq %rbx
jmp 0x50f1
xorl %ebx, %ebx
movq -0x190(%rbp), %rax
movq -0x188(%rbp), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
cmpq %rbx, %rcx
jbe 0x5149
movq (%rax,%rbx,8), %rsi
movq %r12, %rdi
callq 0x6360
incq %rbx
jmp 0x511e
leaq -0x8f8(%rbp), %rdi
callq 0x3070
leaq -0x8f8(%rbp), %rdi
callq 0x30b0
leaq -0x240(%rbp), %rdi
callq 0x3100
leaq -0x150(%rbp), %rdi
callq 0x3100
leaq -0x130(%rbp), %rdi
callq 0x9438
leaq -0x260(%rbp), %rdi
callq 0x8f06
leaq -0x190(%rbp), %rdi
callq 0x9138
leaq -0x170(%rbp), %rdi
callq 0x9116
leaq -0x328(%rbp), %rdi
callq 0x8f06
movq %r12, %rax
addq $0xad8, %rsp            # imm = 0xAD8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x14e1f(%rip), %rdi     # 0x19ff0
leaq 0xe19e(%rip), %rsi      # 0x13376
callq 0x31d0
movq %rax, %rdi
callq 0x3120
xorl %edi, %edi
callq 0x3260
jmp 0x532d
jmp 0x532d
movq %rax, %rbx
leaq -0x470(%rbp), %rdi
jmp 0x531b
jmp 0x532d
movq %rax, %rbx
leaq -0x4b0(%rbp), %rdi
jmp 0x531b
jmp 0x532d
jmp 0x532d
jmp 0x532d
movq %rax, %rbx
leaq -0x4f0(%rbp), %rdi
jmp 0x531b
movq %rax, %rbx
leaq -0x530(%rbp), %rdi
callq 0x3100
jmp 0x5314
jmp 0x532d
jmp 0x5311
jmp 0x5311
jmp 0x532d
movq %rax, %rbx
leaq -0x570(%rbp), %rdi
jmp 0x531b
movq %rax, %rbx
leaq -0x5b0(%rbp), %rdi
jmp 0x531b
jmp 0x532d
jmp 0x5311
jmp 0x532d
movq %rax, %rbx
jmp 0x5348
jmp 0x532d
movq %rax, %rbx
movl $0x2b8, %esi            # imm = 0x2B8
jmp 0x52cc
jmp 0x532d
jmp 0x5311
movq %rax, %rbx
leaq -0x610(%rbp), %rdi
jmp 0x531b
jmp 0x5328
movq %rax, %rbx
jmp 0x5360
jmp 0x532d
jmp 0x532d
movq %rax, %rbx
movl $0x210, %esi            # imm = 0x210
movq %r15, %rdi
jmp 0x52fa
movq %rax, %rbx
leaq -0x650(%rbp), %rdi
jmp 0x531b
jmp 0x532d
jmp 0x532d
movq %rax, %rbx
leaq -0x690(%rbp), %rdi
jmp 0x531b
jmp 0x532d
movq %rax, %rbx
movl $0x118, %esi            # imm = 0x118
movq %r12, %rdi
callq 0x3200
jmp 0x5330
jmp 0x532d
jmp 0x532d
movq %rax, %rbx
leaq -0x6d0(%rbp), %rdi
jmp 0x531b
movq %rax, %rbx
leaq -0x110(%rbp), %rdi
callq 0x3100
jmp 0x5330
jmp 0x5328
jmp 0x5328
jmp 0x5328
movq %rax, %rbx
jmp 0x533c
movq %rax, %rbx
leaq -0xa78(%rbp), %rdi
callq 0x3110
leaq -0x8f8(%rbp), %rdi
callq 0x30b0
leaq -0x240(%rbp), %rdi
callq 0x3100
leaq -0x150(%rbp), %rdi
callq 0x3100
leaq -0x130(%rbp), %rdi
callq 0x9438
leaq -0x260(%rbp), %rdi
callq 0x8f06
leaq -0x190(%rbp), %rdi
callq 0x9138
leaq -0x170(%rbp), %rdi
callq 0x9116
leaq -0x328(%rbp), %rdi
callq 0x8f06
movq %rbx, %rdi
callq 0x33f0