| 4434 | } |
| 4435 | |
| 4436 | void Profiler::MemDiscardCallstack( const char* name, bool secure, int32_t depth ) |
| 4437 | { |
| 4438 | if( secure && !ProfilerAvailable() ) return; |
| 4439 | if( depth > 0 && has_callstack() ) |
| 4440 | { |
| 4441 | # ifdef TRACY_ON_DEMAND |
| 4442 | if( !GetProfiler().IsConnected() ) return; |
| 4443 | # endif |
| 4444 | const auto thread = GetThreadHandle(); |
| 4445 | |
| 4446 | auto callstack = Callstack( depth ); |
| 4447 | |
| 4448 | GetProfiler().m_serialLock.lock(); |
| 4449 | SendCallstackSerial( callstack ); |
| 4450 | SendMemDiscard( QueueType::MemDiscard, thread, name ); |
| 4451 | GetProfiler().m_serialLock.unlock(); |
| 4452 | } |
| 4453 | else |
| 4454 | { |
| 4455 | MemDiscard( name, secure ); |
| 4456 | } |
| 4457 | } |
| 4458 | |
| 4459 | void Profiler::SendCallstack( int depth ) |
| 4460 | { |
nothing calls this directly
no test coverage detected