#include "common/profiler.h" #include "common/emulatorConfig.h" #include #include #include #include namespace Profiler { void SetThreadName(const char* name) { if (tracy::ProfilerAvailable() && name != nullptr) { tracy::SetThreadName(name); } } void Initialize() { if (Config::ProfilerEnabled() && !tracy::ProfilerAvailable()) { tracy::StartupProfiler(); TracySetProgramName("KytyPS5"); ::printf("Tracy profiler enabled: client %d.%d.%d, protocol %u, " "broadcast %u, connect to 127.0.0.1:8086\n", tracy::Version::Major, tracy::Version::Minor, tracy::Version::Patch, tracy::ProtocolVersion, tracy::BroadcastVersion); } } void Shutdown() { if (tracy::ProfilerAvailable()) { tracy::ShutdownProfiler(); } } } // namespace Profiler