Commit 70b7f3b2 authored by Sakthivel Velumani's avatar Sakthivel Velumani

creating memory for llrOut

parent 144cb781
...@@ -95,9 +95,7 @@ static inline uint32_t nrLDPC_decoder_core(int8_t* p_llr, int8_t* p_out, t_nrLDP ...@@ -95,9 +95,7 @@ static inline uint32_t nrLDPC_decoder_core(int8_t* p_llr, int8_t* p_out, t_nrLDP
else else
{ {
// Use LLR processing buffer as temporary output buffer // Use LLR processing buffer as temporary output buffer
p_llrOut = p_procBuf->llrProcBuf; p_llrOut = p_procBuf->llrOut;
// Clear llrProcBuf
memset(p_llrOut,0, NR_LDPC_MAX_NUM_LLR*sizeof(int8_t));
} }
...@@ -342,7 +340,6 @@ static inline uint32_t nrLDPC_decoder_core(int8_t* p_llr, int8_t* p_out, t_nrLDP ...@@ -342,7 +340,6 @@ static inline uint32_t nrLDPC_decoder_core(int8_t* p_llr, int8_t* p_out, t_nrLDP
{ {
nrLDPC_llr2bit(p_out, p_llrOut, numLLR); nrLDPC_llr2bit(p_out, p_llrOut, numLLR);
} }
#ifdef NR_LDPC_PROFILER_DETAIL #ifdef NR_LDPC_PROFILER_DETAIL
stop_meas(&p_profiler->llr2bit); stop_meas(&p_profiler->llr2bit);
#endif #endif
......
...@@ -66,6 +66,7 @@ static inline t_nrLDPC_procBuf* nrLDPC_init_mem(void) ...@@ -66,6 +66,7 @@ static inline t_nrLDPC_procBuf* nrLDPC_init_mem(void)
p_procBuf->bnProcBufRes = (int8_t*) malloc32_clear(NR_LDPC_SIZE_BN_PROC_BUF*sizeof(int8_t)); p_procBuf->bnProcBufRes = (int8_t*) malloc32_clear(NR_LDPC_SIZE_BN_PROC_BUF*sizeof(int8_t));
p_procBuf->llrRes = (int8_t*) malloc32_clear(NR_LDPC_MAX_NUM_LLR *sizeof(int8_t)); p_procBuf->llrRes = (int8_t*) malloc32_clear(NR_LDPC_MAX_NUM_LLR *sizeof(int8_t));
p_procBuf->llrProcBuf = (int8_t*) malloc32_clear(NR_LDPC_MAX_NUM_LLR *sizeof(int8_t)); p_procBuf->llrProcBuf = (int8_t*) malloc32_clear(NR_LDPC_MAX_NUM_LLR *sizeof(int8_t));
p_procBuf->llrOut = (int8_t*) malloc32_clear(NR_LDPC_MAX_NUM_LLR *sizeof(int8_t));
} }
return(p_procBuf); return(p_procBuf);
...@@ -79,6 +80,7 @@ static inline void nrLDPC_free_mem(t_nrLDPC_procBuf* p_procBuf) ...@@ -79,6 +80,7 @@ static inline void nrLDPC_free_mem(t_nrLDPC_procBuf* p_procBuf)
free(p_procBuf->bnProcBufRes); free(p_procBuf->bnProcBufRes);
free(p_procBuf->llrRes); free(p_procBuf->llrRes);
free(p_procBuf->llrProcBuf); free(p_procBuf->llrProcBuf);
free(p_procBuf->llrOut);
free(p_procBuf); free(p_procBuf);
} }
......
...@@ -104,6 +104,7 @@ typedef struct nrLDPC_procBuf { ...@@ -104,6 +104,7 @@ typedef struct nrLDPC_procBuf {
int8_t* bnProcBufRes; /**< Buffer for BN processing results */ int8_t* bnProcBufRes; /**< Buffer for BN processing results */
int8_t* llrRes; /**< Buffer for LLR results */ int8_t* llrRes; /**< Buffer for LLR results */
int8_t* llrProcBuf; /**< LLR processing buffer */ int8_t* llrProcBuf; /**< LLR processing buffer */
int8_t* llrOut;
} t_nrLDPC_procBuf; } t_nrLDPC_procBuf;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment