Re: [v8-dev] Re: Stack limits and AST visitors

2015-10-13 Thread Jochen Eisinger
The 'main thread' for a isolate is supposed to be interruptable, e.g., via Isolate::RequestInterrupt or Isolate::TerminateExecution. I can't answer your question about how the parser / ast visitors is supposed to behave here :-/ On Mon, Oct 12, 2015 at 9:37 PM Adam Klein

Re: [v8-dev] Re: Stack limits and AST visitors

2015-10-13 Thread Jakob Kummerow
Maybe I'm missing something, but AFAIK we have two very different kinds of stack checks: (1) generated code contains stack checks at function entry and loop back edge. These are for interruptibility of long-running code sequences. (2) AST visitors do stack checks at recursive calls to check for

[v8-dev] Re: Stack limits and AST visitors

2015-10-12 Thread Adam Klein
Any thoughts here? Caitlin is currently running into exactly the same need in her do expression patch, so it'd be good to understand if we can do something general here instead of having most AST visitors be Isolate-bound while the few used from the parser need special duplicated code for stack

Re: [v8-dev] Re: Stack limits and AST visitors

2015-10-12 Thread Jochen Eisinger
We use the stack limit to request interrupts from different threads, so checking it on a regular basis is important On Mon, Oct 12, 2015, 9:30 PM Adam Klein wrote: > Any thoughts here? Caitlin is currently running into exactly the same need > in her do expression patch, so

Re: [v8-dev] Re: Stack limits and AST visitors

2015-10-12 Thread Adam Klein
Which sorts of threads are expected to be interruptable? Clearly the parser isn't (currently) interruptable in this way, since it takes in a stack limit at construction time and never re-sets it. I guess the question is: is interruptability something that _all_ AstVisitors should have, with a few