From c36ed4b8b83023b61595525734b757de02dca3d4 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sun, 1 Mar 2020 01:48:20 +0100 Subject: [PATCH] Boring warning fixes. --- client/TracyProfiler.cpp | 4 +--- server/TracyFilesystem.hpp | 2 +- server/TracyView.cpp | 10 ++++------ server/TracyWorker.cpp | 8 ++++---- 4 files changed, 10 insertions(+), 14 deletions(-) diff --git a/client/TracyProfiler.cpp b/client/TracyProfiler.cpp index a8f99911..7a09a8c2 100644 --- a/client/TracyProfiler.cpp +++ b/client/TracyProfiler.cpp @@ -2438,8 +2438,6 @@ void Profiler::CalibrateDelay() enum { Events = Iterations * 2 }; // start + end static_assert( Events < QueuePrealloc, "Delay calibration loop will allocate memory in queue" ); - moodycamel::ProducerToken ptoken_detail( GetQueue() ); - moodycamel::ConcurrentQueue::ExplicitProducer* ptoken = GetQueue().get_explicit_producer( ptoken_detail ); static const tracy::SourceLocationData __tracy_source_location { nullptr, __FUNCTION__, __FILE__, (uint32_t)__LINE__, 0 }; const auto t0 = GetTime(); for( int i=0; iEnd() - ev.Start(); cpus[it->Cpu()] = 1; ++it; - for( int64_t i=0; iEnd() - it->Start(); cpus[it->Cpu()] = 1; @@ -7974,13 +7974,13 @@ void View::DrawOptions() const auto srcval = m_threadOrder[source]; if( target < source ) { - assert( source < m_threadOrder.size() ); + assert( source < (int)m_threadOrder.size() ); m_threadOrder.erase( m_threadOrder.begin() + source ); m_threadOrder.insert( m_threadOrder.begin() + target, srcval ); } else { - assert( target <= m_threadOrder.size() ); + assert( target <= (int)m_threadOrder.size() ); m_threadOrder.insert( m_threadOrder.begin() + target, srcval ); m_threadOrder.erase( m_threadOrder.begin() + source ); } @@ -11518,7 +11518,6 @@ void View::DrawCallstackWindow() } ImGui::NextColumn(); { - ImGuiWindow* window = ImGui::GetCurrentWindow(); ImGui::PushTextWrapPos( 0.0f ); if( txt[0] == '[' ) { @@ -13475,7 +13474,6 @@ void View::DrawSampleParents() } ImGui::NextColumn(); { - ImGuiWindow* window = ImGui::GetCurrentWindow(); ImGui::PushTextWrapPos( 0.0f ); if( txt[0] == '[' ) { @@ -15762,7 +15760,7 @@ bool View::GetZoneRunningTime( const ContextSwitch* ctx, const ZoneEvent& ev, in { int64_t running = it->End() - ev.Start(); ++it; - for( int64_t i=0; iEnd() - it->Start(); ++it; diff --git a/server/TracyWorker.cpp b/server/TracyWorker.cpp index f1acab42..a0576f6f 100644 --- a/server/TracyWorker.cpp +++ b/server/TracyWorker.cpp @@ -277,7 +277,7 @@ Worker::Worker( const std::string& program, const std::vectorSync(); td.reset(); - for( size_t i=0; isecond; - if( txt[0] >= '0' && txt[0] <= '9' && atoi( txt ) == id ) + if( txt[0] >= '0' && txt[0] <= '9' && (uint64_t)atoi( txt ) == id ) { const auto eit = m_data.externalNames.find( id ); if( eit != m_data.externalNames.end() ) @@ -3967,7 +3967,7 @@ void Worker::ProcessFrameImage( const QueueFrameImage& ev ) m_data.frameImage.push_back( fi ); m_pendingFrameImageData.erase( it ); - if( fidx >= frames.size() ) + if( fidx >= (int64_t)frames.size() ) { if( m_frameImageStaging.find( fidx ) != m_frameImageStaging.end() ) {