Skip to content

Conversation

nashif
Copy link
Member

@nashif nashif commented Aug 4, 2025

Using semihosting on supported architectures (arm, xtensa, riscv) it now
possible to generate tracing giles easily and without being restricted
by size.
Using qemu for example, it is now possible to generate the tracing file
simply by running:


 west build -p -b mps2/an385 tests/kernel/msgq/msgq_api/ \
        -t run --snippet semihost-tracing

This will generate a tracing file in the build/ directory which can be
viewed with babeltrace.

  • kernel: msgq: return once to simplify tracing
  • tracing: add semihosting backend
  • tracing: ctf: add missing return value for mutex_unlock
  • tracing: ctf: add tracing for memory slabs
  • tracing: ctf: add tracing for message queues
  • tracing: ctf: add condition variables
  • tracing: ctf: add work queues
  • tracing: ctf: add poll
  • tracing: ctf: thread extended
  • tracing: ctf: add mbox support
  • tracing: ctf: add event support
  • tracing: systemview: add tracing for message queues
  • tracing: systemview: add tracing for stacks
  • tracing: systemview: add tracing for events
  • tracing: systemview: add tracing for mail boxes
  • snippets: add semihost tracing snippet

@nashif nashif force-pushed the topic/tracing/semihosting branch from 7dffa10 to 6d263fb Compare August 5, 2025 02:54
Copy link

sonarqubecloud bot commented Aug 5, 2025

@nashif nashif force-pushed the topic/tracing/semihosting branch from 6d263fb to 3620182 Compare August 5, 2025 19:02
Copy link

github-actions bot commented Oct 5, 2025

This pull request has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this pull request will automatically be closed in 14 days. Note, that you can always re-open a closed pull request at any time.

@github-actions github-actions bot added the Stale label Oct 5, 2025
@nashif nashif removed the Stale label Oct 5, 2025
@nashif nashif force-pushed the topic/tracing/semihosting branch 3 times, most recently from c0a704e to 75f5350 Compare October 6, 2025 10:32
Copy link

github-actions bot commented Oct 6, 2025

The following west manifest projects have changed revision in this Pull Request:

Name Old Revision New Revision Diff
percepio zephyrproject-rtos/percepio@49e6dc2 (zephyr) zephyrproject-rtos/percepio#15 zephyrproject-rtos/percepio#15/files

DNM label due to: 1 project with PR revision

Note: This message is automatically posted and updated by the Manifest GitHub Action.

@github-actions github-actions bot added manifest manifest-percepio DNM (manifest) This PR should not be merged (controlled by action-manifest) labels Oct 6, 2025
@nashif nashif marked this pull request as ready for review October 6, 2025 10:35
@zephyrbot zephyrbot added area: Tracing Tracing area: Kernel area: Build System area: Tests Issues related to a particular existing or missing test labels Oct 6, 2025
@zephyrbot zephyrbot requested review from teburd and tejlmand October 6, 2025 10:37
@nashif nashif assigned nashif and unassigned tejlmand Oct 6, 2025
@nashif
Copy link
Member Author

nashif commented Oct 6, 2025

reassign: mostly tracing related, assigned by mistake to build system because of the addition of a snippet.

nashif added 19 commits October 7, 2025 05:39
Return once simplifying tracing macros.

Signed-off-by: Anas Nashif <[email protected]>
Using semihosting on supported architectures (arm, xtensa, riscv) it now
possible to generate tracing giles easily and without being restricted
by size.
Using qemu for example, it is now possible to generate the tracing file
simply by running:

 west build -p -b mps2/an385 tests/kernel/msgq/msgq_api/ \
 	-t run --snippet semihost-tracing

This will generate a tracing file in the build/ directory which can be
viewed with babeltrace.

Signed-off-by: Anas Nashif <[email protected]>
Add missing return for mutex_unlock.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for memory slabs.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for message queues.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for condition variables.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for work queues.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for poll object.

Signed-off-by: Anas Nashif <[email protected]>
Add more thread related tracing functions.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for mail boxes.

Signed-off-by: Anas Nashif <[email protected]>
Add hooks for events.

Signed-off-by: Anas Nashif <[email protected]>
Add missing hooks for message queues.

Signed-off-by: Anas Nashif <[email protected]>
Add missing hooks for stack objects.

Signed-off-by: Anas Nashif <[email protected]>
Add missing hooks for events.

Signed-off-by: Anas Nashif <[email protected]>
Add missing hooks for mail boxes.

Signed-off-by: Anas Nashif <[email protected]>
Add semihost tracing to easy generating tracing data for existing
applications/tests.

Signed-off-by: Anas Nashif <[email protected]>
Violates coding guideline rule 21.2

Signed-off-by: Anas Nashif <[email protected]>
run clang-format and fix various checkpatch issues.

Signed-off-by: Anas Nashif <[email protected]>
Fix k_condvar arguments in percepio module.

Signed-off-by: Anas Nashif <[email protected]>
@nashif nashif force-pushed the topic/tracing/semihosting branch from 75f5350 to f71edee Compare October 7, 2025 09:45
Copy link

sonarqubecloud bot commented Oct 7, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Build System area: Kernel area: Tests Issues related to a particular existing or missing test area: Tracing Tracing DNM (manifest) This PR should not be merged (controlled by action-manifest) manifest manifest-percepio
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants