mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-20 22:05:12 +00:00
add --disable-cache option
This commit is contained in:
parent
6a2507c777
commit
fc12bee2cb
4 changed files with 23 additions and 10 deletions
|
|
@ -2,6 +2,7 @@
|
|||
#include "Device.hpp"
|
||||
#include "amdgpu/tiler.hpp"
|
||||
#include "gnm/vulkan.hpp"
|
||||
#include "rx/Config.hpp"
|
||||
#include "rx/hexdump.hpp"
|
||||
#include "rx/mem.hpp"
|
||||
#include "shader/Evaluator.hpp"
|
||||
|
|
@ -24,8 +25,6 @@
|
|||
using namespace amdgpu;
|
||||
using namespace shader;
|
||||
|
||||
static constexpr bool kDisableCache = false;
|
||||
|
||||
static bool testHostInvalidations(Device *device, int vmId,
|
||||
std::uint64_t address, std::uint64_t size) {
|
||||
auto firstPage = address / rx::mem::pageSize;
|
||||
|
|
@ -703,7 +702,7 @@ struct CachedHostVisibleBuffer : CachedBuffer {
|
|||
using CachedBuffer::update;
|
||||
|
||||
bool expensive() {
|
||||
return !kDisableCache && addressRange.size() >= rx::mem::pageSize;
|
||||
return !rx::g_config.disableGpuCache && addressRange.size() >= rx::mem::pageSize;
|
||||
}
|
||||
|
||||
bool flush(void *target, rx::AddressRange range) {
|
||||
|
|
@ -779,7 +778,7 @@ struct CachedImageBuffer : Cache::Entry {
|
|||
unsigned depth = 1;
|
||||
|
||||
bool expensive() {
|
||||
if (kDisableCache) {
|
||||
if (rx::g_config.disableGpuCache) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -954,7 +953,7 @@ struct CachedImage : Cache::Entry {
|
|||
|
||||
bool expensive() {
|
||||
return false;
|
||||
if (kDisableCache) {
|
||||
if (rx::g_config.disableGpuCache) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue