diff --git a/openair1/PHY/MODULATION/nr_modulation.c b/openair1/PHY/MODULATION/nr_modulation.c index e0a4254563..ee880f8c2a 100644 --- a/openair1/PHY/MODULATION/nr_modulation.c +++ b/openair1/PHY/MODULATION/nr_modulation.c @@ -20,6 +20,7 @@ */ #include "nr_modulation.h" +#include "PHY/NR_REFSIG/nr_mod_table.h" extern short nr_mod_table[NR_MOD_TABLE_SIZE_SHORT]; @@ -30,16 +31,29 @@ void nr_modulation(uint32_t *in, { uint16_t offset; uint16_t mask = ((1<>((i*mod_order)&0x1f)) & mask); @@ -47,18 +61,42 @@ void nr_modulation(uint32_t *in, idx |= (in[(i*mod_order/32)+1]<>((i*mod_order)&0x1f)) & mask); + return; - out[i<<1] = nr_mod_table[(offset+idx)<<1]; - out[(i<<1)+1] = nr_mod_table[((offset+idx)<<1)+1]; - } + case 8: + nr_mod_table32 = (int32_t*) nr_mod_table; + for (int i=0; i>((i*mod_order)&0x1f)) & mask); + + out32[i] = nr_mod_table32[(offset+idx)]; } } diff --git a/openair1/PHY/NR_REFSIG/nr_mod_table.h b/openair1/PHY/NR_REFSIG/nr_mod_table.h index 99d207ecc8..f644e86359 100644 --- a/openair1/PHY/NR_REFSIG/nr_mod_table.h +++ b/openair1/PHY/NR_REFSIG/nr_mod_table.h @@ -30,4 +30,8 @@ #define NR_MOD_TABLE_QAM256_OFFSET 87 short nr_mod_table[NR_MOD_TABLE_SIZE_SHORT] = {0,0,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,7327,7327,-7327,7327,7327,-7327,-7327,-7327,21981,7327,-21981,7327,21981,-7327,-21981,-7327,7327,21981,-7327,21981,7327,-21981,-7327,-21981,21981,21981,-21981,21981,21981,-21981,-21981,-21981,10726,10726,-10726,10726,10726,-10726,-10726,-10726,17876,10726,-17876,10726,17876,-10726,-17876,-10726,10726,17876,-10726,17876,10726,-17876,-10726,-17876,17876,17876,-17876,17876,17876,-17876,-17876,-17876,3576,10726,-3576,10726,3576,-10726,-3576,-10726,25027,10726,-25027,10726,25027,-10726,-25027,-10726,3576,17876,-3576,17876,3576,-17876,-3576,-17876,25027,17876,-25027,17876,25027,-17876,-25027,-17876,10726,3576,-10726,3576,10726,-3576,-10726,-3576,17876,3576,-17876,3576,17876,-3576,-17876,-3576,10726,25027,-10726,25027,10726,-25027,-10726,-25027,17876,25027,-17876,25027,17876,-25027,-17876,-25027,3576,3576,-3576,3576,3576,-3576,-3576,-3576,25027,3576,-25027,3576,25027,-3576,-25027,-3576,3576,25027,-3576,25027,3576,-25027,-3576,-25027,25027,25027,-25027,25027,25027,-25027,-25027,-25027,8886,8886,-8886,8886,8886,-8886,-8886,-8886,19547,8886,-19547,8886,19547,-8886,-19547,-8886,8886,19547,-8886,19547,8886,-19547,-8886,-19547,19547,19547,-19547,19547,19547,-19547,-19547,-19547,5332,8886,-5332,8886,5332,-8886,-5332,-8886,23101,8886,-23101,8886,23101,-8886,-23101,-8886,5332,19547,-5332,19547,5332,-19547,-5332,-19547,23101,19547,-23101,19547,23101,-19547,-23101,-19547,8886,5332,-8886,5332,8886,-5332,-8886,-5332,19547,5332,-19547,5332,19547,-5332,-19547,-5332,8886,23101,-8886,23101,8886,-23101,-8886,-23101,19547,23101,-19547,23101,19547,-23101,-19547,-23101,5332,5332,-5332,5332,5332,-5332,-5332,-5332,23101,5332,-23101,5332,23101,-5332,-23101,-5332,5332,23101,-5332,23101,5332,-23101,-5332,-23101,23101,23101,-23101,23101,23101,-23101,-23101,-23101,12439,8886,-12439,8886,12439,-8886,-12439,-8886,15993,8886,-15993,8886,15993,-8886,-15993,-8886,12439,19547,-12439,19547,12439,-19547,-12439,-19547,15993,19547,-15993,19547,15993,-19547,-15993,-19547,1778,8886,-1778,8886,1778,-8886,-1778,-8886,26655,8886,-26655,8886,26655,-8886,-26655,-8886,1778,19547,-1778,19547,1778,-19547,-1778,-19547,26655,19547,-26655,19547,26655,-19547,-26655,-19547,12439,5332,-12439,5332,12439,-5332,-12439,-5332,15993,5332,-15993,5332,15993,-5332,-15993,-5332,12439,23101,-12439,23101,12439,-23101,-12439,-23101,15993,23101,-15993,23101,15993,-23101,-15993,-23101,1778,5332,-1778,5332,1778,-5332,-1778,-5332,26655,5332,-26655,5332,26655,-5332,-26655,-5332,1778,23101,-1778,23101,1778,-23101,-1778,-23101,26655,23101,-26655,23101,26655,-23101,-26655,-23101,8886,12439,-8886,12439,8886,-12439,-8886,-12439,19547,12439,-19547,12439,19547,-12439,-19547,-12439,8886,15993,-8886,15993,8886,-15993,-8886,-15993,19547,15993,-19547,15993,19547,-15993,-19547,-15993,5332,12439,-5332,12439,5332,-12439,-5332,-12439,23101,12439,-23101,12439,23101,-12439,-23101,-12439,5332,15993,-5332,15993,5332,-15993,-5332,-15993,23101,15993,-23101,15993,23101,-15993,-23101,-15993,8886,1778,-8886,1778,8886,-1778,-8886,-1778,19547,1778,-19547,1778,19547,-1778,-19547,-1778,8886,26655,-8886,26655,8886,-26655,-8886,-26655,19547,26655,-19547,26655,19547,-26655,-19547,-26655,5332,1778,-5332,1778,5332,-1778,-5332,-1778,23101,1778,-23101,1778,23101,-1778,-23101,-1778,5332,26655,-5332,26655,5332,-26655,-5332,-26655,23101,26655,-23101,26655,23101,-26655,-23101,-26655,12439,12439,-12439,12439,12439,-12439,-12439,-12439,15993,12439,-15993,12439,15993,-12439,-15993,-12439,12439,15993,-12439,15993,12439,-15993,-12439,-15993,15993,15993,-15993,15993,15993,-15993,-15993,-15993,1778,12439,-1778,12439,1778,-12439,-1778,-12439,26655,12439,-26655,12439,26655,-12439,-26655,-12439,1778,15993,-1778,15993,1778,-15993,-1778,-15993,26655,15993,-26655,15993,26655,-15993,-26655,-15993,12439,1778,-12439,1778,12439,-1778,-12439,-1778,15993,1778,-15993,1778,15993,-1778,-15993,-1778,12439,26655,-12439,26655,12439,-26655,-12439,-26655,15993,26655,-15993,26655,15993,-26655,-15993,-26655,1778,1778,-1778,1778,1778,-1778,-1778,-1778,26655,1778,-26655,1778,26655,-1778,-26655,-1778,1778,26655,-1778,26655,1778,-26655,-1778,-26655,26655,26655,-26655,26655,26655,-26655,-26655,-26655}; + +short nr_qpsk_byte_mod_table[2048] = {16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,16384,16384,16384,-16384,-16384,16384,16384,16384,16384,16384,16384,-16384,16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384,-16384}; + +short nr_qam16_byte_mod_table[1024] = {7327,7327,7327,7327,-7327,7327,7327,7327,7327,-7327,7327,7327,-7327,-7327,7327,7327,21981,7327,7327,7327,-21981,7327,7327,7327,21981,-7327,7327,7327,-21981,-7327,7327,7327,7327,21981,7327,7327,-7327,21981,7327,7327,7327,-21981,7327,7327,-7327,-21981,7327,7327,21981,21981,7327,7327,-21981,21981,7327,7327,21981,-21981,7327,7327,-21981,-21981,7327,7327,7327,7327,-7327,7327,-7327,7327,-7327,7327,7327,-7327,-7327,7327,-7327,-7327,-7327,7327,21981,7327,-7327,7327,-21981,7327,-7327,7327,21981,-7327,-7327,7327,-21981,-7327,-7327,7327,7327,21981,-7327,7327,-7327,21981,-7327,7327,7327,-21981,-7327,7327,-7327,-21981,-7327,7327,21981,21981,-7327,7327,-21981,21981,-7327,7327,21981,-21981,-7327,7327,-21981,-21981,-7327,7327,7327,7327,7327,-7327,-7327,7327,7327,-7327,7327,-7327,7327,-7327,-7327,-7327,7327,-7327,21981,7327,7327,-7327,-21981,7327,7327,-7327,21981,-7327,7327,-7327,-21981,-7327,7327,-7327,7327,21981,7327,-7327,-7327,21981,7327,-7327,7327,-21981,7327,-7327,-7327,-21981,7327,-7327,21981,21981,7327,-7327,-21981,21981,7327,-7327,21981,-21981,7327,-7327,-21981,-21981,7327,-7327,7327,7327,-7327,-7327,-7327,7327,-7327,-7327,7327,-7327,-7327,-7327,-7327,-7327,-7327,-7327,21981,7327,-7327,-7327,-21981,7327,-7327,-7327,21981,-7327,-7327,-7327,-21981,-7327,-7327,-7327,7327,21981,-7327,-7327,-7327,21981,-7327,-7327,7327,-21981,-7327,-7327,-7327,-21981,-7327,-7327,21981,21981,-7327,-7327,-21981,21981,-7327,-7327,21981,-21981,-7327,-7327,-21981,-21981,-7327,-7327,7327,7327,21981,7327,-7327,7327,21981,7327,7327,-7327,21981,7327,-7327,-7327,21981,7327,21981,7327,21981,7327,-21981,7327,21981,7327,21981,-7327,21981,7327,-21981,-7327,21981,7327,7327,21981,21981,7327,-7327,21981,21981,7327,7327,-21981,21981,7327,-7327,-21981,21981,7327,21981,21981,21981,7327,-21981,21981,21981,7327,21981,-21981,21981,7327,-21981,-21981,21981,7327,7327,7327,-21981,7327,-7327,7327,-21981,7327,7327,-7327,-21981,7327,-7327,-7327,-21981,7327,21981,7327,-21981,7327,-21981,7327,-21981,7327,21981,-7327,-21981,7327,-21981,-7327,-21981,7327,7327,21981,-21981,7327,-7327,21981,-21981,7327,7327,-21981,-21981,7327,-7327,-21981,-21981,7327,21981,21981,-21981,7327,-21981,21981,-21981,7327,21981,-21981,-21981,7327,-21981,-21981,-21981,7327,7327,7327,21981,-7327,-7327,7327,21981,-7327,7327,-7327,21981,-7327,-7327,-7327,21981,-7327,21981,7327,21981,-7327,-21981,7327,21981,-7327,21981,-7327,21981,-7327,-21981,-7327,21981,-7327,7327,21981,21981,-7327,-7327,21981,21981,-7327,7327,-21981,21981,-7327,-7327,-21981,21981,-7327,21981,21981,21981,-7327,-21981,21981,21981,-7327,21981,-21981,21981,-7327,-21981,-21981,21981,-7327,7327,7327,-21981,-7327,-7327,7327,-21981,-7327,7327,-7327,-21981,-7327,-7327,-7327,-21981,-7327,21981,7327,-21981,-7327,-21981,7327,-21981,-7327,21981,-7327,-21981,-7327,-21981,-7327,-21981,-7327,7327,21981,-21981,-7327,-7327,21981,-21981,-7327,7327,-21981,-21981,-7327,-7327,-21981,-21981,-7327,21981,21981,-21981,-7327,-21981,21981,-21981,-7327,21981,-21981,-21981,-7327,-21981,-21981,-21981,-7327,7327,7327,7327,21981,-7327,7327,7327,21981,7327,-7327,7327,21981,-7327,-7327,7327,21981,21981,7327,7327,21981,-21981,7327,7327,21981,21981,-7327,7327,21981,-21981,-7327,7327,21981,7327,21981,7327,21981,-7327,21981,7327,21981,7327,-21981,7327,21981,-7327,-21981,7327,21981,21981,21981,7327,21981,-21981,21981,7327,21981,21981,-21981,7327,21981,-21981,-21981,7327,21981,7327,7327,-7327,21981,-7327,7327,-7327,21981,7327,-7327,-7327,21981,-7327,-7327,-7327,21981,21981,7327,-7327,21981,-21981,7327,-7327,21981,21981,-7327,-7327,21981,-21981,-7327,-7327,21981,7327,21981,-7327,21981,-7327,21981,-7327,21981,7327,-21981,-7327,21981,-7327,-21981,-7327,21981,21981,21981,-7327,21981,-21981,21981,-7327,21981,21981,-21981,-7327,21981,-21981,-21981,-7327,21981,7327,7327,7327,-21981,-7327,7327,7327,-21981,7327,-7327,7327,-21981,-7327,-7327,7327,-21981,21981,7327,7327,-21981,-21981,7327,7327,-21981,21981,-7327,7327,-21981,-21981,-7327,7327,-21981,7327,21981,7327,-21981,-7327,21981,7327,-21981,7327,-21981,7327,-21981,-7327,-21981,7327,-21981,21981,21981,7327,-21981,-21981,21981,7327,-21981,21981,-21981,7327,-21981,-21981,-21981,7327,-21981,7327,7327,-7327,-21981,-7327,7327,-7327,-21981,7327,-7327,-7327,-21981,-7327,-7327,-7327,-21981,21981,7327,-7327,-21981,-21981,7327,-7327,-21981,21981,-7327,-7327,-21981,-21981,-7327,-7327,-21981,7327,21981,-7327,-21981,-7327,21981,-7327,-21981,7327,-21981,-7327,-21981,-7327,-21981,-7327,-21981,21981,21981,-7327,-21981,-21981,21981,-7327,-21981,21981,-21981,-7327,-21981,-21981,-21981,-7327,-21981,7327,7327,21981,21981,-7327,7327,21981,21981,7327,-7327,21981,21981,-7327,-7327,21981,21981,21981,7327,21981,21981,-21981,7327,21981,21981,21981,-7327,21981,21981,-21981,-7327,21981,21981,7327,21981,21981,21981,-7327,21981,21981,21981,7327,-21981,21981,21981,-7327,-21981,21981,21981,21981,21981,21981,21981,-21981,21981,21981,21981,21981,-21981,21981,21981,-21981,-21981,21981,21981,7327,7327,-21981,21981,-7327,7327,-21981,21981,7327,-7327,-21981,21981,-7327,-7327,-21981,21981,21981,7327,-21981,21981,-21981,7327,-21981,21981,21981,-7327,-21981,21981,-21981,-7327,-21981,21981,7327,21981,-21981,21981,-7327,21981,-21981,21981,7327,-21981,-21981,21981,-7327,-21981,-21981,21981,21981,21981,-21981,21981,-21981,21981,-21981,21981,21981,-21981,-21981,21981,-21981,-21981,-21981,21981,7327,7327,21981,-21981,-7327,7327,21981,-21981,7327,-7327,21981,-21981,-7327,-7327,21981,-21981,21981,7327,21981,-21981,-21981,7327,21981,-21981,21981,-7327,21981,-21981,-21981,-7327,21981,-21981,7327,21981,21981,-21981,-7327,21981,21981,-21981,7327,-21981,21981,-21981,-7327,-21981,21981,-21981,21981,21981,21981,-21981,-21981,21981,21981,-21981,21981,-21981,21981,-21981,-21981,-21981,21981,-21981,7327,7327,-21981,-21981,-7327,7327,-21981,-21981,7327,-7327,-21981,-21981,-7327,-7327,-21981,-21981,21981,7327,-21981,-21981,-21981,7327,-21981,-21981,21981,-7327,-21981,-21981,-21981,-7327,-21981,-21981,7327,21981,-21981,-21981,-7327,21981,-21981,-21981,7327,-21981,-21981,-21981,-7327,-21981,-21981,-21981,21981,21981,-21981,-21981,-21981,21981,-21981,-21981,21981,-21981,-21981,-21981,-21981,-21981,-21981,-21981}; #endif diff --git a/openair1/PHY/NR_TRANSPORT/nr_dci.c b/openair1/PHY/NR_TRANSPORT/nr_dci.c index a29211b55b..3344682f20 100644 --- a/openair1/PHY/NR_TRANSPORT/nr_dci.c +++ b/openair1/PHY/NR_TRANSPORT/nr_dci.c @@ -161,7 +161,7 @@ uint8_t nr_generate_dci_top(nfapi_nr_dl_tti_pdcch_pdu *pdcch_pdu, int16_t amp, NR_DL_FRAME_PARMS frame_parms) { - int16_t mod_dmrs[NR_MAX_CSET_DURATION][NR_MAX_PDCCH_DMRS_LENGTH>>1]; // 3 for the max coreset duration + int16_t mod_dmrs[NR_MAX_CSET_DURATION][NR_MAX_PDCCH_DMRS_LENGTH>>1] __attribute__((aligned(128))); // 3 for the max coreset duration uint16_t cset_start_sc; uint8_t cset_start_symb, cset_nsymb; int k,l,k_prime,dci_idx, dmrs_idx; @@ -260,7 +260,7 @@ uint8_t nr_generate_dci_top(nfapi_nr_dl_tti_pdcch_pdu *pdcch_pdu, scrambled_output[6], scrambled_output[7], scrambled_output[8], scrambled_output[9], scrambled_output[10],scrambled_output[11] ); #endif /// QPSK modulation - int16_t mod_dci[NR_MAX_DCI_SIZE>>1]; + int16_t mod_dci[NR_MAX_DCI_SIZE>>1] __attribute__((aligned(128))); nr_modulation(scrambled_output, encoded_length, DMRS_MOD_ORDER, mod_dci); //Qm = 2 as DMRS is QPSK modulated #ifdef DEBUG_DCI diff --git a/openair1/SIMULATION/NR_PHY/dlschsim.c b/openair1/SIMULATION/NR_PHY/dlschsim.c index 9374050e58..8f53b9acc4 100644 --- a/openair1/SIMULATION/NR_PHY/dlschsim.c +++ b/openair1/SIMULATION/NR_PHY/dlschsim.c @@ -37,7 +37,6 @@ #include "PHY/INIT/phy_init.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" #include "PHY/NR_TRANSPORT/nr_dlsch.h" #include "PHY/NR_TRANSPORT/nr_transport_proto.h" diff --git a/openair1/SIMULATION/NR_PHY/dlsim.c b/openair1/SIMULATION/NR_PHY/dlsim.c index 137c358d7f..90aa3f6333 100644 --- a/openair1/SIMULATION/NR_PHY/dlsim.c +++ b/openair1/SIMULATION/NR_PHY/dlsim.c @@ -39,7 +39,6 @@ #include "PHY/INIT/phy_init.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" #include "PHY/NR_TRANSPORT/nr_transport_proto.h" #include "PHY/NR_UE_TRANSPORT/nr_transport_proto_ue.h" diff --git a/openair1/SIMULATION/NR_PHY/pbchsim.c b/openair1/SIMULATION/NR_PHY/pbchsim.c index 2144652f86..8c37024858 100644 --- a/openair1/SIMULATION/NR_PHY/pbchsim.c +++ b/openair1/SIMULATION/NR_PHY/pbchsim.c @@ -33,7 +33,6 @@ #include "PHY/defs_nr_UE.h" #include "PHY/defs_gNB.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" #include "PHY/INIT/phy_init.h" diff --git a/openair1/SIMULATION/NR_PHY/prachsim.c b/openair1/SIMULATION/NR_PHY/prachsim.c index 2db5bc905c..950f9a67f6 100644 --- a/openair1/SIMULATION/NR_PHY/prachsim.c +++ b/openair1/SIMULATION/NR_PHY/prachsim.c @@ -37,7 +37,6 @@ #include "SCHED_NR_UE/phy_frame_config_nr.h" #include "PHY/phy_vars_nr_ue.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" #include "PHY/INIT/phy_init.h" diff --git a/openair1/SIMULATION/NR_PHY/pucchsim.c b/openair1/SIMULATION/NR_PHY/pucchsim.c index 004a7b8de8..86f7d651e4 100644 --- a/openair1/SIMULATION/NR_PHY/pucchsim.c +++ b/openair1/SIMULATION/NR_PHY/pucchsim.c @@ -33,7 +33,6 @@ #include "PHY/defs_nr_UE.h" #include "PHY/defs_gNB.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" #include "PHY/INIT/phy_init.h" diff --git a/openair1/SIMULATION/NR_PHY/ulschsim.c b/openair1/SIMULATION/NR_PHY/ulschsim.c index b0557ef1b4..af49aa757b 100644 --- a/openair1/SIMULATION/NR_PHY/ulschsim.c +++ b/openair1/SIMULATION/NR_PHY/ulschsim.c @@ -34,7 +34,6 @@ #include "PHY/defs_gNB.h" #include "PHY/INIT/phy_init.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/MODULATION/modulation_eNB.h" #include "PHY/MODULATION/modulation_UE.h" #include "PHY/NR_TRANSPORT/nr_transport_proto.h" diff --git a/openair1/SIMULATION/NR_PHY/ulsim.c b/openair1/SIMULATION/NR_PHY/ulsim.c index bcaa967a30..f016092442 100644 --- a/openair1/SIMULATION/NR_PHY/ulsim.c +++ b/openair1/SIMULATION/NR_PHY/ulsim.c @@ -37,7 +37,6 @@ #include "PHY/MODULATION/modulation_UE.h" #include "PHY/MODULATION/nr_modulation.h" #include "PHY/NR_REFSIG/dmrs_nr.h" -#include "PHY/NR_REFSIG/nr_mod_table.h" #include "PHY/NR_REFSIG/refsig_defs_ue.h" #include "PHY/NR_TRANSPORT/nr_dlsch.h" #include "PHY/NR_TRANSPORT/nr_sch_dmrs.h"