protonscr

Skyrim: DxvkMemoryAllocator: Memory allocation failed

dxvkclosed d3d932-bit
doitsujin/dxvk#1894 · opened 2021-01-13 by chumik6000 · updated 2021-01-14 · 6 comments · github
Cchumik6000 2021-01-13 github

When i try to use DXVK memory patch it says DxvkMemoryAllocator: Memory allocation failed.
TESV_d3d9.log

Here my dxvk.conf settings:

Create the VkSurface on the first call to IDXGISwapChain::Present,

rather than when creating the swap chain. Some games that start

rendering with a different graphics API may require this option,

or otherwise the window may stay black.

Supported values: True, False

dxgi.deferSurfaceCreation = False

d3d9.deferSurfaceCreation = False

Enforce a stricter maximum frame latency. Overrides the application

setting specified by calling IDXGIDevice::SetMaximumFrameLatency.

Setting this to 0 will have no effect.

Supported values : 0 - 16

dxgi.maxFrameLatency = 0

d3d9.maxFrameLatency = 0

Override PCI vendor and device IDs reported to the application. Can

cause the app to adjust behaviour depending on the selected values.

Supported values: Any four-digit hex number.

dxgi.customDeviceId = 0000

dxgi.customVendorId = 0000

d3d9.customDeviceId = 0000

d3d9.customVendorId = 1002

Report Nvidia GPUs as AMD GPUs by default. This is enabled by default

to work around issues with NVAPI, but may cause issues in some games.

Supported values: True, False

dxgi.nvapiHack = False

Override maximum amount of device memory and shared system memory

reported to the application. This may fix texture streaming issues

in games that do not support cards with large amounts of VRAM.

Supported values: Any number in Megabytes.

dxgi.maxDeviceMemory = 16318
dxgi.maxSharedMemory = 16318

Overrides synchronization interval (Vsync) for presentation.

Setting this to 0 disables vertical synchronization entirely.

A positive value 'n' will enable Vsync and repeat the same

image n times, and a negative value will have no effect.

Supported values: Any non-negative number

dxgi.syncInterval = -1
d3d9.presentInterval = -1

True enables the mailbox present mode in case regular Vsync is disabled.

This should avoid tearing, but may be unsupported on some systems

or require setting dxgi.numBackBuffers to a higher value in order

to work properly.

False enables the relaxed fifo present mode in case regular Vsync is enabled.

This should result in tearing but reduce stutter if FPS are too low,

but may be unsupported on some systems.

Please do not report issues with this option.

Supported values: Auto, True, False

dxgi.tearFree = True
d3d9.tearFree = True

Declares vertex positions as invariant in order to solve

potential Z-fighting issues at a small performance cost.

Supported values: True, False

d3d11.invariantPosition = False

d3d9.invariantPosition = true

Sets number of pipeline compiler threads.

Supported values:

- 0 to automatically determine the number of threads to use

- any positive number to enforce the thread count

dxvk.numCompilerThreads = 16

Toggles raw SSBO usage.

Uses storage buffers to implement raw and structured buffer

views. Enabled by default on hardware which has a storage

buffer offset alignment requirement of 4 Bytes (e.g. AMD).

Enabling this may improve performance, but is not safe on

hardware with higher alignment requirements.

Supported values:

- Auto: Don't change the default

- True, False: Always enable / disable

dxvk.useRawSsbo = True

Toggles early discard.

Uses subgroup operations to determine whether it is safe to

discard fragments before the end of a fragment shader. This

is enabled by default on all drivers except RADV and Nvidia.

Enabling this may improve or degrade performance depending

on the game and hardware, or cause other issues.

Supported values:

- Auto: Don't change the default

- True, False: Always enable / disable

dxvk.useEarlyDiscard = True

Sets enabled HUD elements

Behaves like the DXVK_HUD environment variable if the

environment variable is not set, otherwise it will be

ignored. The syntax is identical.

dxvk.hud = 1

Reported shader model

The shader model to state that we support in the device

capabilities that the applicatation queries.

Supported values:

- 1: Shader Model 1

- 2: Shader Model 2

- 3: Shader Model 3

d3d9.shaderModel = 3

Evict Managed on Unlock

Decides whether we should evict managed resources from

system memory when they are unlocked entirely.

Supported values:

- True, False: Always enable / disable

d3d9.evictManagedOnUnlock = True

DPI Awareness

Decides whether we should call SetProcessDPIAware on device

creation. Helps avoid upscaling blur in modern Windows on

Hi-DPI screens/devices.

Supported values:

- True, False: Always enable / disable

d3d9.dpiAware = True

Strict Constant Copies

Decides whether we should always copy defined constants to

the UBO when relative addressing is used, or only when the

relative addressing starts a defined constant.

Supported values:

- True, False: Always enable / disable

d3d9.strictConstantCopies = False

Strict Pow

Decides whether we have an opSelect for handling pow(0,0) = 0

otherwise it becomes undefined.

Supported values:

- True, False: Always enable / disable

d3d9.strictPow = True

Lenient Clear

Decides whether or not we fastpath clear anyway if we are close enough to

clearing a full render target.

Supported values:

- True, False: Always enable / disable

d3d9.lenientClear = False

Max available memory

Changes the max initial value used in tracking and GetAvailableTextureMem

Value in Megabytes

Supported values:

- Any int32_t

d3d9.maxAvailableMemory = 32768
My video: RX 6900xt (latest driver), total ram 32 gb 5800x Ryzen.
Pls some help me to fix this problem. TY!

KK0bin maintainer 2021-01-13 github

Another case of: #1318

Unfortunately there is nothing we can do.

Side note: Please pay attention to formatting when you make issues on GitHub and put the config on something like Pastebin instead of just dumping it here. It's not readable and the logs tell us which config option you've set anyway.

KK0bin maintainer 2021-01-13 github

You could try to patch the Skyrim EXE and set the large address aware flag:
https://www.techpowerup.com/forums/threads/large-address-aware.112556/

No idea if this works with Skyrim but it's something you could try.

I just saw your other issue, maybe keep ReduceSystemMemoryUsage enabled after all.

Cchumik6000 2021-01-14 github

You could try to patch the Skyrim EXE and set the large address aware flag:
https://www.techpowerup.com/forums/threads/large-address-aware.112556/

No idea if this works with Skyrim but it's something you could try.

I just saw your other issue, maybe keep ReduceSystemMemoryUsage enabled after all.

Well the main problem is when ReduceSystemMemoryUsage set to true, my skyrim have terrible stutters. With your patch it has no stutter, but game run out of memory. Also i found that if i delete my textures folder, i can load my save, so as i understand dxvk patch have problem with vram memory allocation,

KK0bin maintainer 2021-01-14 github

Did you apply the LAA patch?

If that didn't help, there's nothing we can do. Just play without DXVK then.

Cchumik6000 2021-01-14 github

Did you apply the LAA patch?

If that didn't help, there's nothing we can do. Just play without DXVK then.

Yes it didnt help. But when i use dxvk mem patch in stalker COP it works good. Why not on Skyrim LE?

KK0bin maintainer 2021-01-14 github

Because different games do different things and manage memory differently. Apparently this is mostly caused by the ENB mod.

Launch options