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

Side by Side Diff: src/log-utils.h

Issue 70013002: Support for the Linux 'perf report' and 'perf annotate' tools. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Remove forgotten printfs. Created 7 years, 1 month 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/log.cc ('K') | « src/log.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 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 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 29 matching lines...) Expand all
40 public: 40 public:
41 // Performs process-wide initialization. 41 // Performs process-wide initialization.
42 void Initialize(const char* log_file_name); 42 void Initialize(const char* log_file_name);
43 43
44 // Disables logging, but preserves acquired resources. 44 // Disables logging, but preserves acquired resources.
45 void stop() { is_stopped_ = true; } 45 void stop() { is_stopped_ = true; }
46 46
47 static bool InitLogAtStart() { 47 static bool InitLogAtStart() {
48 return FLAG_log || FLAG_log_runtime || FLAG_log_api 48 return FLAG_log || FLAG_log_runtime || FLAG_log_api
49 || FLAG_log_code || FLAG_log_gc || FLAG_log_handles || FLAG_log_suspect 49 || FLAG_log_code || FLAG_log_gc || FLAG_log_handles || FLAG_log_suspect
50 || FLAG_log_regexp || FLAG_ll_prof || FLAG_log_internal_timer_events; 50 || FLAG_log_regexp || FLAG_ll_prof || FLAG_perf_basic_prof
51 || FLAG_perf_jit_prof || FLAG_log_internal_timer_events;
51 } 52 }
52 53
53 // Frees all resources acquired in Initialize and Open... functions. 54 // Frees all resources acquired in Initialize and Open... functions.
54 // When a temporary file is used for the log, returns its stream descriptor, 55 // When a temporary file is used for the log, returns its stream descriptor,
55 // leaving the file open. 56 // leaving the file open.
56 FILE* Close(); 57 FILE* Close();
57 58
58 // Returns whether logging is enabled. 59 // Returns whether logging is enabled.
59 bool IsEnabled() { 60 bool IsEnabled() {
60 return !is_stopped_ && output_handle_ != NULL; 61 return !is_stopped_ && output_handle_ != NULL;
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 151
151 Logger* logger_; 152 Logger* logger_;
152 153
153 friend class Logger; 154 friend class Logger;
154 }; 155 };
155 156
156 157
157 } } // namespace v8::internal 158 } } // namespace v8::internal
158 159
159 #endif // V8_LOG_UTILS_H_ 160 #endif // V8_LOG_UTILS_H_
OLDNEW
« src/log.cc ('K') | « src/log.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698