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

Issue 6685084: Add support for CPU and heap profiles deletion. (Closed)

Created:
9 years, 9 months ago by mnaganov (inactive)
Modified:
9 years, 7 months ago
Reviewers:
Vitaly Repeshko
CC:
v8-dev
Visibility:
Public.

Description

Add support for CPU and heap profiles deletion. R=vitalyr@chromium.org BUG=none TEST=none Committed: http://code.google.com/p/v8/source/detail?r=7308

Patch Set 1 #

Patch Set 2 : Implemente per-profile deletion #

Total comments: 16
Unified diffs Side-by-side diffs Delta from patch set Stats (+395 lines, -28 lines) Patch
M include/v8-profiler.h View 1 5 chunks +31 lines, -1 line 6 comments Download
M src/api.cc View 1 4 chunks +40 lines, -0 lines 2 comments Download
M src/cpu-profiler.h View 1 2 chunks +5 lines, -0 lines 0 comments Download
M src/cpu-profiler.cc View 1 3 chunks +44 lines, -15 lines 0 comments Download
M src/heap-profiler.h View 1 2 chunks +2 lines, -0 lines 0 comments Download
M src/heap-profiler.cc View 1 2 chunks +14 lines, -0 lines 0 comments Download
M src/profile-generator.h View 1 5 chunks +6 lines, -0 lines 0 comments Download
M src/profile-generator.cc View 1 7 chunks +64 lines, -12 lines 4 comments Download
M test/cctest/test-cpu-profiler.cc View 1 2 chunks +131 lines, -0 lines 4 comments Download
M test/cctest/test-heap-profiler.cc View 1 1 chunk +58 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
mnaganov (inactive)
9 years, 9 months ago (2011-03-18 10:07:24 UTC) #1
mnaganov (inactive)
This is mainly needed for heap snapshots, as they consume significant amounts of memory on ...
9 years, 9 months ago (2011-03-22 08:20:40 UTC) #2
Vitaly Repeshko
LGTM http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h File include/v8-profiler.h (right): http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h#newcode143 include/v8-profiler.h:143: void Delete() const; "const" looks weird here. http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h#newcode392 ...
9 years, 9 months ago (2011-03-22 14:30:36 UTC) #3
mnaganov (inactive)
9 years, 9 months ago (2011-03-22 16:03:09 UTC) #4
http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h
File include/v8-profiler.h (right):

http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h#newcod...
include/v8-profiler.h:143: void Delete() const;
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> "const" looks weird here.

Hmm, maybe. I added 'const' because all methods return const pointers (to
emphasize that embedder can't do much with them). So calling a non-const Delete
will require embedder to do a const_cast. But probably it's OK, as it attracts
more attention to calls to this method.

http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h#newcod...
include/v8-profiler.h:392: void Delete() const;
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> Ditto.

Done.

http://codereview.chromium.org/6685084/diff/3001/include/v8-profiler.h#newcod...
include/v8-profiler.h:496: * are freed by calling the Delete class function.
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> Accidental edit?

Ah, yes. Massive renaming. Reverted.

http://codereview.chromium.org/6685084/diff/3001/src/api.cc
File src/api.cc (right):

http://codereview.chromium.org/6685084/diff/3001/src/api.cc#newcode5084
src/api.cc:5084: const_cast<i::CpuProfile*>(
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> Dropping "const" will allow to avoid this const_cast.

Done.

http://codereview.chromium.org/6685084/diff/3001/src/profile-generator.cc
File src/profile-generator.cc (right):

http://codereview.chromium.org/6685084/diff/3001/src/profile-generator.cc#new...
src/profile-generator.cc:553: if (*list_ptr) {
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> nit: Use explicit != NULL comparison.

Done.

http://codereview.chromium.org/6685084/diff/3001/src/profile-generator.cc#new...
src/profile-generator.cc:673: p;
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> != NULL

Done.

http://codereview.chromium.org/6685084/diff/3001/test/cctest/test-cpu-profile...
File test/cctest/test-cpu-profiler.cc (right):

http://codereview.chromium.org/6685084/diff/3001/test/cctest/test-cpu-profile...
test/cctest/test-cpu-profiler.cc:287: CHECK_EQ(NULL,
v8::CpuProfiler::FindProfile(uid1));
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> It'd be nice to test this again later to make sure it won't reappear.

Added a couple of times more after.

http://codereview.chromium.org/6685084/diff/3001/test/cctest/test-cpu-profile...
test/cctest/test-cpu-profiler.cc:307: CHECK_EQ(NULL,
v8::CpuProfiler::FindProfile(uid2));
On 2011/03/22 14:30:36, Vitaly Repeshko wrote:
> Same here.

Done.

Powered by Google App Engine
This is Rietveld 408576698