Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
spbro
OpenXG-RAN
Commits
51df6625
Commit
51df6625
authored
Mar 03, 2022
by
Sagar Parsawar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OAI dft/idft support for 768 and 384
parent
865fdb98
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
85 additions
and
2 deletions
+85
-2
openair1/PHY/MODULATION/ofdm_mod.c
openair1/PHY/MODULATION/ofdm_mod.c
+8
-0
openair1/PHY/MODULATION/slot_fep_nr.c
openair1/PHY/MODULATION/slot_fep_nr.c
+3
-0
openair1/PHY/NR_UE_TRANSPORT/pss_nr.c
openair1/PHY/NR_UE_TRANSPORT/pss_nr.c
+12
-0
openair1/PHY/TOOLS/oai_dfts.c
openair1/PHY/TOOLS/oai_dfts.c
+62
-2
No files found.
openair1/PHY/MODULATION/ofdm_mod.c
View file @
51df6625
...
...
@@ -149,10 +149,18 @@ void PHY_ofdm_mod(int *input, /// pointer to complex input
idftsize
=
IDFT_256
;
break
;
case
384
:
idftsize
=
IDFT_384
;
break
;
case
512
:
idftsize
=
IDFT_512
;
break
;
case
768
:
idftsize
=
IDFT_768
;
break
;
case
1024
:
idftsize
=
IDFT_1024
;
break
;
...
...
openair1/PHY/MODULATION/slot_fep_nr.c
View file @
51df6625
...
...
@@ -43,6 +43,9 @@ dft_size_idx_t get_dft_size_idx(uint16_t ofdm_symbol_size)
case
256
:
return
DFT_256
;
case
384
:
return
DFT_384
;
case
512
:
return
DFT_512
;
...
...
openair1/PHY/NR_UE_TRANSPORT/pss_nr.c
View file @
51df6625
...
...
@@ -74,6 +74,10 @@ idft_size_idx_t get_idft(int ofdm_symbol_size)
return
IDFT_256
;
break
;
case
384
:
return
IDFT_384
;
break
;
case
512
:
return
IDFT_512
;
break
;
...
...
@@ -139,10 +143,18 @@ dft_size_idx_t get_dft(int ofdm_symbol_size)
return
DFT_256
;
break
;
case
384
:
return
DFT_384
;
break
;
case
512
:
return
DFT_512
;
break
;
case
768
:
return
DFT_768
;
break
;
case
1024
:
return
DFT_1024
;
break
;
...
...
openair1/PHY/TOOLS/oai_dfts.c
View file @
51df6625
...
...
@@ -8680,6 +8680,7 @@ void dft384(int16_t *x,int16_t *y,unsigned char scale_flag) // 96 x 4
};
static int16_t twa432[107*2*4];
static int16_t twb432[107*2*4];
static int16_t twc432[107*2*4];
...
...
@@ -9059,7 +9060,7 @@ static int16_t twc768[191*2*4];
void dft768(int16_t *x,int16_t *y,unsigned char scale_flag) { // 192x 4;
#if
1
#if
0
int i,j;
simd_q15_t *x128=(simd_q15_t *)x;
simd_q15_t *y128=(simd_q15_t *)y;
...
...
@@ -9162,6 +9163,63 @@ void dft768(int16_t *x,int16_t *y,unsigned char scale_flag) { // 192x 4;
}
static int16_t twa384i[95*2*4];
static int16_t twb384i[95*2*4];
// 128 x 3
void idft384(int16_t *input, int16_t *output, unsigned char scale)
{
int i,i2,j;
uint32_t tmp[3][128]__attribute__((aligned(32)));
uint32_t tmpo[3][128] __attribute__((aligned(32)));
simd_q15_t *y128p=(simd_q15_t*)output;
simd_q15_t ONE_OVER_SQRT3_Q15_128 = set1_int16(ONE_OVER_SQRT3_Q15);
for (i=0,j=0; i<128; i++) {
tmp[0][i] = ((uint32_t *)input)[j++];
tmp[1][i] = ((uint32_t *)input)[j++];
tmp[2][i] = ((uint32_t *)input)[j++];
}
idft128((int16_t*)(tmp[0]),(int16_t*)(tmpo[0]),1);
idft128((int16_t*)(tmp[1]),(int16_t*)(tmpo[1]),1);
idft128((int16_t*)(tmp[2]),(int16_t*)(tmpo[2]),1);
for (i=0,i2=0; i<256; i+=8,i2+=4) {
ibfly3((simd_q15_t*)(&tmpo[0][i2]),(simd_q15_t*)(&tmpo[1][i2]),(simd_q15_t*)(&tmpo[2][i2]),
(simd_q15_t*)(output+i),(simd_q15_t*)(output+256+i),(simd_q15_t*)(output+512+i),
(simd_q15_t*)(twa384+i),(simd_q15_t*)(twb384+i));
}
if (scale==1) {
for (i=0; i<6; i++) {
y128p[0] = mulhi_int16(y128p[0],ONE_OVER_SQRT3_Q15_128);
y128p[1] = mulhi_int16(y128p[1],ONE_OVER_SQRT3_Q15_128);
y128p[2] = mulhi_int16(y128p[2],ONE_OVER_SQRT3_Q15_128);
y128p[3] = mulhi_int16(y128p[3],ONE_OVER_SQRT3_Q15_128);
y128p[4] = mulhi_int16(y128p[4],ONE_OVER_SQRT3_Q15_128);
y128p[5] = mulhi_int16(y128p[5],ONE_OVER_SQRT3_Q15_128);
y128p[6] = mulhi_int16(y128p[6],ONE_OVER_SQRT3_Q15_128);
y128p[7] = mulhi_int16(y128p[7],ONE_OVER_SQRT3_Q15_128);
y128p[8] = mulhi_int16(y128p[8],ONE_OVER_SQRT3_Q15_128);
y128p[9] = mulhi_int16(y128p[9],ONE_OVER_SQRT3_Q15_128);
y128p[10] = mulhi_int16(y128p[10],ONE_OVER_SQRT3_Q15_128);
y128p[11] = mulhi_int16(y128p[11],ONE_OVER_SQRT3_Q15_128);
y128p[12] = mulhi_int16(y128p[12],ONE_OVER_SQRT3_Q15_128);
y128p[13] = mulhi_int16(y128p[13],ONE_OVER_SQRT3_Q15_128);
y128p[14] = mulhi_int16(y128p[14],ONE_OVER_SQRT3_Q15_128);
y128p[15] = mulhi_int16(y128p[15],ONE_OVER_SQRT3_Q15_128);
y128p+=16;
}
}
_mm_empty();
_m_empty();
}
// 256 x 3
void idft768(int16_t *input, int16_t *output, unsigned char scale)
{
...
...
@@ -10669,6 +10727,7 @@ int dfts_autoinit(void)
init_rad3_rep(324,twa324,twb324);
init_rad3_rep(360,twa360,twb360);
init_rad4_rep(384,twa384,twb384,twc384);
init_rad3_rep(384,twa384i,twb384i);
init_rad4_rep(432,twa432,twb432,twc432);
init_rad4_rep(480,twa480,twb480,twc480);
init_rad3_rep(540,twa540,twb540);
...
...
@@ -10676,7 +10735,8 @@ int dfts_autoinit(void)
init_rad2_rep(600,twa600);
init_rad3_rep(648,twa648,twb648);
init_rad4_rep(720,twa720,twb720,twc720);
init_rad4_rep
(
768
,
twa768
,
twb768
,
twc768
);
//init_rad4_rep(768,twa768,twb768,twc768);
init_rad3_rep(768,twa768,twb768);
init_rad3_rep(864,twa864,twb864);
init_rad3_rep(900,twa900,twb900);
init_rad4_rep(960,twa960,twb960,twc960);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment