mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-10 02:31:48 +00:00
Implement build id retrieval by image name.
This commit is contained in:
parent
324cab3d34
commit
ae373b4050
@ -728,6 +728,20 @@ int GetDebugInfoDescriptor( const char* buildid_data, size_t buildid_size, const
|
||||
it->fd = fd >= 0 ? fd : -1;
|
||||
return it->fd;
|
||||
}
|
||||
|
||||
const uint8_t* GetBuildIdForImage( const char* image, size_t& size )
|
||||
{
|
||||
assert( image );
|
||||
for( auto& v : s_di_known )
|
||||
{
|
||||
if( strcmp( image, v.filename ) == 0 )
|
||||
{
|
||||
size = v.buildid_size;
|
||||
return v.buildid;
|
||||
}
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
#endif
|
||||
|
||||
void EndCallstack()
|
||||
|
@ -54,6 +54,10 @@ void InitCallstack();
|
||||
void EndCallstack();
|
||||
const char* GetKernelModulePath( uint64_t addr );
|
||||
|
||||
#ifdef TRACY_DEBUGINFOD
|
||||
const uint8_t* GetBuildIdForImage( const char* image, size_t& size );
|
||||
#endif
|
||||
|
||||
#if TRACY_HAS_CALLSTACK == 1
|
||||
|
||||
extern "C"
|
||||
|
Loading…
Reference in New Issue
Block a user