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

Side by Side Diff: src/log.h

Issue 56064: Fixed numerous issues that were causing errors in profiler log processing (Closed)
Patch Set: Updated according to Soeren's comments Created 11 years, 8 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
« no previous file with comments | « no previous file | src/log.cc » ('j') | 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-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 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 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 static void ApiEntryCall(const char* name); 160 static void ApiEntryCall(const char* name);
161 161
162 162
163 // ==== Events logged by --log-code. ==== 163 // ==== Events logged by --log-code. ====
164 // Emits a code create event. 164 // Emits a code create event.
165 static void CodeCreateEvent(const char* tag, Code* code, const char* source); 165 static void CodeCreateEvent(const char* tag, Code* code, const char* source);
166 static void CodeCreateEvent(const char* tag, Code* code, String* name); 166 static void CodeCreateEvent(const char* tag, Code* code, String* name);
167 static void CodeCreateEvent(const char* tag, Code* code, String* name, 167 static void CodeCreateEvent(const char* tag, Code* code, String* name,
168 String* source, int line); 168 String* source, int line);
169 static void CodeCreateEvent(const char* tag, Code* code, int args_count); 169 static void CodeCreateEvent(const char* tag, Code* code, int args_count);
170 // Emits a code create event for a RegExp.
171 static void RegExpCodeCreateEvent(Code* code, String* source);
170 static void CodeAllocateEvent(Code* code, Assembler* assem); 172 static void CodeAllocateEvent(Code* code, Assembler* assem);
171 // Emits a code move event. 173 // Emits a code move event.
172 static void CodeMoveEvent(Address from, Address to); 174 static void CodeMoveEvent(Address from, Address to);
173 // Emits a code delete event. 175 // Emits a code delete event.
174 static void CodeDeleteEvent(Address from); 176 static void CodeDeleteEvent(Address from);
175 // Emits region delimiters 177 // Emits region delimiters
176 static void BeginCodeRegionEvent(CodeRegion* region, 178 static void BeginCodeRegionEvent(CodeRegion* region,
177 Assembler* masm, 179 Assembler* masm,
178 const char* name); 180 const char* name);
179 static void EndCodeRegionEvent(CodeRegion* region, Assembler* masm); 181 static void EndCodeRegionEvent(CodeRegion* region, Assembler* masm);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 222
221 // Emits a profiler tick event. Used by the profiler thread. 223 // Emits a profiler tick event. Used by the profiler thread.
222 static void TickEvent(TickSample* sample, bool overflow); 224 static void TickEvent(TickSample* sample, bool overflow);
223 225
224 static void ApiEvent(const char* name, ...); 226 static void ApiEvent(const char* name, ...);
225 227
226 // Logs a StringEvent regardless of whether FLAG_log is true. 228 // Logs a StringEvent regardless of whether FLAG_log is true.
227 static void UncheckedStringEvent(const char* name, const char* value); 229 static void UncheckedStringEvent(const char* name, const char* value);
228 230
229 // Size of buffer used for formatting log messages. 231 // Size of buffer used for formatting log messages.
230 static const int kMessageBufferSize = 256; 232 static const int kMessageBufferSize = 2048;
231 233
232 // Buffer used for formatting log messages. This is a singleton buffer and 234 // Buffer used for formatting log messages. This is a singleton buffer and
233 // mutex_ should be acquired before using it. 235 // mutex_ should be acquired before using it.
234 static char* message_buffer_; 236 static char* message_buffer_;
235 237
236 // When logging is active, logfile_ refers the file events are written to. 238 // When logging is active, logfile_ refers the file events are written to.
237 // mutex_ should be acquired before using logfile_. 239 // mutex_ should be acquired before using logfile_.
238 static FILE* logfile_; 240 static FILE* logfile_;
239 241
240 // The sampler used by the profiler and the sliding state window. 242 // The sampler used by the profiler and the sliding state window.
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 void Trace(TickSample* sample); 283 void Trace(TickSample* sample);
282 private: 284 private:
283 285
284 unsigned int low_stack_bound_; 286 unsigned int low_stack_bound_;
285 }; 287 };
286 288
287 289
288 } } // namespace v8::internal 290 } } // namespace v8::internal
289 291
290 #endif // V8_LOG_H_ 292 #endif // V8_LOG_H_
OLDNEW
« no previous file with comments | « no previous file | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698