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

Side by Side Diff: src/objects.h

Issue 8467010: Refactor embedded pointer visitors for the serializer (Closed)
Patch Set: Created 9 years, 1 month 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
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 7872 matching lines...) Expand 10 before | Expand all | Expand 10 after
7883 virtual void VisitPointer(Object** p) { VisitPointers(p, p + 1); } 7883 virtual void VisitPointer(Object** p) { VisitPointers(p, p + 1); }
7884 7884
7885 // Visit pointer embedded into a code object. 7885 // Visit pointer embedded into a code object.
7886 virtual void VisitEmbeddedPointer(RelocInfo* rinfo); 7886 virtual void VisitEmbeddedPointer(RelocInfo* rinfo);
7887 7887
7888 // Visits a contiguous arrays of external references (references to the C++ 7888 // Visits a contiguous arrays of external references (references to the C++
7889 // heap) in the half-open range [start, end). Any or all of the values 7889 // heap) in the half-open range [start, end). Any or all of the values
7890 // may be modified on return. 7890 // may be modified on return.
7891 virtual void VisitExternalReferences(Address* start, Address* end) {} 7891 virtual void VisitExternalReferences(Address* start, Address* end) {}
7892 7892
7893 virtual void VisitExternalReference(RelocInfo* rinfo);
7894
7893 inline void VisitExternalReference(Address* p) { 7895 inline void VisitExternalReference(Address* p) {
7894 VisitExternalReferences(p, p + 1); 7896 VisitExternalReferences(p, p + 1);
7895 } 7897 }
7896 7898
7897 // Visits a handle that has an embedder-assigned class ID. 7899 // Visits a handle that has an embedder-assigned class ID.
7898 virtual void VisitEmbedderReference(Object** p, uint16_t class_id) {} 7900 virtual void VisitEmbedderReference(Object** p, uint16_t class_id) {}
7899 7901
7900 #ifdef DEBUG 7902 #ifdef DEBUG
7901 // Intended for serialization/deserialization checking: insert, or 7903 // Intended for serialization/deserialization checking: insert, or
7902 // check for the presence of, a tag at this position in the stream. 7904 // check for the presence of, a tag at this position in the stream.
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
7938 } else { 7940 } else {
7939 value &= ~(1 << bit_position); 7941 value &= ~(1 << bit_position);
7940 } 7942 }
7941 return value; 7943 return value;
7942 } 7944 }
7943 }; 7945 };
7944 7946
7945 } } // namespace v8::internal 7947 } } // namespace v8::internal
7946 7948
7947 #endif // V8_OBJECTS_H_ 7949 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/mark-compact.cc ('k') | src/objects.cc » ('j') | src/objects.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698