im wondering if there is a specified behavior for branches in shader code if the condition is not really dynamic.
While searching the forum i found some hints that dynamic branching is not possible if some functions like Sample(...) are used. What if the condition is a value defined in the constant buffer? In this case all threads are following the same path and evaluating both paths is theoretically not requiered. Is this depending on the compiler and driver or are there any specified and documented rules?
with shader i mean sharder in general rendering pipeline and compute shader or cuda.