HN user

bsorbo

30 karma
Posts1
Comments8
View on HN

While the readme does state this (could be) a joke, this unfortunately isn't possible with PCI-e today:

Motherboards only support directly accessing a (up to) 256 MB segment of VRAM directly from the CPU. This is the BAR1 space/aperture space.

So attempts to create allocations larger than that that are resident in VRAM but also accessible from the CPU will land in system memory, in order to ensure they are accessible from the CPU. Graphics drivers will either have the GPU read the data from system memory, or will do hidden copies to the GPU when they detect the resource is bound, etc.

The author sort of suspects this could be happening:

"There is no guarantee that the persistently mapped buffer technique actually references video memory. The worst case it's shadow memory and this actually wastes memory."

This seems really promising, can't say I would miss all of the ^ (hat) usage for Modern Windows APIs.

I wonder how he intends to wrap/change the DirectX APIs. AFAIK Direct2D, WIC, DirectComposition are already native COM-based APIs, much like Direct3D.