Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Issue 919653002: [V8] Use Function.name in Error.stack (Closed)

Created:
5 years, 10 months ago by kozy
Modified:
5 years, 9 months ago
Reviewers:
aandrey, yurys, Yang
CC:
v8-dev
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[V8] Use Function.name in Error.stack Error.stack contains function.name if its type is string. Otherwise if function have inferred name then .stack contains it. For functions from eval .stack property contains "eval". LOG=N BUG=chromium:17356 R=yurys@chromium.org Committed: https://crrev.com/ec73e0886059d1fd3e84ea0171b2de9dcf9bfabe Cr-Commit-Position: refs/heads/master@{#27186}

Patch Set 1 #

Total comments: 4

Patch Set 2 : #

Total comments: 2

Patch Set 3 : #

Patch Set 4 : #

Total comments: 4

Patch Set 5 : #

Total comments: 4

Patch Set 6 : Moved DebugName, inferred name test added #

Patch Set 7 : #

Total comments: 1

Patch Set 8 : #

Total comments: 2

Patch Set 9 : Replaced DebugName with GetDebugName handlified version #

Total comments: 2

Patch Set 10 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+61 lines, -12 lines) Patch
M src/isolate.cc View 1 2 3 4 5 6 7 8 3 chunks +1 line, -6 lines 0 comments Download
M src/messages.js View 1 2 3 4 5 6 7 1 chunk +3 lines, -6 lines 0 comments Download
M src/objects.h View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -0 lines 0 comments Download
M src/objects.cc View 1 2 3 4 5 6 7 8 9 1 chunk +9 lines, -0 lines 0 comments Download
M src/runtime/runtime.h View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M src/runtime/runtime-debug.cc View 1 2 3 4 5 6 7 8 1 chunk +9 lines, -0 lines 0 comments Download
M test/mjsunit/stack-traces.js View 1 2 3 4 5 2 chunks +34 lines, -0 lines 0 comments Download

Messages

Total messages: 32 (5 generated)
kozy
Yury, please take a look!
5 years, 10 months ago (2015-02-11 14:52:38 UTC) #1
aandrey
https://codereview.chromium.org/919653002/diff/1/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/1/src/messages.js#newcode827 src/messages.js:827: var name = GET_PRIVATE(this, CallSiteFunctionKey).displayName; unlike Function.name, this can ...
5 years, 10 months ago (2015-02-11 15:47:39 UTC) #3
aandrey
https://codereview.chromium.org/919653002/diff/1/test/mjsunit/stack-traces.js File test/mjsunit/stack-traces.js (right): https://codereview.chromium.org/919653002/diff/1/test/mjsunit/stack-traces.js#newcode101 test/mjsunit/stack-traces.js:101: FAIL; nit: use { } in v8 code
5 years, 10 months ago (2015-02-11 15:50:40 UTC) #4
kozy
https://codereview.chromium.org/919653002/diff/1/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/1/src/messages.js#newcode827 src/messages.js:827: var name = GET_PRIVATE(this, CallSiteFunctionKey).displayName; On 2015/02/11 15:47:39, aandrey ...
5 years, 10 months ago (2015-02-11 16:11:56 UTC) #5
kozy
Andrey, please take a look.
5 years, 10 months ago (2015-02-12 10:17:32 UTC) #6
aandrey
lgtm
5 years, 10 months ago (2015-02-12 10:20:10 UTC) #7
kozy
Yang, please take a look.
5 years, 10 months ago (2015-02-12 10:28:21 UTC) #9
yurys
lgtm
5 years, 10 months ago (2015-02-12 12:45:37 UTC) #10
Yang
I'm not sure we really should support this non-standard feature. This will likely regress jsbench ...
5 years, 10 months ago (2015-02-12 14:15:29 UTC) #11
kozy
Our stack getter is lazy, isn't it? I suppose if user want to receive stack ...
5 years, 10 months ago (2015-02-12 14:59:57 UTC) #13
kozy
Yury, please take a look. I've uploaded new version of this patch. It uses Function.name ...
5 years, 9 months ago (2015-03-06 10:05:03 UTC) #14
yurys
https://codereview.chromium.org/919653002/diff/60001/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/60001/src/messages.js#newcode837 src/messages.js:837: if (IS_STRING(name)) { Is it supposed to return in ...
5 years, 9 months ago (2015-03-06 11:11:26 UTC) #15
kozy
https://codereview.chromium.org/919653002/diff/60001/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/60001/src/messages.js#newcode837 src/messages.js:837: if (IS_STRING(name)) { On 2015/03/06 11:11:26, yurys wrote: > ...
5 years, 9 months ago (2015-03-06 12:49:59 UTC) #16
kozy
Yury, ptal.
5 years, 9 months ago (2015-03-10 08:05:20 UTC) #17
yurys
lgtm
5 years, 9 months ago (2015-03-10 09:31:24 UTC) #18
kozy
Yang, ptal.
5 years, 9 months ago (2015-03-10 09:31:59 UTC) #19
Yang
https://codereview.chromium.org/919653002/diff/80001/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/80001/src/messages.js#newcode836 src/messages.js:836: var name = %GetDataProperty(fun, 'name'); How about we make ...
5 years, 9 months ago (2015-03-10 10:48:55 UTC) #20
kozy
Yang, ptal. https://codereview.chromium.org/919653002/diff/80001/src/messages.js File src/messages.js (right): https://codereview.chromium.org/919653002/diff/80001/src/messages.js#newcode836 src/messages.js:836: var name = %GetDataProperty(fun, 'name'); On 2015/03/10 ...
5 years, 9 months ago (2015-03-10 15:26:09 UTC) #21
kozy
New version uploaded. Yang, please take a look.
5 years, 9 months ago (2015-03-13 13:09:54 UTC) #22
Yang
Almost there. https://codereview.chromium.org/919653002/diff/140001/src/objects.cc File src/objects.cc (right): https://codereview.chromium.org/919653002/diff/140001/src/objects.cc#newcode10330 src/objects.cc:10330: String* JSFunction::DebugName() { This is not GC-safe. ...
5 years, 9 months ago (2015-03-13 13:19:13 UTC) #23
kozy
https://codereview.chromium.org/919653002/diff/140001/src/objects.cc File src/objects.cc (right): https://codereview.chromium.org/919653002/diff/140001/src/objects.cc#newcode10330 src/objects.cc:10330: String* JSFunction::DebugName() { On 2015/03/13 13:19:13, Yang wrote: > ...
5 years, 9 months ago (2015-03-13 14:05:14 UTC) #24
yurys
https://codereview.chromium.org/919653002/diff/160001/src/objects.cc File src/objects.cc (right): https://codereview.chromium.org/919653002/diff/160001/src/objects.cc#newcode10334 src/objects.cc:10334: String* debug_name = NULL; You should avoid raw pointers ...
5 years, 9 months ago (2015-03-13 14:18:21 UTC) #25
kozy
Yang, please take a look. https://codereview.chromium.org/919653002/diff/160001/src/objects.cc File src/objects.cc (right): https://codereview.chromium.org/919653002/diff/160001/src/objects.cc#newcode10334 src/objects.cc:10334: String* debug_name = NULL; ...
5 years, 9 months ago (2015-03-13 14:54:47 UTC) #26
Yang
On 2015/03/13 14:54:47, kozyatinskiy wrote: > Yang, please take a look. > > https://codereview.chromium.org/919653002/diff/160001/src/objects.cc > ...
5 years, 9 months ago (2015-03-13 15:09:00 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/919653002/180001
5 years, 9 months ago (2015-03-13 15:10:27 UTC) #30
commit-bot: I haz the power
Committed patchset #10 (id:180001)
5 years, 9 months ago (2015-03-13 15:11:52 UTC) #31
commit-bot: I haz the power
5 years, 9 months ago (2015-03-13 15:12:05 UTC) #32
Message was sent while issue was closed.
Patchset 10 (id:??) landed as
https://crrev.com/ec73e0886059d1fd3e84ea0171b2de9dcf9bfabe
Cr-Commit-Position: refs/heads/master@{#27186}

Powered by Google App Engine
This is Rietveld 408576698