summaryrefslogtreecommitdiffstats
path: root/src/core/memory.cpp
diff options
context:
space:
mode:
authorJames Rowe <jroweboy@gmail.com>2018-01-12 04:33:56 +0100
committerJames Rowe <jroweboy@gmail.com>2018-01-13 03:11:04 +0100
commit389979018cce654b1ade0161abfc627832afe592 (patch)
tree90536049d982e4f5ee1df984b1d9da52db704e95 /src/core/memory.cpp
parentRemove references to PICA and rasterizers in video_core (diff)
downloadyuzu-389979018cce654b1ade0161abfc627832afe592.tar
yuzu-389979018cce654b1ade0161abfc627832afe592.tar.gz
yuzu-389979018cce654b1ade0161abfc627832afe592.tar.bz2
yuzu-389979018cce654b1ade0161abfc627832afe592.tar.lz
yuzu-389979018cce654b1ade0161abfc627832afe592.tar.xz
yuzu-389979018cce654b1ade0161abfc627832afe592.tar.zst
yuzu-389979018cce654b1ade0161abfc627832afe592.zip
Diffstat (limited to 'src/core/memory.cpp')
-rw-r--r--src/core/memory.cpp41
1 files changed, 1 insertions, 40 deletions
diff --git a/src/core/memory.cpp b/src/core/memory.cpp
index 01ec231f6..74a598852 100644
--- a/src/core/memory.cpp
+++ b/src/core/memory.cpp
@@ -4,7 +4,6 @@
#include <array>
#include <cstring>
-#include "audio_core/audio_core.h"
#include "common/assert.h"
#include "common/common_types.h"
#include "common/logging/log.h"
@@ -311,7 +310,6 @@ u8* GetPhysicalPointer(PAddr address) {
target_pointer = vram.data() + offset_into_region;
break;
case DSP_RAM_PADDR:
- target_pointer = AudioCore::GetDspMemory().data() + offset_into_region;
break;
case FCRAM_PADDR:
for (const auto& region : Kernel::memory_regions) {
@@ -413,53 +411,16 @@ void RasterizerMarkRegionCached(PAddr start, u64 size, int count_delta) {
}
}
-void RasterizerFlushRegion(PAddr start, u64 size) {
- if (VideoCore::g_renderer != nullptr) {
- VideoCore::g_renderer->Rasterizer()->FlushRegion(start, size);
- }
-}
+void RasterizerFlushRegion(PAddr start, u64 size) {}
void RasterizerFlushAndInvalidateRegion(PAddr start, u64 size) {
// Since pages are unmapped on shutdown after video core is shutdown, the renderer may be
// null here
- if (VideoCore::g_renderer != nullptr) {
- VideoCore::g_renderer->Rasterizer()->FlushAndInvalidateRegion(start, size);
- }
}
void RasterizerFlushVirtualRegion(VAddr start, u64 size, FlushMode mode) {
// Since pages are unmapped on shutdown after video core is shutdown, the renderer may be
// null here
- if (VideoCore::g_renderer != nullptr) {
- VAddr end = start + size;
-
- auto CheckRegion = [&](VAddr region_start, VAddr region_end) {
- if (start >= region_end || end <= region_start) {
- // No overlap with region
- return;
- }
-
- VAddr overlap_start = std::max(start, region_start);
- VAddr overlap_end = std::min(end, region_end);
-
- PAddr physical_start = TryVirtualToPhysicalAddress(overlap_start).value();
- u32 overlap_size = static_cast<u32>(overlap_end - overlap_start);
-
- auto* rasterizer = VideoCore::g_renderer->Rasterizer();
- switch (mode) {
- case FlushMode::Flush:
- rasterizer->FlushRegion(physical_start, overlap_size);
- break;
- case FlushMode::FlushAndInvalidate:
- rasterizer->FlushAndInvalidateRegion(physical_start, overlap_size);
- break;
- }
- };
-
- CheckRegion(LINEAR_HEAP_VADDR, LINEAR_HEAP_VADDR_END);
- CheckRegion(NEW_LINEAR_HEAP_VADDR, NEW_LINEAR_HEAP_VADDR_END);
- CheckRegion(VRAM_VADDR, VRAM_VADDR_END);
- }
}
u8 Read8(const VAddr addr) {