Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 231 ObjectSlotCallback copy_object_func); | 231 ObjectSlotCallback copy_object_func); |
| 232 | 232 |
| 233 | 233 |
| 234 // The all static Heap captures the interface to the global object heap. | 234 // The all static Heap captures the interface to the global object heap. |
| 235 // All JavaScript contexts by this process share the same object heap. | 235 // All JavaScript contexts by this process share the same object heap. |
| 236 | 236 |
| 237 class Heap : public AllStatic { | 237 class Heap : public AllStatic { |
| 238 public: | 238 public: |
| 239 // Configure heap size before setup. Return false if the heap has been | 239 // Configure heap size before setup. Return false if the heap has been |
| 240 // setup already. | 240 // setup already. |
| 241 static bool ConfigureHeap(intptr_t max_semispace_size, | 241 static bool ConfigureHeap(int max_semispace_size, |
|
Vyacheslav Egorov (Chromium)
2011/06/28 12:28:37
Hmm. This is pretty strange change. What about ove
Lasse Reichstein
2011/06/29 10:54:58
The fields are ints, so passing something bigger h
| |
| 242 intptr_t max_old_gen_size, | 242 int max_old_gen_size, |
| 243 intptr_t max_executable_size); | 243 int max_executable_size); |
| 244 static bool ConfigureHeapDefault(); | 244 static bool ConfigureHeapDefault(); |
| 245 | 245 |
| 246 // Initializes the global object heap. If create_heap_objects is true, | 246 // Initializes the global object heap. If create_heap_objects is true, |
| 247 // also creates the basic non-mutable objects. | 247 // also creates the basic non-mutable objects. |
| 248 // Returns whether it succeeded. | 248 // Returns whether it succeeded. |
| 249 static bool Setup(bool create_heap_objects); | 249 static bool Setup(bool create_heap_objects); |
| 250 | 250 |
| 251 // Destroys all memory allocated by the heap. | 251 // Destroys all memory allocated by the heap. |
| 252 static void TearDown(); | 252 static void TearDown(); |
| 253 | 253 |
| (...skipping 1919 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2173 | 2173 |
| 2174 private: | 2174 private: |
| 2175 static const uintptr_t kNotMarkedBit = 0x1; | 2175 static const uintptr_t kNotMarkedBit = 0x1; |
| 2176 STATIC_ASSERT((kHeapObjectTag & kNotMarkedBit) != 0); | 2176 STATIC_ASSERT((kHeapObjectTag & kNotMarkedBit) != 0); |
| 2177 }; | 2177 }; |
| 2178 | 2178 |
| 2179 | 2179 |
| 2180 } } // namespace v8::internal | 2180 } } // namespace v8::internal |
| 2181 | 2181 |
| 2182 #endif // V8_HEAP_H_ | 2182 #endif // V8_HEAP_H_ |
| OLD | NEW |