Function to compute RSS memory usage in a fast way, suitable to be called inside keys eviction loops

This commit is contained in:
antirez
2010-11-02 11:40:35 +01:00
parent 10c12171cc
commit 7d47ecd543
2 changed files with 45 additions and 0 deletions

View File

@ -397,6 +397,8 @@ struct redisServer {
char *requirepass;
int rdbcompression;
int activerehashing;
/* Memory related */
float fragmentation;
/* Replication related */
int isslave;
char *masterauth;
@ -751,6 +753,7 @@ void usage();
void updateDictResizePolicy(void);
int htNeedsResize(dict *dict);
void oom(const char *msg);
size_t redisEstimateRSS(void);
/* Virtual Memory */
void vmInit(void);