4ef74379c2
In VxWorks Kernel, the re-schedule mechanism does not enable "round-robin" reschdule between the same priority tasks by default. So the case "stack_unbounded_stress_test" will lead to test case hang forever. Here's the details: The test case creates 4 tasks as “Reader”, and then 4 tasks as “Writer”, all those 8 task has the same priority 220. If the target has 2 cores, the first 2 reader tasks will occupy the cores by “while (1)” without yield, so the other 2 readers tasks and 4 writers tasks have no chance to be run. This will lead to the test case loop forever , then the exp scrip will catch it and print “RTP Execution Timeout; rebooting” The test case creates 4 tasks as “Reader”, and then 4 tasks as “Writer”, all those 8 task has the same priority 220 in VxWorks Kernel. If the target has 2 cores, the first 2 reader tasks will occupy the cores by “while (1)” without yield, so the other 2 readers tasks and 4 writers tasks have no chance to be run. This will lead to the test case loop forever without any ending. Why modify spsc_queue_stress_test.cpp : In VxWorks user-land task (Wind River calls it as RTP), the max number of objects (the internal data structure RTP uses) in one RTP is limited at most 65535. When the test is selected to run, the C++ constructor will create 1<<16 number of mutex via "new spsc_queue_tester". And after test1->run() is finished, the C++ destructor will delete 1<<16 number of mutex by default. This caused the problem, because VxWorks just support ((1<<16)-1) objects within an RTP. |
||
---|---|---|
.. | ||
freelist_test.cpp | ||
Jamfile.v2 | ||
queue_bounded_stress_test.cpp | ||
queue_fixedsize_stress_test.cpp | ||
queue_interprocess_test.cpp | ||
queue_test.cpp | ||
queue_unbounded_stress_test.cpp | ||
spsc_queue_stress_test.cpp | ||
spsc_queue_test.cpp | ||
stack_bounded_stress_test.cpp | ||
stack_fixedsize_stress_test.cpp | ||
stack_interprocess_test.cpp | ||
stack_test.cpp | ||
stack_unbounded_stress_test.cpp | ||
tagged_ptr_test.cpp | ||
test_common.hpp | ||
test_helpers.hpp |