Commit Graph

42 Commits

Author SHA1 Message Date
Jakob Kummerow
a5906c241e Revert "[tools] Add a simple gdb frame unwinder"
This reverts commit c3ac338bb9.

Reason for revert: Breaks stepping with `n`

Original change's description:
> [tools] Add a simple gdb frame unwinder
>
> Add a simple unwinder for gdb which, on x64,  walks frame pointers
> whenever there is no source information available. Ideally we would only
> do this for V8 PCs but this appears hard to do in an Unwinder without
> messing with gdb's internal assumptions.
>
> Change-Id: Iba1e62a3768340ee912e81d691237c1920a8ae91
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3608628
> Reviewed-by: Camillo Bruni <cbruni@chromium.org>
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#80204}

Change-Id: I0264cf34cfe8fe2331bacf202dedbb4706535936
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3644855
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80493}
2022-05-12 14:48:42 +00:00
Leszek Swirski
c3ac338bb9 [tools] Add a simple gdb frame unwinder
Add a simple unwinder for gdb which, on x64,  walks frame pointers
whenever there is no source information available. Ideally we would only
do this for V8 PCs but this appears hard to do in an Unwinder without
messing with gdb's internal assumptions.

Change-Id: Iba1e62a3768340ee912e81d691237c1920a8ae91
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3608628
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80204}
2022-04-27 08:51:23 +00:00
Pierre Langlois
76b40ef6c0 [gdbinit] Do not enable ASLR if not possible.
The `set disable-randomization off` command may fail on some platforms,
such as the `rr` debugger. We can just ignore the error and carry on.

Change-Id: I9b8dae183a9852178a3d3411172bf3aef173c995
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3602519
Auto-Submit: Pierre Langlois <pierre.langlois@arm.com>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80143}
2022-04-25 11:43:32 +00:00
Clemens Backes
b04d9eea02 [gdbinit] Also look for OS::DebugBreak frames
If such a frame is near the top of the stack frame, move to the frame
below instead, which is the caller of OS::DebugBreak.
Also, rename dcheck_stop_handler to v8_stop_handler since we handle more
than DCHECKs there.

R=leszeks@chromium.org

No-Try: true
Change-Id: Ib31c2dc8278ec779a00babfdc952453e66e5f110
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3366238
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78481}
2022-01-04 15:51:18 +00:00
Leszek Swirski
5e9afd645c [tools] Fix gdb frame skip over dummy frames
The gdb DCHECK frame skipping automatically skips over all the abort
etc. frames to get you to that DCHECK callsite you're actually looking
for.

However, this is annoying if you tried to call a function with a
breakpoint from the gdb prompt; the frame skipping wold skip over your
breakpoint back up to the failing DCHECK.

Now, we abort the frame walk on dummy frames inserted by gdb execution.

Change-Id: I2cf89ea9219374ad7c562c6eb13afe471038b033
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3229376
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#77436}
2021-10-18 14:49:13 +00:00
Ng Zhi An
bb78e62810 [tools] Default to printing $pc when jco is called without args
This makes jco on gdb behave the same as jco on lldb.

Bug: v8:11879
Change-Id: Id6a338878d518984986d2b719588966ee09de3c6
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3000956
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#75620}
2021-07-07 17:24:01 +00:00
Santiago Aboy Solanes
42409a2e69 [objects] Delete double field unboxing
Reasons:
 * We disabled it more than a year ago for all configs
 * Not easy to re-enable
 * Not compatible with pointer compression as-is
 * Not compatible with concurrent TP/TF as-is
 * No concrete plans to re-enable it

Also remove Map's layout_descriptor since it was only used for double
field unboxing.

Bug: v8:11422
Change-Id: I9260906eac199213b3210712e9903f1ecf1d7979
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2676637
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72671}
2021-02-11 17:24:15 +00:00
Leszek Swirski
1f72df06b3 [arm64/sim] Add a 'sim' gdb command
Extract out the command processing from Simulator::Debug(), and expose
it to gdb as a new 'sim' command. Example usage:

    (gdb) sim p x15
    (gdb) sim stack

The sim command will execute that one command, and will return to gdb.

For a list of all commands, you can call

    (gdb) sim help

Note that sim won't resume simulator execution until gdb continues
execution; for example, `sim next` will set a breakpoint on the next
instruction, and will return to gdb. The user then has to continue
execution in gdb, at which point the simulator will break. The user can
then re-enter gdb with the gdb command. This will look like this:

    (gdb) sim next
    (gdb) continue
    ...
    sim> gdb
    (gdb) ...

Change-Id: I678e71e2642d8427950b5f7ed65890ceae69e18d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2664448
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72479}
2021-02-02 11:59:53 +00:00
Clemens Backes
af854e8365 [gdbinit] Slightly increase dcheck stack walk limit
I hit a case where the 'V8_Dcheck' was only the sixth stack frame. Thus
increase the limit from 5 to 7.

R=ahaas@chromium.org

No-Try: true
Change-Id: I1ea37f07ff08ab5acffdfcc89d01ff102750a1e0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2016589
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#65943}
2020-01-23 11:27:28 +00:00
Pierre Langlois
f1c5be441e [gdb] Do not set disassembly-flavor on non-x86 platforms.
The `set disassembly-flavor` command is only available when debugging a x86
target. On other targets, sourcing `tools/gdbinit` fails as a result.

Sadly, we have to resort to using python's exception to ignore errors and carry
on.

NOTRY=true

Change-Id: If37450ee5bca43d5edb02fa9a5b218d7992f8885
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1847353
Commit-Queue: Pierre Langlois <pierre.langlois@arm.com>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#64182}
2019-10-09 11:25:21 +00:00
Sigurd Schneider
12b45fdf00 [gdb] Add gdb macro 'pn' that prints TurboFan nodes
The macro pn ensures that TurboFan nodes can be easily
printed in gdb, even in release builds where Node::Print
is sometimes not available (because all uses have been
inlined).

This CL also modifies the print function to deal gracefully
with nullptr input nodes, which is helpful for debugging.

Change-Id: Ib5f58aa13b719c8390826bc89dfe21cf58586de5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1672941
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Tamer Tas <tmrts@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Cr-Commit-Position: refs/heads/master@{#62422}
2019-06-27 13:29:08 +00:00
Leszek Swirski
e41bdb5eb1 [tools] Remove chrome-specific gdbinit code
Change-Id: Ie38c77aafbe75f61fc568f1013ca5815d6750364
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1662289
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#62284}
2019-06-19 12:34:05 +00:00
Ben L. Titzer
7cba46adee [tools] Import gdbinit from Chromium
This CL imports some gdbinit magic from Chromium's tools. This fixes
gdb warnings about differences between psymtab and symtab.

R=bmeurer@chromium.org
CC=leszeks@chromium.org

Change-Id: I06e67c17e03b803c516ab59aeb6c17435b81d6d0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1611540
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Ben Titzer <titzer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61492}
2019-05-14 16:39:08 +00:00
Leszek Swirski
ad4865b93b [gdb] Remove $job helper
It doesn't seem to work properly, use _v8_internal_Get_Object until
we can think of a better workaround.

Bug: v8:8994
Change-Id: I47496d442f5b62e6cb78edcdf35fe1ac1aad2084
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1529005
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60348}
2019-03-20 09:10:32 +00:00
Leszek Swirski
b240733fd5 [gdb] Add helper for creating an object from a pointer
Since the new Objects were introduced, we can no longer cast integers to
and Object pointer and call methods on them in gdb (due to how gdb's
expression evaluator deals with temporaries). So, we add a new helper
method to our gdbinit, "$job", which takes an address and returns an
Object that is now exists in real (stack) memory.

Bug: v8:8994
Change-Id: I760a007e7d2303e3a4b1fecb87e094fb9974e91e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1523329
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60245}
2019-03-14 17:33:19 +00:00
Yang Guo
6eb397c405 Fix heap_find gdb macro
R=ulan@chromium.org

Change-Id: Ib2caeeeb9877f853848b4014a8088ee447d1705a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1503765
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60055}
2019-03-06 11:48:12 +00:00
Ben L. Titzer
70a7287c96 [tools] Fix gdbinit cast error
R=clemensh@chromium.org

Change-Id: I1dec320464f5bc80e248cdf0b31b4a095bc54994
Reviewed-on: https://chromium-review.googlesource.com/c/1495981
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Ben Titzer <titzer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59966}
2019-03-01 11:52:54 +00:00
Dan Elphick
2d4777fc79 [gdbinit] Fix regex for assertion scopes in bta
This restores assertion scope marking in the bta command making it
obvious which frames disallowed heap allocation for instance.

Change-Id: Ie99ff06df95b6ab6820e53798b12b1cd1bd97338
Reviewed-on: https://chromium-review.googlesource.com/c/1477213
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59676}
2019-02-19 09:20:06 +00:00
Dan Elphick
3ef8ae90d1 [gdb] Limit stack search when looking for DCHECK
Only look 5 frames up the stack when looking for a DCHECK to move the
frame to to prevent excessive iteration especially after a stack
overflow.

Change-Id: I227c46596f09c9af0a47e6673d3165eaccb75163
Reviewed-on: https://chromium-review.googlesource.com/c/1400408
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58621}
2019-01-08 10:46:34 +00:00
Clemens Hammacher
8344890bd7 [gdb] Fix dcheck_stop_handler
Some frames have no name. gdb showed an error in these cases. This CL
avoids this by explicitly handling unnamed frames.

R=ahaas@chromium.org

No-Try: true
Change-Id: Id3918705fbfe66306b5d1c34c3638b67e037aa18
Reviewed-on: https://chromium-review.googlesource.com/c/1382211
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58313}
2018-12-18 11:09:53 +00:00
Clemens Hammacher
19d39a0f33 [gdb] Print DCHECK error message
When selecting the frame above the V8_Dcheck method (at the DCHECK
location), it helps enormously to immediately see the error message
generated by the DCHECK. This extends the dcheck_stop_handler to find
and print this message.

Drive-by: Speed up the handler by stopping after the first V8_Dcheck
frame.

R=mstarzinger@chromium.org

Bug: v8:8562
Change-Id: If3a8f3aaab6a0014006ccac7260f37d5d90363c5
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/1378170
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58238}
2018-12-14 10:48:35 +00:00
Igor Sheludko
c3f543ab0c [gdb] Add jh macro for printing objects inside handles
because for some reason gdb does not want to execute
  job *handle
anymore.

Bug: v8:8238
Change-Id: I9b632f5d34048b80e1f9542de963f738f1afb613
Reviewed-on: https://chromium-review.googlesource.com/c/1332230
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57449}
2018-11-12 22:08:21 +00:00
Dan Elphick
d9770a27b5 [gdb] Move stack frame up to frame above V8_Fatal
UNREACHABLE and CHECK call V8_Fatal directly so treat them like
V8_Dcheck, but also ensure that the frame is moved up to the DCHECK
frame even if it calls V8_Fatal.

Change-Id: Iad5f2e3ea95182bed473d6b2d843a0c1e111911d
Reviewed-on: https://chromium-review.googlesource.com/1183303
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#55267}
2018-08-21 12:32:03 +00:00
Dan Elphick
421571953f [gdb] Select frame above the DCHECK function
Rather than having GDB always stop on the line containing
V8_IMMEDIATE_CRASH(), walk up the stack looking for V8_Dcheck and select
the frame above it. This will be the frame containing DCHECK (including
related macros like DCHECK_EQ).

Change-Id: I9760e7a4dd78b567dfa77ff12569d287d80ca873
Reviewed-on: https://chromium-review.googlesource.com/1172780
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#55112}
2018-08-14 09:43:00 +00:00
Dan Elphick
edec05ea73 [explicit isolates] Pass Isolate to Object::Print
All Object::Print functions now take an Isolate* parameter. Various
XX::XXPrint functions now take an Isolate if it's needed rather than
calling GetIsolate(). Such method use DECL_PRINTER_WITH_ISOLATE rather
than DECL_PRINTER.

The _v8_internal_Print_ function (intended for use in gdb) now uses
Isolate::Current() to get hold of an Isolate.

Reduces the GetIsolate and GetHeap count by 9 and 5 respectively.

Also removes unneeded gdb/lldb macros (along with their support
functions), jfv, jfm, jda and jta, since job does the same thing.

Bug: v8:7786
Change-Id: Ib93ebca6ca47c4db9c85cc6d9ff8004da5942dec
Reviewed-on: https://chromium-review.googlesource.com/1112001
Commit-Queue: Dan Elphick <delphick@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54029}
2018-06-26 12:32:04 +00:00
Yang Guo
9a64d7b626 Fix jlh gdb macro.
R=franzih@chromium.org

Change-Id: I5f5ac245408c76a072f5cb3ae81b8773ddcd47cc
Reviewed-on: https://chromium-review.googlesource.com/808784
Reviewed-by: Franziska Hinkelmann <franzih@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49912}
2017-12-06 19:42:23 +00:00
Camillo Bruni
b104434974 [debugging] Add helper to print transition trees
jtt will now print the complete transition tree of a given Map in gdb.

Change-Id: I07031dd3d463bec0072e8ac696406279ff057489
Reviewed-on: https://chromium-review.googlesource.com/558257
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#46437}
2017-07-06 10:44:01 +00:00
Camillo Bruni
4a4699edac [tools] Adding heap_find gdb helper
heap_find walks all the page of the heap and finds the references to a given
address.

NOTRY=true

Change-Id: I3271ab96d0224acf2361fe5bc4c8b0a608caf091
Reviewed-on: https://chromium-review.googlesource.com/500190
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45202}
2017-05-09 15:27:01 +00:00
ishell@chromium.org
8dde6acb74 [gdbinit] Rename TypeFeedback* to Feedback*.
BUG=

Change-Id: I1e32fdcf9edda57f5de329c8b694620a5da4558b
Reviewed-on: https://chromium-review.googlesource.com/442444
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#43185}
2017-02-14 12:59:14 +00:00
mvstanton
aea3ce3df3 [TypeFeedbackVector] Root feedback vectors at function literal site.
TypeFeedbackVectors are strongly rooted by a closure. However, in modern
JavaScript closures are created and abandoned more freely. An important
closure may not be present in the root-set at time of garbage collection,
even though we've cached optimized code and use it regularly. For
example, consider leaf functions in an event dispatching system. They may
well be "hot," but tragically non-present when we collect the heap.

Until now, we've relied on a weak root to cache the feedback vector in
this case. Since there is no way to signal intent or relative importance,
this weak root is as susceptible to clearing as any other weak root at
garbage collection time.

Meanwhile, the feedback vector has become more important. All of our
ICs store their data there. Literal and regex boilerplates are stored there.
If we lose the vector, then we not only lose optimized code built from
it, we also lose the very feedback which allowed us to create that optimized
code. Therefore it's vital to express that dependency through the root
set.

This CL does this by creating a strong link to a feedback
vector at the instantiation site of the function closure.
This instantiation site is in the code and feedback vector
of the outer closure.

BUG=v8:5456

Review-Url: https://codereview.chromium.org/2674593003
Cr-Commit-Position: refs/heads/master@{#42953}
2017-02-06 10:18:05 +00:00
yangguo
391f1ac3f5 Add gdb macro for printing v8::Local content.
R=marja@chromium.org

Review-Url: https://codereview.chromium.org/2628293003
Cr-Commit-Position: refs/heads/master@{#42327}
2017-01-13 12:59:30 +00:00
ishell
6fdd480ed4 [printing] Print properties backing store value and add a gdb macro for printing LayoutDescriptors.
BUG=

Review-Url: https://codereview.chromium.org/2537523002
Cr-Commit-Position: refs/heads/master@{#41326}
2016-11-28 19:28:09 +00:00
yangguo
388acfc4ed Add missing "end" to gdb macro
TBR=jochen@chromium.org

Review-Url: https://codereview.chromium.org/2474433011
Cr-Commit-Position: refs/heads/master@{#40749}
2016-11-04 08:24:06 +00:00
yangguo
6ab61037f3 Add gdb macro to find assertion scopes on the stack.
This is how it would look like.

(gdb) bta
[1 ] V8_Fatal                                         ../../src/base/logging.cc:67
[2 ] v8::internal::Heap::AllocateRaw                  ../../src/heap/heap-inl.h:298
[3 ] v8::internal::Heap::AllocateHeapNumber           ../../src/heap/heap.cc:2432
[4 ] v8::internal::Factory::NewHeapNumber             ../../src/factory.cc:1253
[5 ] v8::internal::Factory::NewNumber                 ../../src/factory.cc:1228
[6 ] v8::internal::__RT_impl_Runtime_ConstructDouble  ../../src/runtime/runtime-test.cc:32
 -> Allow HEAP_ALLOCATION (yes_gc)
 -> Disallow HEAP_ALLOCATION (no_gc)
[7 ] v8::internal::Runtime_ConstructDouble            ../../src/runtime/runtime-test.cc:24

R=jochen@chromium.org

Review-Url: https://codereview.chromium.org/2466263007
Cr-Commit-Position: refs/heads/master@{#40748}
2016-11-04 07:27:54 +00:00
ishell
e063b7118c [gdb] Define print functions used by gdb macros in the top level namespace to make them always be available.
This should fix the following errors that sometimes appear when using V8 gdb macros:
  Cannot evaluate function -- may be inlined
or
  No symbol "xxx" in namespace "v8::internal".

Review-Url: https://codereview.chromium.org/2186293002
Cr-Commit-Position: refs/heads/master@{#38145}
2016-07-28 17:09:35 +00:00
jochen
a811808432 Add a jss gdb macro that skips over the jitted stack in gdb
Use it like this:

Program received signal SIGTRAP, Trace/breakpoint trap.
[Switching to Thread 0x7f50d02c4700 (LWP 8152)]
base::debug::(anonymous namespace)::DebugBreak ()
    at ../../base/debug/debugger_posix.cc:230
230     }
(gdb) bt
    at ../../base/debug/debugger_posix.cc:230
...
    args_object=0x7f50d02bfe00, isolate=0x2f001c9e2020)
    at ../../v8/src/builtins/builtins-api.cc:123
...
(gdb) jss
(gdb) bt
    isolate=0x2f001c9e2020, is_construct=false, target=..., receiver=...,
    argc=1, args=0x7f50d02c0518, new_target=...)
    at ../../v8/src/execution.cc:111
    isolate=0x2f001c9e2020, callable=..., receiver=..., argc=1,
    argv=0x7f50d02c0518) at ../../v8/src/execution.cc:168
...

R=yangguo@chromium.org
BUG=

Review-Url: https://codereview.chromium.org/2186013002
Cr-Commit-Position: refs/heads/master@{#38121}
2016-07-28 09:06:39 +00:00
mvstanton
9386b861fd Special printing for type feedback vectors.
Gdb macro jfv on an object will print it as a feedback vector.
Printouts look like this:

DebugPrint: 0x5dc0d2ad: [TypeFeedbackVector]
 - length: 12
 - ics with type info: 3
 - generic ics: 0
 ICSlot 0 CALL_IC MONOMORPHIC
  [4]: 0x5dc0d365 WeakCell for 0x5dc0cd69 <JS Function foo (SharedFunctionInfo 0x5dc0cb0d)>
  [5]: 0x4203c4c1 <Code: HANDLER>
 ICSlot 1 LOAD_IC MONOMORPHIC
  [6]: 0x5dc0d1f5 WeakCell for 0x3a710481 <Map(FAST_HOLEY_SMI_ELEMENTS)>
  [7]: 0x4203a1c1 <Code: HANDLER>
 ICSlot 2 LOAD_IC UNINITIALIZED
  [8]: 0x3060d045 <Symbol: 711234650 <String[20]: uninitialized_symbol>>
  [9]: 0x3060d045 <Symbol: 711234650 <String[20]: uninitialized_symbol>>
 ICSlot 3 LOAD_IC MONOMORPHIC
  [10]: 0x5dc0d3b5 WeakCell for 0x3a710d71 <Map(FAST_HOLEY_ELEMENTS)>
  [11]: 0x4202af01 <Code: HANDLER>

BUG=

Review URL: https://codereview.chromium.org/1225403005

Cr-Commit-Position: refs/heads/master@{#29679}
2015-07-15 12:22:03 +00:00
jochen
21bca71c6d Update PrintStack signature in gdbinit
BUG=none
R=yangguo@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/1179053004

Cr-Commit-Position: refs/heads/master@{#28985}
2015-06-12 08:35:50 +00:00
jkummerow@chromium.org
f916299225 Fix "jst" GDB macro
R=svenpanne@chromium.org

Review URL: https://codereview.chromium.org/669383002

Cr-Commit-Position: refs/heads/master@{#24881}
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24881 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-24 15:04:08 +00:00
ishell@chromium.org
209855a6b6 More details printed for Map, DescriptorArray and TransitionArray.
R=verwaest@chromium.org

Review URL: https://codereview.chromium.org/659363002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24837 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-23 11:31:33 +00:00
mstarzinger@chromium.org
cb778b24ae Fix trailing whitespace in gdbinit file.
R=jkummerow@chromium.org

Review URL: https://codereview.chromium.org/379133003

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22296 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-07-09 10:55:55 +00:00
jkummerow@chromium.org
34e09e5644 Add gdbinit to tools/ directory.
Suggested usage: echo "source /path/to/v8/tools/gdbinit" >> ~/.gdbinit

R=mstarzinger@chromium.org

Review URL: https://codereview.chromium.org/375503009

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22252 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-07-07 16:21:29 +00:00