Tests SMP-specific thread behaviour.
More...
|
| T_TEST_CASE_FIXTURE (ScoreThreadValSmp, &ScoreThreadValSmp_Fixture) |
|
Tests SMP-specific thread behaviour.
This test case performs the following actions:
- Create three worker threads and a mutex. Use the mutex and the worker to move to a helping scheduler.
- Pin the runner thread while it executes on a processor owned by a helping scheduler.
- Pin and unpin the runner thread. This is a nested operation.
- Preempt the pinned runner thread. Worker B and C execute at the same time on processor 0 and 1 respectively for some point in time. This shows that the pinning of the runner thread is maintained.
- Unpin the runner thread. The runner moves back to its home scheduler.
- Release the mutex.
- Pin the runner thread. Unpin the runner thread while it is suspended.
- Make sure the worker released the mutex.
- Clean up all used resources.
- Create three worker threads and a mutex. Use the mutex and the worker to check that a suspended thread does not reconsider help requests.
- Let worker B help worker A through the mutex. Preempt worker A. Delay the thread switch to worker A.
- Suspend worker A and let it wait on its thread state lock. Check that worker A did not reconsider help requests.
- Resume worker A. Check that worker A did reconsider help requests after the thread dispatch.
- Clean up all used resources.