Oh interesting, thanks for looking into this guys. As far as I understand it though, this is still not duplicating the mapping, but setting up a fault handler at the original address to manage access. I don't think we'd want this since when wine remaps the page/s hosting a given buffer it also forces all other resources mapped to the same page/s to go through this presumably slow fault handler. Am I missing something?
Am 10/24/24 um 18:40 schrieb tblodt@icloud.com:
Wait, apparently this was fully merged in kernel 5.13? The man page is simply out of date. https://github.com/torvalds/linux/commit/a4609387859f0281951f5e476d9f76d7fb9...
~Theodore
On Oct 24, 2024, at 9:37 AM, tblodt@icloud.com wrote:
On Oct 24, 2024, at 1:04 AM, Derek Lesho dlesho@codeweavers.com wrote:
In my last mail I responded to this approach all the way at the bottom, so it probably got lost: mremap on Linux as it exists now won't work as it only supports private anonymous mappings (in conjunction with MREMAP_DONTUNMAP), which GPU mappings are not.
This is seemingly not insurmountable: https://lore.kernel.org/linux-mm/20210303175235.3308220-1-bgeffon@google.com...
~Theodore