rtcCommit...WithQueue(3)

πŸ“¦ version 4.4.1, in ubuntu stonking

πŸ’… rtcCommitBufferWithQueue β€” the Embree glow-up for your buffers

okay bestie, so this page lives in the Embree Ray Tracing Kernels 4 manual, section 3, and its whole name on the shelf is rtcCommit...WithQueue(3). It's the one you want when your buffer content needs to travel from host to device and it needs a SYCL queue to do the driving. ✨


🌸 NAME 🌸

rtcCommitBufferWithQueue β€” commits buffer content from host to device using a given SYCL queue

no cap, that's literally the entire job description 🫢


πŸŽ€ SYNOPSIS πŸŽ€

#include <embree4/rtcore.h>

void rtcCommitBufferWithQueue(RTCBuffer buffer,
    sycl::queue queue, sycl::event* event);

✨ DESCRIPTION ✨

so here's the tea β˜• If your buffer was created using rtcNewBufferHostDevice, then the rtcCommitBufferWithQueue function is the main character that actually commits changes of the host buffer data to the device. It's giving "sync me up, bestie." πŸ’–

But β€” and this is important β€” if the buffer was created with a non SYCL Embree device, or the SYCL device has host unified memory, then this call has no effect. Like, zero. Nada. It just vibes there. 🌈

The call to rtcCommitBufferWithQueue will use the given SYCL queue to copy the memory asynchronously. If the SYCL event argument event is a valid pointer, Embree will use this pointer to return a copy of the SYCL event associated to the memory copy. And the parameter event? It's optional, babes β€” it will be ignored if it's a null pointer. πŸ¦‹

the user is responsible for synchronization using the SYCL queue or the optional SYCL event. that's on you, not on Embree. don't forget it 😭

Also, this function is only available on Embree versions with enabled SYCL support. If your build doesn't have SYCL turned on, this function simply doesn't exist for you. πŸ’€


🫢 EXIT STATUS 🫢

On failure an error code is set that can be queried using rtcGetDeviceError. So if something goes sideways, that's where you go looking, bestie. πŸ”


πŸ‘‘ SEE ALSO πŸ‘‘

  • rtcCommitBuffer
  • rtcNewBufferHostDevice

that's the whole page, finished, ate, no crumbs πŸ’…

signing off from the Embree Ray Tracing Kernels 4 corner of the manual β€” this was rtcCommit...WithQueue(3), a true icon. πŸŽ€βœ¨πŸ’œ

πŸ“¦ where this page comes from