#include <stmem.h>

Collaboration diagram for mem_hdr:

Public Member Functions

 mem_hdr ()
 
 ~mem_hdr ()
 
void freeContent ()
 
int64_t lowestOffset () const
 
int64_t endOffset () const
 
int64_t freeDataUpto (int64_t)
 
ssize_t copy (StoreIOBuffer const &) const
 
bool hasContigousContentRange (Range< int64_t > const &range) const
 
bool write (StoreIOBuffer const &)
 
void dump () const
 
size_t size () const
 
mem_nodegetBlockContainingLocation (int64_t location) const
 
const Splay< mem_node * > & getNodes () const
 
char * NodeGet (mem_node *aNode)
 

Static Public Attributes

static Splay< mem_node * >::SPLAYCMP NodeCompare
 

Private Member Functions

void debugDump () const
 
bool unlink (mem_node *aNode)
 
void appendNode (mem_node *aNode)
 
size_t copyAvailable (mem_node *aNode, int64_t location, size_t amount, char *target) const
 
bool unionNotEmpty (StoreIOBuffer const &)
 
mem_nodenodeToRecieve (int64_t offset)
 
size_t writeAvailable (mem_node *aNode, int64_t location, size_t amount, char const *source)
 

Private Attributes

int64_t inmem_hi
 
Splay< mem_node * > nodes
 

Detailed Description

Definition at line 19 of file stmem.h.

Constructor & Destructor Documentation

◆ mem_hdr()

mem_hdr::mem_hdr ( )

Definition at line 334 of file stmem.cc.

References debugs, and inmem_hi.

◆ ~mem_hdr()

mem_hdr::~mem_hdr ( )

Definition at line 339 of file stmem.cc.

References freeContent().

Member Function Documentation

◆ appendNode()

void mem_hdr::appendNode ( mem_node aNode)
private

Definition at line 130 of file stmem.cc.

References Splay< V >::insert(), NodeCompare, and nodes.

Referenced by nodeToRecieve().

◆ copy()

◆ copyAvailable()

size_t mem_hdr::copyAvailable ( mem_node aNode,
int64_t  location,
size_t  amount,
char *  target 
) const
private

◆ debugDump()

void mem_hdr::debugDump ( ) const
private

Definition at line 172 of file stmem.cc.

References debugs, endOffset(), getNodes(), lowestOffset(), and Splay< V >::visit().

Referenced by copy(), and write().

◆ dump()

void mem_hdr::dump ( ) const

Definition at line 361 of file stmem.cc.

References DBG_IMPORTANT, debugs, Splay< V >::finish(), nodes, and Splay< V >::start().

Referenced by MemObject::dump().

◆ endOffset()

◆ freeContent()

void mem_hdr::freeContent ( )

Definition at line 59 of file stmem.cc.

References debugs, Splay< V >::destroy(), inmem_hi, and nodes.

Referenced by ~mem_hdr(), MemObject::~MemObject(), and MemObject::reset().

◆ freeDataUpto()

int64_t mem_hdr::freeDataUpto ( int64_t  target_offset)

◆ getBlockContainingLocation()

mem_node * mem_hdr::getBlockContainingLocation ( int64_t  location) const

◆ getNodes()

const Splay< mem_node * > & mem_hdr::getNodes ( ) const

Definition at line 374 of file stmem.cc.

References nodes.

Referenced by debugDump(), and testHdrVisit().

◆ hasContigousContentRange()

bool mem_hdr::hasContigousContentRange ( Range< int64_t > const &  range) const

◆ lowestOffset()

int64_t mem_hdr::lowestOffset ( ) const

◆ NodeGet()

char * mem_hdr::NodeGet ( mem_node aNode)

Definition at line 26 of file stmem.cc.

References assert, mem_node::data, and mem_node::write_pending.

Referenced by doPages().

◆ nodeToRecieve()

mem_node * mem_hdr::nodeToRecieve ( int64_t  offset)
private

◆ size()

size_t mem_hdr::size ( ) const

Definition at line 368 of file stmem.cc.

References nodes, and Splay< V >::size().

Referenced by StoreEntry::memoryCachable().

◆ unionNotEmpty()

bool mem_hdr::unionNotEmpty ( StoreIOBuffer const &  candidate)
private

◆ unlink()

bool mem_hdr::unlink ( mem_node aNode)
private

Definition at line 67 of file stmem.cc.

References DBG_CRITICAL, debugs, NodeCompare, nodes, Splay< V >::remove(), and mem_node::write_pending.

Referenced by freeDataUpto().

◆ write()

◆ writeAvailable()

size_t mem_hdr::writeAvailable ( mem_node aNode,
int64_t  location,
size_t  amount,
char const *  source 
)
private

Member Data Documentation

◆ inmem_hi

int64_t mem_hdr::inmem_hi
private

Definition at line 52 of file stmem.h.

Referenced by mem_hdr(), endOffset(), freeContent(), and writeAvailable().

◆ NodeCompare

int mem_hdr::NodeCompare
static

◆ nodes


The documentation for this class was generated from the following files:

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors