summaryrefslogtreecommitdiff
path: root/test/smp/regression/threadx_mutex_trace_test.c
AgeCommit message (Collapse)Author
2026-09-20Covered the mutex trace inserts in every state the macro testsFrédéric Desbiens
The six mutex services carry the same in-line trace insert as the semaphore ones, with the same twelve outcomes from six conditions, and the same cause left them uncovered: only one test in the suite enabled tracing. Four of the six sites had never run the macro body and the create and the delete reached five outcomes of twelve. A new test applies the pattern to the mutex services. The subset an interrupt may drive is narrower here and is decided by the shell rather than by the service: the error checking shell rejects a create, a get and a put from an interrupt and a delete from any caller that is not a thread, which leaves the prioritize and the information service for the interrupt pass. The resident mutex is created TX_NO_INHERIT deliberately, so a release with nothing suspended takes the simple path and leaves the calling thread's priority alone; the inheritance paths have tests of their own and nothing here depends on them. All six mutex trace sites read twelve of twelve. The eleven tx_mutex_ files are at 471/471 lines and 310/312 branch outcomes on the union basis; the two left are the exit arms of the TX_MISRA_ENABLE release loops, which are unreachable by construction and carry their own record. 123/123 tests pass in each of the eight configurations, and the new test passes fifty standalone repeats in every one of them. Assisted-by: Claude Code (Opus 5) <[email protected]>