RADV Vulkan Driver Patch For Initial PRIME Support

Written by Michael Larabel in Vulkan on 23 November 2016 at 09:36 AM EST. 5 Comments
VULKAN
David Airlie's latest hacking on the RADV open-source Radeon Vulkan driver code has led to basic PRIME support for this unofficial driver.

RADV users on a multi-GPU system can now have working rendering when the DRI_PRIME=1 environment variable is set. Dave explained with the patch:
This is kind of a gross hacks, but vulkan doesn't specify anything but it would be nice to let people with prime systems at least see some stuff rendering for now.

This creates a linear shadow image in GART that gets blitted to at the image transition.

Now ideally: this would use SDMA - but we want to use SDMA for transfer queues maybe we don't expose a transfer queue on prime cards who knows.

we wouldn't have to add two pointers to every image, but my other attempts at this were ugly.

Is the image transition the proper place to hack this in? not really sure anywhere else is appropriate.

It also relies on DRI_PRIME=1 being set, I should be able to work this out somehow automatically I think, probably getting a DRI3 fd from the X server and doing drmGetDevice on it, and comparing where we end up.
It's not yet in Mesa Git, but presumably will be there soon enough given the recent pace of RADV development.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week