Using Tensor cores and RT cores


This was originally posted in Vulkan forums. I was advised to reach out here in case of no responses.

I would like to do ray tracing along with efficient matrix multiplication in Vulkan.

This is not supported in Optix by design.

The closest hit shader pseudo code for this use-case would look something like this

int main() {
  // .....

  // trace shadow rays
  traceRay(); // leverage RT cores for this


  // compute BSDF if surface is not occuled
  peformMatrixMultiplication(); // leverage Tensor cores for this  

I am mostly interested in this megakernel approach although there might be other ways to do this like the wavefront approach.

I am very new to Vulkan and wanted to know if something like this is even possible? Considering the learning curve, I thought it would be better to get a high level idea before jumping into learning Vulkan and implementing it. Please let me know if you need more details.