tests: Update sys_kernel benchmark

This updates the sys_kernel benchmark project to replace references to
the defunct TICKS_NONE symbol with K_NO_WAIT. It also removes the
outdated build instructions from the README.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
This commit is contained in:
Peter Mitsis 2023-10-10 16:31:48 -04:00 committed by Johan Hedberg
commit 36defb4287
4 changed files with 8 additions and 31 deletions

View file

@ -7,34 +7,12 @@ lifo, fifo, stack and memslab objects.
--------------------------------------------------------------------------------
Building and Running Project:
This project outputs to the console. It can be built and executed
on QEMU as follows:
make run
--------------------------------------------------------------------------------
Troubleshooting:
Problems caused by out-dated project information can be addressed by
issuing one of the following commands then rebuilding the project:
make clean # discard results of previous builds
# but keep existing configuration info
or
make pristine # discard results of previous builds
# and restore pre-defined configuration info
--------------------------------------------------------------------------------
Sample Output:
MODULE: kernel API test
KERNEL VERSION: 0x1066300
KERNEL VERSION: 0xXXYYZZZZ
Each test below is repeated 5000 times;
Each test below is repeated 10 times;
average time for one iteration is displayed.
TEST CASE: Semaphore #1
@ -50,7 +28,7 @@ END TEST CASE
TEST CASE: Semaphore #2
TEST COVERAGE:
k_sem_init
k_sem_take(TICKS_NONE)
k_sem_take(K_NO_WAIT)
k_yield
k_sem_give
Starting test. Please wait...
@ -84,7 +62,7 @@ TEST CASE: LIFO #2
TEST COVERAGE:
k_lifo_init
k_lifo_get(K_FOREVER)
k_lifo_get(TICKS_NONE)
k_lifo_get(K_NO_WAIT)
k_lifo_put
k_yield
Starting test. Please wait...
@ -118,7 +96,7 @@ TEST CASE: FIFO #2
TEST COVERAGE:
k_fifo_init
k_fifo_get(K_FOREVER)
k_fifo_get(TICKS_NONE)
k_fifo_get(K_NO_WAIT)
k_fifo_put
k_yield
Starting test. Please wait...
@ -189,4 +167,3 @@ DETAILS: Average time for 1 iteration: NNNN nSec
END TEST CASE
PROJECT EXECUTION SUCCESSFUL
QEMU: Terminated

View file

@ -177,7 +177,7 @@ int lifo_test(void)
fprintf(output_file, sz_description,
"\n\tk_lifo_init"
"\n\tk_lifo_get(K_FOREVER)"
"\n\tk_lifo_get(TICKS_NONE)"
"\n\tk_lifo_get(K_NO_WAIT)"
"\n\tk_lifo_put"
"\n\tk_yield");
printf(sz_test_start_fmt);

View file

@ -177,7 +177,7 @@ int fifo_test(void)
fprintf(output_file, sz_description,
"\n\tk_fifo_init"
"\n\tk_fifo_get(K_FOREVER)"
"\n\tk_fifo_get(TICKS_NONE)"
"\n\tk_fifo_get(K_NO_WAIT)"
"\n\tk_fifo_put"
"\n\tk_yield");
printf(sz_test_start_fmt);

View file

@ -137,7 +137,7 @@ int sema_test(void)
"Semaphore #2");
fprintf(output_file, sz_description,
"\n\tk_sem_init"
"\n\tk_sem_take(TICKS_NONE)"
"\n\tk_sem_take(K_NO_WAIT)"
"\n\tk_yield"
"\n\tk_sem_give");
printf(sz_test_start_fmt);