@el_burro_muerto Outside of a shader I would just turn off optimization at the first sign of strangeness.
but shaders are difficult.
Shit still needs to be tracked down though, but disabling optimization is an easy test to help find the problem.