The ray_origin, ray_dir and ray_inv_dir arguments should all be vec3 to
match how the hardware instruction works.
Don't change the API of the corresponding OpenCL builtins.
Paths 
  |  Differential  D115032  
[AMDGPU] Change llvm.amdgcn.image.bvh.intersect.ray to take vec3 args ClosedPublic Authored by foad on Dec 3 2021, 1:57 AM. 
Details Summary The ray_origin, ray_dir and ray_inv_dir arguments should all be vec3 to Don't change the API of the corresponding OpenCL builtins. 
Diff Detail 
 Event TimelineHerald added subscribers: kerbowa, hiraditya, t-tye and 6 others.  ·  View Herald TranscriptDec 3 2021, 1:57 AM Herald added projects: Restricted Project, Restricted Project.  ·  View Herald TranscriptDec 3 2021, 1:57 AM Comment Actions This is an alternative to D114957 that does not update the API of the OpenCL builtins. This revision is now accepted and ready to land.Dec 3 2021, 9:51 AM Comment Actions Ideally, we could let the builtins accept both vec3 and vec4. But I am OK with this for now. I think the overhead may be minimal. This revision was landed with ongoing or failed builds.Dec 4 2021, 3:00 AM Closed by commit rG2774bad11242: [AMDGPU] Change llvm.amdgcn.image.bvh.intersect.ray to take vec3 args (authored by foad).  ·  Explain Why This revision was automatically updated to reflect the committed changes. 
Revision Contents 
 
Diff 391821 clang/lib/CodeGen/CGBuiltin.cpp
 
 clang/test/CodeGenOpenCL/builtins-amdgcn-raytracing.cl
 llvm/include/llvm/IR/IntrinsicsAMDGPU.td
 llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
 llvm/lib/Target/AMDGPU/SIISelLowering.cpp
 
 llvm/test/CodeGen/AMDGPU/GlobalISel/llvm.amdgcn.intersect_ray.ll
 llvm/test/CodeGen/AMDGPU/llvm.amdgcn.intersect_ray.ll
  | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||