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

Issue 9361026: Count-based profiling for primitive functions (hidden behind a flag) (Closed)

Created:
8 years, 10 months ago by Jakob Kummerow
Modified:
8 years, 10 months ago
Reviewers:
Erik Corry
CC:
v8-dev
Visibility:
Public.

Description

Count-based profiling for primitive functions (hidden behind a flag) Committed: https://code.google.com/p/v8/source/detail?r=10657

Patch Set 1 #

Total comments: 22

Patch Set 2 : addressed comments #

Total comments: 8

Patch Set 3 : more comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+243 lines, -55 lines) Patch
M src/arm/full-codegen-arm.cc View 1 2 2 chunks +22 lines, -1 line 0 comments Download
M src/ast.h View 1 1 chunk +0 lines, -2 lines 0 comments Download
M src/ast.cc View 1 1 chunk +0 lines, -5 lines 0 comments Download
M src/compiler.h View 1 2 chunks +6 lines, -0 lines 0 comments Download
M src/compiler.cc View 1 2 2 chunks +13 lines, -0 lines 0 comments Download
M src/flag-definitions.h View 1 chunk +3 lines, -0 lines 0 comments Download
M src/full-codegen.cc View 1 2 chunks +4 lines, -1 line 0 comments Download
M src/heap.cc View 2 chunks +4 lines, -1 line 0 comments Download
M src/ia32/full-codegen-ia32.cc View 1 2 2 chunks +21 lines, -1 line 0 comments Download
M src/ic.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M src/ic.cc View 1 2 1 chunk +25 lines, -0 lines 0 comments Download
M src/ic-inl.h View 1 2 3 chunks +4 lines, -1 line 0 comments Download
M src/mark-compact.cc View 2 chunks +9 lines, -5 lines 0 comments Download
M src/objects.h View 3 chunks +7 lines, -2 lines 0 comments Download
M src/objects-inl.h View 1 chunk +2 lines, -0 lines 0 comments Download
M src/runtime.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M src/runtime-profiler.h View 1 4 chunks +15 lines, -2 lines 0 comments Download
M src/runtime-profiler.cc View 1 8 chunks +83 lines, -33 lines 0 comments Download
M src/x64/full-codegen-x64.cc View 1 2 2 chunks +22 lines, -1 line 0 comments Download

Messages

Total messages: 6 (0 generated)
Jakob Kummerow
Please take a look. This is the first CL in a series towards having count-based ...
8 years, 10 months ago (2012-02-08 11:51:40 UTC) #1
Erik Corry
The patch looks incomplete. Where is the ShouldSelfOptimize function? https://chromiumcodereview.appspot.com/9361026/diff/1/src/ia32/full-codegen-ia32.cc File src/ia32/full-codegen-ia32.cc (right): https://chromiumcodereview.appspot.com/9361026/diff/1/src/ia32/full-codegen-ia32.cc#newcode135 src/ia32/full-codegen-ia32.cc:135: ...
8 years, 10 months ago (2012-02-08 14:09:23 UTC) #2
Erik Corry
https://chromiumcodereview.appspot.com/9361026/diff/1/src/full-codegen.cc File src/full-codegen.cc (right): https://chromiumcodereview.appspot.com/9361026/diff/1/src/full-codegen.cc#newcode300 src/full-codegen.cc:300: if (FLAG_counting_profiler) { I suggest this condition could be ...
8 years, 10 months ago (2012-02-08 14:13:29 UTC) #3
Jakob Kummerow
Thank you for the review. I have uploaded a new patch set. On 2012/02/08 14:09:23, ...
8 years, 10 months ago (2012-02-08 15:24:07 UTC) #4
Erik Corry
LGTM https://chromiumcodereview.appspot.com/9361026/diff/3002/src/arm/full-codegen-arm.cc File src/arm/full-codegen-arm.cc (right): https://chromiumcodereview.appspot.com/9361026/diff/3002/src/arm/full-codegen-arm.cc#newcode144 src/arm/full-codegen-arm.cc:144: // for the SharedFunctionInfo::kCallsUntilPrimitiveOptimization-th time. I think this ...
8 years, 10 months ago (2012-02-09 09:43:33 UTC) #5
Jakob Kummerow
8 years, 10 months ago (2012-02-09 10:13:19 UTC) #6
Comments addressed, landing.

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/arm/full-codegen...
File src/arm/full-codegen-arm.cc (right):

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/arm/full-codegen...
src/arm/full-codegen-arm.cc:144: // for the
SharedFunctionInfo::kCallsUntilPrimitiveOptimization-th time.
On 2012/02/09 09:43:33, Erik Corry wrote:
> I think this comment should be moved into ShouldSelfOptimize, where it
actually
> describes the logic used to make the decision.  Then it is in the right place
> for when we change the heuristic.
> 
> Here we should have a more generic comment like:
> 
> // We can optionally optimize based on counters rather than statistical
> sampling.

Done.

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/arm/full-codegen...
src/arm/full-codegen-arm.cc:146: if (FLAG_trace_opt) {
On 2012/02/09 09:43:33, Erik Corry wrote:
> I think this might be annoyingly verbose, but we can add a trace-opt-verbose
> flag later if we need to.

As discussed, let's leave it for now. We can always remove it later.

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/ic-inl.h
File src/ic-inl.h (right):

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/ic-inl.h#newcode93
src/ic-inl.h:93: target);
On 2012/02/09 09:43:33, Erik Corry wrote:
> Confusing that this is under the counting_profiler flag when it relates to the
> statistically sampling profiler.

As discussed, I'll split the flag in a separate CL.

https://chromiumcodereview.appspot.com/9361026/diff/3002/src/ic-inl.h#newcode94
src/ic-inl.h:94: if (FLAG_counting_profiler) {
On 2012/02/09 09:43:33, Erik Corry wrote:
> This function is getting too beefy for an inline function that is used 5
times. 
> I suggest this part be moved to a helper function in the .cc file.

Done.

Powered by Google App Engine
This is Rietveld 408576698