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

Side by Side Diff: src/objects.h

Issue 1108013003: Introduce --zap-cpp-pointers (off by default) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fixes Created 3 years, 7 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
« no previous file with comments | « src/isolate.h ('k') | src/property-descriptor.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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 #ifndef V8_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 #include <memory> 9 #include <memory>
10 10
(...skipping 8705 matching lines...) Expand 10 before | Expand all | Expand 10 after
8716 8716
8717 static void PostGarbageCollectionProcessing(Isolate* isolate); 8717 static void PostGarbageCollectionProcessing(Isolate* isolate);
8718 static int ArchiveSpacePerThread(); 8718 static int ArchiveSpacePerThread();
8719 static char* ArchiveState(Isolate* isolate, char* to); 8719 static char* ArchiveState(Isolate* isolate, char* to);
8720 static char* RestoreState(Isolate* isolate, char* from); 8720 static char* RestoreState(Isolate* isolate, char* from);
8721 static void Iterate(Isolate* isolate, RootVisitor* v); 8721 static void Iterate(Isolate* isolate, RootVisitor* v);
8722 static void Iterate(RootVisitor* v, Relocatable* top); 8722 static void Iterate(RootVisitor* v, Relocatable* top);
8723 static char* Iterate(RootVisitor* v, char* t); 8723 static char* Iterate(RootVisitor* v, char* t);
8724 8724
8725 private: 8725 private:
8726 friend class HeapPointerZapper; // For |prev_|.
8726 Isolate* isolate_; 8727 Isolate* isolate_;
8727 Relocatable* prev_; 8728 Relocatable* prev_;
8728 }; 8729 };
8729 8730
8730 8731
8731 // A flat string reader provides random access to the contents of a 8732 // A flat string reader provides random access to the contents of a
8732 // string independent of the character width of the string. The handle 8733 // string independent of the character width of the string. The handle
8733 // must be valid as long as the reader is being used. 8734 // must be valid as long as the reader is being used.
8734 class FlatStringReader : public Relocatable { 8735 class FlatStringReader : public Relocatable {
8735 public: 8736 public:
8736 FlatStringReader(Isolate* isolate, Handle<String> str); 8737 FlatStringReader(Isolate* isolate, Handle<String> str);
8737 FlatStringReader(Isolate* isolate, Vector<const char> input); 8738 FlatStringReader(Isolate* isolate, Vector<const char> input);
8738 void PostGarbageCollection(); 8739 void PostGarbageCollection() override;
8739 inline uc32 Get(int index); 8740 inline uc32 Get(int index);
8740 template <typename Char> 8741 template <typename Char>
8741 inline Char Get(int index); 8742 inline Char Get(int index);
8742 int length() { return length_; } 8743 int length() { return length_; }
8743 private: 8744 private:
8744 String** str_; 8745 String** str_;
8745 bool is_one_byte_; 8746 bool is_one_byte_;
8746 int length_; 8747 int length_;
8747 const void* start_; 8748 const void* start_;
8748 }; 8749 };
(...skipping 1487 matching lines...) Expand 10 before | Expand all | Expand 10 after
10236 } 10237 }
10237 }; 10238 };
10238 10239
10239 10240
10240 } // NOLINT, false-positive due to second-order macros. 10241 } // NOLINT, false-positive due to second-order macros.
10241 } // NOLINT, false-positive due to second-order macros. 10242 } // NOLINT, false-positive due to second-order macros.
10242 10243
10243 #include "src/objects/object-macros-undef.h" 10244 #include "src/objects/object-macros-undef.h"
10244 10245
10245 #endif // V8_OBJECTS_H_ 10246 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | src/property-descriptor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698