Closed jerrinsg closed 5 years ago
Memtier benchmark throughput before the fix:
$ ./memtier_benchmark --clients=50 --threads=4 --requests=10000 --data-size=1000 --pipeline=100 --ratio=1:0 --port=6378
[RUN #1 100%, 40 secs] 0 threads: 2000000 ops, 71357 (avg: 49741) ops/sec, 71.38MB/sec (avg: 49.76MB/sec), 300.39 (avg: 401.23) msec latency
Memtier benchmark throughput after the fix:
$ ./memtier_benchmark --clients=50 --threads=4 --requests=10000 --data-size=1000 --pipeline=100 --ratio=1:0 --port=6378
[RUN #1 100%, 5 secs] 0 threads: 2000000 ops, 406942 (avg: 360076) ops/sec, 407.06MB/sec (avg: 360.18MB/sec), 49.42 (avg: 55.39) msec latency
Change looks good to me, Jerrin.
Reuse undo log backing array for entries during transaction release
With the new changes, memtier-benchmark throughput was seen to be low when run against go-pmem-redis. This is because of the increase in the number of memory allocations as transaction Release() was allocating a new backing array for the log entries each time. This commit changes the abort function to reuse the backing array on transaction Release() and allocate a new array only in the crash-recovery code path.
Fixes #15