Merge remote-tracking branch 'origin/nrLDPC_coding_improvements_3' into integration_2025_w08 (!3227)

fix(nrLDPC_coding): timers in DL encoding, fix(ldpctest): Confusion in sizes

Main improvements:

1. fix(ldpctest): Confusion in sizes
   IMPORTANT: This fix makes that ldpctest now works with BG2 and K' != K!
   (Worth double checking with more cases than I did check with though)
   The variable block_length had an ambiguous role and was used as both K and
   Kprime. This was leading to arrays with wrong sizes and functions with wrong
   arguments. Now there is not anymore block_length but K and Kprime.
   Kprime can be set with the command line argument -l.
   There was also some problems with array allocation for segments with length
   not divisible by 8. A proper sizing with ((size_in_bits + 7) & ~7) / 8 was
   used.
   A proper masking of the last byte containing payload bits was also added to
   keep filler bits to 0 after random initialization.

2. fix(nrLDPC_coding): timers in DL encoding
   While timers were available for rate matching and interleaving in the new
   interface, these timers were not merged to rate matching and interleaving
   timers in nr_dlsch_coding.
This commit is contained in:
Jaroslava Fiedlerova
2025-02-21 14:23:24 +01:00
6 changed files with 470 additions and 280 deletions
@@ -49,7 +49,7 @@ typedef struct ldpc8blocks_args_s {
encoder_implemparams_t impp;
} ldpc8blocks_args_t;
static void ldpc8blocks_coding_segment(void *p)
static void ldpc8blocks(void *p)
{
ldpc8blocks_args_t *args = (ldpc8blocks_args_t *)p;
nrLDPC_TB_encoding_parameters_t *nrLDPC_TB_encoding_parameters = args->nrLDPC_TB_encoding_parameters;
@@ -192,7 +192,7 @@ static int nrLDPC_prepare_TB_encoding(nrLDPC_slot_encoding_parameters_t *nrLDPC_
perJobImpp->impp = impp;
perJobImpp->nrLDPC_TB_encoding_parameters = nrLDPC_TB_encoding_parameters;
task_t t = {.func = ldpc8blocks_coding_segment, .args = perJobImpp};
task_t t = {.func = ldpc8blocks, .args = perJobImpp};
pushTpool(nrLDPC_slot_encoding_parameters->threadPool, t);
}
return n_seg;