Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: merge concurrent physical read #170

Merged
merged 1 commit into from
Oct 11, 2023
Merged

feat: merge concurrent physical read #170

merged 1 commit into from
Oct 11, 2023

Conversation

MrCroxx
Copy link
Owner

@MrCroxx MrCroxx commented Oct 10, 2023

What's changed and what's your intention?

Please explain IN DETAIL what the changes are in this PR and why they are needed. :D

Add wait map to merge concurrent physical reads.

Benchmark:

commands:

rm -rf /p44pro/foyer && cargo build --release && RUST_BACKTRACE=1 RUST_LOG=warn ./target/release/foyer-storage-bench --dir /p44pro/foyer --capacity 204800 --region-size 64 --lookup-range 100000 --flushers 8 --reclaimers 8 --buffer-pool-size 1024 --time 60 --writers 1024 --w-rate 1 --allocator-bits 2 --ticket-insert-rate-limit 1024 --readers 1024 --r-rate 1 --runtime 2>&1 | tee -i ./target/bench.log

main:

Total:
disk total iops: 172739.5
disk total throughput: 2.0 GiB/s
disk read iops: 103624.9
disk read throughput: 0.9 GiB/s
disk write iops: 69114.5
disk write throughput: 1.1 GiB/s
insert iops: 16331.0/s
insert throughput: 1.0 GiB/s
insert lat p50: 235us
insert lat p90: 523us
insert lat p99: 18943us
insert lat pmax: 249855us
get iops: 17528.7/s
get miss: 6.83%
get throughput: 1.0 GiB/s
get hit lat p50: 17023us
get hit lat p90: 31487us
get hit lat p99: 46591us
get hit lat pmax: 84479us
get miss lat p50: 767us
get miss lat p90: 1319us
get miss lat p99: 5791us
get miss lat pmax: 20735us

branch:

Total:
disk total iops: 75726.3
disk total throughput: 1.1 GiB/s
disk read iops: 6533.4
disk read throughput: 86.7 MiB/s
disk write iops: 69193.0
disk write throughput: 1.1 GiB/s
insert iops: 16331.8/s
insert throughput: 1.0 GiB/s
insert lat p50: 220us
insert lat p90: 433us
insert lat p99: 767us
insert lat pmax: 32639us
get iops: 17497.2/s
get miss: 6.66%
get throughput: 1.0 GiB/s
get hit lat p50: 791us
get hit lat p90: 1503us
get hit lat p99: 2127us
get hit lat pmax: 26367us
get miss lat p50: 727us
get miss lat p90: 1231us
get miss lat p99: 6079us
get miss lat pmax: 25599us

Checklist

  • I have written necessary rustdoc comments
  • I have added necessary unit tests and integration tests
  • I have passed make check and make test or make all in my local envirorment.

Related issues or PRs (optional)

Signed-off-by: MrCroxx <mrcroxx@outlook.com>
@MrCroxx MrCroxx added the feature New feature or request label Oct 10, 2023
@MrCroxx MrCroxx self-assigned this Oct 10, 2023
@MrCroxx
Copy link
Owner Author

MrCroxx commented Oct 11, 2023

On c6id.2xlarge NVMe:

4k readers + 4k writers + 200MB ticket insert rate limit

rm -rf /data/foyer && cargo build --release && RUST_BACKTRACE=1 RUST_LOG=warn ./target/release/foyer-storage-bench --dir /data/foyer --capacity 204800 --region-size 64 --lookup-range 100000 --flushers 8 --reclaimers 8 --buffer-pool-size 1024 --time 60 --writers 4096 --w-rate 1 --allocator-bits 2 --ticket-insert-rate-limit 200 --readers 4096 --r-rate 1 --runtime 2>&1 | tee -i ./target/bench.log
Total:
disk total iops: 28934.2
disk total throughput: 415.7 MiB/s
disk read iops: 15550.2
disk read throughput: 206.5 MiB/s
disk write iops: 13384.0
disk write throughput: 209.2 MiB/s
insert iops: 3194.1/s
insert throughput: 199.6 MiB/s
insert lat p50: 6847us
insert lat p90: 8127us
insert lat p99: 9471us
insert lat pmax: 24447us
get iops: 602552.4/s
get miss: 95.21%
get throughput: 1.8 GiB/s
get hit lat p50: 6815us
get hit lat p90: 8511us
get hit lat p99: 11263us
get hit lat pmax: 26879us
get miss lat p50: 6687us
get miss lat p90: 7903us
get miss lat p99: 9215us
get miss lat pmax: 27135us

@MrCroxx MrCroxx merged commit 75f3363 into main Oct 11, 2023
8 checks passed
@MrCroxx MrCroxx deleted the xx/wait branch October 11, 2023 03:34
MrCroxx added a commit that referenced this pull request Apr 17, 2024
Signed-off-by: MrCroxx <mrcroxx@outlook.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant