@@ -223,9 +223,6 @@ class MemoryPool;
223223class MemoryPoolFactory ;
224224class DynamicMemoryAllocator ;
225225class BlockCheckpointInfo ;
226- #ifdef RTS_ENABLE_CRASHDUMP
227- class AllocationRangeIterator ;
228- #endif
229226
230227// TYPE DEFINES ///////////////////////////////////////////////////////////////
231228
@@ -282,14 +279,6 @@ class Checkpointable
282279};
283280#endif
284281
285- #ifdef RTS_ENABLE_CRASHDUMP
286- struct MemoryPoolAllocatedRange
287- {
288- const char * allocationAddr;
289- size_t allocationSize;
290- };
291- #endif
292-
293282// ----------------------------------------------------------------------------
294283/* *
295284 A MemoryPool provides a way to efficiently allocate objects of the same (or similar)
@@ -395,9 +384,6 @@ class MemoryPool
395384 // / return true iff this block was allocated by this pool.
396385 Bool debugIsBlockInPool (void *pBlock);
397386 #endif
398- #ifdef RTS_ENABLE_CRASHDUMP
399- friend class AllocationRangeIterator ;
400- #endif
401387};
402388
403389// ----------------------------------------------------------------------------
@@ -488,52 +474,13 @@ class DynamicMemoryAllocator
488474 Bool debugIsPoolInDma (MemoryPool *pool);
489475
490476 #endif // MEMORYPOOL_DEBUG
491- #ifdef RTS_ENABLE_CRASHDUMP
492- MemoryPoolSingleBlock* getFirstRawBlock () const ;
493- MemoryPoolSingleBlock* getNextRawBlock (const MemoryPoolSingleBlock* block) const ;
494- void fillAllocationRangeForRawBlock (const MemoryPoolSingleBlock*, MemoryPoolAllocatedRange& allocationRange) const ;
495- #endif
496477};
497478
498479// ----------------------------------------------------------------------------
499480#ifdef MEMORYPOOL_DEBUG
500481enum { MAX_SPECIAL_USED = 256 };
501482#endif
502483
503- #ifdef RTS_ENABLE_CRASHDUMP
504- class AllocationRangeIterator
505- {
506- typedef const MemoryPoolAllocatedRange value_type;
507- typedef const MemoryPoolAllocatedRange* pointer;
508- typedef const MemoryPoolAllocatedRange& reference;
509-
510- public:
511-
512- AllocationRangeIterator ();
513- AllocationRangeIterator (const MemoryPoolFactory* factory);
514- AllocationRangeIterator (MemoryPool& pool, MemoryPoolBlob& blob);
515- AllocationRangeIterator (MemoryPool* pool, MemoryPoolBlob* blob);
516-
517- reference operator *() { return m_range; }
518- pointer operator ->() { return &m_range; }
519-
520- AllocationRangeIterator& operator ++();
521- AllocationRangeIterator operator ++(int );
522-
523- friend const bool operator == (const AllocationRangeIterator& a, const AllocationRangeIterator& b);
524- friend const bool operator != (const AllocationRangeIterator& a, const AllocationRangeIterator& b);
525-
526- private:
527-
528- void updateRange ();
529- void moveToNextBlob ();
530- const MemoryPoolFactory* m_factory;
531- MemoryPool* m_currentPool;
532- MemoryPoolBlob* m_currentBlobInPool;
533- MemoryPoolAllocatedRange m_range;
534- };
535- #endif
536-
537484// ----------------------------------------------------------------------------
538485/* *
539486 The class that manages all the MemoryPools and DynamicMemoryAllocators.
@@ -626,20 +573,6 @@ class MemoryPoolFactory
626573 void debugResetCheckpoints ();
627574
628575 #endif
629- #ifdef RTS_ENABLE_CRASHDUMP
630- AllocationRangeIterator cbegin () const
631- {
632- return AllocationRangeIterator (this );
633- }
634-
635- AllocationRangeIterator cend () const
636- {
637- return AllocationRangeIterator (NULL , NULL );
638- }
639-
640- MemoryPool* getFirstMemoryPool () const ;
641- friend class AllocationRangeIterator ;
642- #endif
643576};
644577
645578// how many bytes are we allowed to 'waste' per pool allocation before the debug code starts yelling at us...
0 commit comments