s3:smbd: improve writecache profiling
commit86a951b4ff9b3a1bbe03b3448d45f9750c949c00
authorStefan Metzmacher <metze@samba.org>
Wed, 5 Nov 2014 14:54:02 +0000 (5 15:54 +0100)
committerJeremy Allison <jra@samba.org>
Wed, 19 Nov 2014 19:51:37 +0000 (19 20:51 +0100)
treed5e7587700733208a1d5b1b885e6d51353af3fa7
parent297d1877614b4f4f33f7e19f2d107feb5fe460ed
s3:smbd: improve writecache profiling

In order to have useful profiling counters should never be decremented.
We need a separate counter for deallocation events.

The current value can be calculated by allocations - deallocations.

We also use better names and avoid having an array for the flush reasons.
This will simplify further profiling improvements a lot.

The value writecache_num_write_caches (this was similar to writecache_allocations)
is replaced by writecache_cached_writes, which counts the amount of writes which
were completely handled by the cache.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/include/smb.h
source3/include/smbprofile.h
source3/smbd/fileio.c
source3/utils/status_profile.c