Commit 0db0c4fb authored by Jason Ekstrand's avatar Jason Ekstrand Committed by Jason Ekstrand

WIP! anv: Implement CPU-side BVH building with embree

This commit also adds an environment variable to force a CPU-side build
in vkCmdBuildAccelerationStructuresKHR.  This is useful for getting more
tests working because most tests assume GPU-side builds.  Also, when
running in simulation, a CPU-side build with Embree is likely to be much
faster than a GPU-side build with simulated compute shaders.  This, of
course, assumes that the data is already in the memory at the time that
vkCmdBuildAccelerationStructureKHR is called.  However, this is likely
true for most CTS tests and we can get more stuff running this way.

TODO: Take advantage of deferred operations
parent 8e84bb57
Pipeline #233075 waiting for manual action with stages
in 1 minute and 1 second
......@@ -1104,7 +1104,8 @@ void anv_GetPhysicalDeviceFeatures2(
features->accelerationStructure = false;
features->accelerationStructureCaptureReplay = false;
features->accelerationStructureIndirectBuild = false;
features->accelerationStructureHostCommands = false;
features->accelerationStructureHostCommands =
pdevice->info.has_ray_tracing && sizeof(void *) >= 8;
features->descriptorBindingAccelerationStructureUpdateAfterBind = true;
break;
}
......
......@@ -18,6 +18,8 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
dep_embree = dependency('embree', cmake_package_version :'3.0')
anv_extensions_py = files('anv_extensions.py')
anv_entrypoints = custom_target(
......@@ -130,6 +132,7 @@ libanv_files = files(
)
anv_deps = [
dep_embree,
dep_libdrm,
dep_valgrind,
idep_genxml,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment