Open GoogleCodeExporter opened 9 years ago
Infinite loop detection isn't actually part of the ESSL spec. In fact, even
enforcement of properly formed for loop conditions (e.g., rejection of
"for(;;)") is optional in ES 2.0 (and ANGLE does support these optional
restrictions). For WebGL, responsibility for protecting the system against
infinite loops falls to the browser/WebGL implementation level; Chrome and
Firefox handle this by using a watchdog to monitor the GPU process/thread for
calls that don't return after a certain time, and then forcibly kill the
process.
Are you running into this with a browser, or do you have a different sort of
build?
Original comment by shannonw...@chromium.org
on 20 Feb 2015 at 5:50
Ah-- is this a WebKit issue?
Original comment by shannonw...@chromium.org
on 20 Feb 2015 at 5:51
[deleted comment]
As Shannon said, it's not an ANGLE job to detect if programs complete. Even as
a browser-level project, if you wanted use ANGLE to detect infinite or very
slow programs, it's tough without actually running the program.
You might be able to do something if you limit loops in certain ways, but
iteration count can depend on uniforms, attributes, or texture lookups. It's
certainly not impossible, but it's a large, challenging piece of work, that's
already solved by the watchdog process Shannon mentioned.
Original comment by jmad...@chromium.org
on 20 Feb 2015 at 6:10
Original issue reported on code.google.com by
roger.d....@gmail.com
on 19 Feb 2015 at 6:25