MaranBr
3 days ago
committed by
crueter
No known key found for this signature in database
GPG Key ID: 425ACD2D4830EBC6
1 changed files with
6 additions and
7 deletions
-
src/video_core/fence_manager.h
|
|
@ -76,21 +76,20 @@ public: |
|
|
TryReleasePendingFences<false>(); |
|
|
TryReleasePendingFences<false>(); |
|
|
} |
|
|
} |
|
|
const bool should_flush = ShouldFlush(); |
|
|
const bool should_flush = ShouldFlush(); |
|
|
|
|
|
const bool delay_fence = Settings::IsGPULevelHigh() || (Settings::IsGPULevelMedium() && should_flush); |
|
|
CommitAsyncFlushes(); |
|
|
CommitAsyncFlushes(); |
|
|
TFence new_fence = CreateFence(!should_flush); |
|
|
TFence new_fence = CreateFence(!should_flush); |
|
|
if constexpr (can_async_check) { |
|
|
if constexpr (can_async_check) { |
|
|
guard.lock(); |
|
|
guard.lock(); |
|
|
} |
|
|
} |
|
|
if (Settings::IsGPULevelLow() || (Settings::IsGPULevelMedium() && !should_flush)) { |
|
|
|
|
|
func(); |
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
|
if (delay_fence) { |
|
|
uncommitted_operations.emplace_back(std::move(func)); |
|
|
uncommitted_operations.emplace_back(std::move(func)); |
|
|
} |
|
|
} |
|
|
if (!uncommitted_operations.empty()) { |
|
|
|
|
|
pending_operations.emplace_back(std::move(uncommitted_operations)); |
|
|
|
|
|
uncommitted_operations.clear(); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
pending_operations.emplace_back(std::move(uncommitted_operations)); |
|
|
QueueFence(new_fence); |
|
|
QueueFence(new_fence); |
|
|
|
|
|
if (!delay_fence) { |
|
|
|
|
|
func(); |
|
|
|
|
|
} |
|
|
fences.push(std::move(new_fence)); |
|
|
fences.push(std::move(new_fence)); |
|
|
if (should_flush) { |
|
|
if (should_flush) { |
|
|
rasterizer.FlushCommands(); |
|
|
rasterizer.FlushCommands(); |
|
|
|