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

Side by Side Diff: src/heap.h

Issue 40063002: Bookkeeping for allocation site pretenuring (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase built on site fields in another CL. Created 7 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 | Annotate | Revision Log
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 1438 matching lines...) Expand 10 before | Expand all | Expand 10 after
1449 void TracePathToGlobal(); 1449 void TracePathToGlobal();
1450 #endif 1450 #endif
1451 1451
1452 // Callback function passed to Heap::Iterate etc. Copies an object if 1452 // Callback function passed to Heap::Iterate etc. Copies an object if
1453 // necessary, the object might be promoted to an old space. The caller must 1453 // necessary, the object might be promoted to an old space. The caller must
1454 // ensure the precondition that the object is (a) a heap object and (b) in 1454 // ensure the precondition that the object is (a) a heap object and (b) in
1455 // the heap's from space. 1455 // the heap's from space.
1456 static inline void ScavengePointer(HeapObject** p); 1456 static inline void ScavengePointer(HeapObject** p);
1457 static inline void ScavengeObject(HeapObject** p, HeapObject* object); 1457 static inline void ScavengeObject(HeapObject** p, HeapObject* object);
1458 1458
1459 // If there is an AllocationMemento after the object, we may need to perform
1460 // some extra work.
Hannes Payer (out of office) 2013/11/21 20:52:24 Ambiguous comment, can we be more precise here.
mvstanton 2013/11/22 11:18:51 Thx, I renamed the method to UpdateAllocationSiteF
1461 static inline void AddressMemento(HeapObject* object);
1462
1463 // Commits from space if it is uncommitted.
1464 void EnsureFromSpaceIsCommitted();
Hannes Payer (out of office) 2013/11/21 20:52:24 I did not find the reason why this method has to b
mvstanton 2013/11/22 11:18:51 Me neither! fixed.
1465
1459 // Support for partial snapshots. After calling this we have a linear 1466 // Support for partial snapshots. After calling this we have a linear
1460 // space to write objects in each space. 1467 // space to write objects in each space.
1461 void ReserveSpace(int *sizes, Address* addresses); 1468 void ReserveSpace(int *sizes, Address* addresses);
1462 1469
1463 // 1470 //
1464 // Support for the API. 1471 // Support for the API.
1465 // 1472 //
1466 1473
1467 bool CreateApiObjects(); 1474 bool CreateApiObjects();
1468 1475
(...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after
2144 // Allocate a tenured JS global property cell initialized with the hole. 2151 // Allocate a tenured JS global property cell initialized with the hole.
2145 MUST_USE_RESULT MaybeObject* AllocatePropertyCell(); 2152 MUST_USE_RESULT MaybeObject* AllocatePropertyCell();
2146 2153
2147 // Allocate Box. 2154 // Allocate Box.
2148 MUST_USE_RESULT MaybeObject* AllocateBox(Object* value, 2155 MUST_USE_RESULT MaybeObject* AllocateBox(Object* value,
2149 PretenureFlag pretenure); 2156 PretenureFlag pretenure);
2150 2157
2151 // Performs a minor collection in new generation. 2158 // Performs a minor collection in new generation.
2152 void Scavenge(); 2159 void Scavenge();
2153 2160
2154 // Commits from space if it is uncommitted.
2155 void EnsureFromSpaceIsCommitted();
2156
2157 // Uncommit unused semi space. 2161 // Uncommit unused semi space.
2158 bool UncommitFromSpace() { return new_space_.UncommitFromSpace(); } 2162 bool UncommitFromSpace() { return new_space_.UncommitFromSpace(); }
2159 2163
2160 // Fill in bogus values in from space 2164 // Fill in bogus values in from space
2161 void ZapFromSpace(); 2165 void ZapFromSpace();
2162 2166
2163 static String* UpdateNewSpaceReferenceInExternalStringTableEntry( 2167 static String* UpdateNewSpaceReferenceInExternalStringTableEntry(
2164 Heap* heap, 2168 Heap* heap,
2165 Object** pointer); 2169 Object** pointer);
2166 2170
(...skipping 914 matching lines...) Expand 10 before | Expand all | Expand 10 after
3081 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. 3085 DisallowHeapAllocation no_allocation; // i.e. no gc allowed.
3082 3086
3083 private: 3087 private:
3084 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); 3088 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer);
3085 }; 3089 };
3086 #endif // DEBUG 3090 #endif // DEBUG
3087 3091
3088 } } // namespace v8::internal 3092 } } // namespace v8::internal
3089 3093
3090 #endif // V8_HEAP_H_ 3094 #endif // V8_HEAP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698