1. 03 Feb, 2019 1 commit
  2. 30 Jan, 2019 1 commit
  3. 25 Jan, 2019 1 commit
  4. 23 Jan, 2019 1 commit
  5. 14 Jan, 2019 1 commit
  6. 11 Jan, 2019 2 commits
  7. 09 Jan, 2019 1 commit
    • Leszek Swirski's avatar
      [parser] Don't desugar destructuring declarations. · 5e725a2b
      Leszek Swirski authored
      Emit a single destructuring assignment for destructuring declarations,
      which can be desugared by the bytecode generator. This allows us to
      remove destructuring desugaring from the parser (specifically, the
      pattern rewriter) entirely.
      
      The pattern "rewriter" is now only responsible for walking the
      destructuring pattern to declare variables, mark them assigned, and
      potentially rewrite scopes for the edge case of parameters with a sloppy
      eval.
      
      Note that since the rewriter is no longer rewriting, we have to flip the
      VariableProxy copying logic for var re-lookup, so that we now pass the
      new VariableProxy to the variable declaration and leave the original
      unresolved (rather than passing the original through and rewriting to a
      new unresolved VariableProxy).
      
      This change does have some effect on breakpoint locations, due to some
      of the available information changing between the parser and bytecode
      generator, however the new locations appear to be more consistent
      between assignments and declarations.
      
      Change-Id: I3a58dd0a387d2bfb8e5e9e22dde0acc5f440cb82
      Reviewed-on: https://chromium-review.googlesource.com/c/1382462
      Commit-Queue: Leszek Swirski <leszeks@chromium.org>
      Reviewed-by: 's avatarAdam Klein <adamk@chromium.org>
      Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
      Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
      Reviewed-by: 's avatarToon Verwaest <verwaest@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#58670}
      5e725a2b
  8. 08 Jan, 2019 1 commit
  9. 24 Dec, 2018 1 commit
  10. 21 Dec, 2018 1 commit
  11. 20 Dec, 2018 1 commit
  12. 13 Dec, 2018 1 commit
    • Sigurd Schneider's avatar
      Reland "Reland "Reland "[code-comments] Put code comments into the code object""" · b55dd17f
      Sigurd Schneider authored
      This is a reland of 9c0a4858
      
      Original change's description:
      > Reland "Reland "[code-comments] Put code comments into the code object""
      >
      > This is a reland of ed3d6472
      >
      > This reland fixes that padding at the end of Wasm instruction streams
      > triggered asserts in the code printer.
      >
      > Original change's description:
      > > Reland "[code-comments] Put code comments into the code object"
      > >
      > > This is a reland of e774cffe
      > >
      > > This reland disables a test as v8:8548 is blocking it, which was
      > > broken by a recent CL. CQ did not catch this because the merge-base
      > > CQ used did not yet contain the CL that caused v8:8548.
      > >
      > > Original change's description:
      > > > [code-comments] Put code comments into the code object
      > > >
      > > > Code comments in the snapshot can now be enabled with gn
      > > > arg 'v8_enable_snapshot_code_comments'
      > > >
      > > > Bug: v8:7989
      > > > Change-Id: I8bd00cafa63132d00d849394c311ba15e6b6daf3
      > > > Reviewed-on: https://chromium-review.googlesource.com/c/1329173
      > > > Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
      > > > Reviewed-by: Jakob Gruber <jgruber@chromium.org>
      > > > Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
      > > > Reviewed-by: Michael Stanton <mvstanton@chromium.org>
      > > > Cr-Commit-Position: refs/heads/master@{#58020}
      > >
      > > TBR=mvstanton@chromium.org,mstarzinger@chromium.org,jgruber@chromium.org,tebbi@chromium.org
      > >
      > > Bug: v8:7989, v8:8548
      > > Change-Id: I464fc897205fefdf2dfc2eadc54d699c4e08a0e9
      > > Reviewed-on: https://chromium-review.googlesource.com/c/1361166
      > > Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
      > > Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
      > > Cr-Commit-Position: refs/heads/master@{#58028}
      >
      > Bug: v8:7989, v8:8548
      > Change-Id: I254f55ff687ad049f8d92b09331ed26a2bd05d7d
      > Reviewed-on: https://chromium-review.googlesource.com/c/1371784
      > Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
      > Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
      > Reviewed-by: Jakob Gruber <jgruber@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#58221}
      
      TBR=jgruber@chromium.org,mstarzinger@chromium.org
      
      Bug: v8:7989, v8:8548, v8:8593
      Change-Id: I4f7ffc98e0281c7b744eb4a04ba0763896c7b59b
      Reviewed-on: https://chromium-review.googlesource.com/c/1375919Reviewed-by: 's avatarSigurd Schneider <sigurds@chromium.org>
      Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#58232}
      b55dd17f
  13. 06 Dec, 2018 1 commit
    • Dmitry Gozman's avatar
      Revert "inspector: return [[StableObjectId]] as internal property" · 4401ac44
      Dmitry Gozman authored
      This reverts commit d9fbfeb8.
      
      Reason for revert: see bug.
      Bug: 906847
      
      Original change's description:
      > inspector: return [[StableObjectId]] as internal property
      > 
      > This property might be useful for fast '===' check.
      > 
      > R=​dgozman@chromium.org,yangguo@chromium.org
      > 
      > Bug: none
      > Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      > Change-Id: Iabc3555ce1ec2c14cf0ccd40b7d964ae144e7352
      > Reviewed-on: https://chromium-review.googlesource.com/1226411
      > Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
      > Reviewed-by: Yang Guo <yangguo@chromium.org>
      > Reviewed-by: Jakob Gruber <jgruber@chromium.org>
      > Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#56095}
      
      TBR=dgozman@chromium.org,yangguo@chromium.org,kozyatinskiy@chromium.org,jgruber@chromium.org
      
      # Not skipping CQ checks because original CL landed > 1 day ago.
      
      Bug: none
      Change-Id: I68c700b7b8fd0a015f099460c15665d74e4da183
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      Reviewed-on: https://chromium-review.googlesource.com/c/1363558Reviewed-by: 's avatarDmitry Gozman <dgozman@chromium.org>
      Reviewed-by: 's avatarAlexei Filippov <alph@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#58077}
      4401ac44
  14. 30 Nov, 2018 1 commit
    • Yang Guo's avatar
      Make termination exception more consistent. · 7e5cac2c
      Yang Guo authored
      Termination exceptions tear down V8 to the bottom-most V8 call. If there is a
      v8::TryCatch scope around that call, it returns true for HasTerminated() and
      HasCaught(). However, Isolate::IsExecutionTerminating() returns false and we
      can call into V8 from still inside the v8::TryCatch scope.
      
      Changes that this patch introduces:
       - You need to leave the v8::TryCatch scope around the bottom-most call to
         reset the termination state, in order to resume.
       - Explicitly check for termination exception and reporting it through the
         DevTools protocol after Runtime.evaluate and Debugger.evaluateOnCallFrame.
      
      Bug: v8:8455
      Change-Id: I1f36f7a365985469813c2619bf16f18ee69aa4b8
      Reviewed-on: https://chromium-review.googlesource.com/c/1337582Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
      Reviewed-by: 's avatarDmitry Gozman <dgozman@chromium.org>
      Commit-Queue: Yang Guo <yangguo@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57963}
      7e5cac2c
  15. 29 Nov, 2018 1 commit
  16. 06 Nov, 2018 2 commits
  17. 02 Nov, 2018 2 commits
    • Ross McIlroy's avatar
      Reland "Get BytecodeArray via current frame where possible." · 3530998c
      Ross McIlroy authored
      This is a reland of 7350e7b2
      
      Disabled LayoutTest that was causing issues and will rebaseline once this has rolled.
      
      Original change's description:
      > Get BytecodeArray via current frame where possible.
      >
      > With BytecodeArray flushing the SFI->BytecodeArray pointer will become pseudo weak.
      > Instead of getting the bytecode array from the SFI, get it from the frame instead
      > (which is a strong pointer). Note: This won't actually change behaviour since the
      > fact that the bytecode array was on the frame will retain it strongly, however it
      > makes the contract that the BytecodeArray must exist at these points more explicit.
      >
      > Updates code in runtime-profiler.cc, frames.cc and runtime-test.cc to do this.
      >
      > BUG=v8:8395
      >
      > Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      > Change-Id: Id7a3e6857abd0e89bf238e9b0b01de4461df54e1
      > Reviewed-on: https://chromium-review.googlesource.com/c/1310193
      > Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      > Reviewed-by: Mythri Alle <mythria@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#57198}
      
      TBR=mythria@chromium.org
      
      Bug: v8:8395
      Change-Id: I63044138f876a1cdfb8bb71499732a257f30d29a
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Reviewed-on: https://chromium-review.googlesource.com/c/1314336Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
      Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57219}
      3530998c
    • Maya Lekova's avatar
      Revert "Get BytecodeArray via current frame where possible." · ea27a244
      Maya Lekova authored
      This reverts commit 7350e7b2.
      
      Reason for revert: Braking layout test, blocking the roll, see
      https://bugs.chromium.org/p/v8/issues/detail?id=8405
      
      Original change's description:
      > Get BytecodeArray via current frame where possible.
      > 
      > With BytecodeArray flushing the SFI->BytecodeArray pointer will become pseudo weak.
      > Instead of getting the bytecode array from the SFI, get it from the frame instead
      > (which is a strong pointer). Note: This won't actually change behaviour since the
      > fact that the bytecode array was on the frame will retain it strongly, however it
      > makes the contract that the BytecodeArray must exist at these points more explicit.
      > 
      > Updates code in runtime-profiler.cc, frames.cc and runtime-test.cc to do this.
      > 
      > BUG=v8:8395
      > 
      > Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      > Change-Id: Id7a3e6857abd0e89bf238e9b0b01de4461df54e1
      > Reviewed-on: https://chromium-review.googlesource.com/c/1310193
      > Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      > Reviewed-by: Mythri Alle <mythria@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#57198}
      
      TBR=rmcilroy@chromium.org,mythria@chromium.org
      
      Change-Id: Ie5db0ec1d68ca01d62e9880a4476704ad4d013b5
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: v8:8395
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Reviewed-on: https://chromium-review.googlesource.com/c/1314330Reviewed-by: 's avatarMaya Lekova <mslekova@chromium.org>
      Commit-Queue: Maya Lekova <mslekova@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57205}
      ea27a244
  18. 01 Nov, 2018 1 commit
    • Ross McIlroy's avatar
      Get BytecodeArray via current frame where possible. · 7350e7b2
      Ross McIlroy authored
      With BytecodeArray flushing the SFI->BytecodeArray pointer will become pseudo weak.
      Instead of getting the bytecode array from the SFI, get it from the frame instead
      (which is a strong pointer). Note: This won't actually change behaviour since the
      fact that the bytecode array was on the frame will retain it strongly, however it
      makes the contract that the BytecodeArray must exist at these points more explicit.
      
      Updates code in runtime-profiler.cc, frames.cc and runtime-test.cc to do this.
      
      BUG=v8:8395
      
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Change-Id: Id7a3e6857abd0e89bf238e9b0b01de4461df54e1
      Reviewed-on: https://chromium-review.googlesource.com/c/1310193
      Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      Reviewed-by: 's avatarMythri Alle <mythria@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57198}
      7350e7b2
  19. 31 Oct, 2018 2 commits
    • Alexey Kozyatinskiy's avatar
      reland: inspector: move injected script source to native · ebd070ec
      Alexey Kozyatinskiy authored
      - introduced ValueMirror interface, this interface contains methods to generate
        different protocol entities,
      - introduced DebugPropertyIterator, this iterator iterates through object properties
        in the following order: exotic indices, enumerable strings, all other properties,
      - removed all injected script infra, e.g. closure compiler,
      
      R=dgozman@chromium.org
      TBR=yangguo@chromium.org
      
      Bug: chromium:595206
      Change-Id: I030fdb3a80074ca6edd4749f86b39b590776ae6f
      Reviewed-on: https://chromium-review.googlesource.com/c/1310056Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57181}
      ebd070ec
    • Aleksey Kozyatinskiy's avatar
      Revert "inspector: move injected script source to native" · fc5c8d7f
      Aleksey Kozyatinskiy authored
      This reverts commit 7e079c66.
      
      Reason for revert: native implementation should be ready for navigation.
      
      Original change's description:
      > inspector: move injected script source to native
      > 
      > - introduced ValueMirror interface, this interface contains methods to generate
      >   different protocol entities,
      > - introduced DebugPropertyIterator, this iterator iterates through object properties
      >   in the following order: exotic indices, enumerable strings, all other properties,
      > - removed all injected script infra, e.g. closure compiler,
      > 
      > R=​dgozman@chromium.org
      > TBR=yangguo@chromium.org
      > 
      > Bug: chromium:595206
      > Change-Id: Idcfc04489ee52e015ad1d1d191c3474cc65e63f2
      > Reviewed-on: https://chromium-review.googlesource.com/c/1308353
      > Reviewed-by: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      > Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#57150}
      
      TBR=dgozman@chromium.org,yangguo@chromium.org,kozyatinskiy@chromium.org
      
      Change-Id: I8c5c61f4cfe5a66cd33eadd02ab4acec539cc3bb
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: chromium:595206
      Reviewed-on: https://chromium-review.googlesource.com/c/1310055Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57176}
      fc5c8d7f
  20. 30 Oct, 2018 3 commits
    • Alexey Kozyatinskiy's avatar
      inspector: move injected script source to native · 7e079c66
      Alexey Kozyatinskiy authored
      - introduced ValueMirror interface, this interface contains methods to generate
        different protocol entities,
      - introduced DebugPropertyIterator, this iterator iterates through object properties
        in the following order: exotic indices, enumerable strings, all other properties,
      - removed all injected script infra, e.g. closure compiler,
      
      R=dgozman@chromium.org
      TBR=yangguo@chromium.org
      
      Bug: chromium:595206
      Change-Id: Idcfc04489ee52e015ad1d1d191c3474cc65e63f2
      Reviewed-on: https://chromium-review.googlesource.com/c/1308353Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57150}
      7e079c66
    • Clemens Hammacher's avatar
      Revert "inspector: move injected script source to native" · 192bee6b
      Clemens Hammacher authored
      This reverts commit 34686abe.
      
      Reason for revert: Compile errors on several bots, e.g. https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux%20-%20debug%20builder/33299
      
      Original change's description:
      > inspector: move injected script source to native
      > 
      > - introduced ValueMirror interface, this interface contains methods to generate
      >   different protocol entities,
      > - introduced DebugPropertyIterator, this iterator iterates through object properties
      >   in the following order: exotic indices, enumerable strings, all other properties,
      > - removed all injected script infra, e.g. closure compiler,
      > 
      > R=​dgozman@chromium.org
      > TBR=yangguo@chromium.org
      > 
      > Bug: chromium:595206
      > Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      > Change-Id: I077c1879622aa0d9900d719b80d2ef5ba4221a22
      > Reviewed-on: https://chromium-review.googlesource.com/c/1295550
      > Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      > Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#57142}
      
      TBR=dgozman@chromium.org,yangguo@chromium.org,kozyatinskiy@chromium.org
      
      Change-Id: I6e4ccaf1d6b151fbc0ffe4f26daa584433321c77
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: chromium:595206
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      Reviewed-on: https://chromium-review.googlesource.com/c/1307432Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57144}
      192bee6b
    • Alexey Kozyatinskiy's avatar
      inspector: move injected script source to native · 34686abe
      Alexey Kozyatinskiy authored
      - introduced ValueMirror interface, this interface contains methods to generate
        different protocol entities,
      - introduced DebugPropertyIterator, this iterator iterates through object properties
        in the following order: exotic indices, enumerable strings, all other properties,
      - removed all injected script infra, e.g. closure compiler,
      
      R=dgozman@chromium.org
      TBR=yangguo@chromium.org
      
      Bug: chromium:595206
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      Change-Id: I077c1879622aa0d9900d719b80d2ef5ba4221a22
      Reviewed-on: https://chromium-review.googlesource.com/c/1295550
      Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Reviewed-by: 's avatarDmitry Gozman <dgozman@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57142}
      34686abe
  21. 18 Oct, 2018 1 commit
  22. 12 Oct, 2018 1 commit
    • Sathya Gunasekaran's avatar
      [Class] Fix debug scope iteration for class fields · 230dd86c
      Sathya Gunasekaran authored
      When trying to print the scope information for the class fields
      initializer function, the debugger asks the parser to parse the class
      literal as a function literal (to get the scope info) ... which
      doesn't quite work.
      
      Instead of adding support for parsing the class literal, we just short
      cicruit this parsing step by just returning an empty context.
      
      This works fine because initializer function doesn't have any
      variables in it's local scope.
      
      The one caveat is that the objects in the scope above this function
      (like the global) are now missing. This trade off is possibly fine
      for now, as adding parsing support for class literal to only produce
      would be a lot of code for not enough use.
      
      As a follow up to this change, the devtools UI needs to be updated to
      handle this empty context cleanly. Currently, it doesn't show the
      `this` object if no context exists even if the `this` object is
      correctly passed to the UI from the backend.
      
      Bug: v8:5367, v8:8122
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Change-Id: I52965f26241bbf6abdc988783aa0fc44bb36901f
      Reviewed-on: https://chromium-review.googlesource.com/c/1274268
      Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
      Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
      Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#56611}
      230dd86c
  23. 10 Oct, 2018 2 commits
    • Clemens Hammacher's avatar
      [wasm][test] Refactor breakpoint inspector test · 7074113d
      Clemens Hammacher authored
      Before adding another test for removing breakpoint, this CL modernizes
      the existing test for setting breakpoints.
      
      R=kozy@chromium.org
      CC=ahaas@chromium.org
      
      Bug: chromium:837572
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Change-Id: I642f9673f327f4ec569a4f67a61b5e264cf25b8f
      Reviewed-on: https://chromium-review.googlesource.com/c/1264636Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#56514}
      7074113d
    • Benedikt Meurer's avatar
      [async] Improve async function handling. · 0038e5f0
      Benedikt Meurer authored
      This change introduces new intrinsics used to desugar async functions
      in the Parser and the BytecodeGenerator, namely we introduce a new
      %_AsyncFunctionEnter intrinsic that constructs the generator object
      for the async function (and in the future will also create the outer
      promise for the async function). This generator object is internal
      and never escapes to user code, plus since async functions don't have
      a "prototype" property, we can just a single map here instead of tracking
      the prototype/initial_map on every async function. This saves one word
      per async function plus one initial_map per async function that was
      invoked at least once.
      
      We also introduce two new intrinsics %_AsyncFunctionReject, which
      rejects the outer promise with the caught exception, and another
      %_AsyncFunctionResolve, which resolves the outer promise with the
      right hand side of the `return` statement. These functions also perform
      the DevTools part of the job (aka popping from the promise stack and
      sending the debug event). This allows us to get rid of the implicit
      try-finally from async functions completely; because the finally
      block only called to the %AsyncFunctionPromiseRelease builtin, which
      was used to inform DevTools.
      
      In essence we now turn an async function like
      
      ```js
      async function f(x) { return await bar(x); }
      ```
      
      into something like this (in Parser and BytecodeGenerator respectively):
      
      ```
      function f(x) {
        .generator_object = %_AsyncFunctionEnter(.closure, this);
        .promise = %AsyncFunctionCreatePromise();
        try {
          .tmp = await bar(x);
          return %_AsyncFunctionResolve(.promise, .tmp);
        } catch (e) {
          return %_AsyncFunctionReject(.promise, e);
        }
      }
      ```
      
      Overall the bytecode for async functions gets significantly shorter
      already (and will get even shorter once we put the outer promise into
      the async function generator object). For example the bytecode for a
      simple async function
      
      ```js
      async function f(x) { return await x; }
      ```
      
      goes from 175 bytes to 110 bytes (a ~38% reduction in size), which
      is in particular due to the simplification around the try-finally
      removal.
      
      Overall this seems to improve the doxbee-async-es2017-native test by
      around 2-3%. On the test case mentioned in v8:8276 we go from
      1124ms to 441ms, which corresponds to a 60% reduction in total
      execution time!
      
      Tbr: marja@chromium.org
      Bug: v8:7253, v8:7522, v8:8276
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
      Change-Id: Id29dc92de7490b387ff697860c900cee44c9a7a4
      Reviewed-on: https://chromium-review.googlesource.com/c/1269041
      Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
      Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
      Reviewed-by: 's avatarSathya Gunasekaran <gsathya@chromium.org>
      Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
      Reviewed-by: 's avatarJaroslav Sevcik <jarin@chromium.org>
      Reviewed-by: 's avatarMaya Lekova <mslekova@chromium.org>
      Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#56502}
      0038e5f0
  24. 01 Oct, 2018 2 commits
  25. 28 Sep, 2018 1 commit
  26. 25 Sep, 2018 1 commit
  27. 21 Sep, 2018 1 commit
  28. 20 Sep, 2018 1 commit
  29. 17 Sep, 2018 1 commit
  30. 13 Sep, 2018 1 commit
  31. 03 Sep, 2018 1 commit
    • Yang Guo's avatar
      Revert "inspector: find magic comment using V8 scanner" · 4a96850a
      Yang Guo authored
      This reverts commit 1b3b808a.
      
      Reason for revert: crbug/879988
      
      TBR=kozy@chromium.org
      
      Original change's description:
      > inspector: find magic comment using V8 scanner
      >
      > Inspector tries to provide sourceURL and sourceMappingURL for scripts
      > with parser errors. Without this CL we convert source of each script
      > to inspector string and search for magic comment there. Some web sites
      > use pattern when they get some data from network and constantly try to
      > parse this data as JSON, in this case we do a lot of useless work.
      >
      > So we can parse magic comments on V8 side only for compilation errors
      > (excluding parse JSON errors), to do it we can reuse scanner by running
      > it on each potential comment.
      >
      > R=​alph@chromium.org,verwaest@chromium.org,yangguo@chromium.org
      >
      > Bug: chromium:873865,v8:7731
      > Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      > Change-Id: I77c270fd0e95cd7b2c9ee4b7f72ef344bc1fa104
      > Reviewed-on: https://chromium-review.googlesource.com/1182446
      > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
      > Reviewed-by: Alexei Filippov <alph@chromium.org>
      > Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#55280}
      
      TBR=alph@chromium.org,yangguo@chromium.org,kozyatinskiy@chromium.org,verwaest@chromium.org
      
      # Not skipping CQ checks because original CL landed > 1 day ago.
      
      Bug: chromium:873865, v8:7731, chromium:879988
      Change-Id: Ia7ac766e19f9b58562d9430811f10b25c4556a46
      Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
      Reviewed-on: https://chromium-review.googlesource.com/1202583
      Commit-Queue: Yang Guo <yangguo@chromium.org>
      Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#55594}
      4a96850a
  32. 31 Aug, 2018 1 commit