option q is to set cpu measurements but it is hardcoded in some places
This commit is contained in:
@@ -29,7 +29,7 @@
|
|||||||
#include "common/config/config_userapi.h"
|
#include "common/config/config_userapi.h"
|
||||||
#include <common/utils/threadPool/thread-pool.h>
|
#include <common/utils/threadPool/thread-pool.h>
|
||||||
// global var for openair performance profiler
|
// global var for openair performance profiler
|
||||||
int opp_enabled = 0;
|
int cpu_meas_enabled = 0;
|
||||||
double cpu_freq_GHz __attribute__ ((aligned(32)));
|
double cpu_freq_GHz __attribute__ ((aligned(32)));
|
||||||
|
|
||||||
double cpu_freq_GHz __attribute__ ((aligned(32)))=0.0;
|
double cpu_freq_GHz __attribute__ ((aligned(32)))=0.0;
|
||||||
@@ -56,7 +56,7 @@ void print_meas_now(time_stats_t *ts,
|
|||||||
const char *name,
|
const char *name,
|
||||||
FILE *file_name)
|
FILE *file_name)
|
||||||
{
|
{
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
//static double cpu_freq_GHz = 3.2;
|
//static double cpu_freq_GHz = 3.2;
|
||||||
|
|
||||||
//if (cpu_freq_GHz == 0.0)
|
//if (cpu_freq_GHz == 0.0)
|
||||||
@@ -73,7 +73,7 @@ void print_meas(time_stats_t *ts,
|
|||||||
time_stats_t *total_exec_time,
|
time_stats_t *total_exec_time,
|
||||||
time_stats_t *sf_exec_time)
|
time_stats_t *sf_exec_time)
|
||||||
{
|
{
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
static int first_time = 0;
|
static int first_time = 0;
|
||||||
static double cpu_freq_GHz = 0.0;
|
static double cpu_freq_GHz = 0.0;
|
||||||
|
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
#include <linux/types.h>
|
#include <linux/types.h>
|
||||||
// global var to enable openair performance profiler
|
// global var to enable openair performance profiler
|
||||||
extern int opp_enabled;
|
extern int cpu_meas_enabled;
|
||||||
extern double cpu_freq_GHz __attribute__ ((aligned(32)));;
|
extern double cpu_freq_GHz __attribute__ ((aligned(32)));;
|
||||||
// structure to store data to compute cpu measurment
|
// structure to store data to compute cpu measurment
|
||||||
#if defined(__x86_64__) || defined(__i386__)
|
#if defined(__x86_64__) || defined(__i386__)
|
||||||
@@ -74,13 +74,9 @@ typedef struct time_stats {
|
|||||||
} time_stats_t;
|
} time_stats_t;
|
||||||
#define MEASURE_ENABLED(X) (X->meas_enabled)
|
#define MEASURE_ENABLED(X) (X->meas_enabled)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static inline void start_meas(time_stats_t *ts) __attribute__((always_inline));
|
static inline void start_meas(time_stats_t *ts) __attribute__((always_inline));
|
||||||
static inline void stop_meas(time_stats_t *ts) __attribute__((always_inline));
|
static inline void stop_meas(time_stats_t *ts) __attribute__((always_inline));
|
||||||
|
|
||||||
|
|
||||||
void print_meas_now(time_stats_t *ts, const char *name, FILE *file_name);
|
void print_meas_now(time_stats_t *ts, const char *name, FILE *file_name);
|
||||||
void print_meas(time_stats_t *ts, const char *name, time_stats_t *total_exec_time, time_stats_t *sf_exec_time);
|
void print_meas(time_stats_t *ts, const char *name, time_stats_t *total_exec_time, time_stats_t *sf_exec_time);
|
||||||
size_t print_meas_log(time_stats_t *ts,
|
size_t print_meas_log(time_stats_t *ts,
|
||||||
@@ -130,11 +126,11 @@ static inline uint32_t rdtsc_oai(void) {
|
|||||||
static inline int cpumeas(int action) {
|
static inline int cpumeas(int action) {
|
||||||
switch (action) {
|
switch (action) {
|
||||||
case CPUMEAS_ENABLE:
|
case CPUMEAS_ENABLE:
|
||||||
opp_enabled = 1;
|
cpu_meas_enabled = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CPUMEAS_DISABLE:
|
case CPUMEAS_DISABLE:
|
||||||
opp_enabled = 0;
|
cpu_meas_enabled = 0;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CPUMEAS_GETSTATE:
|
case CPUMEAS_GETSTATE:
|
||||||
@@ -142,11 +138,11 @@ static inline int cpumeas(int action) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return opp_enabled;
|
return cpu_meas_enabled;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void start_meas(time_stats_t *ts) {
|
static inline void start_meas(time_stats_t *ts) {
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
if (ts->meas_flag==0) {
|
if (ts->meas_flag==0) {
|
||||||
ts->trials++;
|
ts->trials++;
|
||||||
ts->in = rdtsc_oai();
|
ts->in = rdtsc_oai();
|
||||||
@@ -159,7 +155,7 @@ static inline void start_meas(time_stats_t *ts) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline void stop_meas(time_stats_t *ts) {
|
static inline void stop_meas(time_stats_t *ts) {
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
long long out = rdtsc_oai();
|
long long out = rdtsc_oai();
|
||||||
if (ts->in) {
|
if (ts->in) {
|
||||||
ts->diff += (out - ts->in);
|
ts->diff += (out - ts->in);
|
||||||
@@ -186,7 +182,7 @@ static inline void reset_meas(time_stats_t *ts) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline void copy_meas(time_stats_t *dst_ts,time_stats_t *src_ts) {
|
static inline void copy_meas(time_stats_t *dst_ts,time_stats_t *src_ts) {
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
dst_ts->trials=src_ts->trials;
|
dst_ts->trials=src_ts->trials;
|
||||||
dst_ts->diff=src_ts->diff;
|
dst_ts->diff=src_ts->diff;
|
||||||
dst_ts->max=src_ts->max;
|
dst_ts->max=src_ts->max;
|
||||||
@@ -195,7 +191,7 @@ static inline void copy_meas(time_stats_t *dst_ts,time_stats_t *src_ts) {
|
|||||||
|
|
||||||
static inline void merge_meas(time_stats_t *dst_ts, const time_stats_t *src_ts)
|
static inline void merge_meas(time_stats_t *dst_ts, const time_stats_t *src_ts)
|
||||||
{
|
{
|
||||||
if (!opp_enabled)
|
if (!cpu_meas_enabled)
|
||||||
return;
|
return;
|
||||||
dst_ts->trials += src_ts->trials;
|
dst_ts->trials += src_ts->trials;
|
||||||
dst_ts->diff += src_ts->diff;
|
dst_ts->diff += src_ts->diff;
|
||||||
|
|||||||
@@ -925,7 +925,7 @@ void init_eNB_proc(int inst) {
|
|||||||
|
|
||||||
AssertFatal(proc->instance_cnt_prach == -1,"instance_cnt_prach = %d\n",proc->instance_cnt_prach);
|
AssertFatal(proc->instance_cnt_prach == -1,"instance_cnt_prach = %d\n",proc->instance_cnt_prach);
|
||||||
|
|
||||||
if (opp_enabled == 1)
|
if (cpu_meas_enabled)
|
||||||
threadCreate(&proc->process_stats_thread, process_stats_thread, (void *)eNB, "opp stats", -1, sched_get_priority_min(SCHED_OAI));
|
threadCreate(&proc->process_stats_thread, process_stats_thread, (void *)eNB, "opp stats", -1, sched_get_priority_min(SCHED_OAI));
|
||||||
if (!IS_SOFTMODEM_NOSTATS_BIT)
|
if (!IS_SOFTMODEM_NOSTATS_BIT)
|
||||||
threadCreate(&proc->L1_stats_thread, L1_stats_thread, (void *)eNB, "L1 stats", -1, sched_get_priority_min(SCHED_OAI));
|
threadCreate(&proc->L1_stats_thread, L1_stats_thread, (void *)eNB, "L1 stats", -1, sched_get_priority_min(SCHED_OAI));
|
||||||
|
|||||||
@@ -1460,7 +1460,7 @@ static void *ru_stats_thread(void *param) {
|
|||||||
while (!oai_exit) {
|
while (!oai_exit) {
|
||||||
sleep(1);
|
sleep(1);
|
||||||
|
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
if (ru->feprx) print_meas(&ru->ofdm_demod_stats,"feprx_ru",NULL,NULL);
|
if (ru->feprx) print_meas(&ru->ofdm_demod_stats,"feprx_ru",NULL,NULL);
|
||||||
|
|
||||||
if (ru->feptx_ofdm) print_meas(&ru->ofdm_mod_stats,"feptx_ofdm_ru",NULL,NULL);
|
if (ru->feptx_ofdm) print_meas(&ru->ofdm_mod_stats,"feptx_ofdm_ru",NULL,NULL);
|
||||||
@@ -2322,7 +2322,7 @@ void init_RU_proc(RU_t *ru) {
|
|||||||
init_feptx_thread(ru, NULL);
|
init_feptx_thread(ru, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (opp_enabled == 1)
|
if (cpu_meas_enabled)
|
||||||
pthread_create(&ru->ru_stats_thread, NULL, ru_stats_thread, (void *)ru);
|
pthread_create(&ru->ru_stats_thread, NULL, ru_stats_thread, (void *)ru);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2420,7 +2420,7 @@ void kill_RU_proc(RU_t *ru) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
LOG_D(PHY, "Joining ru_stats_thread\n");
|
LOG_D(PHY, "Joining ru_stats_thread\n");
|
||||||
pthread_join(ru->ru_stats_thread, NULL);
|
pthread_join(ru->ru_stats_thread, NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2264,7 +2264,6 @@ static void *timer_thread( void *param ) {
|
|||||||
//double t_diff;
|
//double t_diff;
|
||||||
int external_timer = 0;
|
int external_timer = 0;
|
||||||
wait_sync("timer_thread");
|
wait_sync("timer_thread");
|
||||||
opp_enabled = 1;
|
|
||||||
|
|
||||||
// first check if we are receiving timing indications
|
// first check if we are receiving timing indications
|
||||||
if(NFAPI_MODE==NFAPI_UE_STUB_OFFNET) {
|
if(NFAPI_MODE==NFAPI_UE_STUB_OFFNET) {
|
||||||
|
|||||||
+6
-8
@@ -1040,7 +1040,7 @@ void *ru_stats_thread(void *param) {
|
|||||||
while (!oai_exit) {
|
while (!oai_exit) {
|
||||||
sleep(1);
|
sleep(1);
|
||||||
|
|
||||||
if (opp_enabled == 1) {
|
if (cpu_meas_enabled) {
|
||||||
if (ru->feprx) print_meas(&ru->ofdm_demod_stats,"feprx (all ports)",NULL,NULL);
|
if (ru->feprx) print_meas(&ru->ofdm_demod_stats,"feprx (all ports)",NULL,NULL);
|
||||||
|
|
||||||
if (ru->feptx_ofdm) {
|
if (ru->feptx_ofdm) {
|
||||||
@@ -1142,8 +1142,7 @@ void *ru_thread( void *param ) {
|
|||||||
int slot = fp->slots_per_frame-1;
|
int slot = fp->slots_per_frame-1;
|
||||||
int frame = 1023;
|
int frame = 1023;
|
||||||
char threadname[40];
|
char threadname[40];
|
||||||
int initial_wait=0;
|
int initial_wait = 0;
|
||||||
int opp_enabled0 = opp_enabled;
|
|
||||||
|
|
||||||
#ifndef OAI_FHI72
|
#ifndef OAI_FHI72
|
||||||
bool rx_tti_busy[RU_RX_SLOT_DEPTH] = {false};
|
bool rx_tti_busy[RU_RX_SLOT_DEPTH] = {false};
|
||||||
@@ -1231,7 +1230,7 @@ void *ru_thread( void *param ) {
|
|||||||
else LOG_I(PHY,"RU %d rf device ready\n",ru->idx);
|
else LOG_I(PHY,"RU %d rf device ready\n",ru->idx);
|
||||||
} else LOG_I(PHY,"RU %d no rf device\n",ru->idx);
|
} else LOG_I(PHY,"RU %d no rf device\n",ru->idx);
|
||||||
|
|
||||||
LOG_I(PHY,"RU %d RF started opp_enabled %d\n",ru->idx,opp_enabled);
|
LOG_I(PHY, "RU %d RF started cpu_meas_enabled %d\n", ru->idx, cpu_meas_enabled);
|
||||||
// start trx write thread
|
// start trx write thread
|
||||||
if(usrp_tx_thread == 1) {
|
if(usrp_tx_thread == 1) {
|
||||||
if (ru->start_write_thread) {
|
if (ru->start_write_thread) {
|
||||||
@@ -1294,8 +1293,7 @@ void *ru_thread( void *param ) {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (proc->frame_rx>=300) {
|
if (proc->frame_rx>=300) {
|
||||||
initial_wait=0;
|
initial_wait = 0;
|
||||||
opp_enabled = opp_enabled0;
|
|
||||||
}
|
}
|
||||||
if (initial_wait == 0 && ru->rx_fhaul.trials > 1000) {
|
if (initial_wait == 0 && ru->rx_fhaul.trials > 1000) {
|
||||||
reset_meas(&ru->rx_fhaul);
|
reset_meas(&ru->rx_fhaul);
|
||||||
@@ -1460,7 +1458,7 @@ void init_RU_proc(RU_t *ru) {
|
|||||||
|
|
||||||
if(emulate_rf)
|
if(emulate_rf)
|
||||||
threadCreate( &proc->pthread_emulateRF, emulatedRF_thread, (void *)proc, "emulateRF", -1, OAI_PRIORITY_RT );
|
threadCreate( &proc->pthread_emulateRF, emulatedRF_thread, (void *)proc, "emulateRF", -1, OAI_PRIORITY_RT );
|
||||||
if (opp_enabled == 1)
|
if (cpu_meas_enabled)
|
||||||
threadCreate(&ru->ru_stats_thread, ru_stats_thread, (void *)ru, "ru_stats", -1, OAI_PRIORITY_RT);
|
threadCreate(&ru->ru_stats_thread, ru_stats_thread, (void *)ru, "ru_stats", -1, OAI_PRIORITY_RT);
|
||||||
LOG_I(PHY, "Initialized RU proc %d (%s,%s),\n", ru->idx, NB_functions[ru->function], NB_timing[ru->if_timing]);
|
LOG_I(PHY, "Initialized RU proc %d (%s,%s),\n", ru->idx, NB_functions[ru->function], NB_timing[ru->if_timing]);
|
||||||
}
|
}
|
||||||
@@ -1485,7 +1483,7 @@ void kill_NR_RU_proc(int inst) {
|
|||||||
pthread_mutex_unlock( &proc->mutex_fep[0] );
|
pthread_mutex_unlock( &proc->mutex_fep[0] );
|
||||||
pthread_join(proc->pthread_FH, NULL);
|
pthread_join(proc->pthread_FH, NULL);
|
||||||
|
|
||||||
if (opp_enabled) {
|
if (cpu_meas_enabled) {
|
||||||
LOG_D(PHY, "Joining ru_stats_thread\n");
|
LOG_D(PHY, "Joining ru_stats_thread\n");
|
||||||
pthread_join(ru->ru_stats_thread, NULL);
|
pthread_join(ru->ru_stats_thread, NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -631,7 +631,7 @@ int main( int argc, char **argv ) {
|
|||||||
set_taus_seed (0);
|
set_taus_seed (0);
|
||||||
printf("configuring for RAU/RRU\n");
|
printf("configuring for RAU/RRU\n");
|
||||||
|
|
||||||
if (opp_enabled ==1) {
|
if (cpu_meas_enabled) {
|
||||||
reset_opp_meas();
|
reset_opp_meas();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -166,7 +166,7 @@ extern int usrp_tx_thread;
|
|||||||
{"CO" , CONFIG_HLP_ULF, 0, .iptr=&(uplink_frequency_offset[0][0]), .defintval=0, TYPE_INT, 0}, \
|
{"CO" , CONFIG_HLP_ULF, 0, .iptr=&(uplink_frequency_offset[0][0]), .defintval=0, TYPE_INT, 0}, \
|
||||||
{"a" , CONFIG_HLP_CHOFF, 0, .iptr=&CHAIN_OFFSET, .defintval=0, TYPE_INT, 0}, \
|
{"a" , CONFIG_HLP_CHOFF, 0, .iptr=&CHAIN_OFFSET, .defintval=0, TYPE_INT, 0}, \
|
||||||
{"d" , CONFIG_HLP_SOFTS, PARAMFLAG_BOOL, .uptr=&do_forms, .defintval=0, TYPE_UINT, 0}, \
|
{"d" , CONFIG_HLP_SOFTS, PARAMFLAG_BOOL, .uptr=&do_forms, .defintval=0, TYPE_UINT, 0}, \
|
||||||
{"q" , CONFIG_HLP_STMON, PARAMFLAG_BOOL, .iptr=&opp_enabled, .defintval=0, TYPE_INT, 0}, \
|
{"q" , CONFIG_HLP_STMON, PARAMFLAG_BOOL, .iptr=&cpu_meas_enabled, .defintval=0, TYPE_INT, 0}, \
|
||||||
{"numerology" , CONFIG_HLP_NUMEROLOGY, 0, .iptr=&NUMEROLOGY, .defintval=1, TYPE_INT, 0}, \
|
{"numerology" , CONFIG_HLP_NUMEROLOGY, 0, .iptr=&NUMEROLOGY, .defintval=1, TYPE_INT, 0}, \
|
||||||
{"band" , CONFIG_HLP_BAND, 0, .iptr=&BAND, .defintval=78, TYPE_INT, 0}, \
|
{"band" , CONFIG_HLP_BAND, 0, .iptr=&BAND, .defintval=78, TYPE_INT, 0}, \
|
||||||
{"emulate-rf" , CONFIG_HLP_EMULATE_RF, PARAMFLAG_BOOL, .iptr=&EMULATE_RF, .defintval=0, TYPE_INT, 0}, \
|
{"emulate-rf" , CONFIG_HLP_EMULATE_RF, PARAMFLAG_BOOL, .iptr=&EMULATE_RF, .defintval=0, TYPE_INT, 0}, \
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ one_measurement_t test_ldpc(short max_iterations,
|
|||||||
|
|
||||||
double sigma;
|
double sigma;
|
||||||
sigma = 1.0/sqrt(2*SNR);
|
sigma = 1.0/sqrt(2*SNR);
|
||||||
opp_enabled=1;
|
cpu_meas_enabled = 1;
|
||||||
//short test_input[block_length];
|
//short test_input[block_length];
|
||||||
uint8_t *test_input[MAX_NUM_NR_DLSCH_SEGMENTS_PER_LAYER * NR_MAX_NB_LAYERS];
|
uint8_t *test_input[MAX_NUM_NR_DLSCH_SEGMENTS_PER_LAYER * NR_MAX_NB_LAYERS];
|
||||||
uint8_t estimated_output[MAX_NUM_DLSCH_SEGMENTS][block_length];
|
uint8_t estimated_output[MAX_NUM_DLSCH_SEGMENTS][block_length];
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
//Initiate timing. (Results depend on CPU Frequency. Therefore, might change due to performance variances during simulation.)
|
//Initiate timing. (Results depend on CPU Frequency. Therefore, might change due to performance variances during simulation.)
|
||||||
time_stats_t timeEncoder,timeDecoder;
|
time_stats_t timeEncoder,timeDecoder;
|
||||||
opp_enabled=1;
|
cpu_meas_enabled = 1;
|
||||||
reset_meas(&timeEncoder);
|
reset_meas(&timeEncoder);
|
||||||
reset_meas(&timeDecoder);
|
reset_meas(&timeDecoder);
|
||||||
randominit(0);
|
randominit(0);
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ configmodule_interface_t *uniqCfg = NULL;
|
|||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
time_stats_t timeEncoder, timeDecoder;
|
time_stats_t timeEncoder, timeDecoder;
|
||||||
opp_enabled = 1;
|
cpu_meas_enabled = 1;
|
||||||
reset_meas(&timeEncoder);
|
reset_meas(&timeEncoder);
|
||||||
reset_meas(&timeDecoder);
|
reset_meas(&timeDecoder);
|
||||||
randominit(0);
|
randominit(0);
|
||||||
|
|||||||
@@ -277,7 +277,6 @@ uint32_t dlsch_decoding(PHY_VARS_UE *phy_vars_ue,
|
|||||||
#ifdef DEBUG_DLSCH_DECODING
|
#ifdef DEBUG_DLSCH_DECODING
|
||||||
printf("Segmentation: C %d, Cminus %d, Kminus %d, Kplus %d\n",harq_process->C,harq_process->Cminus,harq_process->Kminus,harq_process->Kplus);
|
printf("Segmentation: C %d, Cminus %d, Kminus %d, Kplus %d\n",harq_process->C,harq_process->Cminus,harq_process->Kminus,harq_process->Kplus);
|
||||||
#endif
|
#endif
|
||||||
opp_enabled=1;
|
|
||||||
set_abort(&harq_process->abort_decode, false);
|
set_abort(&harq_process->abort_decode, false);
|
||||||
for (r=0; r<harq_process->C; r++) {
|
for (r=0; r<harq_process->C; r++) {
|
||||||
// Get Turbo interleaver parameters
|
// Get Turbo interleaver parameters
|
||||||
|
|||||||
@@ -342,14 +342,7 @@ void decimation_synchro_nr(PHY_VARS_NR_UE *PHY_vars_UE, int rate_change, int **r
|
|||||||
NR_DL_FRAME_PARMS *frame_parms = &(PHY_vars_UE->frame_parms);
|
NR_DL_FRAME_PARMS *frame_parms = &(PHY_vars_UE->frame_parms);
|
||||||
int samples_for_frame = 2*frame_parms->samples_per_frame;
|
int samples_for_frame = 2*frame_parms->samples_per_frame;
|
||||||
|
|
||||||
#if TEST_SYNCHRO_TIMING_PSS
|
|
||||||
|
|
||||||
opp_enabled = 1;
|
|
||||||
|
|
||||||
start_meas(&generic_time[TIME_RATE_CHANGE]);
|
start_meas(&generic_time[TIME_RATE_CHANGE]);
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* build with cic filter does not work properly. Performances are significantly deteriorated */
|
/* build with cic filter does not work properly. Performances are significantly deteriorated */
|
||||||
#ifdef CIC_DECIMATOR
|
#ifdef CIC_DECIMATOR
|
||||||
|
|
||||||
@@ -409,14 +402,8 @@ int pss_synchro_nr(const c16_t **rxdata,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if TEST_SYNCHRO_TIMING_PSS
|
|
||||||
|
|
||||||
opp_enabled = 1;
|
|
||||||
|
|
||||||
start_meas(&generic_time[TIME_PSS]);
|
start_meas(&generic_time[TIME_PSS]);
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PSS_SEARCH_TIME_NR, VCD_FUNCTION_IN);
|
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PSS_SEARCH_TIME_NR, VCD_FUNCTION_IN);
|
||||||
|
|
||||||
int synchro_position =
|
int synchro_position =
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ uint32_t timing_advance;
|
|||||||
int8_t threequarter_fs;
|
int8_t threequarter_fs;
|
||||||
uint64_t downlink_frequency[MAX_NUM_CCs][4];
|
uint64_t downlink_frequency[MAX_NUM_CCs][4];
|
||||||
int32_t uplink_frequency_offset[MAX_NUM_CCs][4];
|
int32_t uplink_frequency_offset[MAX_NUM_CCs][4];
|
||||||
int opp_enabled;
|
int cpu_meas_enabled;
|
||||||
THREAD_STRUCT thread_struct;
|
THREAD_STRUCT thread_struct;
|
||||||
uint32_t target_ul_mcs = 9;
|
uint32_t target_ul_mcs = 9;
|
||||||
uint32_t target_dl_mcs = 9;
|
uint32_t target_dl_mcs = 9;
|
||||||
|
|||||||
@@ -8118,47 +8118,47 @@ int main(int argc, char**argv)
|
|||||||
dfts_autoinit();
|
dfts_autoinit();
|
||||||
|
|
||||||
set_taus_seed(0);
|
set_taus_seed(0);
|
||||||
opp_enabled = 1;
|
cpu_meas_enabled = 1;
|
||||||
/*
|
/*
|
||||||
((int16_t *)&tw0)[0] = 32767;
|
((int16_t *)&tw0)[0] = 32767;
|
||||||
((int16_t *)&tw0)[1] = 0;
|
((int16_t *)&tw0)[1] = 0;
|
||||||
((int16_t *)&tw0)[2] = 32767;
|
((int16_t *)&tw0)[2] = 32767;
|
||||||
((int16_t *)&tw0)[3] = 0;
|
((int16_t *)&tw0)[3] = 0;
|
||||||
((int16_t *)&tw0)[4] = 32767;
|
((int16_t *)&tw0)[4] = 32767;
|
||||||
((int16_t *)&tw0)[5] = 0;
|
((int16_t *)&tw0)[5] = 0;
|
||||||
((int16_t *)&tw0)[6] = 32767;
|
((int16_t *)&tw0)[6] = 32767;
|
||||||
((int16_t *)&tw0)[7] = 0;
|
((int16_t *)&tw0)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw1)[0] = 32767;
|
((int16_t *)&tw1)[0] = 32767;
|
||||||
((int16_t *)&tw1)[1] = 0;
|
((int16_t *)&tw1)[1] = 0;
|
||||||
((int16_t *)&tw1)[2] = 32767;
|
((int16_t *)&tw1)[2] = 32767;
|
||||||
((int16_t *)&tw1)[3] = 0;
|
((int16_t *)&tw1)[3] = 0;
|
||||||
((int16_t *)&tw1)[4] = 32767;
|
((int16_t *)&tw1)[4] = 32767;
|
||||||
((int16_t *)&tw1)[5] = 0;
|
((int16_t *)&tw1)[5] = 0;
|
||||||
((int16_t *)&tw1)[6] = 32767;
|
((int16_t *)&tw1)[6] = 32767;
|
||||||
((int16_t *)&tw1)[7] = 0;
|
((int16_t *)&tw1)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw2)[0] = 32767;
|
((int16_t *)&tw2)[0] = 32767;
|
||||||
((int16_t *)&tw2)[1] = 0;
|
((int16_t *)&tw2)[1] = 0;
|
||||||
((int16_t *)&tw2)[2] = 32767;
|
((int16_t *)&tw2)[2] = 32767;
|
||||||
((int16_t *)&tw2)[3] = 0;
|
((int16_t *)&tw2)[3] = 0;
|
||||||
((int16_t *)&tw2)[4] = 32767;
|
((int16_t *)&tw2)[4] = 32767;
|
||||||
((int16_t *)&tw2)[5] = 0;
|
((int16_t *)&tw2)[5] = 0;
|
||||||
((int16_t *)&tw2)[6] = 32767;
|
((int16_t *)&tw2)[6] = 32767;
|
||||||
((int16_t *)&tw2)[7] = 0;
|
((int16_t *)&tw2)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw3)[0] = 32767;
|
((int16_t *)&tw3)[0] = 32767;
|
||||||
((int16_t *)&tw3)[1] = 0;
|
((int16_t *)&tw3)[1] = 0;
|
||||||
((int16_t *)&tw3)[2] = 32767;
|
((int16_t *)&tw3)[2] = 32767;
|
||||||
((int16_t *)&tw3)[3] = 0;
|
((int16_t *)&tw3)[3] = 0;
|
||||||
((int16_t *)&tw3)[4] = 32767;
|
((int16_t *)&tw3)[4] = 32767;
|
||||||
((int16_t *)&tw3)[5] = 0;
|
((int16_t *)&tw3)[5] = 0;
|
||||||
((int16_t *)&tw3)[6] = 32767;
|
((int16_t *)&tw3)[6] = 32767;
|
||||||
((int16_t *)&tw3)[7] = 0;
|
((int16_t *)&tw3)[7] = 0;
|
||||||
*/
|
*/
|
||||||
for (i=0;i<300;i++) {
|
for (i = 0; i < 300; i++) {
|
||||||
x[i] = simde_mm256_set1_epi32(taus());
|
x[i] = simde_mm256_set1_epi32(taus());
|
||||||
x[i] = simde_mm256_srai_epi16(x[i],4);
|
x[i] = simde_mm256_srai_epi16(x[i], 4);
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
bfly2_tw1(x,x+1,y,y+1);
|
bfly2_tw1(x,x+1,y,y+1);
|
||||||
|
|||||||
@@ -7337,47 +7337,47 @@ int main(int argc, char**argv)
|
|||||||
dfts_autoinit();
|
dfts_autoinit();
|
||||||
|
|
||||||
set_taus_seed(0);
|
set_taus_seed(0);
|
||||||
opp_enabled = 1;
|
cpu_meas_enabled = 1;
|
||||||
/*
|
/*
|
||||||
((int16_t *)&tw0)[0] = 32767;
|
((int16_t *)&tw0)[0] = 32767;
|
||||||
((int16_t *)&tw0)[1] = 0;
|
((int16_t *)&tw0)[1] = 0;
|
||||||
((int16_t *)&tw0)[2] = 32767;
|
((int16_t *)&tw0)[2] = 32767;
|
||||||
((int16_t *)&tw0)[3] = 0;
|
((int16_t *)&tw0)[3] = 0;
|
||||||
((int16_t *)&tw0)[4] = 32767;
|
((int16_t *)&tw0)[4] = 32767;
|
||||||
((int16_t *)&tw0)[5] = 0;
|
((int16_t *)&tw0)[5] = 0;
|
||||||
((int16_t *)&tw0)[6] = 32767;
|
((int16_t *)&tw0)[6] = 32767;
|
||||||
((int16_t *)&tw0)[7] = 0;
|
((int16_t *)&tw0)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw1)[0] = 32767;
|
((int16_t *)&tw1)[0] = 32767;
|
||||||
((int16_t *)&tw1)[1] = 0;
|
((int16_t *)&tw1)[1] = 0;
|
||||||
((int16_t *)&tw1)[2] = 32767;
|
((int16_t *)&tw1)[2] = 32767;
|
||||||
((int16_t *)&tw1)[3] = 0;
|
((int16_t *)&tw1)[3] = 0;
|
||||||
((int16_t *)&tw1)[4] = 32767;
|
((int16_t *)&tw1)[4] = 32767;
|
||||||
((int16_t *)&tw1)[5] = 0;
|
((int16_t *)&tw1)[5] = 0;
|
||||||
((int16_t *)&tw1)[6] = 32767;
|
((int16_t *)&tw1)[6] = 32767;
|
||||||
((int16_t *)&tw1)[7] = 0;
|
((int16_t *)&tw1)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw2)[0] = 32767;
|
((int16_t *)&tw2)[0] = 32767;
|
||||||
((int16_t *)&tw2)[1] = 0;
|
((int16_t *)&tw2)[1] = 0;
|
||||||
((int16_t *)&tw2)[2] = 32767;
|
((int16_t *)&tw2)[2] = 32767;
|
||||||
((int16_t *)&tw2)[3] = 0;
|
((int16_t *)&tw2)[3] = 0;
|
||||||
((int16_t *)&tw2)[4] = 32767;
|
((int16_t *)&tw2)[4] = 32767;
|
||||||
((int16_t *)&tw2)[5] = 0;
|
((int16_t *)&tw2)[5] = 0;
|
||||||
((int16_t *)&tw2)[6] = 32767;
|
((int16_t *)&tw2)[6] = 32767;
|
||||||
((int16_t *)&tw2)[7] = 0;
|
((int16_t *)&tw2)[7] = 0;
|
||||||
|
|
||||||
((int16_t *)&tw3)[0] = 32767;
|
((int16_t *)&tw3)[0] = 32767;
|
||||||
((int16_t *)&tw3)[1] = 0;
|
((int16_t *)&tw3)[1] = 0;
|
||||||
((int16_t *)&tw3)[2] = 32767;
|
((int16_t *)&tw3)[2] = 32767;
|
||||||
((int16_t *)&tw3)[3] = 0;
|
((int16_t *)&tw3)[3] = 0;
|
||||||
((int16_t *)&tw3)[4] = 32767;
|
((int16_t *)&tw3)[4] = 32767;
|
||||||
((int16_t *)&tw3)[5] = 0;
|
((int16_t *)&tw3)[5] = 0;
|
||||||
((int16_t *)&tw3)[6] = 32767;
|
((int16_t *)&tw3)[6] = 32767;
|
||||||
((int16_t *)&tw3)[7] = 0;
|
((int16_t *)&tw3)[7] = 0;
|
||||||
*/
|
*/
|
||||||
for (i=0;i<300;i++) {
|
for (i = 0; i < 300; i++) {
|
||||||
x[i] = (int16x8_t)vdupq_n_s32(taus());
|
x[i] = (int16x8_t)vdupq_n_s32(taus());
|
||||||
x[i] = vshrq_n_s16(x[i],4);
|
x[i] = vshrq_n_s16(x[i], 4);
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
bfly2_tw1(x,x+1,y,y+1);
|
bfly2_tw1(x,x+1,y,y+1);
|
||||||
|
|||||||
@@ -374,7 +374,7 @@ bool dlsch_procedures(PHY_VARS_eNB *eNB,
|
|||||||
dlsch_encoding(eNB, proc, dlsch_harq->pdu, dlsch_harq->pdsch_start, dlsch, frame, subframe, &eNB->dlsch_rate_matching_stats, &eNB->dlsch_turbo_encoding_stats, &eNB->dlsch_interleaving_stats);
|
dlsch_encoding(eNB, proc, dlsch_harq->pdu, dlsch_harq->pdsch_start, dlsch, frame, subframe, &eNB->dlsch_rate_matching_stats, &eNB->dlsch_turbo_encoding_stats, &eNB->dlsch_interleaving_stats);
|
||||||
stop_meas(&eNB->dlsch_encoding_stats);
|
stop_meas(&eNB->dlsch_encoding_stats);
|
||||||
|
|
||||||
if(eNB->dlsch_encoding_stats.p_time>500*3000 && opp_enabled == 1) {
|
if (eNB->dlsch_encoding_stats.p_time > 500 * 3000 && cpu_meas_enabled) {
|
||||||
print_meas_now(&eNB->dlsch_encoding_stats,"total coding",stderr);
|
print_meas_now(&eNB->dlsch_encoding_stats,"total coding",stderr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -229,10 +229,6 @@ static void *feptx_thread(void *param)
|
|||||||
exit_fun( "ERROR pthread_cond_signal" );
|
exit_fun( "ERROR pthread_cond_signal" );
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
/*if(opp_enabled == 1 && ru->ofdm_mod_wakeup_stats.p_time>30*3000){
|
|
||||||
print_meas_now(&ru->ofdm_mod_wakeup_stats,"fep wakeup",stderr);
|
|
||||||
printf("delay in fep wakeup in frame_tx: %d subframe_rx: %d \n",proc->frame_tx,proc->tti_tx);
|
|
||||||
}*/
|
|
||||||
}
|
}
|
||||||
return(NULL);
|
return(NULL);
|
||||||
}
|
}
|
||||||
@@ -288,7 +284,7 @@ void feptx_ofdm_2thread(RU_t *ru,
|
|||||||
start_meas(&ru->ofdm_mod_wait_stats);
|
start_meas(&ru->ofdm_mod_wait_stats);
|
||||||
wait_on_busy_condition(&proc->mutex_feptx,&proc->cond_feptx,&proc->instance_cnt_feptx,"feptx thread");
|
wait_on_busy_condition(&proc->mutex_feptx,&proc->cond_feptx,&proc->instance_cnt_feptx,"feptx thread");
|
||||||
stop_meas(&ru->ofdm_mod_wait_stats);
|
stop_meas(&ru->ofdm_mod_wait_stats);
|
||||||
/*if(opp_enabled == 1 && ru->ofdm_mod_wait_stats.p_time>30*3000){
|
/*if(cpu_meas_enabled == 1 && ru->ofdm_mod_wait_stats.p_time>30*3000){
|
||||||
print_meas_now(&ru->ofdm_mod_wait_stats,"fep wakeup",stderr);
|
print_meas_now(&ru->ofdm_mod_wait_stats,"fep wakeup",stderr);
|
||||||
printf("delay in feptx wait on condition in frame_rx: %d subframe_rx: %d \n", proc->frame_tx, proc->tti_tx);
|
printf("delay in feptx wait on condition in frame_rx: %d subframe_rx: %d \n", proc->frame_tx, proc->tti_tx);
|
||||||
}*/
|
}*/
|
||||||
@@ -578,7 +574,7 @@ static void *fep_thread(void *param)
|
|||||||
exit_fun( "ERROR pthread_cond_signal" );
|
exit_fun( "ERROR pthread_cond_signal" );
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
/*if(opp_enabled == 1 && ru->ofdm_demod_wakeup_stats.p_time>30*3000){
|
/*if(cpu_meas_enabled == 1 && ru->ofdm_demod_wakeup_stats.p_time>30*3000){
|
||||||
print_meas_now(&ru->ofdm_demod_wakeup_stats,"fep wakeup",stderr);
|
print_meas_now(&ru->ofdm_demod_wakeup_stats,"fep wakeup",stderr);
|
||||||
printf("delay in fep wakeup in frame_rx: %d subframe_rx: %d \n",proc->frame_rx,proc->subframe_rx);
|
printf("delay in fep wakeup in frame_rx: %d subframe_rx: %d \n",proc->frame_rx,proc->subframe_rx);
|
||||||
}*/
|
}*/
|
||||||
@@ -699,7 +695,7 @@ void ru_fep_full_2thread(RU_t *ru,
|
|||||||
start_meas(&ru->ofdm_demod_wait_stats);
|
start_meas(&ru->ofdm_demod_wait_stats);
|
||||||
wait_on_busy_condition(&proc->mutex_fep[0],&proc->cond_fep[0],&proc->instance_cnt_fep[0],"fep thread");
|
wait_on_busy_condition(&proc->mutex_fep[0],&proc->cond_fep[0],&proc->instance_cnt_fep[0],"fep thread");
|
||||||
stop_meas(&ru->ofdm_demod_wait_stats);
|
stop_meas(&ru->ofdm_demod_wait_stats);
|
||||||
if(opp_enabled == 1 && ru->ofdm_demod_wakeup_stats.p_time>30*3000){
|
if (cpu_meas_enabled == 1 && ru->ofdm_demod_wakeup_stats.p_time > 30 * 3000) {
|
||||||
print_meas_now(&ru->ofdm_demod_wakeup_stats,"fep wakeup",stderr);
|
print_meas_now(&ru->ofdm_demod_wakeup_stats,"fep wakeup",stderr);
|
||||||
printf("delay in fep wait on condition in frame_rx: %d subframe_rx: %d \n", proc->frame_rx, proc->tti_rx);
|
printf("delay in fep wait on condition in frame_rx: %d subframe_rx: %d \n", proc->frame_rx, proc->tti_rx);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -573,7 +573,7 @@ int main(int argc, char **argv) {
|
|||||||
uint32_t Nsoft;
|
uint32_t Nsoft;
|
||||||
int sf;
|
int sf;
|
||||||
int CCE_table[800];
|
int CCE_table[800];
|
||||||
opp_enabled=1; // to enable the time meas
|
cpu_meas_enabled = 1; // to enable the time meas
|
||||||
FILE *csv_fd=NULL;
|
FILE *csv_fd=NULL;
|
||||||
char csv_fname[FILENAME_MAX];
|
char csv_fname[FILENAME_MAX];
|
||||||
int DLSCH_RB_ALLOC = 0;
|
int DLSCH_RB_ALLOC = 0;
|
||||||
|
|||||||
@@ -307,7 +307,7 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
int threequarter_fs=0;
|
int threequarter_fs=0;
|
||||||
|
|
||||||
opp_enabled=1; // to enable the time meas
|
cpu_meas_enabled = 1; // to enable the time meas
|
||||||
|
|
||||||
#if defined(__arm__) || defined(__aarch64__)
|
#if defined(__arm__) || defined(__aarch64__)
|
||||||
FILE *proc_fd = NULL;
|
FILE *proc_fd = NULL;
|
||||||
|
|||||||
@@ -189,7 +189,7 @@ int main(int argc, char **argv) {
|
|||||||
uint32_t Nsoft;
|
uint32_t Nsoft;
|
||||||
int CCE_table[800];
|
int CCE_table[800];
|
||||||
int threequarter_fs=0;
|
int threequarter_fs=0;
|
||||||
opp_enabled=1; // to enable the time meas
|
cpu_meas_enabled = 1; // to enable the time meas
|
||||||
#if defined(__arm__) || defined(__aarch64__)
|
#if defined(__arm__) || defined(__aarch64__)
|
||||||
FILE *proc_fd = NULL;
|
FILE *proc_fd = NULL;
|
||||||
char buf[64];
|
char buf[64];
|
||||||
|
|||||||
@@ -661,7 +661,7 @@ int main(int argc, char **argv) {
|
|||||||
uint32_t Nsoft;
|
uint32_t Nsoft;
|
||||||
int sf;
|
int sf;
|
||||||
int CCE_table[800];
|
int CCE_table[800];
|
||||||
opp_enabled=1; // to enable the time meas
|
cpu_meas_enabled = 1; // to enable the time meas
|
||||||
FILE *csv_fd=NULL;
|
FILE *csv_fd=NULL;
|
||||||
char csv_fname[FILENAME_MAX];
|
char csv_fname[FILENAME_MAX];
|
||||||
int DLSCH_RB_ALLOC = 0;
|
int DLSCH_RB_ALLOC = 0;
|
||||||
|
|||||||
@@ -380,7 +380,6 @@ int main(int argc, char **argv) {
|
|||||||
int sf;
|
int sf;
|
||||||
static int threequarter_fs=0;
|
static int threequarter_fs=0;
|
||||||
int ndi;
|
int ndi;
|
||||||
opp_enabled=1; // to enable the time meas
|
|
||||||
sched_resp.DL_req = &DL_req;
|
sched_resp.DL_req = &DL_req;
|
||||||
sched_resp.UL_req = &UL_req;
|
sched_resp.UL_req = &UL_req;
|
||||||
sched_resp.HI_DCI0_req = &HI_DCI0_req;
|
sched_resp.HI_DCI0_req = &HI_DCI0_req;
|
||||||
@@ -568,7 +567,7 @@ int main(int argc, char **argv) {
|
|||||||
|
|
||||||
case 'P':
|
case 'P':
|
||||||
dump_perf=1;
|
dump_perf=1;
|
||||||
opp_enabled=1;
|
cpu_meas_enabled = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'L':
|
case 'L':
|
||||||
|
|||||||
@@ -460,7 +460,7 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
case 'P':
|
case 'P':
|
||||||
print_perf=1;
|
print_perf=1;
|
||||||
opp_enabled=1;
|
cpu_meas_enabled = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'I':
|
case 'I':
|
||||||
|
|||||||
@@ -432,7 +432,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
case 'P':
|
case 'P':
|
||||||
print_perf=1;
|
print_perf=1;
|
||||||
opp_enabled=1;
|
cpu_meas_enabled = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'L':
|
case 'L':
|
||||||
|
|||||||
Reference in New Issue
Block a user