Debugging using printf statements in SYCL code

According the docs:

https://developer.blender.org/docs/handbook/new_developers/tips/

You could use printf statements yo debug your code. But in parts of the sources (cycles rendering) SYCL doesn’t work with printf statements. Does anybody have a good idea to work around this?

Thanx,

Michiel

Hi,
not sure you saw Brechts reply on the chat the other day:

We don’t have a printf mechanism for SYCL kernels. It seems sycl::stream exists for this purpose, but you’d have to figure out how to get it working.

1 Like

Thanx Thomas,

I was hoping someone could help me with a nice trick or something. I have no knowledge about SYCL and was hoping you could disable SYCL easily or set number of threads to one or…

Gr

Michiel

You can of course render on the CPU but if you want to render and debug on Intel GPUs, there is no way around SYCL.

I’m thinking; can blender be build without SYCL? Maybe some CMAKE/debug switch?

Disable WITH_CYCLES_DEVICE_ONEAPI to disable it

1 Like