mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-05 01:24:14 +01:00
[dxvk] Remove dxvk.allowMemoryOvercommit option
The default behaviour is now to allow overallocation by default, which makes sense especially when VK_EXT_memory_priority is used. Does not seem to affect Nvidia drivers.
This commit is contained in:
parent
dfa8524e73
commit
b76f470c5f
@ -273,9 +273,6 @@ namespace dxvk {
|
|||||||
VkDeviceMemoryOverallocationCreateInfoAMD overallocInfo;
|
VkDeviceMemoryOverallocationCreateInfoAMD overallocInfo;
|
||||||
overallocInfo.sType = VK_STRUCTURE_TYPE_DEVICE_MEMORY_OVERALLOCATION_CREATE_INFO_AMD;
|
overallocInfo.sType = VK_STRUCTURE_TYPE_DEVICE_MEMORY_OVERALLOCATION_CREATE_INFO_AMD;
|
||||||
overallocInfo.pNext = nullptr;
|
overallocInfo.pNext = nullptr;
|
||||||
overallocInfo.overallocationBehavior = VK_MEMORY_OVERALLOCATION_BEHAVIOR_DISALLOWED_AMD;
|
|
||||||
|
|
||||||
if (m_instance->options().allowMemoryOvercommit)
|
|
||||||
overallocInfo.overallocationBehavior = VK_MEMORY_OVERALLOCATION_BEHAVIOR_ALLOWED_AMD;
|
overallocInfo.overallocationBehavior = VK_MEMORY_OVERALLOCATION_BEHAVIOR_ALLOWED_AMD;
|
||||||
|
|
||||||
// Create one single queue for graphics and present
|
// Create one single queue for graphics and present
|
||||||
|
@ -156,8 +156,7 @@ namespace dxvk {
|
|||||||
: m_vkd (device->vkd()),
|
: m_vkd (device->vkd()),
|
||||||
m_device (device),
|
m_device (device),
|
||||||
m_devProps (device->adapter()->deviceProperties()),
|
m_devProps (device->adapter()->deviceProperties()),
|
||||||
m_memProps (device->adapter()->memoryProperties()),
|
m_memProps (device->adapter()->memoryProperties()) {
|
||||||
m_allowOvercommit (device->config().allowMemoryOvercommit) {
|
|
||||||
for (uint32_t i = 0; i < m_memProps.memoryHeapCount; i++) {
|
for (uint32_t i = 0; i < m_memProps.memoryHeapCount; i++) {
|
||||||
VkDeviceSize heapSize = m_memProps.memoryHeaps[i].size;
|
VkDeviceSize heapSize = m_memProps.memoryHeaps[i].size;
|
||||||
|
|
||||||
|
@ -265,7 +265,6 @@ namespace dxvk {
|
|||||||
const DxvkDevice* m_device;
|
const DxvkDevice* m_device;
|
||||||
const VkPhysicalDeviceProperties m_devProps;
|
const VkPhysicalDeviceProperties m_devProps;
|
||||||
const VkPhysicalDeviceMemoryProperties m_memProps;
|
const VkPhysicalDeviceMemoryProperties m_memProps;
|
||||||
const bool m_allowOvercommit;
|
|
||||||
|
|
||||||
std::mutex m_mutex;
|
std::mutex m_mutex;
|
||||||
std::array<DxvkMemoryHeap, VK_MAX_MEMORY_HEAPS> m_memHeaps;
|
std::array<DxvkMemoryHeap, VK_MAX_MEMORY_HEAPS> m_memHeaps;
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
namespace dxvk {
|
namespace dxvk {
|
||||||
|
|
||||||
DxvkOptions::DxvkOptions(const Config& config) {
|
DxvkOptions::DxvkOptions(const Config& config) {
|
||||||
allowMemoryOvercommit = config.getOption<bool> ("dxvk.allowMemoryOvercommit", false);
|
|
||||||
enableStateCache = config.getOption<bool> ("dxvk.enableStateCache", true);
|
enableStateCache = config.getOption<bool> ("dxvk.enableStateCache", true);
|
||||||
numCompilerThreads = config.getOption<int32_t> ("dxvk.numCompilerThreads", 0);
|
numCompilerThreads = config.getOption<int32_t> ("dxvk.numCompilerThreads", 0);
|
||||||
useRawSsbo = config.getOption<Tristate>("dxvk.useRawSsbo", Tristate::Auto);
|
useRawSsbo = config.getOption<Tristate>("dxvk.useRawSsbo", Tristate::Auto);
|
||||||
|
@ -8,10 +8,6 @@ namespace dxvk {
|
|||||||
DxvkOptions() { }
|
DxvkOptions() { }
|
||||||
DxvkOptions(const Config& config);
|
DxvkOptions(const Config& config);
|
||||||
|
|
||||||
/// Allow allocating more memory from
|
|
||||||
/// a heap than the device supports.
|
|
||||||
bool allowMemoryOvercommit;
|
|
||||||
|
|
||||||
/// Enable state cache
|
/// Enable state cache
|
||||||
bool enableStateCache;
|
bool enableStateCache;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user