• Maya Lekova's avatar
    Revert "[stack-traces] Don't hold on to code objects from StackFrameInfos." · 3ea957a6
    Maya Lekova authored
    This reverts commit 6b1fb003.
    
    Reason for revert: breaks gc stress bots - https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux%20-%20gc%20stress/36626/overview
    
    Original change's description:
    > [stack-traces] Don't hold on to code objects from StackFrameInfos.
    >
    > Previously every `StackFrameInfo` instance would maintain a reference to
    > an AbstractCode object, which was used to resolve the `code_offset` on
    > that stack frame. However, it turns out that nowadays this is not
    > necessary anymore, since all `code_offset`s reported for JavaScript
    > frames are already bytecode offsets and thus can be resolved by just
    > looking at the functions' bytecode.
    >
    > For WebAssembly frames we will also eagerly resolve the `code_offset`
    > (which is different depending on whether we're looking at Liftoff or
    > TurboFan code) to the byte offset (relative to the function start) and
    > stash that away in the `StackFrameInfo`.
    >
    > For builtin exit frames, the `abstract_code` on the function always
    > refers to the builtin code object and thus, there's no point in keeping
    > an extra pointer to it around on the `StackFrameInfo`.
    >
    > This way the `StackFrameInfo` representation is somewhat uniform, and
    > more importantly, the `StackFrameInfo` instances will no longer need to
    > hold to concrete code objects.
    >
    > Drive-by-fix: Use `FixedArray::SetAndGrow()` when adding to the elements
    > in the `StackTraceBuilder`.
    >
    > Also-By: szuend@chromium.org, jarin@chromium.org
    > Bug: chromium:1258599, chromium:1077657, v8:8742, chromium:1069425
    > Change-Id: I650e400e0e1acd920281669bdc7b5e1199683ae8
    > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3323073
    > Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
    > Reviewed-by: Leszek Swirski <leszeks@chromium.org>
    > Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
    > Cr-Commit-Position: refs/heads/main@{#78320}
    
    Bug: chromium:1258599, chromium:1077657, v8:8742, chromium:1069425
    Change-Id: I20643ad8f0c383b754841fc52f9b3447b004c9d0
    No-Presubmit: true
    No-Tree-Checks: true
    No-Try: true
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3327141
    Auto-Submit: Maya Lekova <mslekova@chromium.org>
    Owners-Override: Maya Lekova <mslekova@chromium.org>
    Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
    Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
    Cr-Commit-Position: refs/heads/main@{#78323}
    3ea957a6
Name
Last commit
Last update
..
arm Loading commit data...
arm64 Loading commit data...
ia32 Loading commit data...
loong64 Loading commit data...
mips Loading commit data...
mips64 Loading commit data...
ppc Loading commit data...
riscv64 Loading commit data...
s390 Loading commit data...
x64 Loading commit data...
DEPS Loading commit data...
DIR_METADATA Loading commit data...
OWNERS Loading commit data...
arguments-inl.h Loading commit data...
arguments.cc Loading commit data...
arguments.h Loading commit data...
embedder-state.cc Loading commit data...
embedder-state.h Loading commit data...
encoded-c-signature.cc Loading commit data...
encoded-c-signature.h Loading commit data...
execution.cc Loading commit data...
execution.h Loading commit data...
frame-constants.h Loading commit data...
frames-inl.h Loading commit data...
frames.cc Loading commit data...
frames.h Loading commit data...
futex-emulation.cc Loading commit data...
futex-emulation.h Loading commit data...
interrupts-scope.cc Loading commit data...
interrupts-scope.h Loading commit data...
isolate-data.h Loading commit data...
isolate-inl.h Loading commit data...
isolate-utils-inl.h Loading commit data...
isolate-utils.h Loading commit data...
isolate.cc Loading commit data...
isolate.h Loading commit data...
local-isolate-inl.h Loading commit data...
local-isolate.cc Loading commit data...
local-isolate.h Loading commit data...
messages.cc Loading commit data...
messages.h Loading commit data...
microtask-queue.cc Loading commit data...
microtask-queue.h Loading commit data...
pointer-authentication-dummy.h Loading commit data...
pointer-authentication.h Loading commit data...
protectors-inl.h Loading commit data...
protectors.cc Loading commit data...
protectors.h Loading commit data...
runtime-profiler.cc Loading commit data...
runtime-profiler.h Loading commit data...
shared-mutex-guard-if-off-thread.h Loading commit data...
simulator-base.cc Loading commit data...
simulator-base.h Loading commit data...
simulator.h Loading commit data...
stack-guard.cc Loading commit data...
stack-guard.h Loading commit data...
thread-id.cc Loading commit data...
thread-id.h Loading commit data...
thread-local-top.cc Loading commit data...
thread-local-top.h Loading commit data...
v8threads.cc Loading commit data...
v8threads.h Loading commit data...
vm-state-inl.h Loading commit data...
vm-state.h Loading commit data...