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

Side by Side Diff: src/profile-generator.cc

Issue 11140023: Merged r12731 into trunk branch. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 8 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 | « no previous file | src/version.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 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 3076 matching lines...) Expand 10 before | Expand all | Expand 10 after
3087 // full GC is reachable from the root when computing dominators. 3087 // full GC is reachable from the root when computing dominators.
3088 // This is not true for weakly reachable objects. 3088 // This is not true for weakly reachable objects.
3089 // As a temporary solution we call GC twice. 3089 // As a temporary solution we call GC twice.
3090 Isolate::Current()->heap()->CollectAllGarbage( 3090 Isolate::Current()->heap()->CollectAllGarbage(
3091 Heap::kMakeHeapIterableMask, 3091 Heap::kMakeHeapIterableMask,
3092 "HeapSnapshotGenerator::GenerateSnapshot"); 3092 "HeapSnapshotGenerator::GenerateSnapshot");
3093 Isolate::Current()->heap()->CollectAllGarbage( 3093 Isolate::Current()->heap()->CollectAllGarbage(
3094 Heap::kMakeHeapIterableMask, 3094 Heap::kMakeHeapIterableMask,
3095 "HeapSnapshotGenerator::GenerateSnapshot"); 3095 "HeapSnapshotGenerator::GenerateSnapshot");
3096 3096
3097 #ifdef DEBUG 3097 #ifdef VERIFY_HEAP
3098 Heap* debug_heap = Isolate::Current()->heap(); 3098 Heap* debug_heap = Isolate::Current()->heap();
3099 ASSERT(!debug_heap->old_data_space()->was_swept_conservatively()); 3099 CHECK(!debug_heap->old_data_space()->was_swept_conservatively());
3100 ASSERT(!debug_heap->old_pointer_space()->was_swept_conservatively()); 3100 CHECK(!debug_heap->old_pointer_space()->was_swept_conservatively());
3101 ASSERT(!debug_heap->code_space()->was_swept_conservatively()); 3101 CHECK(!debug_heap->code_space()->was_swept_conservatively());
3102 ASSERT(!debug_heap->cell_space()->was_swept_conservatively()); 3102 CHECK(!debug_heap->cell_space()->was_swept_conservatively());
3103 ASSERT(!debug_heap->map_space()->was_swept_conservatively()); 3103 CHECK(!debug_heap->map_space()->was_swept_conservatively());
3104 #endif 3104 #endif
3105 3105
3106 // The following code uses heap iterators, so we want the heap to be 3106 // The following code uses heap iterators, so we want the heap to be
3107 // stable. It should follow TagGlobalObjects as that can allocate. 3107 // stable. It should follow TagGlobalObjects as that can allocate.
3108 AssertNoAllocation no_alloc; 3108 AssertNoAllocation no_alloc;
3109 3109
3110 #ifdef VERIFY_HEAP 3110 #ifdef VERIFY_HEAP
3111 debug_heap->Verify(); 3111 debug_heap->Verify();
3112 #endif 3112 #endif
3113 3113
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after
3578 3578
3579 3579
3580 void HeapSnapshotJSONSerializer::SortHashMap( 3580 void HeapSnapshotJSONSerializer::SortHashMap(
3581 HashMap* map, List<HashMap::Entry*>* sorted_entries) { 3581 HashMap* map, List<HashMap::Entry*>* sorted_entries) {
3582 for (HashMap::Entry* p = map->Start(); p != NULL; p = map->Next(p)) 3582 for (HashMap::Entry* p = map->Start(); p != NULL; p = map->Next(p))
3583 sorted_entries->Add(p); 3583 sorted_entries->Add(p);
3584 sorted_entries->Sort(SortUsingEntryValue); 3584 sorted_entries->Sort(SortUsingEntryValue);
3585 } 3585 }
3586 3586
3587 } } // namespace v8::internal 3587 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/version.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698