mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-12-25 15:16:02 +00:00
Remove rejit requests queue logging
This commit is contained in:
parent
b65480cdf5
commit
60e56f3efe
1 changed files with 0 additions and 33 deletions
|
@ -24,10 +24,6 @@ namespace ARMeilleure.Translation
|
||||||
{
|
{
|
||||||
private const int CountTableCapacity = 4 * 1024 * 1024;
|
private const int CountTableCapacity = 4 * 1024 * 1024;
|
||||||
|
|
||||||
private long _nextUpdate;
|
|
||||||
private long _requestAdded;
|
|
||||||
private long _requestRemoved;
|
|
||||||
|
|
||||||
private readonly IJitMemoryAllocator _allocator;
|
private readonly IJitMemoryAllocator _allocator;
|
||||||
private readonly IMemoryManager _memory;
|
private readonly IMemoryManager _memory;
|
||||||
|
|
||||||
|
@ -50,8 +46,6 @@ namespace ARMeilleure.Translation
|
||||||
|
|
||||||
public Translator(IJitMemoryAllocator allocator, IMemoryManager memory)
|
public Translator(IJitMemoryAllocator allocator, IMemoryManager memory)
|
||||||
{
|
{
|
||||||
_nextUpdate = Stopwatch.GetTimestamp();
|
|
||||||
|
|
||||||
_allocator = allocator;
|
_allocator = allocator;
|
||||||
_memory = memory;
|
_memory = memory;
|
||||||
|
|
||||||
|
@ -79,8 +73,6 @@ namespace ARMeilleure.Translation
|
||||||
if (_backgroundStack.TryPop(out RejitRequest request) &&
|
if (_backgroundStack.TryPop(out RejitRequest request) &&
|
||||||
_backgroundSet.TryRemove(request.Address, out _))
|
_backgroundSet.TryRemove(request.Address, out _))
|
||||||
{
|
{
|
||||||
Interlocked.Increment(ref _requestRemoved);
|
|
||||||
|
|
||||||
TranslatedFunction func = Translate(
|
TranslatedFunction func = Translate(
|
||||||
_memory,
|
_memory,
|
||||||
_jumpTable,
|
_jumpTable,
|
||||||
|
@ -102,28 +94,6 @@ namespace ARMeilleure.Translation
|
||||||
PtcProfiler.UpdateEntry(request.Address, request.Mode, highCq: true);
|
PtcProfiler.UpdateEntry(request.Address, request.Mode, highCq: true);
|
||||||
}
|
}
|
||||||
|
|
||||||
var nextUpdate = Interlocked.Exchange(ref _nextUpdate, 0);
|
|
||||||
|
|
||||||
if (nextUpdate != 0)
|
|
||||||
{
|
|
||||||
var now = Stopwatch.GetTimestamp();
|
|
||||||
|
|
||||||
if (now < nextUpdate)
|
|
||||||
{
|
|
||||||
_nextUpdate = nextUpdate;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
Ryujinx.Common.Logging.Logger.Info?.Print(
|
|
||||||
Ryujinx.Common.Logging.LogClass.Cpu,
|
|
||||||
$"{_backgroundStack.Count} rejit requests remaining (+{_requestAdded}:-{_requestRemoved}).");
|
|
||||||
|
|
||||||
_requestAdded = 0;
|
|
||||||
_requestRemoved = 0;
|
|
||||||
_nextUpdate = now + Stopwatch.Frequency * 30;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
_backgroundTranslatorLock.ReleaseReaderLock();
|
_backgroundTranslatorLock.ReleaseReaderLock();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -480,7 +450,6 @@ namespace ARMeilleure.Translation
|
||||||
{
|
{
|
||||||
if (_backgroundSet.TryAdd(guestAddress, null))
|
if (_backgroundSet.TryAdd(guestAddress, null))
|
||||||
{
|
{
|
||||||
Interlocked.Increment(ref _requestAdded);
|
|
||||||
_backgroundStack.Push(new RejitRequest(guestAddress, mode));
|
_backgroundStack.Push(new RejitRequest(guestAddress, mode));
|
||||||
_backgroundTranslatorEvent.Set();
|
_backgroundTranslatorEvent.Set();
|
||||||
}
|
}
|
||||||
|
@ -513,8 +482,6 @@ namespace ARMeilleure.Translation
|
||||||
{
|
{
|
||||||
_backgroundTranslatorLock.AcquireWriterLock(Timeout.Infinite);
|
_backgroundTranslatorLock.AcquireWriterLock(Timeout.Infinite);
|
||||||
|
|
||||||
Interlocked.Add(ref _requestRemoved, _backgroundStack.Count);
|
|
||||||
|
|
||||||
if (allowRequeue)
|
if (allowRequeue)
|
||||||
{
|
{
|
||||||
while (_backgroundStack.TryPop(out var request))
|
while (_backgroundStack.TryPop(out var request))
|
||||||
|
|
Loading…
Reference in a new issue