intel/fs: add a note on possible optimization of root node address

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15910>
This commit is contained in:
Lionel Landwerlin 2022-04-13 09:39:31 +03:00 committed by Marge Bot
parent 9c0805ef91
commit e11bedb9f5
1 changed files with 3 additions and 0 deletions

View File

@ -919,6 +919,9 @@ brw_nir_rt_acceleration_structure_to_root_node(nir_builder *b,
*
* But if the acceleration structure pointer is NULL, then we should return
* NULL as root node pointer.
*
* TODO: we could optimize this by assuming that for a given version of the
* BVH, we can find the root node at a given offset.
*/
nir_ssa_def *root_node_ptr, *null_node_ptr;
nir_push_if(b, nir_ieq(b, as_addr, nir_imm_int64(b, 0)));