| OLD | NEW |
| 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 515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 526 | 526 |
| 527 // Returns the amount of memory currently committed for the heap. | 527 // Returns the amount of memory currently committed for the heap. |
| 528 intptr_t CommittedMemory(); | 528 intptr_t CommittedMemory(); |
| 529 | 529 |
| 530 // Returns the amount of executable memory currently committed for the heap. | 530 // Returns the amount of executable memory currently committed for the heap. |
| 531 intptr_t CommittedMemoryExecutable(); | 531 intptr_t CommittedMemoryExecutable(); |
| 532 | 532 |
| 533 // Returns the amount of phyical memory currently committed for the heap. | 533 // Returns the amount of phyical memory currently committed for the heap. |
| 534 size_t CommittedPhysicalMemory(); | 534 size_t CommittedPhysicalMemory(); |
| 535 | 535 |
| 536 // Returns the maximum amount of memory ever committed for the heap. |
| 537 intptr_t MaximumCommittedMemory() { return maximum_committed_; } |
| 538 |
| 539 // Updates the maximum committed memory for the heap. Should be called |
| 540 // whenever a space grows. |
| 541 void UpdateMaximumCommitted(); |
| 542 |
| 536 // Returns the available bytes in space w/o growing. | 543 // Returns the available bytes in space w/o growing. |
| 537 // Heap doesn't guarantee that it can allocate an object that requires | 544 // Heap doesn't guarantee that it can allocate an object that requires |
| 538 // all available bytes. Check MaxHeapObjectSize() instead. | 545 // all available bytes. Check MaxHeapObjectSize() instead. |
| 539 intptr_t Available(); | 546 intptr_t Available(); |
| 540 | 547 |
| 541 // Returns of size of all objects residing in the heap. | 548 // Returns of size of all objects residing in the heap. |
| 542 intptr_t SizeOfObjects(); | 549 intptr_t SizeOfObjects(); |
| 543 | 550 |
| 544 // Return the starting address and a mask for the new space. And-masking an | 551 // Return the starting address and a mask for the new space. And-masking an |
| 545 // address with the mask will result in the start address of the new space | 552 // address with the mask will result in the start address of the new space |
| (...skipping 1351 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1897 Isolate* isolate_; | 1904 Isolate* isolate_; |
| 1898 | 1905 |
| 1899 Object* roots_[kRootListLength]; | 1906 Object* roots_[kRootListLength]; |
| 1900 | 1907 |
| 1901 intptr_t code_range_size_; | 1908 intptr_t code_range_size_; |
| 1902 int reserved_semispace_size_; | 1909 int reserved_semispace_size_; |
| 1903 int max_semispace_size_; | 1910 int max_semispace_size_; |
| 1904 int initial_semispace_size_; | 1911 int initial_semispace_size_; |
| 1905 intptr_t max_old_generation_size_; | 1912 intptr_t max_old_generation_size_; |
| 1906 intptr_t max_executable_size_; | 1913 intptr_t max_executable_size_; |
| 1914 intptr_t maximum_committed_; |
| 1907 | 1915 |
| 1908 // For keeping track of how much data has survived | 1916 // For keeping track of how much data has survived |
| 1909 // scavenge since last new space expansion. | 1917 // scavenge since last new space expansion. |
| 1910 int survived_since_last_expansion_; | 1918 int survived_since_last_expansion_; |
| 1911 | 1919 |
| 1912 // For keeping track on when to flush RegExp code. | 1920 // For keeping track on when to flush RegExp code. |
| 1913 int sweep_generation_; | 1921 int sweep_generation_; |
| 1914 | 1922 |
| 1915 int always_allocate_scope_depth_; | 1923 int always_allocate_scope_depth_; |
| 1916 int linear_allocation_scope_depth_; | 1924 int linear_allocation_scope_depth_; |
| (...skipping 1171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3088 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. | 3096 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. |
| 3089 | 3097 |
| 3090 private: | 3098 private: |
| 3091 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 3099 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
| 3092 }; | 3100 }; |
| 3093 #endif // DEBUG | 3101 #endif // DEBUG |
| 3094 | 3102 |
| 3095 } } // namespace v8::internal | 3103 } } // namespace v8::internal |
| 3096 | 3104 |
| 3097 #endif // V8_HEAP_H_ | 3105 #endif // V8_HEAP_H_ |
| OLD | NEW |