// File: /workspace/github_c_makefile_star2_O0/SimpleDoger[P]Darknet_CPU_Only/yolo_layer.c
// Function: avg_flipped_yolo
void avg_flipped_yolo(layer l)
{
    int i,j,n,z;
    float *flip = l.output + l.outputs;
    for (j = 0; j < l.h; ++j) {
        for (i = 0; i < l.w/2; ++i) {
            for (n = 0; n < l.n; ++n) {
                for(z = 0; z < l.classes + 4 + 1; ++z){
                    int i1 = z*l.w*l.h*l.n + n*l.w*l.h + j*l.w + i;
                    int i2 = z*l.w*l.h*l.n + n*l.w*l.h + j*l.w + (l.w - i - 1);
                    float swap = flip[i1];
                    flip[i1] = flip[i2];
                    flip[i2] = swap;
                    if(z == 0){
                        flip[i1] = -flip[i1];
                        flip[i2] = -flip[i2];
                    }
                }
            }
        }
    }
    for(i = 0; i < l.outputs; ++i){
        l.output[i] = (l.output[i] + flip[i])/2.;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x10(%rbp), %rcx
movq %rcx, -0x30(%rbp)
movq 0x268(%rcx), %rax
movslq 0x58(%rcx), %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
movl $0x0, -0x8(%rbp)
movq -0x30(%rbp), %rcx
movl -0x8(%rbp), %eax
cmpl 0x6c(%rcx), %eax
jge 0x534b8
movl $0x0, -0x4(%rbp)
movq -0x30(%rbp), %rax
movl -0x4(%rbp), %ecx
movl %ecx, -0x34(%rbp)
movl 0x70(%rax), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movl -0x34(%rbp), %eax
cmpl %ecx, %eax
jge 0x534a8
movl $0x0, -0xc(%rbp)
movq -0x30(%rbp), %rcx
movl -0xc(%rbp), %eax
cmpl 0x84(%rcx), %eax
jge 0x53498
movl $0x0, -0x10(%rbp)
movq -0x30(%rbp), %rcx
movl -0x10(%rbp), %eax
movl 0xfc(%rcx), %ecx
addl $0x4, %ecx
addl $0x1, %ecx
cmpl %ecx, %eax
jge 0x53488
movq -0x30(%rbp), %rcx
movl -0x10(%rbp), %eax
imull 0x70(%rcx), %eax
imull 0x6c(%rcx), %eax
imull 0x84(%rcx), %eax
movl -0xc(%rbp), %edx
imull 0x70(%rcx), %edx
imull 0x6c(%rcx), %edx
addl %edx, %eax
movl -0x8(%rbp), %edx
imull 0x70(%rcx), %edx
addl %edx, %eax
addl -0x4(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl -0x10(%rbp), %eax
imull 0x70(%rcx), %eax
imull 0x6c(%rcx), %eax
imull 0x84(%rcx), %eax
movl -0xc(%rbp), %edx
imull 0x70(%rcx), %edx
imull 0x6c(%rcx), %edx
addl %edx, %eax
movl -0x8(%rbp), %edx
imull 0x70(%rcx), %edx
addl %edx, %eax
movl 0x70(%rcx), %ecx
subl -0x4(%rbp), %ecx
subl $0x1, %ecx
addl %ecx, %eax
movl %eax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movss %xmm0, -0x24(%rbp)
movq -0x18(%rbp), %rax
movslq -0x20(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movss %xmm0, (%rax,%rcx,4)
movss -0x24(%rbp), %xmm0
movq -0x18(%rbp), %rax
movslq -0x20(%rbp), %rcx
movss %xmm0, (%rax,%rcx,4)
cmpl $0x0, -0x10(%rbp)
jne 0x53478
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movd %xmm0, %eax
xorl $0x80000000, %eax       # imm = 0x80000000
movd %eax, %xmm0
movq -0x18(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movss %xmm0, (%rax,%rcx,4)
movq -0x18(%rbp), %rax
movslq -0x20(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movd %xmm0, %eax
xorl $0x80000000, %eax       # imm = 0x80000000
movd %eax, %xmm0
movq -0x18(%rbp), %rax
movslq -0x20(%rbp), %rcx
movss %xmm0, (%rax,%rcx,4)
jmp 0x5347a
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x53363
jmp 0x5348a
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x53349
jmp 0x5349a
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x53320
jmp 0x534aa
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x53309
movl $0x0, -0x4(%rbp)
movq -0x30(%rbp), %rcx
movl -0x4(%rbp), %eax
cmpl 0x58(%rcx), %eax
jge 0x5351b
movq -0x30(%rbp), %rax
movq 0x268(%rax), %rcx
movslq -0x4(%rbp), %rdx
movss (%rcx,%rdx,4), %xmm0
movq -0x18(%rbp), %rcx
movslq -0x4(%rbp), %rdx
addss (%rcx,%rdx,4), %xmm0
cvtss2sd %xmm0, %xmm0
movsd 0x1db60(%rip), %xmm1    # 0x71058
divsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movq 0x268(%rax), %rax
movslq -0x4(%rbp), %rcx
movss %xmm0, (%rax,%rcx,4)
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x534bf
popq %rbp
retq
nopl (%rax)