diff --git a/common/utils/threadPool/thread-pool.c b/common/utils/threadPool/thread-pool.c index 5531a3aed34652d90f849bfe25f5f5c16b715530..1a2fafdbf8ed2bfb07df894cd465faf75bca83a1 100644 --- a/common/utils/threadPool/thread-pool.c +++ b/common/utils/threadPool/thread-pool.c @@ -106,7 +106,7 @@ void *one_thread(void *arg) { void initNamedTpool(char *params,tpool_t *pool, bool performanceMeas, char *name) { memset(pool,0,sizeof(*pool)); - char *measr=getenv("threadPoolMeasurements"); + char *measr=getenv("OAI_THREADPOOLMEASUREMENTS"); pool->measurePerf=performanceMeas; // force measurement if the output is defined pool->measurePerf |= measr!=NULL; diff --git a/common/utils/threadPool/thread-pool.md b/common/utils/threadPool/thread-pool.md index 311857ff3e912548001572742dda11f7d1594616..02dd9e0387369aca60eb3823d1d54d7a59307c89 100644 --- a/common/utils/threadPool/thread-pool.md +++ b/common/utils/threadPool/thread-pool.md @@ -182,7 +182,7 @@ Returns the total number of jobs that were aborted, i.e., waiting for execution ## Performance measurements -A performance measurement is integrated: the pool will automacillay fill timestamps if you set the environement variable `threadPoolMeasurements` to a valid file name. The following measurements will be written to Linux pipe on a per-job basis: +A performance measurement is integrated: the pool will automacillay fill timestamps if you set the environement variable `OAI_THREADPOOLMEASUREMENTS` to a valid file name. The following measurements will be written to Linux pipe on a per-job basis: * `creationTime`: time the request is push to the pool; * `startProcessingTime`: time a worker start to run on the job @@ -193,6 +193,6 @@ The `measurement_display` tool to read the Linux pipe and display it in ASCII is In the cmake build directory, type `make/ninja measurement_display`. Use as follows: ``` -sudo threadPoolMeasurements=tpool.meas ./nr-softmodem ... +sudo OAI_THREADPOOLMEASUREMENTS=tpool.meas ./nr-softmodem ... ./measurement_display tpool.meas ``` diff --git a/doc/environment-variables.md b/doc/environment-variables.md index 9137533e8ad872ef38968a41c7753122f8377352..9439ebd64c15d3cb01e40a420fbaae30b9dcb8d6 100644 --- a/doc/environment-variables.md +++ b/doc/environment-variables.md @@ -8,10 +8,10 @@ OAI uses/supports a number of environment variables, documented in the following - `NVRAM_DIR`: directory to read/write NVRAM data in (5G) `nvram` tool; if not defined, will use `PWD` (working directory) - `OAI_CONFIGMODULE`: can be used to pass the configuration file instead of `-O` - `OAI_GDBSTACKS`: if defined when hitting an assertion (`DevAssert()`, `AssertFatal()`, ...), OAI will load `gdb` and provide a backtrace for every thread +- `OAI_THREADPOOLMEASUREMENTS`: path to a file to store thread pool debugging information, see the [thread pool documentation](..common/utils/threadPool/thread-pool.md) - `OPENAIR_DIR`: should point to the root directory of OpenAirInterface; some code relies on this to get a filename, e.g., BLER curves for L2sim channel emulation - `RFSIMULATOR`: the RFsimulator's work mode, can be either `server` (for server mode) or a valid IP address (for client mode) - `USIM_DIR`: directory to read/write USIM data in (4G) `usim` tool; if not defined, will use `PWD` (working directory) -- `threadPoolMeasurements`: path to a file to store thread pool debugging information, see the [thread pool documentation](..common/utils/threadPool/thread-pool.md) Furthermore, these variables appear in code that is not maintained and maybe not even compiled anywhere: - `HOST`: alternative host to connect to, for CLI, if neither `REMADDR` nor `SSH_CLIENT` are defined