[SERVER-11099] clang compiled mongo shell crashes on exit with a stack trace in v8 Created: 09/Oct/13 Updated: 11/Jul/16 Resolved: 18/Oct/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell |
| Affects Version/s: | None |
| Fix Version/s: | 2.4.9, 2.5.4 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Andrew Morrow (Inactive) | Assignee: | Andrew Morrow (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | shell | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
So far, only observed on OS X using XCode 5 (which is clang). |
||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
A mongo shell built with --dbg=on --opt=on dies with the following stack trace on exit:
The 'XXX' line was added to the test as the last print in the function to confirm that this was after evaluating the file. |
| Comments |
| Comment by Githook User [ 02/Dec/13 ] | ||||||||||||||||||
|
Author: {u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}Message: This is a backport of the portion of https://github.com/v8/v8/commit/b3775cf3 This will repair the issue with the mongo shell crashing on shutdown (cherry picked from commit 670c981819ed1512b9f623d3879901dda606ed20) | ||||||||||||||||||
| Comment by auto [ 18/Oct/13 ] | ||||||||||||||||||
|
Author: {u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}Message: This is a backport of the portion of https://github.com/v8/v8/commit/b3775cf3 This will repair the issue with the mongo shell crashing on shutdown | ||||||||||||||||||
| Comment by Andrew Morrow (Inactive) [ 16/Oct/13 ] | ||||||||||||||||||
|
The relevant fix has been applied on the v8 master branch: https://code.google.com/p/v8/source/browse/trunk/src/spaces.h#325 This was v8 git commit b3775cf3. We should probably cherry pick this fix to our v8 tree. I recommend we do this for 2.5.4, otherwise developers on OS X using newer XCode will never be able to test 2.6. | ||||||||||||||||||
| Comment by Andrew Morrow (Inactive) [ 10/Oct/13 ] | ||||||||||||||||||
|
Built as follows:
| ||||||||||||||||||
| Comment by Mathias Stearn [ 10/Oct/13 ] | ||||||||||||||||||
|
acm Was that with --opt=on or --opt=off? | ||||||||||||||||||
| Comment by Andrew Morrow (Inactive) [ 10/Oct/13 ] | ||||||||||||||||||
|
I repro'd on Ubuntu Raring with the clang nightlies installed. Running under address sanitizer gives us:
| ||||||||||||||||||
| Comment by Eric Milkie [ 09/Oct/13 ] | ||||||||||||||||||
|
I was using the wrong command line parameters – it does reproduce; my mistake. | ||||||||||||||||||
| Comment by Eric Milkie [ 09/Oct/13 ] | ||||||||||||||||||
|
I tried this on OS X Mavericks in C++11 mode and can't reproduce the crash. | ||||||||||||||||||
| Comment by Mathias Stearn [ 09/Oct/13 ] | ||||||||||||||||||
|
./test js causes an easily reproducible segfault deep in V8's memory management code. Seems to only happen with clang and - |