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

Side by Side Diff: src/serialize.h

Issue 23468021: move HEAP to /test (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 3 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/scopeinfo.cc ('k') | src/serialize.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 602 matching lines...) Expand 10 before | Expand all | Expand 10 after
613 virtual int PartialSnapshotCacheIndex(HeapObject* o); 613 virtual int PartialSnapshotCacheIndex(HeapObject* o);
614 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { 614 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) {
615 // Scripts should be referred only through shared function infos. We can't 615 // Scripts should be referred only through shared function infos. We can't
616 // allow them to be part of the partial snapshot because they contain a 616 // allow them to be part of the partial snapshot because they contain a
617 // unique ID, and deserializing several partial snapshots containing script 617 // unique ID, and deserializing several partial snapshots containing script
618 // would cause dupes. 618 // would cause dupes.
619 ASSERT(!o->IsScript()); 619 ASSERT(!o->IsScript());
620 return o->IsName() || o->IsSharedFunctionInfo() || 620 return o->IsName() || o->IsSharedFunctionInfo() ||
621 o->IsHeapNumber() || o->IsCode() || 621 o->IsHeapNumber() || o->IsCode() ||
622 o->IsScopeInfo() || 622 o->IsScopeInfo() ||
623 o->map() == HEAP->fixed_cow_array_map(); 623 o->map() ==
624 startup_serializer_->isolate()->heap()->fixed_cow_array_map();
624 } 625 }
625 626
626 private: 627 private:
627 Serializer* startup_serializer_; 628 Serializer* startup_serializer_;
628 DISALLOW_COPY_AND_ASSIGN(PartialSerializer); 629 DISALLOW_COPY_AND_ASSIGN(PartialSerializer);
629 }; 630 };
630 631
631 632
632 class StartupSerializer : public Serializer { 633 class StartupSerializer : public Serializer {
633 public: 634 public:
(...skipping 24 matching lines...) Expand all
658 private: 659 private:
659 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { 660 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) {
660 return false; 661 return false;
661 } 662 }
662 }; 663 };
663 664
664 665
665 } } // namespace v8::internal 666 } } // namespace v8::internal
666 667
667 #endif // V8_SERIALIZE_H_ 668 #endif // V8_SERIALIZE_H_
OLDNEW
« no previous file with comments | « src/scopeinfo.cc ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698