| Index: src/heap/heap.h
 | 
| diff --git a/src/heap/heap.h b/src/heap/heap.h
 | 
| index 0b353b70f1d269a79b747f65cedc23fc0d487958..919b606d10e18bf427a0b3905229c663bc5d7328 100644
 | 
| --- a/src/heap/heap.h
 | 
| +++ b/src/heap/heap.h
 | 
| @@ -607,6 +607,9 @@ class Heap {
 | 
|    // Returns the amount of memory currently committed for the heap.
 | 
|    intptr_t CommittedMemory();
 | 
|  
 | 
| +  // Returns the amount of memory currently committed for the old space.
 | 
| +  intptr_t CommittedOldGenerationMemory();
 | 
| +
 | 
|    // Returns the amount of executable memory currently committed for the heap.
 | 
|    intptr_t CommittedMemoryExecutable();
 | 
|  
 | 
| @@ -690,6 +693,12 @@ class Heap {
 | 
|      return old_data_space_->allocation_limit_address();
 | 
|    }
 | 
|  
 | 
| +  // TODO(hpayer): There is still a missmatch between capacity and actual
 | 
| +  // committed memory size.
 | 
| +  bool CanExpandOldGeneration(int size) {
 | 
| +    return (CommittedOldGenerationMemory() + size) < MaxOldGenerationSize();
 | 
| +  }
 | 
| +
 | 
|    // Returns a deep copy of the JavaScript object.
 | 
|    // Properties and elements are copied too.
 | 
|    // Optionally takes an AllocationSite to be appended in an AllocationMemento.
 | 
| 
 |