Add source location overflow failures.

This commit is contained in:
Bartosz Taudul 2023-12-31 12:58:56 +01:00
parent cb7ce1c3aa
commit 54ee77026f
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3
2 changed files with 8 additions and 0 deletions

View File

@ -5029,6 +5029,11 @@ void Worker::FiberLeaveFailure()
m_failure = Failure::FiberLeave;
}
void Worker::SourceLocationOverflowFailure()
{
m_failure = Failure::SourceLocationOverflow;
}
void Worker::ProcessZoneValidation( const QueueZoneValidation& ev )
{
auto td = GetCurrentThreadData();
@ -8370,6 +8375,7 @@ static const char* s_failureReasons[] = {
"Frame image offset is invalid.",
"Multiple frame images were sent for a single frame.",
"Fiber execution stopped on a thread which is not executing a fiber.",
"Too many source locations. You cannot have more than 32K static or dynamic source locations.",
};
static_assert( sizeof( s_failureReasons ) / sizeof( *s_failureReasons ) == (int)Worker::Failure::NUM_FAILURES, "Missing failure reason description." );

View File

@ -441,6 +441,7 @@ public:
FrameImageIndex,
FrameImageTwice,
FiberLeave,
SourceLocationOverflow,
NUM_FAILURES
};
@ -790,6 +791,7 @@ private:
void FrameImageIndexFailure();
void FrameImageTwiceFailure();
void FiberLeaveFailure();
void SourceLocationOverflowFailure();
tracy_force_inline void CheckSourceLocation( uint64_t ptr );
void NewSourceLocation( uint64_t ptr );