-
Don't dynamically recurse when analyzing functions · 1fb04accLingfeng Yang authored
bug: 38257724 With this CL, dEQP-GLES3.functional.shaders.functions.invalid no longer results in a stack overflow and system crash. The fix is to explicitly loop over switch cases in the function call depth analysis. Later on, we probably want to change TIntermSwitch traversal to loop over all cases of the switch statement as well, but that requires a lot of changes; all traversers need to be changed to not have to loop over switch statements themselves, which will break expectations and perhaps functionality that critically depends on seeing/controlling iteration over switch statement cases. Not tested for regressions in dEQP-GLES2.functional.shaders.* Test: dEQP-GLES3.functional.shaders.functions.invalid.dynamic_switch_recursion_vertex: system crash, hang, or fail -> Pass Change-Id: I5d13a5f3296579c8818975e103f5ed6e03a47b68 Reviewed-on: https://swiftshader-review.googlesource.com/9789Reviewed-by:
Lingfeng Yang <lfy@google.com> Reviewed-by:
Nicolas Capens <capn@google.com> Tested-by:
Lingfeng Yang <lfy@google.com>
1fb04acc
×