initial RRC for NSA
This commit is contained in:
@@ -795,152 +795,6 @@ static inline void memcpy_printer(uint32_t* p_lut_cn2bn,int dest0,int M) {
|
||||
}
|
||||
}
|
||||
|
||||
static inline void nrLDPC_prep_bn2cnProcBuf_BG1(t_nrLDPC_lut* p_lut, uint16_t Z)
|
||||
{
|
||||
const uint32_t* lut_cn2bnProcBuf = p_lut->cn2bnProcBuf;
|
||||
const uint32_t* lut_cn2bnProcBuf2 = p_lut->cn2bnProcBuf2;
|
||||
const uint8_t* lut_numCnInCnGroups = p_lut->numCnInCnGroups;
|
||||
const uint32_t* lut_startAddrCnGroups = p_lut->startAddrCnGroups;
|
||||
|
||||
uint32_t* p_lut_cn2bn;
|
||||
uint32_t bitOffsetInGroup;
|
||||
uint32_t i;
|
||||
uint32_t j;
|
||||
uint32_t M;
|
||||
|
||||
// For CN groups 3 to 19 no need to send the last BN back since it's single edge
|
||||
// and BN processing does not change the value already in the CN proc buf
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 3 BNs
|
||||
|
||||
p_lut_cn2bn = &lut_cn2bnProcBuf[0];
|
||||
|
||||
M = lut_numCnInCnGroups[0]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[0]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0;j<2; j++)
|
||||
{
|
||||
printf("******3 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[0] + j*bitOffsetInGroup);
|
||||
|
||||
memcpy_printer(p_lut_cn2bn,lut_startAddrCnGroups[0] + j*bitOffsetInGroup,M);
|
||||
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 4 BNs
|
||||
|
||||
p_lut_cn2bn += (M*3); // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[1]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[1]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<3; j++)
|
||||
{
|
||||
printf("******4 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[1] + j*bitOffsetInGroup);
|
||||
memcpy_printer(p_lut_cn2bn,lut_startAddrCnGroups[0] + j*bitOffsetInGroup,M);
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 5 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*4); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[2]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[2]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<4; j++)
|
||||
{
|
||||
printf("******5 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[2] + j*bitOffsetInGroup);
|
||||
memcpy_printer(p_lut_cn2bn,lut_startAddrCnGroups[0] + j*bitOffsetInGroup,M);
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 6 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*5); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[3]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[3]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<5; j++)
|
||||
{
|
||||
printf("******6 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[3] + j*bitOffsetInGroup);
|
||||
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 7 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*6); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[4]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[4]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<6; j++)
|
||||
{
|
||||
printf("******7 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[4] + j*bitOffsetInGroup);
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 8 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*7); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[5]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[5]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<7; j++)
|
||||
{
|
||||
printf("******8 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[5] + j*bitOffsetInGroup);
|
||||
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 9 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*8); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[6]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[6]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<8; j++)
|
||||
{
|
||||
printf("******9 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[6] + j*bitOffsetInGroup);
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 10 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*9); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[7]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[7]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<9; j++)
|
||||
{
|
||||
p_cnProcBuf = &cnProcBuf[lut_startAddrCnGroups[7] + j*bitOffsetInGroup];
|
||||
printf("******10 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[7] + j*bitOffsetInGroup);
|
||||
}
|
||||
|
||||
// =====================================================================
|
||||
// CN group with 19 BNs
|
||||
|
||||
// p_lut_cn2bn += (M*10); // Number of elements of previous group
|
||||
p_lut_cn2bn += M; // Number of elements of previous group
|
||||
M = lut_numCnInCnGroups[8]*Z;
|
||||
bitOffsetInGroup = lut_numCnInCnGroups_BG1_R13[8]*NR_LDPC_ZMAX;
|
||||
|
||||
for (j=0; j<19; j++)
|
||||
{
|
||||
|
||||
printf("******19 BN (%d): cNProcBuf output at %d\n",j,lut_startAddrCnGroups[8] + j*bitOffsetInGroup);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
\brief Copies the values in the LLR results buffer to their corresponding place in the output LLR vector.
|
||||
\param p_lut Pointer to decoder LUTs
|
||||
|
||||
Reference in New Issue
Block a user