diff options
| author | 2019-04-16 10:19:52 -0400 | |
|---|---|---|
| committer | 2019-04-16 11:22:34 -0400 | |
| commit | 13d626fc217c4286a80071c5885eee2ab8795d62 (patch) | |
| tree | 375697bccef4c12206b1eb8dfeb68e81e2378028 /src/video_core | |
| parent | Document unsafe versions and add BlockCopyUnsafe (diff) | |
| download | yuzu-13d626fc217c4286a80071c5885eee2ab8795d62.tar.gz yuzu-13d626fc217c4286a80071c5885eee2ab8795d62.tar.xz yuzu-13d626fc217c4286a80071c5885eee2ab8795d62.zip | |
Use ReadBlockUnsafe for fetyching DMA CommandLists
Diffstat (limited to 'src/video_core')
| -rw-r--r-- | src/video_core/dma_pusher.cpp | 4 | ||||
| -rw-r--r-- | src/video_core/memory_manager.h | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/video_core/dma_pusher.cpp b/src/video_core/dma_pusher.cpp index 046d047cb..6674d9405 100644 --- a/src/video_core/dma_pusher.cpp +++ b/src/video_core/dma_pusher.cpp | |||
| @@ -57,8 +57,8 @@ bool DmaPusher::Step() { | |||
| 57 | 57 | ||
| 58 | // Push buffer non-empty, read a word | 58 | // Push buffer non-empty, read a word |
| 59 | command_headers.resize(command_list_header.size); | 59 | command_headers.resize(command_list_header.size); |
| 60 | gpu.MemoryManager().ReadBlock(dma_get, command_headers.data(), | 60 | gpu.MemoryManager().ReadBlockUnsafe(dma_get, command_headers.data(), |
| 61 | command_list_header.size * sizeof(u32)); | 61 | command_list_header.size * sizeof(u32)); |
| 62 | 62 | ||
| 63 | for (const CommandHeader& command_header : command_headers) { | 63 | for (const CommandHeader& command_header : command_headers) { |
| 64 | 64 | ||
diff --git a/src/video_core/memory_manager.h b/src/video_core/memory_manager.h index 084d834c8..017b051cf 100644 --- a/src/video_core/memory_manager.h +++ b/src/video_core/memory_manager.h | |||
| @@ -65,7 +65,6 @@ public: | |||
| 65 | u8* GetPointer(GPUVAddr addr); | 65 | u8* GetPointer(GPUVAddr addr); |
| 66 | const u8* GetPointer(GPUVAddr addr) const; | 66 | const u8* GetPointer(GPUVAddr addr) const; |
| 67 | 67 | ||
| 68 | |||
| 69 | /* | 68 | /* |
| 70 | * ReadBlock and WriteBlock are full read and write operations over virtual | 69 | * ReadBlock and WriteBlock are full read and write operations over virtual |
| 71 | * GPU Memory. It's important to use these when GPU memory may not be continous | 70 | * GPU Memory. It's important to use these when GPU memory may not be continous |
| @@ -90,7 +89,6 @@ public: | |||
| 90 | void WriteBlockUnsafe(GPUVAddr dest_addr, const void* src_buffer, const std::size_t size); | 89 | void WriteBlockUnsafe(GPUVAddr dest_addr, const void* src_buffer, const std::size_t size); |
| 91 | void CopyBlockUnsafe(GPUVAddr dest_addr, GPUVAddr src_addr, const std::size_t size); | 90 | void CopyBlockUnsafe(GPUVAddr dest_addr, GPUVAddr src_addr, const std::size_t size); |
| 92 | 91 | ||
| 93 | |||
| 94 | private: | 92 | private: |
| 95 | using VMAMap = std::map<GPUVAddr, VirtualMemoryArea>; | 93 | using VMAMap = std::map<GPUVAddr, VirtualMemoryArea>; |
| 96 | using VMAHandle = VMAMap::const_iterator; | 94 | using VMAHandle = VMAMap::const_iterator; |