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

Issue 1280483002: [turbofan] Debug-time helpers for regalloc data structures (Closed)

Created:
5 years, 4 months ago by Mircea Trofin
Modified:
5 years, 4 months ago
Reviewers:
Benedikt Meurer, Jarin
CC:
v8-dev, Jim Stichnoth, jvoung (off chromium)
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

When working on the register allocator, I often need to introspect the various components of the model - e.g. InstructionSequence, Instruction, LiveRange, etc. A pretty printer would help. While we have a suite of operator<< defined for these types, turns out that using them at debug time is close to impossible - gdb has poor (or convoluted) support for instantiating structures (e.g. OFStream, PrintableInstructionSequence, etc), and calling operator<< with pass-by-reference semantics. I explored gdb macros, but hit an issue quite early with instantiating and initializing an OFStream - "virtual baseclass botch". Currently, I have a side-file that I include (and then remove before publishing CLs), which defines wrappers to the above operator<< APIs, but this is becoming quite awkward, and I believe the functionality to be quite useful to anyone working in this (regalloc) area, so it's worth having something better than local side-files. The gdb path seems overly-twisted for the problem at hand, and I've noticed elsewhere (e.g. Object) the presence of Print APIs - hence this change. BUG= Committed: https://crrev.com/ee005fbb8112d8ee55b4d139a5b1996cede1ea5f Cr-Commit-Position: refs/heads/master@{#30039}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+57 lines, -0 lines) Patch
M src/compiler/register-allocator.h View 1 chunk +6 lines, -0 lines 0 comments Download
M src/compiler/register-allocator.cc View 1 chunk +51 lines, -0 lines 0 comments Download

Messages

Total messages: 7 (2 generated)
Mircea Trofin
Re-opening the topic of pretty printers for regalloc data structures at debug time.
5 years, 4 months ago (2015-08-05 23:15:03 UTC) #2
Jarin
lgtm
5 years, 4 months ago (2015-08-06 05:47:28 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1280483002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1280483002/1
5 years, 4 months ago (2015-08-06 06:13:53 UTC) #5
commit-bot: I haz the power
Committed patchset #1 (id:1)
5 years, 4 months ago (2015-08-06 06:15:27 UTC) #6
commit-bot: I haz the power
5 years, 4 months ago (2015-08-06 06:15:43 UTC) #7
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/ee005fbb8112d8ee55b4d139a5b1996cede1ea5f
Cr-Commit-Position: refs/heads/master@{#30039}

Powered by Google App Engine
This is Rietveld 408576698