// File: /workspace/github_cpp_makefile_star2_O1/CodyNault[P]Image-Filter-Dataflow/src/main.cpp
// Function: main
int main(int argc, char *argv[])
{
    PNMreader reader(argv[1]);

    Crop crop;
    crop.SetRegion(300, 1400, 50, 400);
    crop.SetInput(reader.GetOutput());

    Transpose t;
    t.SetInput(crop.GetOutput());

    Invert i;
    i.SetInput(t.GetOutput());

    Color color(50, 1101, 0, 0, 128);
    
    LRConcat lr;
    lr.SetInput(color.GetOutput());
    lr.SetInput2(i.GetOutput());

    Color white(401, 1101, 255, 255, 255);

    Checkerboard cb;
    cb.SetInput(lr.GetOutput());
    cb.SetInput2(white.GetOutput());

    cb.GetOutput()->Update();

    PNMwriter writer;
    writer.SetInput(cb.GetOutput());
    writer.Write(argv[2]);

    CheckSum cs;
    cs.SetInput(cb.GetOutput());
    cs.OutputCheckSum();
    Logger::Finalize();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
movq %rsi, %r12
movq 0x8(%rsi), %rsi
leaq -0x188(%rbp), %rdi
callq 0x4068
leaq -0x1d8(%rbp), %rdi
callq 0x3840
movaps 0x2bca(%rip), %xmm0     # 0x6010
movups %xmm0, -0x198(%rbp)
leaq -0x188(%rbp), %rdi
callq 0x3c6c
leaq -0x1b0(%rbp), %rdi
movq %rax, %rsi
callq 0x3a48
leaq 0x5309(%rip), %r14      # 0x8778
leaq -0x110(%rbp), %r15
movq %r14, -0x8(%r15)
movq %r15, %rdi
callq 0x38c8
leaq -0xf0(%rbp), %rbx
movq %rbx, %rdi
callq 0x3a30
leaq 0x5700(%rip), %rax      # 0x8b98
leaq 0x10(%rax), %rcx
movq %rcx, -0x118(%rbp)
addq $0x48, %rax
movq %rax, -0xf0(%rbp)
leaq -0x1d8(%rbp), %rdi
callq 0x3c6c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x3a48
leaq -0xd0(%rbp), %r15
movq %r14, -0x8(%r15)
movq %r15, %rdi
callq 0x38c8
leaq -0xb0(%rbp), %rbx
movq %rbx, %rdi
callq 0x3a30
leaq 0x5722(%rip), %rax      # 0x8c10
leaq 0x10(%rax), %rcx
movq %rcx, -0xd8(%rbp)
addq $0x48, %rax
movq %rax, -0xb0(%rbp)
leaq -0x118(%rbp), %rdi
callq 0x3c6c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x3a48
leaq -0x258(%rbp), %rdi
movl $0x32, %esi
movl $0x44d, %edx            # imm = 0x44D
xorl %ecx, %ecx
xorl %r8d, %r8d
movl $0x80, %r9d
callq 0x5546
leaq -0x150(%rbp), %r15
movq %r14, -0x8(%r15)
movq %r15, %rdi
callq 0x38c8
leaq -0x130(%rbp), %r13
movq %r13, %rdi
callq 0x3a30
leaq 0x552b(%rip), %rax      # 0x8a90
leaq 0x10(%rax), %rcx
movq %rcx, -0x158(%rbp)
addq $0x48, %rax
movq %rax, -0x130(%rbp)
leaq -0x258(%rbp), %rdi
callq 0x3c6c
movq %r13, %rdi
movq %rax, %rsi
callq 0x3a48
leaq -0xd8(%rbp), %rdi
callq 0x3c6c
movq %r13, %rdi
movq %rax, %rsi
callq 0x3a52
leaq -0x218(%rbp), %rdi
movl $0x191, %esi            # imm = 0x191
movl $0x44d, %edx            # imm = 0x44D
movl $0xff, %ecx
movl $0xff, %r8d
movl $0xff, %r9d
callq 0x5546
leaq -0x90(%rbp), %r13
movq %r14, -0x8(%r13)
movq %r13, %rdi
callq 0x38c8
leaq -0x70(%rbp), %rbx
movq %rbx, %rdi
callq 0x3a30
leaq 0x5692(%rip), %rax      # 0x8c88
leaq 0x10(%rax), %rcx
movq %rcx, -0x98(%rbp)
addq $0x48, %rax
movq %rax, -0x70(%rbp)
leaq -0x158(%rbp), %rdi
callq 0x3c6c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x3a48
leaq -0x218(%rbp), %rdi
callq 0x3c6c
movq %rbx, %rdi
movq %rax, %rsi
callq 0x3a52
leaq -0x98(%rbp), %rdi
callq 0x3c6c
movq %rax, %rdi
callq 0x3a1a
leaq -0x58(%rbp), %rdi
callq 0x3a30
leaq 0x5155(%rip), %rax      # 0x87b0
movq %rax, -0x58(%rbp)
leaq -0x98(%rbp), %rdi
callq 0x3c6c
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq 0x3a48
movq 0x10(%r12), %rsi
leaq -0x58(%rbp), %rdi
callq 0x4348
leaq -0x40(%rbp), %rdi
callq 0x3a30
leaq 0x515b(%rip), %rax      # 0x87f0
movq %rax, -0x40(%rbp)
leaq -0x98(%rbp), %rdi
callq 0x3c6c
leaq -0x40(%rbp), %rdi
movq %rax, %rsi
callq 0x3a48
leaq -0x40(%rbp), %rdi
callq 0x576a
callq 0x5bfc
movq %r14, -0x98(%rbp)
movq %r13, %rdi
callq 0x3996
leaq -0x210(%rbp), %rdi
movq %r14, -0x8(%rdi)
callq 0x3996
movq %r14, -0x158(%rbp)
movq %r15, %rdi
callq 0x3996
leaq -0x250(%rbp), %rdi
movq %r14, -0x8(%rdi)
callq 0x3996
movq %r14, -0xd8(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0x3996
movq %r14, -0x118(%rbp)
leaq -0x110(%rbp), %rdi
callq 0x3996
leaq -0x1d0(%rbp), %rdi
movq %r14, -0x8(%rdi)
callq 0x3996
leaq -0x188(%rbp), %rdi
callq 0x40d8
xorl %eax, %eax
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x37ad
movq %rax, %r12
jmp 0x37bf
jmp 0x37a6
jmp 0x37a6
movq %rax, %r12
jmp 0x37de
jmp 0x3795
movq %rax, %r12
movq %r14, -0xd8(%rbp)
movq %r15, %rdi
jmp 0x37fc
jmp 0x379a
movq %rax, %r12
movq %r14, -0x118(%rbp)
movq %r15, %rdi
jmp 0x380f
jmp 0x379f
movq %rax, %r12
jmp 0x382b
movq %rax, %r12
jmp 0x37ee
movq %rax, %r12
jmp 0x3801
movq %rax, %r12
jmp 0x3814
jmp 0x37ad
movq %rax, %r12
jmp 0x37cf
jmp 0x37ad
movq %rax, %r12
movq %r14, -0x98(%rbp)
movq %r13, %rdi
callq 0x3996
leaq -0x210(%rbp), %rdi
movq %r14, -0x8(%rdi)
callq 0x3996
movq %r14, -0x158(%rbp)
movq %r15, %rdi
callq 0x3996
leaq -0x250(%rbp), %rdi
movq %r14, -0x8(%rdi)
callq 0x3996
movq %r14, -0xd8(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0x3996
movq %r14, -0x118(%rbp)
leaq -0x110(%rbp), %rdi
callq 0x3996
leaq 0x4f5d(%rip), %rax      # 0x8778
leaq -0x1d0(%rbp), %rdi
movq %rax, -0x8(%rdi)
callq 0x3996
leaq -0x188(%rbp), %rdi
callq 0x40d8
movq %r12, %rdi
callq 0x31b0
nop