Go to file
palfia@homejinni.com 54483c4880 MIPS: Generators: Avoid calling into runtime if operand stack is empty
Port r15240 (909f716e)

Original commit message:
This patch makes yield sites save the resume continuation and context
inline.  If the operand stack is empty, we can avoid a call into the
runtime.  This also makes the SuspendJSGeneratorObject runtime function
less magical: it just has to save the operand stack and stack handlers.

This speeds up the following case by a factor of 3 or so:

  function* until(n) {
    for (var i = 0; i < n; i++)
      yield i;
  }

  function sum(iter) {
    var sum = 0;
    for (var x of iter) sum += x;
    return sum;
  }

  for (var i = 0; i < 10000; i++) sum(until(1000))

Also, there is no more sentinel value as the generators will resume in
the right place already, allowing me to remove the hack added to the
--debug-code check in r14437.

BUG=

Review URL: https://codereview.chromium.org/17291016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15258 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-06-20 23:43:10 +00:00
benchmarks More fixes for V8 benchmark version 7. 2012-03-15 17:13:50 +00:00
build Use -O2 instead -O3 for Android build. 2013-06-12 08:05:43 +00:00
include deprecate old style callbacks 2013-06-20 12:53:19 +00:00
preparser Remove SCons related files 2013-04-18 11:01:14 +00:00
samples Cutover v8 to use new style callbacks internally 2013-06-05 12:36:33 +00:00
src MIPS: Generators: Avoid calling into runtime if operand stack is empty 2013-06-20 23:43:10 +00:00
test Make sure ExternalCallbackScope is always created when VM state changes to EXTERNAL 2013-06-20 14:47:35 +00:00
tools Make sure GCMole pukes when Clang invocation fails. 2013-06-17 18:00:23 +00:00
.gitignore Refactor HCheckMaps to have a private constructor, removing duplicated code and simplifying calls in clients. 2013-04-19 16:46:13 +00:00
AUTHORS Add methods to allow resuming execution after calling TerminateExecution(). 2013-04-22 15:01:45 +00:00
ChangeLog Prepare push to trunk. Now working on 3.19.19. 2013-06-18 11:42:34 +00:00
DEPS Pull more recent gyp. 2012-09-26 09:12:45 +00:00
LICENSE Update LICENSE file 2012-01-03 16:38:42 +00:00
LICENSE.strongtalk Add LICENSE.v8, LICENSE.strongtalk and LICENSE.valgrind to the v8 2011-02-03 07:10:06 +00:00
LICENSE.v8 Add LICENSE.v8, LICENSE.strongtalk and LICENSE.valgrind to the v8 2011-02-03 07:10:06 +00:00
LICENSE.valgrind Add LICENSE.v8, LICENSE.strongtalk and LICENSE.valgrind to the v8 2011-02-03 07:10:06 +00:00
Makefile Enable Native Client build of V8. 2013-04-17 08:27:40 +00:00
Makefile.android MIPS: Add android build support for mips in gyp. 2013-02-25 16:39:03 +00:00
Makefile.nacl Allow a relativ path to the NaCl SDK when building. 2013-05-28 15:33:39 +00:00
OWNERS Added Hannes and Dmitry to OWNERS 2013-03-21 12:09:53 +00:00
PRESUBMIT.py Run style checks also when uploading. 2013-04-11 12:41:31 +00:00