Demon's Souls copies its per-frame constant and descriptor tables with a compute kernel (dst[i] = src[i % N] for i < count). Run on the GPU, the destinations stay GPU-dirty, and every draw whose resource tables read them waits for a readback: about 19% of the render thread in the title scene, for values that never changed. The kernel is now recognized by its instruction sequence. When both descriptors are plain 32-bit words of the same format and neither range is GPU-dirty or GPU image memory, the copy is written to guest memory through the host DMA path and the dispatch is skipped; anything else still runs on the GPU. SHARPEMU_HOST_BOUNDED_COPY=0 turns it off. Title scene with profiling: 7.4-8.6 -> 11.8-15.9 fps. |
||
|---|---|---|
| .. | ||
| SharpEmu.Libs.Tests | ||
| SharpEmu.ShaderCompiler.Metal.Tests | ||
| SharpEmu.ShaderCompiler.Tests | ||
| SharpEmu.SourceGenerators.Tests | ||