// File: /workspace/github_c_makefile_star2_O0/SimpleDoger[P]Darknet_CPU_Only/deconvolutional_layer.c
// Function: forward_deconvolutional_layer
void forward_deconvolutional_layer(const layer l, network net)
{
    int i;

    int m = l.size*l.size*l.n;
    int n = l.h*l.w;
    int k = l.c;

    fill_cpu(l.outputs*l.batch, 0, l.output, 1);

    for(i = 0; i < l.batch; ++i){
        float *a = l.weights;
        float *b = net.input + i*l.c*l.h*l.w;
        float *c = net.workspace;

        gemm_cpu(1,0,m,n,k,1,a,m,b,n,0,c,n);

        col2im_cpu(net.workspace, l.out_c, l.out_h, l.out_w, l.size, l.stride, l.pad, l.output+i*l.outputs);
    }
    if (l.batch_normalize) {
        forward_batchnorm_layer(l, net);
    } else {
        add_bias(l.output, l.biases, l.batch, l.n, l.out_w*l.out_h);
    }
    activate_array(l.output, l.batch*l.n*l.out_w*l.out_h, l.activation);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x5f8, %rsp            # imm = 0x5F8
leaq 0x4b0(%rbp), %rax
movq %rax, -0x50(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x48(%rbp)
movl 0x90(%rax), %ecx
imull 0x90(%rax), %ecx
imull 0x84(%rax), %ecx
movl %ecx, -0x20(%rbp)
movl 0x6c(%rax), %ecx
imull 0x70(%rax), %ecx
movl %ecx, -0x24(%rbp)
movl 0x74(%rax), %ecx
movl %ecx, -0x28(%rbp)
movl 0x58(%rax), %edi
imull 0x48(%rax), %edi
movq 0x268(%rax), %rsi
xorps %xmm0, %xmm0
movl $0x1, %edx
callq 0x2f740
movl $0x0, -0x1c(%rbp)
movq -0x48(%rbp), %rcx
movl -0x1c(%rbp), %eax
cmpl 0x48(%rcx), %eax
jge 0x690f
movq -0x48(%rbp), %rbx
movq -0x50(%rbp), %rax
movq 0x250(%rbx), %rcx
movq %rcx, -0x30(%rbp)
movq 0xd8(%rax), %rcx
movl -0x1c(%rbp), %edx
imull 0x74(%rbx), %edx
imull 0x6c(%rbx), %edx
imull 0x70(%rbx), %edx
movslq %edx, %rdx
shlq $0x2, %rdx
addq %rdx, %rcx
movq %rcx, -0x38(%rbp)
movq 0xf0(%rax), %rax
movq %rax, -0x40(%rbp)
movl -0x20(%rbp), %edx
movl -0x24(%rbp), %ecx
movl -0x28(%rbp), %r8d
movq -0x30(%rbp), %r9
movl -0x20(%rbp), %r15d
movq -0x38(%rbp), %r14
movl -0x24(%rbp), %r11d
movq -0x40(%rbp), %r10
movl -0x24(%rbp), %eax
movl $0x1, %edi
xorl %esi, %esi
movss 0x6a77e(%rip), %xmm0    # 0x7100c
xorps %xmm1, %xmm1
movl %r15d, (%rsp)
movq %r14, 0x8(%rsp)
movl %r11d, 0x10(%rsp)
movq %r10, 0x18(%rsp)
movl %eax, 0x20(%rsp)
callq 0x3900
movq -0x50(%rbp), %rax
movq 0xf0(%rax), %rdi
movl 0x80(%rbx), %esi
movl 0x78(%rbx), %edx
movl 0x7c(%rbx), %ecx
movl 0x90(%rbx), %r8d
movl 0x98(%rbx), %r9d
movl 0xa8(%rbx), %r10d
movq 0x268(%rbx), %rax
movl -0x1c(%rbp), %r11d
imull 0x58(%rbx), %r11d
movslq %r11d, %r11
shlq $0x2, %r11
addq %r11, %rax
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x2e840
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x680c
movq -0x48(%rbp), %rax
cmpl $0x0, 0x40(%rax)
je 0x694a
movq -0x48(%rbp), %rsi
movq %rsp, %rdi
movq %rdi, -0x58(%rbp)
movl $0x94, %ecx
rep  movsq (%rsi), %es:(%rdi)
movq -0x50(%rbp), %rsi
movq -0x58(%rbp), %rdi
addq $0x4a0, %rdi            # imm = 0x4A0
movl $0x22, %ecx
rep  movsq (%rsi), %es:(%rdi)
callq 0x4b2d0
jmp 0x6973
movq -0x48(%rbp), %rax
movq 0x268(%rax), %rdi
movq 0x230(%rax), %rsi
movl 0x48(%rax), %edx
movl 0x84(%rax), %ecx
movl 0x7c(%rax), %r8d
imull 0x78(%rax), %r8d
callq 0x8840
movq -0x48(%rbp), %rax
movq 0x268(%rax), %rdi
movl 0x48(%rax), %esi
imull 0x84(%rax), %esi
imull 0x7c(%rax), %esi
imull 0x78(%rax), %esi
movl 0x4(%rax), %edx
callq 0x2dfa0
addq $0x5f8, %rsp            # imm = 0x5F8
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nopw %cs:(%rax,%rax)