// File: /workspace/github_c_makefile_star2_O0/xtanitfy[P]Murphy/src/layers/linear_layer.c
// Function: LinearLayerForward
int LinearLayerForward(NET_PARA_s *pNetPara,LAYER_s *pLayer)
{
	CHECK_EXPR_RET(pLayer == NULL,-1);
	
	BLOB_s *pPrevData = pLayer->pPrev[0]->pData;
	CHECK_EXPR_RET(pPrevData == NULL,-1);
	
	BLOB_DATA_PTR(pLayer->pData,ptrCurr);
	BLOB_DATA_PTR(pPrevData,ptrPrev);

	int cnt = 0;
	BLOB_s *pData = pLayer->pData;
	
	for (int i_batch = 0;i_batch < pData->numSize;i_batch++) {
		cnt = 0;
		for (int i_in = 0;i_in < pPrevData->channelSize;i_in++) {
			for (int i_w = 0; i_w < pPrevData->widthSize;i_w++) {
				for (int i_h = 0; i_h < pPrevData->heightSize;i_h++) {
					ptrCurr[i_batch][cnt++][0][0] = 
						ptrPrev[i_batch][i_in][i_h][i_w];
				}
			}
		}
	}
	
	
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x87c7
leaq 0x2874(%rip), %rdi      # 0xb015
leaq 0x3022(%rip), %rsi      # 0xb7ca
leaq 0x303a(%rip), %rdx      # 0xb7e9
movl $0x3b, %ecx
movb $0x0, %al
callq 0x1030
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x89e0
movq -0x18(%rbp), %rax
movq 0xa8(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x880e
leaq 0x282d(%rip), %rdi      # 0xb015
leaq 0x2fdb(%rip), %rsi      # 0xb7ca
leaq 0x2ff3(%rip), %rdx      # 0xb7e9
movl $0x3e, %ecx
movb $0x0, %al
callq 0x1030
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x89e0
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x18(%rax), %rax
movq %rax, -0x80(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x20(%rax), %rax
movq %rax, -0x78(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x70(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x20(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x40(%rbp)
movl $0x0, -0x44(%rbp)
movslq -0x44(%rbp), %rax
movq -0x40(%rbp), %rcx
cmpq 0x10(%rcx), %rax
jae 0x89d9
movl $0x0, -0x34(%rbp)
movl $0x0, -0x48(%rbp)
movslq -0x48(%rbp), %rax
movq -0x20(%rbp), %rcx
cmpq 0x18(%rcx), %rax
jae 0x89c9
movl $0x0, -0x4c(%rbp)
movslq -0x4c(%rbp), %rax
movq -0x20(%rbp), %rcx
cmpq 0x28(%rcx), %rax
jae 0x89b9
movl $0x0, -0x50(%rbp)
movslq -0x50(%rbp), %rax
movq -0x20(%rbp), %rcx
cmpq 0x20(%rcx), %rax
jae 0x89a9
movq -0x70(%rbp), %rcx
movq -0x78(%rbp), %rsi
movq -0x80(%rbp), %rdi
movq -0x58(%rbp), %r8
movq -0x60(%rbp), %r9
movq -0x68(%rbp), %r10
movq -0x30(%rbp), %rax
movslq -0x44(%rbp), %rdx
imulq %r9, %r10
imulq %r8, %r10
imulq %r10, %rdx
shlq $0x3, %rdx
addq %rdx, %rax
movslq -0x48(%rbp), %rdx
imulq %r8, %r9
imulq %r9, %rdx
shlq $0x3, %rdx
addq %rdx, %rax
movslq -0x50(%rbp), %rdx
imulq %r8, %rdx
shlq $0x3, %rdx
addq %rdx, %rax
movslq -0x4c(%rbp), %rdx
movsd (%rax,%rdx,8), %xmm0
movq -0x28(%rbp), %rax
movslq -0x44(%rbp), %rdx
imulq %rsi, %rdi
imulq %rcx, %rdi
imulq %rdi, %rdx
shlq $0x3, %rdx
addq %rdx, %rax
movl -0x34(%rbp), %edx
movl %edx, %edi
addl $0x1, %edi
movl %edi, -0x34(%rbp)
movslq %edx, %rdx
imulq %rcx, %rsi
imulq %rsi, %rdx
shlq $0x3, %rdx
addq %rdx, %rax
imulq $0x0, %rcx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0x50(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x50(%rbp)
jmp 0x88ea
jmp 0x89ab
movl -0x4c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4c(%rbp)
jmp 0x88d1
jmp 0x89bb
movl -0x48(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x48(%rbp)
jmp 0x88b8
jmp 0x89cb
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x8898
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)