| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/heap-snapshot-generator-inl.h" | 7 #include "src/heap-snapshot-generator-inl.h" |
| 8 | 8 |
| 9 #include "src/allocation-tracker.h" | 9 #include "src/allocation-tracker.h" |
| 10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
| (...skipping 1876 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1887 obj->Iterate(&refs_extractor); | 1887 obj->Iterate(&refs_extractor); |
| 1888 } | 1888 } |
| 1889 | 1889 |
| 1890 if (!progress_->ProgressReport(false)) interrupted = true; | 1890 if (!progress_->ProgressReport(false)) interrupted = true; |
| 1891 } | 1891 } |
| 1892 return interrupted; | 1892 return interrupted; |
| 1893 } | 1893 } |
| 1894 | 1894 |
| 1895 | 1895 |
| 1896 bool V8HeapExplorer::IsEssentialObject(Object* object) { | 1896 bool V8HeapExplorer::IsEssentialObject(Object* object) { |
| 1897 return object->IsHeapObject() | 1897 return object->IsHeapObject() && !object->IsOddball() && |
| 1898 && !object->IsOddball() | 1898 object != heap_->empty_byte_array() && |
| 1899 && object != heap_->empty_byte_array() | 1899 object != heap_->empty_bytecode_array() && |
| 1900 && object != heap_->empty_fixed_array() | 1900 object != heap_->empty_fixed_array() && |
| 1901 && object != heap_->empty_descriptor_array() | 1901 object != heap_->empty_descriptor_array() && |
| 1902 && object != heap_->fixed_array_map() | 1902 object != heap_->fixed_array_map() && object != heap_->cell_map() && |
| 1903 && object != heap_->cell_map() | 1903 object != heap_->global_property_cell_map() && |
| 1904 && object != heap_->global_property_cell_map() | 1904 object != heap_->shared_function_info_map() && |
| 1905 && object != heap_->shared_function_info_map() | 1905 object != heap_->free_space_map() && |
| 1906 && object != heap_->free_space_map() | 1906 object != heap_->one_pointer_filler_map() && |
| 1907 && object != heap_->one_pointer_filler_map() | 1907 object != heap_->two_pointer_filler_map(); |
| 1908 && object != heap_->two_pointer_filler_map(); | |
| 1909 } | 1908 } |
| 1910 | 1909 |
| 1911 | 1910 |
| 1912 void V8HeapExplorer::SetContextReference(HeapObject* parent_obj, | 1911 void V8HeapExplorer::SetContextReference(HeapObject* parent_obj, |
| 1913 int parent_entry, | 1912 int parent_entry, |
| 1914 String* reference_name, | 1913 String* reference_name, |
| 1915 Object* child_obj, | 1914 Object* child_obj, |
| 1916 int field_offset) { | 1915 int field_offset) { |
| 1917 DCHECK(parent_entry == GetEntry(parent_obj)->index()); | 1916 DCHECK(parent_entry == GetEntry(parent_obj)->index()); |
| 1918 HeapEntry* child_entry = GetEntry(child_obj); | 1917 HeapEntry* child_entry = GetEntry(child_obj); |
| (...skipping 1259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3178 for (int i = 1; i < sorted_strings.length(); ++i) { | 3177 for (int i = 1; i < sorted_strings.length(); ++i) { |
| 3179 writer_->AddCharacter(','); | 3178 writer_->AddCharacter(','); |
| 3180 SerializeString(sorted_strings[i]); | 3179 SerializeString(sorted_strings[i]); |
| 3181 if (writer_->aborted()) return; | 3180 if (writer_->aborted()) return; |
| 3182 } | 3181 } |
| 3183 } | 3182 } |
| 3184 | 3183 |
| 3185 | 3184 |
| 3186 } // namespace internal | 3185 } // namespace internal |
| 3187 } // namespace v8 | 3186 } // namespace v8 |
| OLD | NEW |