Jump to content
Site Stability Read more... ×
  • Advertisement
Sign in to follow this  
Aqua Costa

DirectX pointer and cache

This topic is 2928 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

When a DirectX device/buffer/etc is created the functions return pointers that should be used to access those objects. So since the programmer has no control over where D3D objects are allocated when I call the functions that create those objects, when a function like:
pDeviceContext->IASetIndexBuffer(m_pIndexBuffer, DXGI_FORMAT_R32_UINT, m_IndexBufferOffset);
is called what happens in the cache?
Are the objects pointed by pDeviceContext and m_pIndexBuffer fetched from memory to the cache

If so, since my game-specific-classes objects are all stored using a custom stack allocator and the D3D objects are most likely in a different region of memory will there be a lot of cache misses?

Some game object is loaded into cache to get a pointer to a D3D buffer.
Then cache as to be updated because the device context and the buffer are in a different region of memory

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!