1 #ifndef NDNDPDK_PCCT_PCCT_H
2 #define NDNDPDK_PCCT_PCCT_H
12 struct rte_mempool*
mp;
23 static __rte_always_inline
Pcct*
24 Pcct_FromPit(
const Pit* pit) {
25 return container_of(pit,
Pcct, pit);
28 static __rte_always_inline
Pcct*
29 Pcct_FromCs(
const Cs* cs) {
30 return container_of(cs,
Pcct, cs);
39 __attribute__((nonnull))
bool
40 Pcct_Init(
Pcct* pcct,
const char*
id, uint32_t maxEntries,
int numaSocket);
46 __attribute__((nonnull))
void
61 __attribute__((nonnull))
void
68 __attribute__((nonnull)) uint64_t
72 __attribute__((nonnull))
void
83 #define PCCT_ERASE_BURST 32
101 PcctEraseBatch_New(
Pcct* pcct) {
105 __attribute__((nonnull))
void
109 __attribute__((nonnull))
static inline void
118 __attribute__((nonnull))
static inline void
@ PccKeyMaxExts
Definition: pcc-key.h:16
void Pcct_RemoveToken(Pcct *pcct, PccEntry *entry)
Clear the token on an entry.
Definition: pcct.c:163
struct PcctEraseBatch PcctEraseBatch
Context for erasing several PCC entries.
PccEntry * Pcct_Insert(Pcct *pcct, const PccSearch *search, bool *isNew)
Insert or find an entry.
Definition: pcct.c:88
bool Pcct_Init(Pcct *pcct, const char *id, uint32_t maxEntries, int numaSocket)
Initialize keyHt and tokenHt.
Definition: pcct.c:36
void Pcct_Erase(Pcct *pcct, PccEntry *entry)
Erase an entry.
Definition: pcct.c:122
struct Pcct Pcct
The PIT-CS Composite Table (PCCT).
#define PCCT_ERASE_BURST
Definition: pcct.h:83
PccEntry * Pcct_FindByToken(const Pcct *pcct, uint64_t token)
Find an entry by token.
Definition: pcct.c:178
void Pcct_Clear(Pcct *pcct)
Clear keyHt and tokenHt, and free cached Data.
Definition: pcct.c:54
uint64_t Pcct_AddToken(Pcct *pcct, PccEntry *entry)
Assign a token to an entry.
Definition: pcct.c:129
void PcctEraseBatch_EraseBurst_(PcctEraseBatch *peb)
Definition: pcct.c:191
The Content Store (CS).
Definition: cs-struct.h:63
PIT-CS composite entry.
Definition: pcc-entry.h:56
Hash key for searching among PccEntry .
Definition: pcc-key.h:20
Context for erasing several PCC entries.
Definition: pcct.h:86
int nEntries
Definition: pcct.h:88
void * objs[PCCT_ERASE_BURST *(2+PccKeyMaxExts)]
Definition: pcct.h:89
Pcct * pcct
Definition: pcct.h:87
The PIT-CS Composite Table (PCCT).
Definition: pcct.h:11
PccEntry * keyHt
key hashtable
Definition: pcct.h:13
struct rte_mempool * mp
entry mempool
Definition: pcct.h:12
Pit pit
Definition: pcct.h:17
struct rte_hash * tokenHt
token hashtable
Definition: pcct.h:14
Cs cs
Definition: pcct.h:18
uint64_t lastToken
last assigned token
Definition: pcct.h:15
uint32_t nKeyHtBuckets
Definition: pcct.h:20
The Pending Interest Table (PIT).
Definition: pit-struct.h:20