Add path to ImageEntry in prevision of replacing KernelDriver use + add DestroyImageEntry for ImageEntry cleanup

This commit is contained in:
Clément Grégoire
2025-10-11 14:25:37 +02:00
parent 385f72f9dc
commit aa68c31780
2 changed files with 8 additions and 1 deletions

View File

@@ -117,6 +117,12 @@ extern "C" const char* ___tracy_demangle( const char* mangled )
namespace tracy
{
void DestroyImageEntry( ImageEntry& entry )
{
tracy_free( entry.m_path );
tracy_free( entry.m_name );
}
#ifdef TRACY_USE_IMAGE_CACHE
// when we have access to dl_iterate_phdr(), we can build a cache of address ranges to image paths
// so we can quickly determine which image an address falls into.
@@ -252,7 +258,7 @@ private:
{
for( ImageEntry& entry : m_images )
{
tracy_free( entry.m_name );
DestroyImageEntry( entry );
}
m_images.clear();