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

Side by Side Diff: src/heap.cc

Issue 554131: Enable assertions and debugging code in the release... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/issue555/
Patch Set: Created 10 years, 10 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 | « src/flag-definitions.h ('k') | src/objects.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 2009 the V8 project authors. All rights reserved. 1 // Copyright 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 3922 matching lines...) Expand 10 before | Expand all | Expand 10 after
3933 object_stack.RemoveLast(); 3933 object_stack.RemoveLast();
3934 } 3934 }
3935 3935
3936 3936
3937 static void UnmarkObjectRecursively(Object** p); 3937 static void UnmarkObjectRecursively(Object** p);
3938 class UnmarkObjectVisitor : public ObjectVisitor { 3938 class UnmarkObjectVisitor : public ObjectVisitor {
3939 public: 3939 public:
3940 void VisitPointers(Object** start, Object** end) { 3940 void VisitPointers(Object** start, Object** end) {
3941 // Copy all HeapObject pointers in [start, end) 3941 // Copy all HeapObject pointers in [start, end)
3942 for (Object** p = start; p < end; p++) { 3942 for (Object** p = start; p < end; p++) {
3943 if ((*p)->IsHeapObject()) 3943 if ((*p)->IsHeapObject()) {
3944 UnmarkObjectRecursively(p); 3944 UnmarkObjectRecursively(p);
3945 }
3945 } 3946 }
3946 } 3947 }
3947 }; 3948 };
3948 3949
3949 static UnmarkObjectVisitor unmark_visitor; 3950 static UnmarkObjectVisitor unmark_visitor;
3950 3951
3951 static void UnmarkObjectRecursively(Object** p) { 3952 static void UnmarkObjectRecursively(Object** p) {
3952 if (!(*p)->IsHeapObject()) return; 3953 if (!(*p)->IsHeapObject()) return;
3953 3954
3954 HeapObject* obj = HeapObject::cast(*p); 3955 HeapObject* obj = HeapObject::cast(*p);
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
4195 void ExternalStringTable::TearDown() { 4196 void ExternalStringTable::TearDown() {
4196 new_space_strings_.Free(); 4197 new_space_strings_.Free();
4197 old_space_strings_.Free(); 4198 old_space_strings_.Free();
4198 } 4199 }
4199 4200
4200 4201
4201 List<Object*> ExternalStringTable::new_space_strings_; 4202 List<Object*> ExternalStringTable::new_space_strings_;
4202 List<Object*> ExternalStringTable::old_space_strings_; 4203 List<Object*> ExternalStringTable::old_space_strings_;
4203 4204
4204 } } // namespace v8::internal 4205 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/flag-definitions.h ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698