How do I increase the shared GPU memory allocation multiplicator?

Shared GPU memory is computed by CPU memory ÷ 2

And I want it to be equal to CPU memory.

I need it for my pinned memory with cudaMallocHost.

seems like you misunderstand the term shared memory. Maybe this is the one you need:

No, try it yourself, remove a RAM stick and see your shared GPU memory decrease, add RAM stick with higher GB and you will see your shared GPU memory increase.

But it’s always half of the capacity of your RAM and I want to be it 1:1 ratio

You will find the amount of Shared GPU memory in the Task Manager.

As you see, I have 8.0 GB of Shared GPU memory and I have 16 GB of RAM


If you do 16 ÷ 2, you get 8.0 GB and that’s why I have as Shared GPU memory.

And cudaMallocHost actually allocate on this memory:

int* Data;
cudaMallocHost(&Data, 1000 * 1000 * 1000 * sizeof(int));

It gives

I have a vague recollection that this 50% limit is baked into Windows, at least with the WDDM driver model where the operating system is in charge of GPU memory allocation.

Note that when we speak about “shared memory” in the context of CUDA programming, we usually mean something entirely different than the Windows terminology you are referring to here.

1 Like