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

Store memory image as a btree of pages #561

Merged
merged 2 commits into from
May 12, 2023
Merged

Store memory image as a btree of pages #561

merged 2 commits into from
May 12, 2023

Conversation

shkoo
Copy link
Contributor

@shkoo shkoo commented May 12, 2023

This significantly improves execute performance, both in memory usage and runtime.

This gives us significant performance gains in both memory usage and run time.
@github-actions
Copy link

Benchmark for Linux-cuda c096be1

Click to hide benchmark
Test Base PR %
fib/100/execute 317.9±2.67ms 20.9±0.14ms -93.43%
fib/100/prove 2.9±0.01s 1146.1±6.03ms -60.48%
fib/100/total 3.2±0.01s 1179.8±4.88ms -63.13%
fib/1000/execute 329.7±0.29ms 40.4±0.09ms -87.75%
fib/1000/prove 3.0±0.00s 1174.2±5.81ms -60.86%
fib/1000/total 3.3±0.01s 1235.7±3.92ms -62.55%
fib/10000/execute 449.4±0.78ms 233.2±0.35ms -48.11%
fib/10000/prove 10.6±0.03s 4.8±0.05s +-54.72%
fib/10000/total 11.1±0.04s 4.9±0.04s +-55.86%

Benchmark for Linux-default c096be1

Click to hide benchmark
Test Base PR %
fib/100/execute 1409.6±3.67ms 55.2±0.19ms -96.08%
fib/100/prove 5.9±0.12s 5.1±0.02s -13.56%
fib/100/total 7.2±0.05s 5.1±0.02s -29.17%
fib/1000/execute 1419.4±2.19ms 77.1±0.94ms -94.57%
fib/1000/prove 5.9±0.06s 5.1±0.02s -13.56%
fib/1000/total 7.4±0.08s 5.2±0.01s -29.73%
fib/10000/execute 1554.5±21.47ms 281.8±1.55ms -81.87%
fib/10000/prove 22.2±0.15s 21.1±0.10s -4.95%
fib/10000/total 23.7±0.15s 21.4±0.11s -9.70%

Benchmark for macOS-default c096be1

Click to hide benchmark
Test Base PR %
fib/100/execute 694.6±9.48ms 28.2±0.03ms -95.94%
fib/100/prove 3.8±0.07s 3.7±0.04s -2.63%
fib/100/total 4.5±0.04s 3.7±0.06s -17.78%
fib/1000/execute 691.2±1.40ms 37.9±0.14ms -94.52%
fib/1000/prove 3.8±0.05s 3.7±0.04s -2.63%
fib/1000/total 4.5±0.07s 3.8±0.07s -15.56%
fib/10000/execute 747.9±1.18ms 131.4±0.28ms -82.43%
fib/10000/prove 15.3±0.12s 15.3±0.06s 0.00%
fib/10000/total 16.0±0.13s 15.4±0.15s -3.75%

Benchmark for macOS-metal c096be1

Click to hide benchmark
Test Base PR %
fib/100/execute 685.4±0.85ms 28.2±0.09ms -95.89%
fib/100/prove 901.3±4.24ms 844.3±3.88ms -6.32%
fib/100/total 1614.3±4.71ms 898.3±10.25ms -44.35%
fib/1000/execute 690.4±1.50ms 37.6±0.09ms -94.55%
fib/1000/prove 914.8±4.40ms 862.2±4.34ms -5.75%
fib/1000/total 1634.8±8.08ms 925.0±6.53ms -43.42%
fib/10000/execute 746.8±1.24ms 132.2±0.13ms -82.30%
fib/10000/prove 3.4±0.01s 3.3±0.01s -2.94%
fib/10000/total 4.1±0.01s 3.5±0.01s -14.63%

@shkoo shkoo marked this pull request as ready for review May 12, 2023 17:30
@shkoo shkoo requested review from flaub and jbruestle May 12, 2023 17:31
@flaub
Copy link
Member

flaub commented May 12, 2023

Perf looks amazing!!

@shkoo shkoo enabled auto-merge (squash) May 12, 2023 22:19
@shkoo shkoo changed the title [WIP] Store memory image as a btree of pages Store memory image as a btree of pages May 12, 2023
@shkoo shkoo disabled auto-merge May 12, 2023 22:20
@shkoo shkoo enabled auto-merge (squash) May 12, 2023 22:20
@shkoo shkoo merged commit a10b511 into main May 12, 2023
12 checks passed
@shkoo shkoo deleted the nils/sparse-image branch May 12, 2023 22:42
@github-actions
Copy link

Benchmark for Linux-cuda e062357

Click to hide benchmark
Test Base PR %
fib/100/execute 322.8±0.30ms 21.5±0.13ms -93.34%
fib/100/prove 2.5±0.01s 1111.4±6.66ms -55.54%
fib/100/total 3.0±0.01s 1139.3±5.68ms -62.02%
fib/1000/execute 338.6±8.48ms 41.3±0.18ms -87.80%
fib/1000/prove 2.6±0.01s 1148.4±3.91ms -55.83%
fib/1000/total 3.1±0.01s 1190.9±3.98ms -61.58%
fib/10000/execute 461.4±7.87ms 240.2±1.86ms -47.94%
fib/10000/prove 6.9±0.05s 4.2±0.02s -39.13%
fib/10000/total 7.8±0.06s 4.5±0.04s -42.31%

Benchmark for Linux-default e062357

Click to hide benchmark
Test Base PR %
fib/100/execute 1435.9±4.76ms 56.2±1.27ms -96.09%
fib/100/prove 5.8±0.03s 5.1±0.03s -12.07%
fib/100/total 7.2±0.05s 5.1±0.02s -29.17%
fib/1000/execute 1444.9±18.97ms 76.3±0.31ms -94.72%
fib/1000/prove 5.8±0.05s 5.1±0.01s -12.07%
fib/1000/total 7.3±0.07s 5.2±0.04s -28.77%
fib/10000/execute 1566.9±2.72ms 284.8±0.88ms -81.82%
fib/10000/prove 22.1±0.18s 21.3±0.14s -3.62%
fib/10000/total 23.8±0.17s 21.5±0.07s -9.66%

Benchmark for macOS-default e062357

Click to hide benchmark
Test Base PR %
fib/100/execute 685.8±1.68ms 28.4±0.03ms -95.86%
fib/100/prove 3.7±0.06s 3.7±0.07s 0.00%
fib/100/total 4.5±0.06s 3.8±0.04s -15.56%
fib/1000/execute 690.9±1.30ms 37.5±0.07ms -94.57%
fib/1000/prove 3.7±0.08s 3.7±0.07s 0.00%
fib/1000/total 4.5±0.03s 3.8±0.05s -15.56%
fib/10000/execute 748.1±1.27ms 129.9±0.30ms -82.64%
fib/10000/prove 15.3±0.11s 15.2±0.10s -0.65%
fib/10000/total 16.1±0.07s 15.4±0.07s -4.35%

Benchmark for macOS-metal e062357

Click to hide benchmark
Test Base PR %
fib/100/execute 685.1±1.16ms 28.2±0.04ms -95.88%
fib/100/prove 906.7±3.41ms 850.7±4.37ms -6.18%
fib/100/total 1625.9±5.61ms 906.1±9.11ms -44.27%
fib/1000/execute 690.3±1.08ms 37.6±0.08ms -94.55%
fib/1000/prove 924.0±4.54ms 867.0±4.98ms -6.17%
fib/1000/total 1651.7±9.39ms 934.9±4.08ms -43.40%
fib/10000/execute 746.2±1.50ms 131.6±0.30ms -82.36%
fib/10000/prove 3.4±0.01s 3.3±0.01s -2.94%
fib/10000/total 4.1±0.01s 3.5±0.01s -14.63%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants