Commit Graph

458 Commits

Author SHA1 Message Date
Bartosz Taudul
05cceee0df Release 0.13.1. 2025-12-11 23:46:02 +01:00
Bartosz Taudul
886a0abec9 Merge pull request #1215 from slomp/slomp/worker-thread-race
Fixed race condition around `s_sysTraceThread`
2025-12-03 22:43:42 +01:00
Marcos Slomp
7fa30d08b5 clarification 2025-12-03 12:41:44 -08:00
Marcos Slomp
874d65b036 code formatting 2025-12-03 10:15:19 -08:00
Marcos Slomp
c44beaac28 fixed race condition around s_sysTraceThread 2025-12-02 16:19:20 -08:00
Trevor L. McDonell
d1b0406801 Add option to ignore memory free faults
This replaces the IsApple flag, which was previously only used for this purpose.
2025-12-02 16:16:50 +01:00
Bartosz Taudul
be23d9354a Handle Lost_Event in Vsync callback on Windows. 2025-11-22 15:39:52 +01:00
Dery Almas
e1110d6c58 Fix error suppression macro
My previous fix triggered another issue: apparently at least GCC expects
the `_Pragma` operator to be placed in its own statement (after a
semicolon). The current macro simply dumped the expression and the
_Pragma together, triggering an error. Putting a semicolon after `Expr`
fixes the issue (actually double-checked after a `git clean -fdx`),
although slightly changing the API (the semicolon after the wrapped
macros is now optional).
2025-11-15 21:38:08 +01:00
Dery Almas
458d9ee89e Fix shadow error suppression on GCC
It looks like the actual macro defined by GCC is `__GNUC__`.

From my testing, `__GNU__` does not seem to be defined neither on my
musl machine nor a Fedora Linux VM. I have no idea if it's a typo or set
by specific libraries, but testing for `__GNUC__` actually suppresses
shadowing errors on my end.
2025-11-15 20:07:11 +01:00
Bartosz Taudul
5f4cccaa00 Use proper API to read /proc/mounts. 2025-11-13 19:40:28 +01:00
Simonas Kazlauskas
10b5f0d878 fix: GetDebugInfoDescriptor signature 2025-11-13 19:19:52 +02:00
Bartosz Taudul
89f68babd2 Android user name may be longer than _POSIX_LOGIN_NAME_MAX. 2025-11-13 12:28:57 +01:00
Bartosz Taudul
e6b9ea4609 Release 0.13.0. 2025-11-11 16:31:54 +01:00
Bartosz Taudul
b762dc2a82 Retrieve tracefs mount path. 2025-10-25 21:06:37 +02:00
Matt McGill
491445343f Defer GPU context events in serial C API
Without this, the profiler crashes due to an assert
violation when connecting to a client built with
TRACY_ON_DEMAND that uses these C API calls.
2025-10-24 18:52:36 -04:00
Bartosz Taudul
7b8d868bbd Merge pull request #1120 from siliceum/refactor/unify-module-caches
Unify module caches
2025-10-24 15:44:50 +02:00
Clément Grégoire
8ccc76c66b Use CopyStringFast in FormatImageName 2025-10-24 13:10:23 +02:00
Clément Grégoire
fe516e3596 IsKernelAddress helper 2025-10-24 13:10:23 +02:00
Clément Grégoire
2bdefc2aa3 Move drivers and modules caching to their own functions 2025-10-24 13:10:23 +02:00
Clément Grégoire
903cde50d9 Replace windows caches with ImageCache
- Introduce both s_imageCache and s_krnlCache on all platforms, even if unused (will be reused later to unify platforms handling)
- This means that what userland images that used to be unsorted are now sorted
2025-10-24 13:10:23 +02:00
Clément Grégoire
e1e9fb680d Rename TRACY_USE_IMAGE_CACHE to TRACY_HAS_DL_ITERATE_PHDR_TO_REFRESH_IMAGE_CACHE
Windows is already using a cache, and the only platforms that won't have one for now are those without dl_iterate_phdr.
2025-10-24 13:10:23 +02:00
Clément Grégoire
3b5b32d307 Replace hardcoded string duplication by CopyStringFast
This can be CopyStringFast since we allocated the cache on the same thread.
2025-10-24 13:10:22 +02:00
Clément Grégoire
32f94a05cb Support adding new entries and keeping the image cache sorted
Image cache will remain potentially unsorted until first access or `Sort` is called explicitely.
2025-10-24 12:54:35 +02:00
Clément Grégoire
0b814a2532 Split ImageCache to seperate platform specific so that it can be used on other platforms 2025-10-24 12:50:27 +02:00
Clément Grégoire
aa68c31780 Add path to ImageEntry in prevision of replacing KernelDriver use + add DestroyImageEntry for ImageEntry cleanup 2025-10-24 12:50:26 +02:00
Bartosz Taudul
30267de474 Make sure symbols thread has time to enter into disconnected condition. 2025-10-21 20:42:44 +02:00
Clément Grégoire
385f72f9dc Rename ImageCache::Contains to ContainsImage
The name was a bit misleading as it could be mistaken to mean "The cache contains the address" and not as "has an image with this start address". ie: that it could be mistaken to do GetImageForAddress( startAddress ) != nullptr.
2025-10-11 14:13:33 +02:00
Clément Grégoire
12026dae5b Make ImageEntry m_startAddress/m_endAddress uint64_t as it will later be used in server, and thus not pointing to current process memory 2025-10-11 14:10:18 +02:00
Clément Grégoire
9665f7ac42 Move ImageEntry to header in prevision of sharing it with other CPP files in the future 2025-10-11 13:52:03 +02:00
Lukas Bergdoll
5002c045e2 Make variable shadowing warning suppression optional 2025-10-03 11:57:18 +02:00
Lukas Bergdoll
abd7c4f317 Suppress variable shadowing warnings
This disables the warnings for MSVC, GCC and Clang in the ZoneScopedXX
macros.

The warnings produced are both a false positive since they didn't find a
bug *and* they don't happen in user written code, so the user couldn't
even do much about it. The previous workaround of using ZoneNamedXXX is
a poor solution since the Zone(Text|Name|etc.) macros all rely on the
`___tracy_scoped_zone` name.
2025-09-29 18:58:22 +02:00
Bartosz Taudul
f998e3e2a9 Merge pull request #1151 from dpelle/make-ZoneNameF-less-error-prone
Make ZoneNameF() less error-prone by checking format against args
2025-09-11 12:30:03 +02:00
Bartosz Taudul
5cf408fc10 Cosmetics. 2025-09-11 00:57:22 +02:00
Dominique Pelle
5f36f3d2ec Make ZoneNameF() less error-prone by checking format against args
`ZoneNameF(fmt, ...)` was error-prone: if the format is inconsistent
with arguments, the code compiled fine without errors or warnings.
Use gcc/clang `__attribute__((format(printf, fmt_idx, arg_idx)))`
function attribute, so that `ZoneNameF(fmt, ...)` can now check
at compilation time the consistency between the format and the
arguments.

See https://gcc.gnu.org/onlinedocs/gcc-3.1/gcc/Function-Attributes.html
2025-09-10 20:26:57 +02:00
Anders Wang Kristensen
355a11f47f Missing initialization of dequeueStatus 2025-09-10 14:43:28 +02:00
Anders Wang Kristensen
f21f8d6ad2 Fix crash due to freeing elements of m_serialDequeue twice.
In Profiler::DequeueSerial if AppendData fails part way through m_serialDequeue then the elements could be freed again in Profiler::ClearSerial, which leads to memory corruption in rpmalloc.
2025-09-10 12:56:47 +02:00
Minjie
c545b34f68 Add connection check when TRACY_ON_DEMAND for EnterFiber and LeaveFiber 2025-08-15 22:36:45 +08:00
PewPewCrit
11c9e3fa35 libbacktrace: recognize new Mach-O DWARF sections
Reference: libbacktrace@d48f84034ce3e53e501d10593710d025cb1121db
2025-08-04 14:17:18 +03:00
Marcos Slomp
5864350912 removed duplicated extern "C" 2025-08-02 06:48:00 -07:00
Marcos Slomp
9b84b527a6 adding manual control over sampling profiling 2025-08-01 15:24:30 -07:00
Marcos Slomp
b4b5f46d7b speeding up ExternalName queries 2025-08-01 12:53:56 -07:00
Bartosz Taudul
3bff910a27 Merge pull request #1121 from siliceum/feature/faster-module-caching-windows
Add faster module caching fallback by using GetModuleHandleExA
2025-08-01 20:44:19 +02:00
Gabriel Bon
1f6531f46d Add faster module caching fallback by using GetModuleHandleExA 2025-07-31 15:06:15 +02:00
Clément Grégoire
8c06fec09e Refactor libbacktrace usage with TRACY_USE_LIBBACKTRACE 2025-07-31 10:41:37 +02:00
Bartosz Taudul
c03fdaec1e Merge pull request #1097 from erieaton-amd/rocprofv3-2
Collect dispatches and counter values with Rocprofv3
2025-07-22 13:33:15 +02:00
Eric Eaton
1639598d62 Update documentation
This provides some instructions and tips for the manual. Also:
* Made the calibration feature a CMake option
* Cleaned up some minor code issues
* Fixed an issue with the calibration
* Incremented patch number
2025-07-21 15:30:42 -07:00
nyorain
02295cbfeb Allow to access wrapped Lockable object 2025-07-20 18:26:22 +02:00
Patrik Kraif
a642b84add Add missing TracyWinFamily header include 2025-07-18 10:10:02 +02:00
Patrik Kraif
dacd0fc63f Fix header guard to match the new file name 2025-07-16 12:55:22 +02:00
Patrik Kraif
4a3713cca8 Add support for GDK 2025-07-16 12:51:16 +02:00