Print which shader kernel does not compile to log?

When using several shaders at the same time and one of them does not compile the log output does not say which of the kernel shaders does not compiles.

Maybe there is a way to show which of the kernel does not compile in the error log?

I’ll add this as an enhancement idea, but probably not something we’ll get to anytime soon.

A simple workaround is to just define one shader at a time to isolate your compile error. In general, it’s a good practice to develop your custom effects separately.

I agree, to develop them separately. In my case I developed them separately but did not test them on real device. In simulator the shaders compiled fine but for real device I had to tweak the code further. When I tested on the device the first time one of the shader throw an error but the error message did not say to which kernel the error belongs to.

So I recommend to develop and test on real device each kernel separately.

Best would be if the simulator would give the same errors as the device. In this case I haven’t used a precision qualifier for a variable. The simulator compiled this, but the device gave an error.

Yea, it’d be ideal if the simulator could give the same error as device, but we’re already doing a lot of heavy lifting to bridge GLSL and GLSL-ES. 

GLSL is for desktops. And it’s not quite the same as GLSDL-ES (devices). So we’re already performing several magic tricks to let you write shader code that works on Mac/Win and also iOS/Android. One of the byproducts is that precision qualifier errors aren’t really enforced on the desktop flavor of GLSL – that’s one magic trick we weren’t able to pull off easily (not without a really significant amount of effort).

Yes I see. You have to find the right balance of effort. Thank you.

I’ll add this as an enhancement idea, but probably not something we’ll get to anytime soon.

A simple workaround is to just define one shader at a time to isolate your compile error. In general, it’s a good practice to develop your custom effects separately.

I agree, to develop them separately. In my case I developed them separately but did not test them on real device. In simulator the shaders compiled fine but for real device I had to tweak the code further. When I tested on the device the first time one of the shader throw an error but the error message did not say to which kernel the error belongs to.

So I recommend to develop and test on real device each kernel separately.

Best would be if the simulator would give the same errors as the device. In this case I haven’t used a precision qualifier for a variable. The simulator compiled this, but the device gave an error.

Yea, it’d be ideal if the simulator could give the same error as device, but we’re already doing a lot of heavy lifting to bridge GLSL and GLSL-ES. 

GLSL is for desktops. And it’s not quite the same as GLSDL-ES (devices). So we’re already performing several magic tricks to let you write shader code that works on Mac/Win and also iOS/Android. One of the byproducts is that precision qualifier errors aren’t really enforced on the desktop flavor of GLSL – that’s one magic trick we weren’t able to pull off easily (not without a really significant amount of effort).

Yes I see. You have to find the right balance of effort. Thank you.