OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 } | 253 } |
254 static int SemiSpaceSize() { return semispace_size_; } | 254 static int SemiSpaceSize() { return semispace_size_; } |
255 static int InitialSemiSpaceSize() { return initial_semispace_size_; } | 255 static int InitialSemiSpaceSize() { return initial_semispace_size_; } |
256 static int YoungGenerationSize() { return young_generation_size_; } | 256 static int YoungGenerationSize() { return young_generation_size_; } |
257 static int OldGenerationSize() { return old_generation_size_; } | 257 static int OldGenerationSize() { return old_generation_size_; } |
258 | 258 |
259 // Returns the capacity of the heap in bytes w/o growing. Heap grows when | 259 // Returns the capacity of the heap in bytes w/o growing. Heap grows when |
260 // more spaces are needed until it reaches the limit. | 260 // more spaces are needed until it reaches the limit. |
261 static int Capacity(); | 261 static int Capacity(); |
262 | 262 |
| 263 // Returns the amount of memory currently committed for the heap. |
| 264 static int CommittedMemory(); |
| 265 |
263 // Returns the available bytes in space w/o growing. | 266 // Returns the available bytes in space w/o growing. |
264 // Heap doesn't guarantee that it can allocate an object that requires | 267 // Heap doesn't guarantee that it can allocate an object that requires |
265 // all available bytes. Check MaxHeapObjectSize() instead. | 268 // all available bytes. Check MaxHeapObjectSize() instead. |
266 static int Available(); | 269 static int Available(); |
267 | 270 |
268 // Returns the maximum object size in paged space. | 271 // Returns the maximum object size in paged space. |
269 static inline int MaxObjectSizeInPagedSpace(); | 272 static inline int MaxObjectSizeInPagedSpace(); |
270 | 273 |
271 // Returns of size of all objects residing in the heap. | 274 // Returns of size of all objects residing in the heap. |
272 static int SizeOfObjects(); | 275 static int SizeOfObjects(); |
(...skipping 1316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1589 } | 1592 } |
1590 static TranscendentalCache* caches_[kNumberOfCaches]; | 1593 static TranscendentalCache* caches_[kNumberOfCaches]; |
1591 Element elements_[kCacheSize]; | 1594 Element elements_[kCacheSize]; |
1592 Type type_; | 1595 Type type_; |
1593 }; | 1596 }; |
1594 | 1597 |
1595 | 1598 |
1596 } } // namespace v8::internal | 1599 } } // namespace v8::internal |
1597 | 1600 |
1598 #endif // V8_HEAP_H_ | 1601 #endif // V8_HEAP_H_ |
OLD | NEW |