early-access version 1690

This commit is contained in:
pineappleEA
2021-05-16 21:32:58 +02:00
parent 57e7aafeca
commit 23d1664dc2
15 changed files with 59 additions and 19 deletions

View File

@@ -690,7 +690,10 @@ void BufferCache<P>::BindHostGraphicsUniformBuffer(size_t stage, u32 index, u32
const VAddr cpu_addr = binding.cpu_addr;
const u32 size = binding.size;
Buffer& buffer = slot_buffers[binding.buffer_id];
if (size <= uniform_buffer_skip_cache_size && !buffer.IsRegionGpuModified(cpu_addr, size)) {
const bool use_fast_buffer = binding.buffer_id != NULL_BUFFER_ID &&
size <= uniform_buffer_skip_cache_size &&
!buffer.IsRegionGpuModified(cpu_addr, size);
if (use_fast_buffer) {
if constexpr (IS_OPENGL) {
if (runtime.HasFastBufferSubData()) {
// Fast path for Nvidia

View File

@@ -13,6 +13,7 @@
#include "core/frontend/emu_window.h"
#include "core/hardware_interrupt_manager.h"
#include "core/memory.h"
#include "core/perf_stats.h"
#include "video_core/engines/fermi_2d.h"
#include "video_core/engines/kepler_compute.h"
#include "video_core/engines/kepler_memory.h"
@@ -191,6 +192,10 @@ u64 GPU::GetTicks() const {
return nanoseconds_num * gpu_ticks_num + (nanoseconds_rem * gpu_ticks_num) / gpu_ticks_den;
}
void GPU::RendererFrameEndNotify() {
system.GetPerfStats().EndGameFrame();
}
void GPU::FlushCommands() {
rasterizer->FlushCommands();
}

View File

@@ -247,6 +247,8 @@ public:
return use_nvdec;
}
void RendererFrameEndNotify();
enum class FenceOperation : u32 {
Acquire = 0,
Increment = 1,

View File

@@ -155,6 +155,7 @@ void RendererOpenGL::SwapBuffers(const Tegra::FramebufferConfig* framebuffer) {
++m_current_frame;
gpu.RendererFrameEndNotify();
rasterizer.TickFrame();
context->SwapBuffers();

View File

@@ -154,6 +154,7 @@ void RendererVulkan::SwapBuffers(const Tegra::FramebufferConfig* framebuffer) {
if (swapchain.Present(render_semaphore)) {
blit_screen.Recreate();
}
gpu.RendererFrameEndNotify();
rasterizer.TickFrame();
}