| 
    STXXL
    1.4.1
    
   | 
 
Encapsulates asynchronous prefetching engine.
block_prefetcher overlaps I/Os with consumption of read data. Utilizes optimal asynchronous prefetch scheduling (by Peter Sanders et.al.) 
Definition at line 55 of file block_prefetcher.h.
 Inheritance diagram for stxxl::block_prefetcher< BlockType, BidIteratorType >:
 Collaboration diagram for stxxl::block_prefetcher< BlockType, BidIteratorType >:Public Types | |
| typedef BidIteratorType | bid_iterator_type | 
| typedef block_type::bid_type | bid_type | 
| typedef BlockType | block_type | 
Public Member Functions | |
| block_prefetcher (bid_iterator_type _cons_begin, bid_iterator_type _cons_end, int_type *_pref_seq, int_type _prefetch_buf_size, completion_handler do_after_fetch=completion_handler()) | |
| Constructs an object and immediately starts prefetching.  More... | |
| ~block_prefetcher () | |
| Frees used memory.  More... | |
| bool | block_consumed (block_type *&buffer) | 
| Exchanges buffers between prefetcher and application.  More... | |
| bool | empty () const | 
| No more consumable blocks available, but can't delete the prefetcher, because not all blocks may have been returned, yet.  More... | |
| unsigned_type | pos () const | 
| Index of the next element in the consume sequence.  More... | |
| block_type * | pull_block () | 
| Pulls next unconsumed block from the consumption sequence.  More... | |
Protected Member Functions | |
| block_type * | wait (int_type iblock) | 
Additional Inherited Members | |
  Private Member Functions inherited from stxxl::noncopyable | |
| noncopyable () | |
| typedef BidIteratorType stxxl::block_prefetcher< BlockType, BidIteratorType >::bid_iterator_type | 
Definition at line 59 of file block_prefetcher.h.
| typedef block_type::bid_type stxxl::block_prefetcher< BlockType, BidIteratorType >::bid_type | 
Definition at line 61 of file block_prefetcher.h.
| typedef BlockType stxxl::block_prefetcher< BlockType, BidIteratorType >::block_type | 
Definition at line 58 of file block_prefetcher.h.
      
  | 
  inline | 
Constructs an object and immediately starts prefetching.
| _cons_begin | bid_iterator pointing to the bid of the first block to be consumed  | 
| _cons_end | bid_iterator pointing to the bid of the ( last + 1 ) block of consumption sequence  | 
| _pref_seq | gives the prefetch order, is a pointer to the integer array that contains the indices of the blocks in the consumption sequence | 
| _prefetch_buf_size | amount of prefetch buffers to use | 
| do_after_fetch | unknown | 
Definition at line 107 of file block_prefetcher.h.
References STXXL_VERBOSE1.
      
  | 
  inline | 
Frees used memory.
Definition at line 211 of file block_prefetcher.h.
      
  | 
  inline | 
Exchanges buffers between prefetcher and application.
| buffer | pointer to the consumed buffer. After call if return value is true buffer contains valid pointer to the next unconsumed prefetched buffer.  | 
buffer must be value returned by pull_block() or block_consumed() methods false if there are no blocks to prefetch left, true if consumption sequence is not emptied Definition at line 163 of file block_prefetcher.h.
References STXXL_VERBOSE1.
      
  | 
  inline | 
No more consumable blocks available, but can't delete the prefetcher, because not all blocks may have been returned, yet.
Definition at line 199 of file block_prefetcher.h.
      
  | 
  inline | 
Index of the next element in the consume sequence.
Definition at line 205 of file block_prefetcher.h.
      
  | 
  inline | 
Pulls next unconsumed block from the consumption sequence.
Definition at line 153 of file block_prefetcher.h.
References STXXL_VERBOSE1.
Referenced by stxxl::buf_istream_reverse< BlockType, BidIteratorType >::buf_istream_reverse(), and stxxl::stream::basic_runs_merger< typename runs_creator_type::sorted_runs_type, cmp_type, alloc_strategy_type >::initialize().
      
  | 
  inlineprotected | 
Definition at line 84 of file block_prefetcher.h.
References STXXL_VERBOSE1.
      
  | 
  protected | 
Definition at line 79 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 64 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 65 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 82 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 71 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 70 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 73 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 80 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 68 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 77 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 75 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 76 of file block_prefetcher.h.
      
  | 
  protected | 
Definition at line 66 of file block_prefetcher.h.