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

Side by Side Diff: src/heap.cc

Issue 16953002: Trace amount of external memory with --trace-gc-verbose. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 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 | « no previous file | 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 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 ", committed: %6" V8_PTR_PREFIX "d KB\n", 400 ", committed: %6" V8_PTR_PREFIX "d KB\n",
401 lo_space_->SizeOfObjects() / KB, 401 lo_space_->SizeOfObjects() / KB,
402 lo_space_->Available() / KB, 402 lo_space_->Available() / KB,
403 lo_space_->CommittedMemory() / KB); 403 lo_space_->CommittedMemory() / KB);
404 PrintPID("All spaces, used: %6" V8_PTR_PREFIX "d KB" 404 PrintPID("All spaces, used: %6" V8_PTR_PREFIX "d KB"
405 ", available: %6" V8_PTR_PREFIX "d KB" 405 ", available: %6" V8_PTR_PREFIX "d KB"
406 ", committed: %6" V8_PTR_PREFIX "d KB\n", 406 ", committed: %6" V8_PTR_PREFIX "d KB\n",
407 this->SizeOfObjects() / KB, 407 this->SizeOfObjects() / KB,
408 this->Available() / KB, 408 this->Available() / KB,
409 this->CommittedMemory() / KB); 409 this->CommittedMemory() / KB);
410 PrintPID("External memory reported: %6" V8_PTR_PREFIX "d KB\n",
411 amount_of_external_allocated_memory_ / KB);
410 PrintPID("Total time spent in GC : %.1f ms\n", total_gc_time_ms_); 412 PrintPID("Total time spent in GC : %.1f ms\n", total_gc_time_ms_);
411 } 413 }
412 414
413 415
414 // TODO(1238405): Combine the infrastructure for --heap-stats and 416 // TODO(1238405): Combine the infrastructure for --heap-stats and
415 // --log-gc to avoid the complicated preprocessor and flag testing. 417 // --log-gc to avoid the complicated preprocessor and flag testing.
416 void Heap::ReportStatisticsAfterGC() { 418 void Heap::ReportStatisticsAfterGC() {
417 // Similar to the before GC, we use some complicated logic to ensure that 419 // Similar to the before GC, we use some complicated logic to ensure that
418 // NewSpace statistics are logged exactly once when --log-gc is turned on. 420 // NewSpace statistics are logged exactly once when --log-gc is turned on.
419 #if defined(DEBUG) 421 #if defined(DEBUG)
(...skipping 7648 matching lines...) Expand 10 before | Expand all | Expand 10 after
8068 if (FLAG_parallel_recompilation) { 8070 if (FLAG_parallel_recompilation) {
8069 heap_->relocation_mutex_->Lock(); 8071 heap_->relocation_mutex_->Lock();
8070 #ifdef DEBUG 8072 #ifdef DEBUG
8071 heap_->relocation_mutex_locked_by_optimizer_thread_ = 8073 heap_->relocation_mutex_locked_by_optimizer_thread_ =
8072 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread(); 8074 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread();
8073 #endif // DEBUG 8075 #endif // DEBUG
8074 } 8076 }
8075 } 8077 }
8076 8078
8077 } } // namespace v8::internal 8079 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698