Skip to content

Breakpoints in Dartium causing crashes #2401

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
dgrove opened this issue Apr 3, 2012 · 5 comments
Closed

Breakpoints in Dartium causing crashes #2401

dgrove opened this issue Apr 3, 2012 · 5 comments
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. P0 A serious issue requiring immediate resolution

Comments

@dgrove
Copy link
Contributor

dgrove commented Apr 3, 2012

As discussed earlier today, we're seeing breakpoints causing crashes in Dartium very frequently.

(purely as FYI: I just tried this at r6117, and still see the problem)

@dgrove
Copy link
Contributor Author

dgrove commented Apr 3, 2012

Anton, Pavel:

I misunderstood a comment from Ivan earlier - it's not clear whether this is crashing in the VM or in the bindings. The reason for this is that the crashes are only happening in release builds, which have no symbols.

Can you guys see if there's a way for us to build the release build with symbols?

@DartBot
Copy link

DartBot commented Apr 3, 2012

This comment was originally written by [email protected]


Release builds has symbols on linux by default.

For Mac OS see http://www.chromium.org/developers/debugging-on-os-x "Preserving symbols in Release builds".

Some useful tips for debugging multiprocess chrome on linux: http://code.google.com/p/chromium/wiki/LinuxDebugging.

@DartBot
Copy link

DartBot commented Apr 4, 2012

This comment was originally written by @mhausner


The crashes only happen on Release builds. What I've found so far is that while handling a breakpoint, WebCore calls back into the VM to retrieve a list of elements. One of the values it gets back is corrupted, or at least the class object it points to is corrupted. The vtable in that class is sometimes 0, sometimes -1, but when Dart_IsError calls the member function Object::IsError(), we crash.

See below for stack trace at crash. I'm investigating now how the raw object gets corrupted, or how we end up with a class that has no vtable entry.

#­1 0x41e4aafa in WebCore::inspectedListIndexedPropertyHandler ()
#­2 0x411582d9 in v8::internal::JSObject::GetElementWithInterceptor ()
#­3 0x411fe050 in v8::internal::KeyedLoadPropertyWithInterceptor ()
#­4 0x2780a336 in ?? ()
#­5 0x278402de in ?? ()
#­6 0x278160e9 in ?? ()
#­7 0x2783f887 in ?? ()
#­8 0x278160e9 in ?? ()
#­9 0x2783ef9f in ?? ()
#­10 0x27821984 in ?? ()
#­11 0x27821c7a in ?? ()
#­12 0x27812d0a in ?? ()
#­13 0x41098a53 in v8::internal::Invoke ()
#­14 0x41098c39 in v8::internal::Execution::New ()
#­15 0x410547a8 in v8::Object::CallAsConstructor ()
#­16 0x41e49b3a in WebCore::DartDebugServer::handleBreakpoint ()
#­17 0x41e48f5e in WebCore::DartDebugServer::breakpointHandler ()
#­18 0x4168c543 in dart::Debugger::BreakpointCallback ()
#­19 0x416726c1 in dart::DRT_BreakpointStaticHandler ()
#­20 0x237000e2 in ?? ()
#­21 0x23700704 in ?? ()


Added Started label.

@DartBot
Copy link

DartBot commented Apr 4, 2012

This comment was originally written by @mhausner


I think I know what it is. The debugger is getting bogus values from the stack when it is getting the value of a captured variable. It should read the value from the context instead. I even have a TODO in the code that captured variables are not handled yet.

@DartBot
Copy link

DartBot commented Apr 4, 2012

This comment was originally written by @mhausner


Crashes should be gone. The captured variables were indeed the culprit. For now, the name and value of captured variables is not displayed in the debugger. Working on a solution that handles captured variables corretly in a separate change.


Added Fixed label.

@dgrove dgrove added Type-Defect P0 A serious issue requiring immediate resolution area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. labels Apr 4, 2012
dart-bot pushed a commit that referenced this issue Mar 27, 2020
git log --pretty=oneline 737f055d0a1cfb348178dbde6bd13f06704bf6d4..f87c05da8cd049efa26891f1e6927dcfe30777f2
f87c05da8cd049efa26891f1e6927dcfe30777f2 (HEAD -> master, origin/master, origin/HEAD) Always normalize paths before they are passed to the analyzer (#2409)
58bd44b5a46f27eae80cb2ec79af2b3f55faf291 hide mark option from outdated (#2403)
395f644e44c5d7d432623fb1ea74948bf05889db Fix pub outdated help messages consistency (#2408)
1b558f251b9b1d990015260ff9819160956c8093 Use different language version API. (#2400)
a9fdf9ff61f01507bbc9bcecc075f11dc09c13b9 Output a summary when there are newer version, but they cannot resolv… (#2387)
e0e396bf2aadbe21be5174784c6f37de87d34493 Outdated fix messages (#2401)

Change-Id: Icf5a6b8ec9ae50148689cac7bfe5fca33043a70a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141246
Reviewed-by: Jonas Jensen <[email protected]>
Commit-Queue: Kevin Moore <[email protected]>
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. P0 A serious issue requiring immediate resolution
Projects
None yet
Development

No branches or pull requests

2 participants