LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/Moving.cpp
// Function: MyMoving::Move(Traal, Poter&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>>&)
Point MyMoving::Move(Traal monster, Poter &poter, vector<vector<int>> &maze){
    vector<Point> possibleMoveSet;


    Point p = monster.getPoint();
    mvaddch(p.getY(),p.getX(),' ');

    possibleMoveSet = get_possible_moveset(p,maze);

    possibleMoveSet.push_back(p);

    p = getShortestEuclidean(poter,possibleMoveSet);

    mvaddch(p.getY(),p.getX(),'T');


    return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rcx, %r15
movq %rdx, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, -0x40(%rbp)
movq $0x0, -0x30(%rbp)
callq 0x57e0
movq 0x4585(%rip), %rax      # 0x9fd0
movq (%rax), %r12
movq %rbx, %rdi
callq 0x571c
movl %eax, %r13d
movq %rbx, %rdi
callq 0x5708
movq %r12, %rdi
movl %r13d, %esi
movl %eax, %edx
callq 0x3250
cmpl $-0x1, %eax
je 0x5a87
movq 0x4556(%rip), %rax      # 0x9fd0
movq (%rax), %rdi
movl $0x20, %esi
callq 0x3090
leaq -0x78(%rbp), %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x5b96
xorps %xmm0, %xmm0
leaq -0x60(%rbp), %rdi
movaps %xmm0, (%rdi)
leaq -0x40(%rbp), %r15
movaps (%r15), %xmm0
movq 0x10(%r15), %rax
leaq -0x78(%rbp), %r12
movups (%r12), %xmm1
movaps %xmm1, (%r15)
movq 0x10(%r12), %rcx
movq %rcx, 0x10(%r15)
movaps (%rdi), %xmm1
movaps %xmm0, (%rdi)
movq %rax, 0x10(%rdi)
movups %xmm1, (%r12)
movq $0x0, 0x10(%r12)
callq 0x4aa4
movq %r12, %rdi
callq 0x4aa4
movq %r15, %rdi
movq %rbx, %rsi
callq 0x49ba
leaq -0x60(%rbp), %rdi
leaq -0x40(%rbp), %rdx
movq %r14, %rsi
callq 0x5d1e
leaq -0x60(%rbp), %rdi
movq 0x8(%rdi), %rax
movq %rax, 0x8(%rbx)
callq 0x583c
movq 0x44b6(%rip), %rax      # 0x9fd0
movq (%rax), %r14
movq %rbx, %rdi
callq 0x571c
movl %eax, %r15d
movq %rbx, %rdi
callq 0x5708
movq %r14, %rdi
movl %r15d, %esi
movl %eax, %edx
callq 0x3250
cmpl $-0x1, %eax
je 0x5b56
movq 0x4487(%rip), %rax      # 0x9fd0
movq (%rax), %rdi
movl $0x54, %esi
callq 0x3090
leaq -0x40(%rbp), %rdi
callq 0x4aa4
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5b7a
jmp 0x5b7a
movq %rax, %r14
jmp 0x5b85
movq %rax, %r14
movq %rbx, %rdi
callq 0x583c
leaq -0x40(%rbp), %rdi
callq 0x4aa4
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/Moving.cpp
// Function: MyMoving::get_possible_moveset(Point const&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)
vector<Point> MyMoving :: get_possible_moveset(const Point &p, const vector<vector<int>> &maze){
    vector<Point> possibleMoveSet;

    int y = p.getY();
    int x = p.getX();

    if(maze[y+1][x] == DIADROMOS || maze[y+1][x] == POTERAKOS ) {

        Point p1(x,y+1);
        possibleMoveSet.push_back(p1);
    }

    if(maze[y-1][x] == DIADROMOS || maze[y-1][x] == POTERAKOS) {
        Point p1(x,y-1);
        possibleMoveSet.push_back(p1);
    }

    if(maze[y][x+1] == DIADROMOS || maze[y][x+1] == POTERAKOS) {
        Point p1(x+1,y);
        possibleMoveSet.push_back(p1);
    }

    if(maze[y][x-1] == DIADROMOS || maze[y][x-1] == POTERAKOS) {
        Point p1(x-1,y);
        possibleMoveSet.push_back(p1);
    }


    return possibleMoveSet;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq %rsi, %rdi
movq %rbx, -0x40(%rbp)
callq 0x571c
movl %eax, %r14d
movq %r12, %rdi
callq 0x5708
movl %eax, %r12d
leal 0x1(%r14), %edx
movslq %edx, %rax
movq (%r15), %rcx
leaq (%rax,%rax,2), %rax
movslq %r12d, %r13
movq (%rcx,%rax,8), %rax
movl (%rax,%r13,4), %eax
andl $-0x2, %eax
cmpl $0x2, %eax
jne 0x5c1a
leaq -0x38(%rbp), %rdi
movl %r12d, %esi
callq 0x5826
leaq -0x38(%rbp), %rsi
movq %rbx, %rdi
callq 0x49ba
leaq -0x38(%rbp), %rdi
callq 0x583c
leal -0x1(%r14), %edx
movslq %edx, %rax
movq (%r15), %rcx
leaq (%rax,%rax,2), %rax
movq (%rcx,%rax,8), %rax
movl (%rax,%r13,4), %eax
andl $-0x2, %eax
cmpl $0x2, %eax
jne 0x5c59
leaq -0x38(%rbp), %rdi
movl %r12d, %esi
callq 0x5826
leaq -0x38(%rbp), %rsi
movq %rbx, %rdi
callq 0x49ba
leaq -0x38(%rbp), %rdi
callq 0x583c
movslq %r14d, %rax
movq (%r15), %rcx
leaq (%rax,%rax,2), %rbx
movq (%rcx,%rbx,8), %rax
movl 0x4(%rax,%r13,4), %eax
andl $-0x2, %eax
cmpl $0x2, %eax
jne 0x5c9b
leal 0x1(%r12), %esi
leaq -0x38(%rbp), %rdi
movl %r14d, %edx
callq 0x5826
leaq -0x38(%rbp), %rsi
movq -0x40(%rbp), %rdi
callq 0x49ba
leaq -0x38(%rbp), %rdi
callq 0x583c
movq (%r15), %rax
movq (%rax,%rbx,8), %rax
movl -0x4(%rax,%r13,4), %eax
andl $-0x2, %eax
cmpl $0x2, %eax
movq -0x40(%rbp), %rbx
jne 0x5cda
decl %r12d
leaq -0x38(%rbp), %rdi
movl %r12d, %esi
movl %r14d, %edx
callq 0x5826
leaq -0x38(%rbp), %rsi
movq %rbx, %rdi
callq 0x49ba
leaq -0x38(%rbp), %rdi
callq 0x583c
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5cf8
jmp 0x5d0a
jmp 0x5cf8
jmp 0x5d0a
jmp 0x5cf8
jmp 0x5d0a
movq %rax, %r14
leaq -0x38(%rbp), %rdi
callq 0x583c
jmp 0x5d0d
jmp 0x5d0a
jmp 0x5d0a
movq %rax, %r14
movq -0x40(%rbp), %rdi
callq 0x4aa4
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/Moving.cpp
// Function: MyMoving::getShortestEuclidean(Poter&, std::vector<Point, std::allocator<Point>> const&)
Point MyMoving::getShortestEuclidean(Poter &poter, const vector<Point> &possibleMoveSet) {
    int flag_first = 0;
    Point p(0,0);
    float min_euclidean = 0.0;
    for(Point points:possibleMoveSet){
        if(flag_first == 0){
            flag_first = 1;
            p.setY(points.getY());
            p.setX(points.getX());
            min_euclidean = points.euclidean(poter.getPoint());
        }
        else{
            float temp = points.euclidean(poter.getPoint());
            if(temp<min_euclidean){
                p.setY(points.getY());
                p.setX(points.getX());
            }
        }
    }

    return p;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, %r15
movq %rsi, -0x38(%rbp)
movq %rdi, %rbx
xorl %esi, %esi
xorl %edx, %edx
callq 0x5826
movq (%r15), %r13
movq 0x8(%r15), %rax
movq %rax, -0x40(%rbp)
cmpq %rax, %r13
je 0x5e38
xorps %xmm0, %xmm0
movss %xmm0, -0x2c(%rbp)
movb $0x1, %al
leaq 0x3ef9(%rip), %r14      # 0x9c60
addq $0x10, %r14
leaq -0x50(%rbp), %r15
leaq -0x60(%rbp), %r12
movq %r14, -0x50(%rbp)
movq 0x8(%r13), %rcx
movq %rcx, -0x48(%rbp)
testb $0x1, %al
je 0x5dcd
movq %r15, %rdi
callq 0x571c
movq %rbx, %rdi
movl %eax, %esi
callq 0x5712
movq %r15, %rdi
callq 0x5708
movq %rbx, %rdi
movl %eax, %esi
callq 0x56fe
movq %r12, %rdi
movq -0x38(%rbp), %rsi
callq 0x57e0
movq %r15, %rdi
movq %r12, %rsi
callq 0x56b4
movss %xmm0, -0x2c(%rbp)
movq %r12, %rdi
callq 0x583c
jmp 0x5e20
movq %r12, %rdi
movq -0x38(%rbp), %rsi
callq 0x57e0
movq %r15, %rdi
movq %r12, %rsi
callq 0x56b4
movss %xmm0, -0x30(%rbp)
movq %r12, %rdi
callq 0x583c
movss -0x2c(%rbp), %xmm0
ucomiss -0x30(%rbp), %xmm0
jbe 0x5e20
movq %r15, %rdi
callq 0x571c
movq %rbx, %rdi
movl %eax, %esi
callq 0x5712
movq %r15, %rdi
callq 0x5708
movq %rbx, %rdi
movl %eax, %esi
callq 0x56fe
movq %r15, %rdi
callq 0x583c
addq $0x10, %r13
xorl %eax, %eax
cmpq -0x40(%rbp), %r13
jne 0x5d73
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5e60
jmp 0x5e60
jmp 0x5e50
movq %rax, %r14
leaq -0x60(%rbp), %rdi
callq 0x583c
jmp 0x5e63
jmp 0x5e60
movq %rax, %r14
leaq -0x50(%rbp), %rdi
callq 0x583c
movq %rbx, %rdi
callq 0x583c
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/Moving.cpp
// Function: MyMoving::Move(Goblin&, Poter&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>> const&)
Point MyMoving::Move(Goblin &goblin, Poter &poter, const vector<vector<int>> &maze) {
    vector<Point> possibleMoveSet;


    Point p = goblin.getPoint();
    mvaddch(p.getY(),p.getX(),' ');

    possibleMoveSet = get_possible_moveset(p,maze);

    possibleMoveSet.push_back(p);

    p = getShortestEuclidean(poter,possibleMoveSet);

    mvaddch(p.getY(),p.getX(),'G');


    return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rcx, %r15
movq %rdx, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, -0x40(%rbp)
movq $0x0, -0x30(%rbp)
callq 0x57e0
movq 0x411f(%rip), %rax      # 0x9fd0
movq (%rax), %r12
movq %rbx, %rdi
callq 0x571c
movl %eax, %r13d
movq %rbx, %rdi
callq 0x5708
movq %r12, %rdi
movl %r13d, %esi
movl %eax, %edx
callq 0x3250
cmpl $-0x1, %eax
je 0x5eed
movq 0x40f0(%rip), %rax      # 0x9fd0
movq (%rax), %rdi
movl $0x20, %esi
callq 0x3090
leaq -0x78(%rbp), %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x5b96
xorps %xmm0, %xmm0
leaq -0x60(%rbp), %rdi
movaps %xmm0, (%rdi)
leaq -0x40(%rbp), %r15
movaps (%r15), %xmm0
movq 0x10(%r15), %rax
leaq -0x78(%rbp), %r12
movups (%r12), %xmm1
movaps %xmm1, (%r15)
movq 0x10(%r12), %rcx
movq %rcx, 0x10(%r15)
movaps (%rdi), %xmm1
movaps %xmm0, (%rdi)
movq %rax, 0x10(%rdi)
movups %xmm1, (%r12)
movq $0x0, 0x10(%r12)
callq 0x4aa4
movq %r12, %rdi
callq 0x4aa4
movq %r15, %rdi
movq %rbx, %rsi
callq 0x49ba
leaq -0x60(%rbp), %rdi
leaq -0x40(%rbp), %rdx
movq %r14, %rsi
callq 0x5d1e
leaq -0x60(%rbp), %rdi
movq 0x8(%rdi), %rax
movq %rax, 0x8(%rbx)
callq 0x583c
movq 0x4050(%rip), %rax      # 0x9fd0
movq (%rax), %r14
movq %rbx, %rdi
callq 0x571c
movl %eax, %r15d
movq %rbx, %rdi
callq 0x5708
movq %r14, %rdi
movl %r15d, %esi
movl %eax, %edx
callq 0x3250
cmpl $-0x1, %eax
je 0x5fbc
movq 0x4021(%rip), %rax      # 0x9fd0
movq (%rax), %rdi
movl $0x47, %esi
callq 0x3090
leaq -0x40(%rbp), %rdi
callq 0x4aa4
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5fe0
jmp 0x5fe0
movq %rax, %r14
jmp 0x5feb
movq %rax, %r14
movq %rbx, %rdi
callq 0x583c
leaq -0x40(%rbp), %rdi
callq 0x4aa4
movq %r14, %rdi
callq 0x33f0
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/Gem.cpp
// Function: Gem::setPoint(std::vector<Point, std::allocator<Point>>&)
void Gem::setPoint(vector<Point> &startingPoints) {
    srand(time(nullptr));

    int size = (int) startingPoints.size();
    int rand_int = rand()%size;

    this->inMap.setX(startingPoints[rand_int].getX());
    this->inMap.setY(startingPoints[rand_int].getY());


    startingPoints.erase(startingPoints.begin()+0);


}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
xorl %edi, %edi
callq 0x3200
movl %eax, %edi
callq 0x3210
movq 0x8(%rbx), %r15
subq (%rbx), %r15
shrq $0x4, %r15
callq 0x3070
cltd
idivl %r15d
movslq %edx, %r15
shlq $0x4, %r15
movq (%rbx), %rdi
addq %r15, %rdi
callq 0x5708
movq %r14, %rdi
movl %eax, %esi
callq 0x56fe
addq (%rbx), %r15
movq %r15, %rdi
callq 0x571c
movq %r14, %rdi
movl %eax, %esi
callq 0x5712
movq (%rbx), %rsi
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x59b4
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/HighScore.cpp
// Function: HighScore::save(std::basic_ofstream<char, std::char_traits<char>>&)
void HighScore::save(ofstream &of) {
    for(int i=0;i<5;i++){
        if(score[i]!=-1){
            name[i].save(of);
            string str = to_string(score[i]);
            char *writeable = new char[str.size() + 1];
            copy(str.begin(),str.end(),writeable);
            writeable[str.size()] = '\0';
            of.write(writeable,sizeof(int));

        }
    }

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq %rdi, %r14
xorl %r15d, %r15d
movq %rsi, -0x50(%rbp)
cmpl $-0x1, 0x34(%r14,%r15,4)
je 0x642b
leaq (%r15,%r15,4), %rax
leaq (%r14,%rax,2), %rsi
movl $0xa, %edx
movq %rbx, %rdi
callq 0x32f0
movl 0x34(%r14,%r15,4), %ebx
movl %ebx, %r12d
negl %r12d
cmovsl %ebx, %r12d
movl $0x1, %r13d
cmpl $0xa, %r12d
jb 0x63a3
movl $0x4, %r13d
movl %r12d, %eax
movl $0xd1b71759, %edx       # imm = 0xD1B71759
cmpl $0x63, %eax
jbe 0x639a
cmpl $0x3e7, %eax            # imm = 0x3E7
jbe 0x63a0
cmpl $0x2710, %eax           # imm = 0x2710
jb 0x63a3
movl %eax, %ecx
imulq %rdx, %rcx
shrq $0x2d, %rcx
addl $0x4, %r13d
cmpl $0x1869f, %eax          # imm = 0x1869F
movl %ecx, %eax
ja 0x636a
addl $-0x3, %r13d
jmp 0x63a3
addl $-0x2, %r13d
jmp 0x63a3
decl %r13d
shrl $0x1f, %ebx
movl %ebx, %esi
addl %r13d, %esi
leaq -0x38(%rbp), %rax
movq %rax, -0x48(%rbp)
leaq -0x48(%rbp), %rdi
movl $0x2d, %edx
callq 0x32a0
movq -0x48(%rbp), %rdi
addq %rbx, %rdi
movl %r13d, %esi
movl %r12d, %edx
callq 0x6b5d
movq -0x40(%rbp), %r12
leaq 0x1(%r12), %rdi
callq 0x3030
movq -0x50(%rbp), %rbx
movq %rax, %r13
testq %r12, %r12
je 0x63fc
movq -0x48(%rbp), %rsi
movq %r13, %rdi
movq %r12, %rdx
callq 0x3380
movb $0x0, (%r13,%r12)
movl $0x4, %edx
movq %rbx, %rdi
movq %r13, %rsi
callq 0x32f0
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0x642b
movq -0x38(%rbp), %rsi
incq %rsi
callq 0x3240
incq %r15
cmpq $0x5, %r15
jne 0x6320
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0x6463
movq -0x38(%rbp), %rsi
incq %rsi
callq 0x3240
movq %rbx, %rdi
callq 0x33f0
nop
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/HighScore.cpp
// Function: HighScore::load(std::basic_ifstream<char, std::char_traits<char>>&)
void HighScore::load(ifstream &inf) {
    int i=0;
    while (inf.eof()){
        name[i].load(inf);
        char *val = nullptr;
        inf.read(val,sizeof(int));
        this->score[i] = atoi(val);
        i++;
    }

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq (%rsi), %rax
movq -0x18(%rax), %rax
testb $0x2, 0x20(%rsi,%rax)
je 0x64cd
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x34(%rdi), %r15
movl $0xa, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x32e0
movl $0x4, %edx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x32e0
xorl %edi, %edi
callq 0x3360
movl %eax, (%r15)
movq (%rbx), %rax
movq -0x18(%rax), %rax
addq $0x4, %r15
addq $0xa, %r14
testb $0x2, 0x20(%rbx,%rax)
jne 0x648e
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/HighScore.cpp
// Function: HighScore::operator<<(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
HighScore &HighScore::operator<<(string myname) {
    for(int i=0;i<4;i++){
        name[i+1] = name[i];
    }

    name[0].setname(std::move(myname));
    return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
xorl %eax, %eax
movzwl 0x8(%rbx,%rax), %ecx
movw %cx, 0x12(%rbx,%rax)
movq (%rbx,%rax), %rcx
movq %rcx, 0xa(%rbx,%rax)
addq $0xa, %rax
cmpq $0x28, %rax
jne 0x64e6
leaq -0x18(%rbp), %rax
movq %rax, -0x10(%rax)
movq (%rsi), %rdx
leaq 0x10(%rsi), %rcx
cmpq %rcx, %rdx
je 0x6524
movq %rdx, -0x28(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x18(%rbp)
jmp 0x652a
movups (%rcx), %xmm0
movups %xmm0, (%rax)
movq 0x8(%rsi), %rdx
movq %rdx, -0x20(%rbp)
movq %rcx, (%rsi)
xorl %ecx, %ecx
movq %rcx, 0x8(%rsi)
movb $0x0, 0x10(%rsi)
movslq %edx, %rdx
movq -0x28(%rbp), %rsi
testq %rdx, %rdx
cmovleq %rcx, %rdx
cmpq %rcx, %rdx
je 0x6563
movb (%rsi,%rcx), %dil
movb %dil, (%rbx,%rcx)
incq %rcx
cmpq $0xa, %rcx
jne 0x654d
movq -0x28(%rbp), %rdi
cmpq %rax, %rdi
je 0x6578
movq -0x18(%rbp), %rsi
incq %rsi
callq 0x3240
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/Teris45[P]Maze-Game/HighScore.cpp
// Function: HighScore::operator<<(int)
HighScore &HighScore::operator<<(int myscore) {
    for(int i=0;i<4;i++){
        score[i+1] = score[i];
    }
    score[0] = myscore;
    return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
movl 0x34(%rdi), %ecx
movl $0xe, %edx
movl %ecx, (%rax,%rdx,4)
incq %rdx
cmpq $0x12, %rdx
jne 0x6591
movl %esi, 0x34(%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/tests/test_mymodel.cpp
// Function: test_mymodel()
void test_mymodel() {
	float* input = (float*)malloc(sizeof(float) * 1 * 3 * 224 * 224);
	LoadFromFile("../models/my_testmodel/input.dat", (char*)input);

	Model model;
	float* output;
	output = model.Run(input);

	int out_shape[4];
	unsigned long size;
	model.GetOutputShape(out_shape);
	// size = out_shape[0] * out_shape[1] * out_shape[2] * out_shape[3];
	size = out_shape[0] * out_shape[1];
	SaveToFile("../outputs/my_testmodel/output.dat", (char*)output, size * sizeof(float));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movl $0x93000, %edi          # imm = 0x93000
callq 0x2240
movq %rax, %rbx
leaq 0x3a09(%rip), %rdi      # 0x6004
movq %rax, %rsi
xorl %edx, %edx
callq 0x45c0
leaq -0x50(%rbp), %r14
movq %r14, %rdi
callq 0x267a
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2960
movq -0x30(%rbp), %rcx
movq 0xc(%rcx), %rcx
movq %rcx, %rdx
shrq $0x20, %rdx
imull %ecx, %edx
movslq %edx, %rdx
shlq $0x2, %rdx
leaq 0x39e9(%rip), %rdi      # 0x6025
movq %rax, %rsi
callq 0x4c90
leaq -0x50(%rbp), %rdi
callq 0x2b60
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
jmp 0x2658
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x2b60
movq %rbx, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/tests/test_mymodel.cpp
// Function: Model::~Model()
~Model() {
		delete conv1, conv2, conv3;
		delete fc1, fc2;
		delete elt;
		delete cat;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %r14
testq %r14, %r14
je 0x2b87
movq %r14, %rdi
callq 0x2be0
movl $0x80, %esi
movq %r14, %rdi
callq 0x21b0
movq 0x18(%rbx), %r14
testq %r14, %r14
je 0x2ba5
movq %r14, %rdi
callq 0x2c0e
movl $0x30, %esi
movq %r14, %rdi
callq 0x21b0
movq 0x30(%rbx), %rdi
testq %rdi, %rdi
je 0x2bb8
movl $0x48, %esi
callq 0x21b0
movq 0x38(%rbx), %rbx
testq %rbx, %rbx
je 0x2bda
movq %rbx, %rdi
callq 0x2c3c
movl $0x60, %esi
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x21b0
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/./include/Convolution.h
// Function: Convolution::~Convolution()
~Convolution() { 
		if (weight_data != nullptr) 
			free(weight_data); 
		if (bias_data != nullptr)
			free(bias_data);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x68(%rdi), %rdi
testq %rdi, %rdi
je 0x2bf7
callq 0x2200
movq 0x70(%rbx), %rdi
addq $0x8, %rsp
testq %rdi, %rdi
je 0x2c0b
popq %rbx
popq %rbp
jmp 0x2200
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/./include/FullyConnection.h
// Function: FullyConnection::~FullyConnection()
~FullyConnection(){
		if (weight_data != nullptr)
			free(weight_data);
		if (bias_data != nullptr)
			free(bias_data);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
testq %rdi, %rdi
je 0x2c25
callq 0x2200
movq 0x20(%rbx), %rdi
addq $0x8, %rsp
testq %rdi, %rdi
je 0x2c39
popq %rbx
popq %rbp
jmp 0x2200
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/./include/Concat.h
// Function: Concat::~Concat()
~Concat(){
		// Free in_shape
		while (!in_shape.empty()) {
			free(in_shape.back());
			in_shape.pop_back();
		}
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rax
cmpq %rax, (%rdi)
je 0x2c6b
movq -0x8(%rax), %rdi
callq 0x2200
movq (%rbx), %rcx
movq 0x8(%rbx), %rax
addq $-0x8, %rax
movq %rax, 0x8(%rbx)
cmpq %rax, %rcx
jne 0x2c4e
leaq 0x28(%rbx), %rdi
callq 0x2c9e
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x2c8e
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x21b0
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movq %rax, %rdi
callq 0x2cd5
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/Concat.cpp
// Function: Concat::SetKeepOrNot(bool, ...)
int Concat::SetKeepOrNot(bool keep, ...) {
	va_list ap;

	keep_in.clear();
	va_start(ap, keep);
	for (int i = 0; i < in_shape.size(); i++) {
		keep_in.push_back(keep);
		// ‘bool’ is promoted to ‘int’ when passed through ‘...’
		// so you should pass ‘int’ not ‘bool’ to ‘va_arg’
		keep = va_arg(ap, int);
	}
	va_end(ap);

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %rbx
leaq -0xe0(%rbp), %rdi
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0x3109
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
movq 0x28(%rbx), %rax
movq %rax, 0x38(%rbx)
movl $0x0, 0x40(%rbx)
movq %rdi, -0x20(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, -0x30(%rbp)
movq 0x8(%rbx), %rax
cmpq (%rbx), %rax
je 0x318f
leaq 0x28(%rbx), %r14
xorl %r15d, %r15d
movzbl %sil, %esi
andl $0x1, %esi
movq %r14, %rdi
callq 0x31a0
movl -0x30(%rbp), %ecx
cmpq $0x28, %rcx
ja 0x3169
movq %rcx, %rax
addq -0x20(%rbp), %rax
addl $0x8, %ecx
movl %ecx, -0x30(%rbp)
jmp 0x3175
movq -0x28(%rbp), %rax
leaq 0x8(%rax), %rcx
movq %rcx, -0x28(%rbp)
cmpl $0x0, (%rax)
setne %sil
incq %r15
movq 0x8(%rbx), %rax
subq (%rbx), %rax
sarq $0x3, %rax
cmpq %r15, %rax
ja 0x3142
xorl %eax, %eax
addq $0xc8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/Eltwise.cpp
// Function: Eltwise::Eltwise(char const*, int*, bool)
Eltwise::Eltwise(const char* t, int ishape[], bool with_relu) : with_relu(with_relu) {
	elt_t = t;

	memcpy(in_shape, ishape, sizeof(int) * 4);
	memcpy(out_shape, ishape, sizeof(int) * 4);

	out_w = ishape[3];
	out_hw = ishape[2] * out_w;
	out_chw = ishape[1] * out_hw;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq $0x0, 0x38(%rdi)
movb %cl, 0x40(%rdi)
movq %rsi, (%rdi)
movups (%rdx), %xmm0
movups %xmm0, 0x8(%rdi)
movups (%rdx), %xmm0
movups %xmm0, 0x18(%rdi)
movl 0xc(%rdx), %eax
movl %eax, 0x28(%rdi)
imull 0x8(%rdx), %eax
movl %eax, 0x2c(%rdi)
imull 0x4(%rdx), %eax
movl %eax, 0x30(%rdi)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/FullyConnection.cpp
// Function: FullyConnection::FullyConnection(int, int*, bool, bool, bool)
FullyConnection::FullyConnection(int out_num, int ishape[], bool with_relu, bool wiht_bias, bool flatten) 
		: out_num(out_num), with_relu(with_relu), with_bias(with_bias){
	if (flatten) {
		in_shape[0] = ishape[0];
		in_shape[1] = ishape[1] * ishape[2] * ishape[3];
	} else {
		in_shape[0] = ishape[0];
		in_shape[1] = ishape[1];
	}

	out_shape[0] = ishape[0];
	out_shape[1] = out_num;

	weight_data = (float*)malloc(sizeof(float) * in_shape[1] * out_shape[1]);
	if (wiht_bias)
		bias_data = (float*)malloc(sizeof(float) * out_num);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %r8d, %r14d
movq %rdi, %rbx
movl %esi, (%rdi)
movb %cl, 0x14(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%rdi)
movq $0x0, 0x28(%rdi)
movl (%rdx), %eax
movl %eax, 0x4(%rdi)
movl 0x4(%rdx), %eax
testl %r9d, %r9d
je 0x3ea9
imull 0x8(%rdx), %eax
imull 0xc(%rdx), %eax
movl %eax, 0x8(%rbx)
movl (%rdx), %ecx
movl %ecx, 0xc(%rbx)
movl %esi, 0x10(%rbx)
movslq %eax, %rdi
movslq %esi, %r15
imulq %r15, %rdi
shlq $0x2, %rdi
callq 0x2240
movq %rax, 0x18(%rbx)
testb %r14b, %r14b
je 0x3ee0
shlq $0x2, %r15
movq %r15, %rdi
callq 0x2240
movq %rax, 0x20(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/FullyConnection.cpp
// Function: FullyConnection::Run(float*, bool)
float* FullyConnection::Run(float* in_data, bool keep_in) {
	float dat, wt, result;

	out_data = (float*)malloc(sizeof(float) * out_shape[0] * out_shape[1]);

	for (int idx_bs = 0; idx_bs < out_shape[0]; idx_bs++) {
		for (int idx_out = 0; idx_out < out_shape[1]; idx_out++) {
			result = 0.;
			for (int idx_in = 0; idx_in < in_shape[1]; idx_in++) {
				dat = in_data[idx_bs * in_shape[0] + idx_in];
				wt = weight_data[idx_out * in_shape[1] + idx_in];
				result += dat * wt;
			}
			if (with_bias)
				result += bias_data[idx_out];
			if (with_relu && result < 0)
				result = 0;
			out_data[idx_bs * out_shape[1] + idx_out] = result;
		}
	}

	if (!keep_in)
		free(in_data);

	return out_data;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %edx, -0x2c(%rbp)
movq %rsi, -0x38(%rbp)
movq %rdi, %rbx
movslq 0xc(%rdi), %r14
movslq 0x10(%rdi), %r13
movq %r14, %rdi
imulq %r13, %rdi
shlq $0x2, %rdi
callq 0x2240
movq %rbx, -0x40(%rbp)
movq %rax, -0x50(%rbp)
movq %rax, 0x28(%rbx)
testq %r14, %r14
jle 0x3fdc
movq %r14, %rax
movq -0x40(%rbp), %rsi
movl 0x8(%rsi), %ecx
movslq 0x4(%rsi), %rdx
movq 0x18(%rsi), %rdi
movq %rdi, -0x48(%rbp)
movb 0x15(%rsi), %dil
movq 0x20(%rsi), %r8
movb 0x14(%rsi), %r9b
movslq %ecx, %r10
shlq $0x2, %r10
shlq $0x2, %rdx
xorl %r11d, %r11d
movq -0x38(%rbp), %r14
testl %r13d, %r13d
jle 0x3fd1
movq %r11, %rsi
imulq %r13, %rsi
movq -0x50(%rbp), %rbx
leaq (%rbx,%rsi,4), %r15
movq -0x48(%rbp), %rsi
xorl %ebx, %ebx
xorps %xmm0, %xmm0
testl %ecx, %ecx
jle 0x3fa4
xorl %r12d, %r12d
movss (%r14,%r12,4), %xmm1
mulss (%rsi,%r12,4), %xmm1
addss %xmm1, %xmm0
incq %r12
cmpq %r12, %rcx
jne 0x3f8c
testb $0x1, %dil
je 0x3fb0
addss (%r8,%rbx,4), %xmm0
testb $0x1, %r9b
je 0x3fc0
xorps %xmm1, %xmm1
maxss %xmm0, %xmm1
movaps %xmm1, %xmm0
movss %xmm0, (%r15,%rbx,4)
incq %rbx
addq %r10, %rsi
cmpq %r13, %rbx
jne 0x3f82
incq %r11
addq %rdx, %r14
cmpq %rax, %r11
jne 0x3f68
cmpb $0x0, -0x2c(%rbp)
jne 0x3feb
movq -0x38(%rbp), %rdi
callq 0x2200
movq -0x40(%rbp), %rax
movq 0x28(%rax), %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/Pooling.cpp
// Function: Pooling::Pooling(char const*, int, int, int, int*)
Pooling::Pooling(const char* type, int kernel, int stride, int pad, int ishape[])
		: type(type), kernel(kernel), stride(stride), pad(pad), in_channels(ishape[1]){
	for (int i = 0; i < 4; i++)
		in_shape[i] = ishape[i];
	in_w = ishape[3];
	in_hw = ishape[2] * in_w;
	in_chw = ishape[1] * in_hw;

	out_shape[0] = ishape[0];		// batch size
	out_shape[1] = in_channels;	// out_channels
	out_shape[2] = (ishape[2] + 2 * pad - kernel) / stride + 1;   // out_height
	out_shape[3] = (ishape[3] + 2 * pad - kernel) / stride + 1;   // out_width
	out_w = out_shape[3];
	out_hw = out_shape[2] * out_w;
	out_chw = out_shape[1] * out_hw;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edx, (%rdi)
movl %ecx, 0x4(%rdi)
movl %r8d, 0x8(%rdi)
movl 0x4(%r9), %r10d
movl %r10d, 0xc(%rdi)
movq $0x0, 0x48(%rdi)
movq %rsi, 0x50(%rdi)
xorl %eax, %eax
movl (%r9,%rax,4), %esi
movl %esi, 0x10(%rdi,%rax,4)
incq %rax
cmpq $0x4, %rax
jne 0x4097
movl 0xc(%r9), %eax
movl %eax, 0x38(%rdi)
imull 0x8(%r9), %eax
movl %eax, 0x34(%rdi)
imull 0x4(%r9), %eax
movl %eax, 0x30(%rdi)
movl (%r9), %eax
movl %eax, 0x20(%rdi)
movl %r10d, 0x24(%rdi)
addl %r8d, %r8d
subl %edx, %r8d
movl 0x8(%r9), %eax
addl %r8d, %eax
cltd
idivl %ecx
movl %eax, %esi
incl %esi
movl %esi, 0x28(%rdi)
addl 0xc(%r9), %r8d
movl %r8d, %eax
cltd
idivl %ecx
incl %eax
movl %eax, 0x2c(%rdi)
movl %eax, 0x44(%rdi)
imull %esi, %eax
movl %eax, 0x40(%rdi)
imull %r10d, %eax
movl %eax, 0x3c(%rdi)
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/helper.cpp
// Function: DecodeHuffman(Bit&, TarFile*)
Tree* DecodeHuffman(Bit& accessor, TarFile* tarfile) {
	Tree* left, * right;
	unsigned char value = 0;

	switch (accessor.Next()) {
	case -1:
		return nullptr;
	case 0:
		left = DecodeHuffman(accessor, tarfile);
		right = DecodeHuffman(accessor, tarfile);
		return new Tree(-1, left, right);
	case 1:
		value = 0;
		for (int i = 0; i < 8; i++) {
			value <<= 1;
			value += accessor.Next();
		}
		return new Tree(value, nullptr, nullptr);
	default:
		cerr << "DecodeHuffman: unknown bit" << endl;
		exit(1);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
callq 0x4d88
cmpl $-0x1, %eax
je 0x4525
testl %eax, %eax
je 0x44ef
cmpl $0x1, %eax
jne 0x4530
movl $0x8, %r15d
xorl %r14d, %r14d
movl %r14d, %r12d
addb %r14b, %r12b
movq %rbx, %rdi
callq 0x4d88
movl %eax, %r14d
addb %r12b, %r14b
decl %r15d
jne 0x44bd
movl $0x18, %edi
callq 0x21a0
movzbl %r14b, %ecx
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movl %ecx, 0x10(%rax)
jmp 0x4527
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4490
movq %rax, %r15
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4490
movq %rax, %rbx
movl $0x18, %edi
callq 0x21a0
movq %r15, (%rax)
movq %rbx, 0x8(%rax)
movl $0xffffffff, 0x10(%rax) # imm = 0xFFFFFFFF
jmp 0x4527
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq 0x4ab9(%rip), %rdi      # 0x8ff0
leaq 0x1e23(%rip), %rsi      # 0x6361
callq 0x2180
movq %rax, %rdi
callq 0x20d0
movl $0x1, %edi
callq 0x2210
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/helper.cpp
// Function: LoadFromFile(char const*, char*, TarFile*)
unsigned long LoadFromFile(const char* path, char* dst, TarFile* tarfile) {
	unsigned long byte_cnt = 0;
	if (nullptr != tarfile) {
		tarfile->GetFileContents(path, dst);
		byte_cnt = tarfile->GetFileSize(path);
	} else {
		char temp;
		ifstream in_file(path, ios::in | ios::binary);

		if (!in_file) {
			cerr << "Open file failed: " << path << endl;
			return 0;
		}
		while (in_file.read((char*)& temp, sizeof(temp))) {
			dst[byte_cnt] = temp;
			byte_cnt++;
		}
	}

	return byte_cnt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x210, %rsp            # imm = 0x210
movq %rsi, %rbx
movq %rdi, %r14
testq %rdx, %rdx
je 0x4608
movq %rdx, %r15
movq %rdx, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x53e6
movq %r15, %rdi
movq %r14, %rsi
addq $0x210, %rsp            # imm = 0x210
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x54f4
leaq -0x230(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
movl $0xc, %edx
callq 0x2300
movq (%r15), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x210(%rbp,%rax)
je 0x466c
movq 0x49b9(%rip), %rbx      # 0x8ff0
leaq 0x1d3e(%rip), %rsi      # 0x637c
movl $0x12, %edx
movq %rbx, %rdi
callq 0x21e0
testq %r14, %r14
je 0x469d
movq %r14, %rdi
callq 0x20c0
movq 0x4991(%rip), %rdi      # 0x8ff0
movq %r14, %rsi
movq %rax, %rdx
callq 0x21e0
jmp 0x46b4
xorl %r14d, %r14d
leaq -0x21(%rbp), %r12
movl $0x1, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x2220
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x46e2
movb -0x21(%rbp), %al
movb %al, (%rbx,%r14)
incq %r14
jmp 0x4673
movq (%rbx), %rax
movq -0x18(%rax), %rax
leaq (%rbx,%rax), %rdi
movl 0x20(%rbx,%rax), %esi
orl $0x1, %esi
callq 0x22d0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x2160
movsbl %al, %esi
movq 0x491e(%rip), %rdi      # 0x8ff0
callq 0x2050
movq %rax, %rdi
callq 0x2100
xorl %r14d, %r14d
leaq -0x230(%rbp), %rdi
callq 0x2070
movq %r14, %rax
addq $0x210, %rsp            # imm = 0x210
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4703
movq %rax, %rbx
leaq -0x230(%rbp), %rdi
callq 0x2070
movq %rbx, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/helper.cpp
// Function: GetFileLength(char const*)
unsigned long GetFileLength(const char* path) {
	FILE* fp;
	fp =fopen(path, "r");
	if (nullptr == fp) {
		cerr << "GetFileLength: open file fail" << endl;
		exit(1);
	}
	fseek(fp, 0L, SEEK_END);
	long size = ftell(fp);
	fclose(fp);
	return size;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1d4d(%rip), %rsi      # 0x6475
callq 0x21f0
testq %rax, %rax
je 0x475f
movq %rax, %rbx
movq %rax, %rdi
xorl %esi, %esi
movl $0x2, %edx
callq 0x21d0
movq %rbx, %rdi
callq 0x2030
movq %rax, %r14
movq %rbx, %rdi
callq 0x2190
movq %r14, %rax
popq %rbx
popq %r14
popq %rbp
retq
movq 0x488a(%rip), %rdi      # 0x8ff0
leaq 0x1c22(%rip), %rsi      # 0x638f
callq 0x2180
movq %rax, %rdi
callq 0x20d0
movl $0x1, %edi
callq 0x2210
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/helper.cpp
// Function: SaveToFile(char const*, char*, unsigned long)
unsigned long SaveToFile(const char* path, char* src, unsigned long bytes) {
	ofstream out_file(path, ios::out | ios::binary);
	if (!out_file) {
		cerr << "Open result file failed." << endl;
		return 0;
	}
	out_file.write(src, bytes);
	return bytes;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %rsi
leaq -0x218(%rbp), %r15
movq %r15, %rdi
movl $0x14, %edx
callq 0x21c0
movq (%r15), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x1f8(%rbp,%rax)
je 0x4d18
movq 0x431b(%rip), %rbx      # 0x8ff0
leaq 0x171a(%rip), %rsi      # 0x63f6
movl $0x18, %edx
movq %rbx, %rdi
callq 0x21e0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x2160
movsbl %al, %esi
movq 0x42e9(%rip), %rdi      # 0x8ff0
callq 0x2050
movq %rax, %rdi
callq 0x2100
xorl %ebx, %ebx
jmp 0x4d2a
leaq -0x218(%rbp), %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x2230
movq 0x4297(%rip), %rax      # 0x8fc8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq -0x210(%rbp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, -0x218(%rbp,%rcx)
callq 0x2140
leaq -0x120(%rbp), %rdi
callq 0x2090
movq %rbx, %rax
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x218(%rbp), %rdi
callq 0x2280
movq %rbx, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/./include/helper.h
// Function: Bit::Next()
int Next() {
		if ( (ptr >= buffer + size) || (ptr == buffer + size - 1) && (idx + num_pad >= 8) )
			return -1;

		int ret = (*ptr & (1 << (7 - idx++))) ? 1 : 0;
		if (idx >= 8) {
			idx = 0;
			ptr++;
		}

		return ret;
	}

// Assembly:
movq 0x8(%rdi), %rcx
movslq 0x10(%rdi), %rdx
addq (%rdi), %rdx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rdx, %rcx
jae 0x4de6
decq %rdx
cmpq %rdx, %rcx
jne 0x4db0
movl 0x18(%rdi), %edx
addl 0x14(%rdi), %edx
cmpl $0x7, %edx
jg 0x4de6
pushq %rbp
movq %rsp, %rbp
movzbl (%rcx), %edx
movl 0x14(%rdi), %esi
leal 0x1(%rsi), %eax
movl %eax, 0x14(%rdi)
movb $0x7, %al
subb %sil, %al
movzbl %al, %r8d
xorl %eax, %eax
btl %r8d, %edx
setb %al
cmpl $0x7, %esi
jl 0x4de5
movl $0x0, 0x14(%rdi)
incq %rcx
movq %rcx, 0x8(%rdi)
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/./include/helper.h
// Function: Bit::Bit(char const*, TarFile*)
Bit(const char* path, TarFile* tarfile = nullptr) {
		size = (nullptr != tarfile) ? tarfile->GetFileSize(path) : GetFileLength(path);
		buffer = new unsigned char[size];
		if (nullptr != tarfile)
			tarfile->GetFileContents(path, (char*)buffer);
		else
			LoadFromFile(path, (char*)buffer);
		num_pad = buffer[0];
		ptr = buffer + 1;
		idx = 0;
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq $0x0, (%rdi)
testq %rdx, %rdx
je 0x4e14
movq %r15, %rdi
movq %r14, %rsi
callq 0x54f4
jmp 0x4e1c
movq %r14, %rdi
callq 0x471a
movl %eax, 0x10(%rbx)
movslq %eax, %rdi
callq 0x2040
movq %rax, (%rbx)
testq %r15, %r15
je 0x4e3f
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x53e6
jmp 0x4e4c
movq %r14, %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x45c0
movq (%rbx), %rax
movzbl (%rax), %ecx
movl %ecx, 0x18(%rbx)
incq %rax
movq %rax, 0x8(%rbx)
movl $0x0, 0x14(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/TarFile.cpp
// Function: TarFile::TarFile(char const*)
TarFile::TarFile(const char* tar_name)
	: file(nullptr), size(0)
{
	file_names.clear();
	file_sizes.clear();
	file_data_start_addrs.clear();
	// fopen_s(&file, tar_name, "rb");
	file = fopen(tar_name, "rb");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
addq $0x10, %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x40(%rbx)
movups %xmm0, 0x30(%rbx)
movups %xmm0, 0x20(%rbx)
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
movq $0x0, 0x50(%rbx)
xorl %esi, %esi
callq 0x5756
movq 0x28(%rbx), %rax
cmpq %rax, 0x30(%rbx)
je 0x50cc
movq %rax, 0x30(%rbx)
movq 0x40(%rbx), %rax
cmpq %rax, 0x48(%rbx)
je 0x50da
movq %rax, 0x48(%rbx)
leaq 0x1358(%rip), %rsi      # 0x6439
movq %r14, %rdi
callq 0x21f0
movq %rax, (%rbx)
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/TarFile.cpp
// Function: TarFile::~TarFile()
TarFile::~TarFile()
{
	if (file) {
		fclose(file);
		file = nullptr;
	}
	file_names.clear();
	file_sizes.clear();
	file_data_start_addrs.clear();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rdi
testq %rdi, %rdi
je 0x5110
callq 0x2190
movq $0x0, (%rbx)
leaq 0x10(%rbx), %r14
movq 0x10(%rbx), %rsi
movq %r14, %rdi
callq 0x5756
movq 0x28(%rbx), %rax
cmpq %rax, 0x30(%rbx)
je 0x512e
movq %rax, 0x30(%rbx)
movq 0x40(%rbx), %rdi
cmpq %rdi, 0x48(%rbx)
je 0x513c
movq %rdi, 0x48(%rbx)
testq %rdi, %rdi
je 0x514d
movq 0x50(%rbx), %rsi
subq %rdi, %rsi
callq 0x21b0
movq 0x28(%rbx), %rdi
testq %rdi, %rdi
je 0x5162
movq 0x38(%rbx), %rsi
subq %rdi, %rsi
callq 0x21b0
movq %r14, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x55da
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/TarFile.cpp
// Function: TarFile::GetFileContents(char const*, char*)
bool TarFile::GetFileContents(const char* file_name, char* contents)
{
	bool flag = false;
	for (int i = 0; i < file_names.size(); i++) {
		std::string name_(file_name);

		if (file_names[i].compare(name_) == 0) {
			int file_size = file_sizes[i];
			flag = true;
			fseek(file, file_data_start_addrs[i], SEEK_SET);
			fread(contents, file_size, 1, file);
			fseek(file, 0, SEEK_SET);

			break;
		}
	}

	return flag;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, -0x38(%rbp)
movq %rsi, -0x40(%rbp)
movq 0x18(%rdi), %rax
cmpq 0x10(%rdi), %rax
je 0x54ba
movq %rdi, %r15
xorl %r14d, %r14d
xorl %r12d, %r12d
xorl %ebx, %ebx
leaq -0x60(%rbp), %r13
movq %r13, %rdi
movq -0x40(%rbp), %rsi
leaq -0x29(%rbp), %rdx
callq 0x5644
movq 0x10(%r15), %rdi
addq %r14, %rdi
movq %r13, %rsi
callq 0x2060
movl %eax, %r13d
testl %eax, %eax
jne 0x547e
movq (%r15), %rdi
movq 0x28(%r15), %rax
movslq (%rax,%r12,8), %rbx
movq 0x40(%r15), %rax
movq (%rax,%r12,8), %rsi
xorl %edx, %edx
callq 0x21d0
movq (%r15), %rcx
movl $0x1, %edx
movq -0x38(%rbp), %rdi
movq %rbx, %rsi
callq 0x2290
movq (%r15), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x21d0
movb $0x1, %bl
movq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %rax
cmpq %rax, %rdi
je 0x5497
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x21b0
testl %r13d, %r13d
je 0x54bc
movq 0x18(%r15), %rax
subq 0x10(%r15), %rax
incq %r12
sarq $0x5, %rax
addq $0x20, %r14
cmpq %r12, %rax
ja 0x5418
jmp 0x54bc
xorl %ebx, %ebx
andb $0x1, %bl
movl %ebx, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %rax
cmpq %rax, %rdi
je 0x54ec
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x21b0
movq %rbx, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O1/hey-yahei[P]ConvNet/src/TarFile.cpp
// Function: TarFile::GetFileSize(char const*)
size_t TarFile::GetFileSize(const char* file_name)
{
	size_t file_size{ 0 };

	for (int i = 0; i < file_names.size(); i++) {
		std::string name_(file_name);

		if (file_names[i].compare(name_) == 0) {
			file_size = file_sizes[i];
			break;
		}
	}

	return file_size;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, -0x40(%rbp)
movq 0x18(%rdi), %rax
cmpq 0x10(%rdi), %rax
je 0x5591
movq %rdi, %r14
xorl %r15d, %r15d
leaq -0x60(%rbp), %r12
xorl %ebx, %ebx
movq $0x0, -0x38(%rbp)
movq %r12, %rdi
movq -0x40(%rbp), %rsi
leaq -0x29(%rbp), %rdx
callq 0x5644
movq 0x10(%r14), %rdi
addq %r15, %rdi
movq %r12, %rsi
callq 0x2060
movl %eax, %r13d
testl %eax, %eax
jne 0x5559
movq 0x28(%r14), %rax
movq (%rax,%rbx,8), %rax
movq %rax, -0x38(%rbp)
movq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %rax
cmpq %rax, %rdi
je 0x5572
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x21b0
testl %r13d, %r13d
je 0x5599
movq 0x18(%r14), %rax
subq 0x10(%r14), %rax
incq %rbx
sarq $0x5, %rax
addq $0x20, %r15
cmpq %rbx, %rax
ja 0x5527
jmp 0x5599
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %rax
cmpq %rax, %rdi
je 0x55c8
movq -0x50(%rbp), %rsi
incq %rsi
callq 0x21b0
movq %rbx, %rdi
callq 0x22e0
// File: /workspace/github_cpp_makefile_star2_O1/renzibei[P]TSProxy/utils.cpp
// Function: writeNBytes(int, void const*, unsigned long, int)
ssize_t writeNBytes(int fd, const void *buf, size_t nbyte, int isNonBlocking) {
    size_t hasWritten = 0;
    const char* src = (const char*)buf;
    

    while(hasWritten < nbyte) {
        ssize_t tempLen = send(fd, src + hasWritten, nbyte - hasWritten, 0);
        if(tempLen < 0) {
            if (isNonBlocking && errno == EAGAIN) {
                continue;
            }
            LogHelper::log(Error, "Errors when write fd, fd: %d, %s", fd, strerror(errno));
            return -1;
        }
        if (isNonBlocking && tempLen == 0) {
            LogHelper::log(Error, "Connection has been closed in sockFd %d when tried to send", fd);
            return hasWritten;
        }
        hasWritten += tempLen;
    }
    return hasWritten;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdx, %rdx
je 0x5b83
movl %ecx, %ebx
movq %rdx, %r14
movq %rsi, %r15
movl %edi, %ebp
xorl %r12d, %r12d
leaq (%r15,%r12), %rsi
movq %r14, %rdx
subq %r12, %rdx
movl %ebp, %edi
xorl %ecx, %ecx
callq 0x2100
testq %rax, %rax
js 0x5b2c
testl %ebx, %ebx
je 0x5b6e
testq %rax, %rax
jne 0x5b6e
xorl %edi, %edi
leaq 0x2fb9(%rip), %rsi      # 0x8ad2
movl %ebp, %edx
xorl %eax, %eax
callq 0x273c
movl $0x1, %ecx
movq %r12, %r13
jmp 0x5b73
testl %ebx, %ebx
je 0x5b3f
callq 0x2040
movl $0x2, %ecx
cmpl $0xb, (%rax)
je 0x5b73
callq 0x2040
movl (%rax), %edi
callq 0x20d0
xorl %edi, %edi
leaq 0x2f5d(%rip), %rsi      # 0x8ab1
movl %ebp, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0x273c
movl $0x1, %ecx
movq $-0x1, %r13
jmp 0x5b73
addq %rax, %r12
xorl %ecx, %ecx
testb $0x1, %cl
jne 0x5b88
cmpq %r14, %r12
jb 0x5aef
jmp 0x5b8b
xorl %r12d, %r12d
jmp 0x5b8b
movq %r13, %r12
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/renzibei[P]TSProxy/aes.cpp
// Function: GLOBAL__sub_I_aes.cpp
static void subBytes(int (&array)[4][4]){
	int i,j;
	for(i = 0; i < 4; i++)
		for(j = 0; j < 4; j++)
			array[i][j] = getNumFromBox(S, array[i][j]);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
leaq 0xbaef6(%rip), %rax     # 0xbd4b0
movq %rax, 0xbaedf(%rip)     # 0xbd4a0
leaq 0xbaed8(%rip), %rsi     # 0xbd4a0
movabsq $0x2e302e302e373231, %r15 # imm = 0x2E302E302E373231
movq %r15, 0xbaed7(%rip)     # 0xbd4b0
movw $0x31, %bp
movw %bp, 0xbaed4(%rip)      # 0xbd4b8
movl $0x9, %r12d
movq %r12, 0xbaeb7(%rip)     # 0xbd4a8
movq 0xa9c8(%rip), %rbx      # 0xcfc0
leaq 0xabb1(%rip), %r14      # 0xd1b0
movq %rbx, %rdi
movq %r14, %rdx
callq 0x2180
leaq 0xbaebf(%rip), %rax     # 0xbd4d0
movq %rax, 0xbaea8(%rip)     # 0xbd4c0
leaq 0xbaea1(%rip), %rsi     # 0xbd4c0
movq %r15, 0xbaeaa(%rip)     # 0xbd4d0
movw %bp, 0xbaeab(%rip)      # 0xbd4d8
movq %r12, 0xbae94(%rip)     # 0xbd4c8
movq %rbx, %rdi
movq %r14, %rdx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2180
nopw (%rax,%rax)
// File: /workspace/github_cpp_makefile_star2_O1/renzibei[P]TSProxy/loghelper.cpp
// Function: LogHelper::log(LogType, char const*, ...)
void LogHelper::log(LogType type, const char * format, ...) {
#ifdef LOG_TRACE
    if(type <= Trace)
#elif defined LOG_DEBUG
    if(type <= Debug)
#elif defined LOG_INFO
    if(type <= Info)
#elif defined LOG_WARN
    if(type <= Warn)
#endif
    {
        va_list args;
        if (type == Error) {
            fprintf(stderr, "\033[40;31m");
        }
        else if (type == Warn) {
            fprintf(stderr, "\033[40;33m");
        }
        va_start(args, format);
        vfprintf(stderr, format, args);
        va_end(args);
        if (type == Error || type == Warn) {
            fprintf(stderr, "\033[0m");
        }
        fprintf(stderr, "\n");
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0xd0, %rsp
movq %rdx, 0x30(%rsp)
movq %rcx, 0x38(%rsp)
movq %r8, 0x40(%rsp)
movq %r9, 0x48(%rsp)
testb %al, %al
je 0x2797
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
cmpl $0x2, %edi
jle 0x27a9
addq $0xd0, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rsi, %r14
movl %edi, %ebx
testl %edi, %edi
je 0x27c0
cmpl $0x1, %ebx
jne 0x27cc
leaq 0x584f(%rip), %rdi      # 0x800d
jmp 0x27c7
leaq 0x583d(%rip), %rdi      # 0x8004
callq 0x2360
leaq 0x20(%rsp), %rax
movq %rsp, %rdx
movq %rax, 0x10(%rdx)
leaq 0xf0(%rsp), %rax
movq %rax, 0x8(%rdx)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, (%rdx)
movq 0xa7e0(%rip), %r15      # 0xcfd8
movq (%r15), %rdi
movq %r14, %rsi
callq 0x2270
cmpl $0x1, %ebx
jbe 0x2817
movq (%r15), %rsi
movl $0xa, %edi
callq 0x2220
jmp 0x279c
callq 0x2375
jmp 0x2808
nop
// File: /workspace/github_cpp_makefile_star2_O1/renzibei[P]TSProxy/proxyserver.cpp
// Function: sendData(int, unsigned char const*, unsigned long, std::unordered_map<int, ClientNode*, std::hash<int>, std::equal_to<int>, std::allocator<std::pair<int const, ClientNode*>>>&, int)
int sendData(int sockFd, const uint8_t *data, size_t nbyte, ClientMap &cMap, int msgType = 5) {
    ClientNode *node = cMap[sockFd];
    static InnerMsg innerMsg;
    memset(&innerMsg, 0, sizeof(innerMsg));
    node->sSeq++;
    
    innerMsg.cSeq = node->cSeq;
    innerMsg.sSeq = node->sSeq;
    innerMsg.msgType = msgType;
    if (nbyte > sizeof(innerMsg.data)) {
        LogHelper::log(Error, "Failed to send data, nbyte too large, nbyte: %lu", nbyte);
        return -1;
    }
    innerMsg.dataLength = nbyte;
    memcpy(innerMsg.data, data, nbyte);
    ssize_t sendCode = sendTSPacket(sockFd, &innerMsg, constants::serverNonBlocking);
    if (sendCode < 0) {
        LogHelper::log(Error, "Fail to send data");
        return sendCode;
    }
    node->lastTime = time(NULL);
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl %r8d, %ebp
movq %rdx, %rbx
movq %rsi, %r14
leaq 0xc(%rsp), %rsi
movl %edi, (%rsi)
movq %rcx, %rdi
callq 0x4a0e
movq (%rax), %r12
leaq 0x1a7cd(%rip), %rdi     # 0x1d210
movl $0x10000, %edx          # imm = 0x10000
xorl %esi, %esi
callq 0x2120
movq (%r12), %rax
movq 0x8(%r12), %rcx
incq %rcx
movq %rcx, 0x8(%r12)
movq %rax, 0x1a7a9(%rip)     # 0x1d210
movq %rcx, 0x1a7aa(%rip)     # 0x1d218
movw %bp, 0x1a7ab(%rip)      # 0x1d220
cmpq $0xffed, %rbx           # imm = 0xFFED
jb 0x2a98
leaq 0x5749(%rip), %rsi      # 0x81ce
xorl %edi, %edi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x273c
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
jmp 0x2af1
movw %bx, 0x1a783(%rip)      # 0x1d222
leaq 0x1a76a(%rip), %r15     # 0x1d210
leaq 0x1a777(%rip), %rdi     # 0x1d224
movq %r14, %rsi
movq %rbx, %rdx
callq 0x2150
movl 0xc(%rsp), %edi
movq %r15, %rsi
movl $0x1, %edx
callq 0x5ec0
testq %rax, %rax
js 0x2ade
xorl %ebx, %ebx
xorl %edi, %edi
callq 0x2190
movq %rax, 0x10(%r12)
jmp 0x2af1
movq %rax, %rbx
leaq 0x5717(%rip), %rsi      # 0x81ff
xorl %edi, %edi
xorl %eax, %eax
callq 0x273c
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq