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

Side by Side Diff: src/runtime-profiler.cc

Issue 22926025: Add --trace-hydrogen-filter flag. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: refactored Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« src/compiler.cc ('K') | « src/objects.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 } 120 }
121 *percentage = *ic_total_count > 0 121 *percentage = *ic_total_count > 0
122 ? 100 * *ic_with_type_info_count / *ic_total_count 122 ? 100 * *ic_with_type_info_count / *ic_total_count
123 : 100; 123 : 100;
124 } 124 }
125 125
126 126
127 void RuntimeProfiler::Optimize(JSFunction* function, const char* reason) { 127 void RuntimeProfiler::Optimize(JSFunction* function, const char* reason) {
128 ASSERT(function->IsOptimizable()); 128 ASSERT(function->IsOptimizable());
129 129
130 if (FLAG_trace_opt && function->PassesHydrogenFilter()) { 130 if (FLAG_trace_opt && function->PassesFilter(FLAG_hydrogen_filter)) {
131 PrintF("[marking "); 131 PrintF("[marking ");
132 function->ShortPrint(); 132 function->ShortPrint();
133 PrintF(" for recompilation, reason: %s", reason); 133 PrintF(" for recompilation, reason: %s", reason);
134 if (FLAG_type_info_threshold > 0) { 134 if (FLAG_type_info_threshold > 0) {
135 int typeinfo, total, percentage; 135 int typeinfo, total, percentage;
136 GetICCounts(function->shared()->code(), &typeinfo, &total, &percentage); 136 GetICCounts(function->shared()->code(), &typeinfo, &total, &percentage);
137 PrintF(", ICs with typeinfo: %d/%d (%d%%)", typeinfo, total, percentage); 137 PrintF(", ICs with typeinfo: %d/%d (%d%%)", typeinfo, total, percentage);
138 } 138 }
139 PrintF("]\n"); 139 PrintF("]\n");
140 } 140 }
(...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 436
437 437
438 void RuntimeProfiler::UpdateSamplesAfterCompact(ObjectVisitor* visitor) { 438 void RuntimeProfiler::UpdateSamplesAfterCompact(ObjectVisitor* visitor) {
439 for (int i = 0; i < kSamplerWindowSize; i++) { 439 for (int i = 0; i < kSamplerWindowSize; i++) {
440 visitor->VisitPointer(&sampler_window_[i]); 440 visitor->VisitPointer(&sampler_window_[i]);
441 } 441 }
442 } 442 }
443 443
444 444
445 } } // namespace v8::internal 445 } } // namespace v8::internal
OLDNEW
« src/compiler.cc ('K') | « src/objects.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698