diff --git a/Ryujinx.HLE/HOS/Services/IpcService.cs b/Ryujinx.HLE/HOS/Services/IpcService.cs index a840786c57..7ae5934b0c 100644 --- a/Ryujinx.HLE/HOS/Services/IpcService.cs +++ b/Ryujinx.HLE/HOS/Services/IpcService.cs @@ -97,8 +97,8 @@ namespace Ryujinx.HLE.HOS.Services Logger.PrintDebug(LogClass.KernelIpc, $"{service.GetType().Name}: {processRequest.Method.Name}"); ProfileConfig profile = Profiles.ServiceCall; - profile.SessionGroup = service.GetType().Name; - profile.SessionItem = processRequest.Method.Name; + profile.SessionGroup = service.GetType().Name; + profile.SessionItem = processRequest.Method.Name; Profile.Begin(profile); long result = processRequest(context); diff --git a/Ryujinx.Profiler/Settings.cs b/Ryujinx.Profiler/Settings.cs index f8db5bb98d..35476b9dec 100644 --- a/Ryujinx.Profiler/Settings.cs +++ b/Ryujinx.Profiler/Settings.cs @@ -14,7 +14,7 @@ namespace Ryujinx.Profiler public int MaxLevel { get; set; } = 0; // 19531225 = 5 seconds in ticks - public long History { get; set; } = 19531225; + public long History { get; set; } = 19531225; // Controls public NpadDebug Controls; diff --git a/Ryujinx.Profiler/TimingInfo.cs b/Ryujinx.Profiler/TimingInfo.cs index 2dc3072340..e444e42376 100644 --- a/Ryujinx.Profiler/TimingInfo.cs +++ b/Ryujinx.Profiler/TimingInfo.cs @@ -50,7 +50,6 @@ namespace Ryujinx.Profiler // Depth of current timer, // each begin call increments and each end call decrements private int _depth; - public TimingInfo() { diff --git a/Ryujinx.Profiler/UI/ProfileWindow.cs b/Ryujinx.Profiler/UI/ProfileWindow.cs index ee09512b74..b13e7b8da4 100644 --- a/Ryujinx.Profiler/UI/ProfileWindow.cs +++ b/Ryujinx.Profiler/UI/ProfileWindow.cs @@ -41,14 +41,11 @@ namespace Ryujinx.Profiler.UI private ProfileButton[] _buttons; private bool _initComplete = false; - private bool _visible = true; private bool _visibleChanged = true; private bool _viewportUpdated = true; private bool _redrawPending = true; - private bool _displayGraph = true; - private bool _showInactive = true; private bool _paused = false; private bool _doStep = false; @@ -84,6 +81,7 @@ namespace Ryujinx.Profiler.UI private bool _prevBackspaceDown = false; private double _backspaceDownTime = 0; + // F35 used as no key private Key _graphControlKey = Key.F35; // Event management @@ -91,7 +89,6 @@ namespace Ryujinx.Profiler.UI private double _processEventTimer; private bool _profileUpdated = false; private readonly object _profileDataLock = new object(); - public ProfileWindow() // Graphigs mode enables 2xAA @@ -553,9 +550,9 @@ namespace Ryujinx.Profiler.UI // Totals yHeight = FilterHeight + 2; - _fontService.DrawText($"{totalInstant / PerformanceCounter.TicksPerMillisecond:F3} ({totalCount})", xOffset, yHeight, TitleFontHeight); - _fontService.DrawText($"{totalAverage / PerformanceCounter.TicksPerMillisecond:F3}", 150 + xOffset, yHeight, TitleFontHeight); - _fontService.DrawText($"{totalTime / PerformanceCounter.TicksPerMillisecond:F3}", 260 + xOffset, yHeight, TitleFontHeight); + _fontService.DrawText($"{totalInstant / PerformanceCounter.TicksPerMillisecond:F3} ({totalCount})", xOffset, yHeight, TitleFontHeight); + _fontService.DrawText($"{totalAverage / PerformanceCounter.TicksPerMillisecond:F3}", 150 + xOffset, yHeight, TitleFontHeight); + _fontService.DrawText($"{totalTime / PerformanceCounter.TicksPerMillisecond:F3}", 260 + xOffset, yHeight, TitleFontHeight); #endregion } diff --git a/Ryujinx.Profiler/UI/ProfileWindowBars.cs b/Ryujinx.Profiler/UI/ProfileWindowBars.cs index 978c4bedc5..b1955a0766 100644 --- a/Ryujinx.Profiler/UI/ProfileWindowBars.cs +++ b/Ryujinx.Profiler/UI/ProfileWindowBars.cs @@ -23,7 +23,7 @@ namespace Ryujinx.Profiler.UI { maxInstant = Math.Max(maxInstant, kvp.Value.Instant); maxAverage = Math.Max(maxAverage, kvp.Value.AverageTime); - maxTotal = Math.Max(maxTotal, kvp.Value.TotalTime); + maxTotal = Math.Max(maxTotal, kvp.Value.TotalTime); } GL.Enable(EnableCap.ScissorTest); @@ -33,8 +33,8 @@ namespace Ryujinx.Profiler.UI // Instant GL.Color3(Color.Blue); float bottom = GetLineY(yOffset, LineHeight, LinePadding, true, verticalIndex++); - float top = bottom + barHeight; - float right = (float)entry.Value.Instant / maxInstant * width + xOffset; + float top = bottom + barHeight; + float right = (float)entry.Value.Instant / maxInstant * width + xOffset; // Skip rendering out of bounds bars if (top < 0 || bottom > Height) @@ -42,17 +42,18 @@ namespace Ryujinx.Profiler.UI GL.Vertex2(xOffset, bottom); GL.Vertex2(xOffset, top); - GL.Vertex2(right, top); + GL.Vertex2(right, top); - GL.Vertex2(right, top); - GL.Vertex2(right, bottom); + GL.Vertex2(right, top); + GL.Vertex2(right, bottom); GL.Vertex2(xOffset, bottom); // Average GL.Color3(Color.Green); - top += barHeight; + top += barHeight; bottom += barHeight; - right = (float)entry.Value.AverageTime / maxAverage * width + xOffset; + right = (float)entry.Value.AverageTime / maxAverage * width + xOffset; + GL.Vertex2(xOffset, bottom); GL.Vertex2(xOffset, top); GL.Vertex2(right, top); @@ -63,9 +64,10 @@ namespace Ryujinx.Profiler.UI // Total GL.Color3(Color.Red); - top += barHeight; + top += barHeight; bottom += barHeight; - right = (float)entry.Value.TotalTime / maxTotal * width + xOffset; + right = (float)entry.Value.TotalTime / maxTotal * width + xOffset; + GL.Vertex2(xOffset, bottom); GL.Vertex2(xOffset, top); GL.Vertex2(right, top);