New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 604458 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Apr 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: iOS
Pri: 2
Type: Bug



Sign in to add a comment

Dev Tools crash in ToT developer release build in debug-scopes.cc

Project Member Reported by michae...@chromium.org, Apr 18 2016

Issue description

Version: 52.0.2712.0
OS: Chrome OS on Linux

What steps will reproduce the problem?
(1) open dev tools
(2) have breakpoints
(3) trigger a breakpoint via the page

#
# Fatal error in ../../v8/src/debug/debug-scopes.cc, line 854
# Check failed: beg_pos >= 0 && end_pos >= 0.
#

==== C stack trace ===============================

 1: 0x7f399ff026b5
 2: 0x7f399fabe115
 3: 0x7f399fabaa2f
 4: 0x7f399fd16c18
 5: 0x7f399fd16628
 6: 0x260c00b0a627
Received signal 4 ILL_ILLOPN 7f399ff0508f
Received signal 11 SEGV_MAPERR 003000000020

 
Owner: kozyatinskiy@chromium.org
Labels: Needs-Feedback
I can't reproduce it with NTP and google.com. Could you provide link to page or javascript source from page where issues is reproducible?
Repro would be awesome.
Labels: -Needs-Feedback
This is happening in chrome://md-settings, in the source for md-settings/languages_page/languages.js. I don't know if it's specific to the CL I'm working on.
Labels: Needs-Feedback
Thank you.
I try to debug this file and DCHECK isn't triggered. Could you explain in what line you set a breakpoint and provide small snippet of code with function that contains this line?
I think that is problem that some of statement in scope has uninitialized location.
Labels: -Needs-Feedback
I haven't found a repro case outside of my own development. I've uploaded a patch generated via `git diff 6adf4a13` if you care to apply it...

0. build out/Release with chromeos=1 component=shared_library dcheck_always_on=1
1. open chrome://md-settings/advanced
2. ctrl+shift+j
3. open source for md-settings/languages_page/languages.js
3. ctrl+f getEnabledLanguages_:
4. add a breakpoint to the next line (line 338)
5. reload

Sometimes the crash happens when the breakpoint is elsewhere -- not every line triggers it, but some lines do.


    Polymer({
    ....
      getEnabledLanguages_: function(translateTarget) {
        assert(CrSettingsPrefs.isInitialized); // <-- add the breakpoint here




604458.diff
95.2 KB Download
Status: Assigned (was: Untriaged)
Thanks! I can reproduce it.
Simplified repro scenario: type following code in DevTools console:

for (var a of [1])
  debugger;
Haha, yes that's a slightly easier repro. Thanks!
Owner: yangguo@chromium.org
Nice. Converted to a d8 repro:

var Debug = debug.Debug;

function listener(event, exec_state, event_data, data) {
  if (event != Debug.DebugEvent.Break) return;
  try {
    exec_state.frame(0).allScopes();
  } catch (e) {
    exception = e;
  }
}


Debug.setListener(listener);

for (var a of [1]) 
debugger;

I can take over from here.
Cc: -yangguo@chromium.org kozyatinskiy@chromium.org
I think that scopes from V8 internal scripts doesn't have locations and we can just ignore it but I'm sure that you know better then me :)
I have a fix:

https://codereview.chromium.org/1901413002

This probably breaks some layout tests, so I'm checking whether I need to rebaseline any.
The scope causing this issue does not have any location associated because it's introduced by the parser for desugaring of for-of. I'm implementing the idea we discussed a while ago where scopes like this should not be exposed to the debugger.
Project Member

Comment 14 by bugdroid1@chromium.org, Apr 22 2016

Labels: OS-iOS
Status: Fixed (was: Assigned)

Sign in to add a comment