![]() |
XRootD
|
#include <XrdRmcData.hh>
Public Member Functions | |
XrdRmcData (XrdRmcReal *cP, XrdOucCacheIO *ioP, long long vn, int opts) | |
bool | Detach (XrdOucCacheIOCD &iocd) |
long long | FSize () |
const char * | Path () |
void | Preread () |
void | Preread (aprParms &Parms) |
void | Preread (long long Offs, int rLen, int Opts=0) |
int | Read (char *Buffer, long long Offset, int Length) |
int | Sync () |
int | Trunc (long long Offset) |
int | Write (char *Buffer, long long Offset, int Length) |
![]() | |
XrdOucCacheIO () | |
Construct and Destructor. More... | |
virtual int | Fstat (struct stat &sbuff) |
virtual const char * | Location (bool refresh=false) |
virtual int | pgRead (char *buff, long long offs, int rdlen, std::vector< uint32_t > &csvec, uint64_t opts=0, int *csfix=0) |
virtual void | pgRead (XrdOucCacheIOCB &iocb, char *buff, long long offs, int rdlen, std::vector< uint32_t > &csvec, uint64_t opts=0, int *csfix=0) |
virtual int | pgWrite (char *buff, long long offs, int wrlen, std::vector< uint32_t > &csvec, uint64_t opts=0, int *csfix=0) |
virtual void | pgWrite (XrdOucCacheIOCB &iocb, char *buff, long long offs, int wrlen, std::vector< uint32_t > &csvec, uint64_t opts=0, int *csfix=0) |
virtual void | Read (XrdOucCacheIOCB &iocb, char *buff, long long offs, int rlen) |
virtual int | ReadV (const XrdOucIOVec *readV, int rnum) |
virtual void | ReadV (XrdOucCacheIOCB &iocb, const XrdOucIOVec *readV, int rnum) |
virtual void | Sync (XrdOucCacheIOCB &iocb) |
virtual void | Trunc (XrdOucCacheIOCB &iocb, long long offs) |
virtual void | Update (XrdOucCacheIO &iocp) |
virtual void | Write (XrdOucCacheIOCB &iocb, char *buff, long long offs, int wlen) |
virtual int | WriteV (const XrdOucIOVec *writV, int wnum) |
virtual void | WriteV (XrdOucCacheIOCB &iocb, const XrdOucIOVec *writV, int wnum) |
Static Public Member Functions | |
static int | setAPR (aprParms &Dest, aprParms &Src, int pSize) |
Additional Inherited Members | |
![]() | |
static const uint64_t | forceCS = 0x0000000000000001ULL |
static const int | SingleUse = 0x0001 |
Mark pages for single use. More... | |
![]() | |
virtual | ~XrdOucCacheIO () |
Definition at line 42 of file XrdRmcData.hh.
XrdRmcData::XrdRmcData | ( | XrdRmcReal * | cP, |
XrdOucCacheIO * | ioP, | ||
long long | vn, | ||
int | opts | ||
) |
Definition at line 42 of file XrdRmcData.cc.
References XrdRmc::ioMTSafe, XrdOucCache::optFIS, XrdOucCache::optRW, opts, XrdOucCacheIO::aprParms::prRecalc, XrdRmc::Serialized, setAPR(), xs_Exclusive, and xs_Shared.
|
virtual |
Detach this CacheIO object from the cache.
iocd | reference to the detach complete callback object. |
Implements XrdOucCacheIO.
Definition at line 97 of file XrdRmcData.cc.
References XrdOucCacheStats::Add(), XrdOucCacheStats::CacheStats::BytesGet, XrdOucCacheStats::CacheStats::BytesPass, XrdOucCacheStats::CacheStats::BytesPead, XrdOucCacheStats::CacheStats::BytesPut, XrdOucCacheStats::CacheStats::BytesRead, XrdOucCacheStats::CacheStats::BytesWrite, XrdOucCacheStats::CacheStats::Hits, XrdOucCacheStats::CacheStats::HitsPR, XrdSysMutex::Lock(), XrdSysXSLock::Lock(), XrdOucCacheStats::CacheStats::Miss, XrdOucCacheStats::CacheStats::MissPR, XrdOucCacheIO::Path(), XrdOucCache::Statistics, XrdSysMutex::UnLock(), XrdSysXSLock::UnLock(), XrdSysSemaphore::Wait(), XrdOucCacheStats::X, and xs_Exclusive.
|
inlinevirtual |
Obtain size of the file.
Implements XrdOucCacheIO.
Definition at line 48 of file XrdRmcData.hh.
References XrdOucCacheIO::FSize().
|
inlinevirtual |
Get the path associated with this object.
Implements XrdOucCacheIO.
Definition at line 50 of file XrdRmcData.hh.
References XrdOucCacheIO::Path().
void XrdRmcData::Preread | ( | ) |
Definition at line 155 of file XrdRmcData.cc.
References XrdOucCacheStats::CacheStats::BytesPead, XrdRmcSlot::isNew, XrdRmcSlot::isSUSE, XrdOucCacheStats::Lock(), XrdSysMutex::Lock(), XrdOucCacheStats::CacheStats::MissPR, XrdOucCacheIO::Path(), XrdSysSemaphore::Post(), XrdRmcReal::PreRead(), XrdOucCacheStats::UnLock(), XrdSysMutex::UnLock(), and XrdOucCacheStats::X.
|
virtual |
Reimplemented from XrdOucCacheIO.
Definition at line 239 of file XrdRmcData.cc.
References XrdSysMutex::Lock(), setAPR(), and XrdSysMutex::UnLock().
|
virtual |
Reimplemented from XrdOucCacheIO.
Definition at line 220 of file XrdRmcData.cc.
References XrdMpx::Opts, and XrdOucCacheIO::SingleUse.
|
virtual |
Perform an synchronous read.
buff | pointer to the buffer to receive the results. The buffer must remain valid until the callback is invoked. |
offs | the offset into the file. |
rlen | the number of bytes to read. |
Implements XrdOucCacheIO.
Definition at line 337 of file XrdRmcData.cc.
References XrdOucCacheStats::Add(), XrdOucCacheStats::CacheStats::BytesGet, XrdOucCacheStats::CacheStats::BytesRead, XrdOucCacheStats::CacheStats::Hits, XrdOucCacheStats::CacheStats::HitsPR, XrdSysMutex::Lock(), XrdOucCacheStats::CacheStats::Miss, XrdOucCacheIO::aprParms::Trigger, XrdSysMutex::UnLock(), and XrdOucCacheStats::X.
Definition at line 489 of file XrdRmcData.cc.
References XrdOucCacheIO::aprParms::minPages, XrdOucCacheIO::aprParms::minPerf, XrdOucCacheIO::aprParms::prRecalc, and XrdOucCacheIO::aprParms::Trigger.
Referenced by XrdRmcData(), XrdRmcReal::XrdRmcReal(), and Preread().
|
inlinevirtual |
Perform an synchronous sync() operation.
Implements XrdOucCacheIO.
Definition at line 62 of file XrdRmcData.hh.
|
virtual |
Perform an synchronous trunc() operation.
offs | the size the file is have. |
Implements XrdOucCacheIO.
Definition at line 514 of file XrdRmcData.cc.
References XrdOucCacheIO::Trunc(), and xs_Exclusive.
|
virtual |
Perform an synchronous write.
buff | pointer to the buffer holding the contents. The buffer must remain valid until the callback is invoked. |
offs | the offset into the file. |
wlen | the number of bytes to write |
Implements XrdOucCacheIO.
Definition at line 536 of file XrdRmcData.cc.
References XrdOucCacheStats::CacheStats::BytesPut, XrdOucCacheStats::CacheStats::BytesWrite, XrdOucCacheStats::CacheStats::Hits, XrdOucCacheStats::CacheStats::HitsPR, XrdOucCacheStats::CacheStats::Miss, XrdOucCacheIO::Write(), XrdOucCacheStats::X, and xs_Exclusive.