2015-08-15 02:13:25 +08:00
|
|
|
Title: Nanokernel Object Performance
|
2015-04-11 07:44:37 +08:00
|
|
|
|
|
|
|
Description:
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
The SysKernel test measures the performance of the nanokernel's semaphore,
|
|
|
|
lifo, fifo and stack objects.
|
2015-04-11 07:44:37 +08:00
|
|
|
|
|
|
|
--------------------------------------------------------------------------------
|
|
|
|
|
|
|
|
Building and Running Project:
|
|
|
|
|
|
|
|
This microkernel project outputs to the console. It can be built and executed
|
|
|
|
on QEMU as follows:
|
|
|
|
|
2015-06-06 09:48:58 +08:00
|
|
|
make qemu
|
2015-04-11 07:44:37 +08:00
|
|
|
|
|
|
|
--------------------------------------------------------------------------------
|
2015-06-01 22:30:09 +08:00
|
|
|
|
|
|
|
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
|
|
|
|
|
|
|
|
--------------------------------------------------------------------------------
|
2015-04-11 07:44:37 +08:00
|
|
|
|
|
|
|
Sample Output:
|
|
|
|
|
|
|
|
MODULE: Nanokernel API test
|
|
|
|
KERNEL VERSION: <varies>
|
|
|
|
|
|
|
|
Each test below are repeated 5000 times and the average
|
|
|
|
time for one iteration is displayed.
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Semaphore #1
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_sem_init
|
|
|
|
nano_fiber_sem_take_wait
|
|
|
|
nano_fiber_sem_give
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Semaphore #2
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_sem_init
|
|
|
|
nano_fiber_sem_take
|
|
|
|
fiber_yield
|
|
|
|
nano_fiber_sem_give
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Semaphore #3
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_sem_init
|
|
|
|
nano_fiber_sem_take_wait
|
|
|
|
nano_fiber_sem_give
|
|
|
|
nano_task_sem_give
|
|
|
|
nano_task_sem_take_wait
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: LIFO #1
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_lifo_init
|
|
|
|
nano_fiber_lifo_get_wait
|
|
|
|
nano_fiber_lifo_put
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: LIFO #2
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_lifo_init
|
|
|
|
nano_fiber_lifo_get_wait
|
|
|
|
nano_fiber_lifo_get
|
|
|
|
nano_fiber_lifo_put
|
|
|
|
fiber_yield
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: LIFO #3
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_lifo_init
|
|
|
|
nano_fiber_lifo_get_wait
|
|
|
|
nano_fiber_lifo_put
|
|
|
|
nano_task_lifo_get_wait
|
|
|
|
nano_task_lifo_put
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: FIFO #1
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_fifo_init
|
|
|
|
nano_fiber_fifo_get_wait
|
|
|
|
nano_fiber_fifo_put
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: FIFO #2
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_fifo_init
|
|
|
|
nano_fiber_fifo_get_wait
|
|
|
|
nano_fiber_fifo_get
|
|
|
|
nano_fiber_fifo_put
|
|
|
|
fiber_yield
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: FIFO #3
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_fifo_init
|
|
|
|
nano_fiber_fifo_get_wait
|
|
|
|
nano_fiber_fifo_put
|
|
|
|
nano_task_fifo_get_wait
|
|
|
|
nano_task_fifo_put
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Stack #1
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_stack_init
|
|
|
|
nano_fiber_stack_pop_wait
|
|
|
|
nano_fiber_stack_push
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Stack #2
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_stack_init
|
|
|
|
nano_fiber_stack_pop_wait
|
|
|
|
nano_fiber_stack_pop
|
|
|
|
nano_fiber_stack_push
|
|
|
|
fiber_yield
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-10 03:38:18 +08:00
|
|
|
TEST CASE: Stack #3
|
|
|
|
TEST COVERAGE:
|
|
|
|
nano_stack_init
|
|
|
|
nano_fiber_stack_pop_wait
|
|
|
|
nano_fiber_stack_push
|
|
|
|
nano_task_stack_pop_wait
|
|
|
|
nano_task_stack_push
|
|
|
|
Starting test. Please wait...
|
2015-04-11 07:44:37 +08:00
|
|
|
TEST RESULT: SUCCESSFUL
|
2015-06-10 03:38:18 +08:00
|
|
|
DETAILS: Average time for 1 iteration: NNNN nSec
|
2015-04-11 07:44:37 +08:00
|
|
|
END TEST CASE
|
|
|
|
|
2015-06-05 20:24:47 +08:00
|
|
|
PROJECT EXECUTION SUCCESSFUL
|