Currently if we create a blob of 128 clusters, we lock/unlock the used_cluster_mutex 128 times - once for each cluster. Same when those clusters are released when the blob is deleted. Batching these lock/unlock operations is very easy and gives a noticeable efficiency improvement. My local benchmark (1GiB ramdisk, 4KB cluster size, 128 clusters/blob) creates enough blobs to fill the blobstore and then continuously deletes and recreates them. Performance increases 20% on that benchmark with this patch. Signed-off-by: Jim Harris <james.r.harris@intel.com> Change-Id: Ic503accf1ca1ab1af7254b4067771d956f52014d Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4069 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> |
||
---|---|---|
.. | ||
blob_bs_dev.c | ||
blobstore.c | ||
blobstore.h | ||
Makefile | ||
request.c | ||
request.h | ||
spdk_blob.map | ||
zeroes.c |