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

Side by Side Diff: tools/tickprocessor.js

Issue 638633002: Tick processor: Print C++ entry points (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: rebased Created 6 years, 2 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
« no previous file with comments | « tools/profile.js ('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 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
478 this.printHeader('Summary'); 478 this.printHeader('Summary');
479 this.printLine('JavaScript', jsTicks, totalTicks, nonLibraryTicks); 479 this.printLine('JavaScript', jsTicks, totalTicks, nonLibraryTicks);
480 this.printLine('C++', cppTicks, totalTicks, nonLibraryTicks); 480 this.printLine('C++', cppTicks, totalTicks, nonLibraryTicks);
481 this.printLine('GC', this.ticks_.gc, totalTicks, nonLibraryTicks); 481 this.printLine('GC', this.ticks_.gc, totalTicks, nonLibraryTicks);
482 this.printLine('Shared libraries', libraryTicks, totalTicks, null); 482 this.printLine('Shared libraries', libraryTicks, totalTicks, null);
483 if (!this.ignoreUnknown_ && this.ticks_.unaccounted > 0) { 483 if (!this.ignoreUnknown_ && this.ticks_.unaccounted > 0) {
484 this.printLine('Unaccounted', this.ticks_.unaccounted, 484 this.printLine('Unaccounted', this.ticks_.unaccounted,
485 this.ticks_.total, null); 485 this.ticks_.total, null);
486 } 486 }
487 487
488 print('\n [C++ entry points]:');
489 print(' ticks cpp total name');
490 var c_entry_functions = this.profile_.getCEntryProfile();
491 var total_c_entry = c_entry_functions[0].ticks;
492 for (var i = 1; i < c_entry_functions.length; i++) {
493 c = c_entry_functions[i];
494 this.printLine(c.name, c.ticks, total_c_entry, totalTicks);
495 }
496
488 this.printHeavyProfHeader(); 497 this.printHeavyProfHeader();
489 var heavyProfile = this.profile_.getBottomUpProfile(); 498 var heavyProfile = this.profile_.getBottomUpProfile();
490 var heavyView = this.viewBuilder_.buildView(heavyProfile); 499 var heavyView = this.viewBuilder_.buildView(heavyProfile);
491 // To show the same percentages as in the flat profile. 500 // To show the same percentages as in the flat profile.
492 heavyView.head.totalTime = totalTicks; 501 heavyView.head.totalTime = totalTicks;
493 // Sort by total time, desc, then by name, desc. 502 // Sort by total time, desc, then by name, desc.
494 heavyView.sort(function(rec1, rec2) { 503 heavyView.sort(function(rec1, rec2) {
495 return rec2.totalTime - rec1.totalTime || 504 return rec2.totalTime - rec1.totalTime ||
496 (rec2.internalFuncName < rec1.internalFuncName ? -1 : 1); }); 505 (rec2.internalFuncName < rec1.internalFuncName ? -1 : 1); });
497 this.printHeavyProfile(heavyView.head.children); 506 this.printHeavyProfile(heavyView.head.children);
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after
944 for (var synArg in this.argsDispatch_) { 953 for (var synArg in this.argsDispatch_) {
945 if (arg !== synArg && dispatch === this.argsDispatch_[synArg]) { 954 if (arg !== synArg && dispatch === this.argsDispatch_[synArg]) {
946 synonims.push(synArg); 955 synonims.push(synArg);
947 delete this.argsDispatch_[synArg]; 956 delete this.argsDispatch_[synArg];
948 } 957 }
949 } 958 }
950 print(' ' + padRight(synonims.join(', '), 20) + dispatch[2]); 959 print(' ' + padRight(synonims.join(', '), 20) + dispatch[2]);
951 } 960 }
952 quit(2); 961 quit(2);
953 }; 962 };
OLDNEW
« no previous file with comments | « tools/profile.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698