From 7fba3a88f1ced610eca0c23516a1e720d75160cd Mon Sep 17 00:00:00 2001 From: Anand Avati Date: Sat, 29 Mar 2014 06:59:39 -0700 Subject: mem-accounting: enable memory accounting by default memory accounting are constant time operations which involve a few pointer dereferences and integer increments (no loops or searches etc.) benefits of having memory usage info outweigh the minor accounting overheads Change-Id: If9bc6db5ffd0e00f0fd64b2f6eed094bf3543996 BUG: 1089216 Signed-off-by: Anand Avati Reviewed-on: http://review.gluster.org/7543 Tested-by: Gluster Build System Reviewed-by: Harshavardhana --- libglusterfs/src/ctx.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libglusterfs/src/ctx.c') diff --git a/libglusterfs/src/ctx.c b/libglusterfs/src/ctx.c index 0082601d466..f273451a74b 100644 --- a/libglusterfs/src/ctx.c +++ b/libglusterfs/src/ctx.c @@ -31,6 +31,8 @@ glusterfs_ctx_new () goto out; } + ctx->mem_acct_enable = 1; + INIT_LIST_HEAD (&ctx->graphs); INIT_LIST_HEAD (&ctx->mempool_list); -- cgit