Skip to content

Better tracefs detection#1343

Merged
wolfpld merged 5 commits intowolfpld:masterfrom
siliceum:fix/better-tracefs-detection
Apr 21, 2026
Merged

Better tracefs detection#1343
wolfpld merged 5 commits intowolfpld:masterfrom
siliceum:fix/better-tracefs-detection

Conversation

@Lectem
Copy link
Copy Markdown
Collaborator

@Lectem Lectem commented Apr 20, 2026

On older kernels and some systems (e.g. Android, embedded), tracefs is not mounted directly but is accessible under debugfs at <debugfs>/tracing. Users may also have been instructed to use sudo mount -t debugfs debugfs /sys/kernel/debug. Tracy would fail to find it and silently skip system tracing.

  • Switch tracefs detection from mnt_fsname to mnt_type, consistent with libtracefs. A tracefs mount with a custom source name (e.g. mount -t tracefs nodev /path) would previously be missed.
  • When no direct tracefs mount is found, fall back to <debugfs>/tracing if debugfs is present. Continues iterating /proc/mounts after a debugfs hit so a later tracefs entry still takes priority.
  • Also logs the reason when SysTraceStart fails to help users diagnose missing systrace information.

Comment thread public/client/TracySysTrace.cpp Outdated
Comment thread public/client/TracySysTrace.cpp Outdated
Comment thread public/client/TracySysTrace.cpp Outdated
@wolfpld wolfpld merged commit 217bdcf into wolfpld:master Apr 21, 2026
7 checks passed
@Lectem Lectem deleted the fix/better-tracefs-detection branch April 21, 2026 10:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants