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

Add all weighted shortest path #4922

Merged
merged 2 commits into from
Feb 20, 2025
Merged

Add all weighted shortest path #4922

merged 2 commits into from
Feb 20, 2025

Conversation

andyfengHKU
Copy link
Contributor

@andyfengHKU andyfengHKU commented Feb 17, 2025

Description

Add all weighted shortest path. The implementation follows single weighted shortest path so should be quite straight forward.

Split weighted shortest path implementation to different files (pure refactor).

Copy link

Benchmark Result

Master commit hash: ff20ff3ac9921dff1e70d1cd8a2e1d927edd3d3c
Branch commit hash: 473f8b9024c49a1278b527e8ff6d3280ed9bd6ed

Query Group Query Name Mean Time - Commit (ms) Mean Time - Master (ms) Diff
aggregation q24 742.84 726.52 16.33 (2.25%)
aggregation q28 6356.74 6373.14 -16.40 (-0.26%)
filter q14 145.28 128.77 16.51 (12.82%)
filter q15 141.73 123.36 18.37 (14.89%)
filter q16 319.31 300.18 19.13 (6.37%)
filter q17 463.20 445.43 17.77 (3.99%)
filter q18 1970.91 1925.34 45.57 (2.37%)
filter zonemap-node 106.23 88.45 17.78 (20.10%)
filter zonemap-node-lhs-cast 106.77 89.11 17.66 (19.82%)
filter zonemap-node-null 105.71 88.95 16.76 (18.84%)
filter zonemap-rel 5586.18 5580.08 6.10 (0.11%)
fixed_size_expr_evaluator q07 594.39 571.80 22.58 (3.95%)
fixed_size_expr_evaluator q08 822.62 803.46 19.16 (2.38%)
fixed_size_expr_evaluator q09 824.03 802.04 21.99 (2.74%)
fixed_size_expr_evaluator q10 262.11 236.71 25.40 (10.73%)
fixed_size_expr_evaluator q11 253.10 229.52 23.58 (10.27%)
fixed_size_expr_evaluator q12 250.27 226.86 23.41 (10.32%)
fixed_size_expr_evaluator q13 1472.63 1454.71 17.93 (1.23%)
fixed_size_seq_scan q23 137.15 108.40 28.75 (26.52%)
join q29 708.56 680.64 27.92 (4.10%)
join q30 10206.48 9822.19 384.29 (3.91%)
join q31 9.02 5.01 4.01 (80.11%)
join SelectiveTwoHopJoin 56.06 55.42 0.64 (1.15%)
ldbc_snb_ic q35 2651.27 2620.67 30.60 (1.17%)
ldbc_snb_ic q36 478.03 471.89 6.14 (1.30%)
ldbc_snb_is q32 3.52 5.70 -2.18 (-38.27%)
ldbc_snb_is q33 13.96 15.05 -1.09 (-7.23%)
ldbc_snb_is q34 1.18 1.12 0.06 (5.13%)
multi-rel multi-rel-large-scan 1377.56 1369.92 7.64 (0.56%)
multi-rel multi-rel-lookup 26.35 29.15 -2.80 (-9.59%)
multi-rel multi-rel-small-scan 91.99 61.28 30.71 (50.11%)
order_by q25 149.80 130.37 19.43 (14.91%)
order_by q26 470.88 454.82 16.07 (3.53%)
order_by q27 1411.03 1416.65 -5.62 (-0.40%)
recursive_join recursive-join-bidirection 285.44 323.29 -37.85 (-11.71%)
recursive_join recursive-join-dense 7097.59 7066.95 30.65 (0.43%)
recursive_join recursive-join-path 23663.82 23616.92 46.90 (0.20%)
recursive_join recursive-join-sparse 1057.29 1060.85 -3.55 (-0.33%)
recursive_join recursive-join-trail 7048.49 7025.93 22.56 (0.32%)
scan_after_filter q01 188.79 172.77 16.02 (9.27%)
scan_after_filter q02 173.72 169.48 4.24 (2.50%)
shortest_path_ldbc100 q37 91.14 86.77 4.37 (5.04%)
shortest_path_ldbc100 q38 382.08 370.80 11.28 (3.04%)
shortest_path_ldbc100 q39 66.07 64.88 1.19 (1.84%)
shortest_path_ldbc100 q40 474.94 419.56 55.39 (13.20%)
var_size_expr_evaluator q03 2079.45 2078.86 0.59 (0.03%)
var_size_expr_evaluator q04 2270.73 2206.24 64.50 (2.92%)
var_size_expr_evaluator q05 2638.07 2648.73 -10.67 (-0.40%)
var_size_expr_evaluator q06 1333.89 1343.47 -9.58 (-0.71%)
var_size_seq_scan q19 1467.35 1456.43 10.92 (0.75%)
var_size_seq_scan q20 2500.70 2432.76 67.94 (2.79%)
var_size_seq_scan q21 2304.17 2281.12 23.05 (1.01%)
var_size_seq_scan q22 130.45 126.34 4.10 (3.25%)

Copy link
Contributor

@ray6080 ray6080 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Have two minor comments for reference.

Copy link

Benchmark Result

Master commit hash: bf8c8b88cbdeb1a10e58e53a07a156ea72932d40
Branch commit hash: 865c0cfb8423c19bdc2ebc04f9c878fc37050508

Query Group Query Name Mean Time - Commit (ms) Mean Time - Master (ms) Diff
aggregation q24 739.50 722.70 16.80 (2.32%)
aggregation q28 6386.25 6396.89 -10.64 (-0.17%)
filter q14 128.72 130.34 -1.62 (-1.24%)
filter q15 132.68 125.08 7.60 (6.07%)
filter q16 303.81 306.73 -2.92 (-0.95%)
filter q17 455.36 448.03 7.34 (1.64%)
filter q18 1959.38 1934.88 24.50 (1.27%)
filter zonemap-node 88.89 94.15 -5.26 (-5.58%)
filter zonemap-node-lhs-cast 90.75 90.39 0.36 (0.40%)
filter zonemap-node-null 90.55 89.94 0.61 (0.68%)
filter zonemap-rel 5630.70 5587.69 43.02 (0.77%)
fixed_size_expr_evaluator q07 574.80 570.73 4.07 (0.71%)
fixed_size_expr_evaluator q08 805.92 801.53 4.38 (0.55%)
fixed_size_expr_evaluator q09 804.01 800.49 3.52 (0.44%)
fixed_size_expr_evaluator q10 242.05 236.62 5.43 (2.29%)
fixed_size_expr_evaluator q11 234.48 230.25 4.23 (1.84%)
fixed_size_expr_evaluator q12 231.58 226.52 5.06 (2.23%)
fixed_size_expr_evaluator q13 1462.20 1458.46 3.74 (0.26%)
fixed_size_seq_scan q23 112.25 108.92 3.33 (3.06%)
join q29 705.77 768.96 -63.20 (-8.22%)
join q30 10653.90 11630.24 -976.34 (-8.39%)
join q31 7.66 8.94 -1.28 (-14.31%)
join SelectiveTwoHopJoin 56.26 57.24 -0.98 (-1.71%)
ldbc_snb_ic q35 2672.41 2621.22 51.19 (1.95%)
ldbc_snb_ic q36 478.66 484.63 -5.97 (-1.23%)
ldbc_snb_is q32 3.93 5.68 -1.76 (-30.91%)
ldbc_snb_is q33 15.68 15.43 0.25 (1.64%)
ldbc_snb_is q34 1.21 1.20 0.01 (0.92%)
multi-rel multi-rel-large-scan 1346.16 1499.32 -153.16 (-10.22%)
multi-rel multi-rel-lookup 27.08 44.94 -17.86 (-39.75%)
multi-rel multi-rel-small-scan 86.27 88.16 -1.88 (-2.13%)
order_by q25 132.02 134.53 -2.51 (-1.87%)
order_by q26 456.17 461.64 -5.46 (-1.18%)
order_by q27 1424.29 1407.49 16.80 (1.19%)
recursive_join recursive-join-bidirection 310.22 305.79 4.43 (1.45%)
recursive_join recursive-join-dense 7119.51 7092.58 26.93 (0.38%)
recursive_join recursive-join-path 23542.71 23969.41 -426.70 (-1.78%)
recursive_join recursive-join-sparse 1068.44 1047.42 21.01 (2.01%)
recursive_join recursive-join-trail 7055.04 7036.01 19.03 (0.27%)
scan_after_filter q01 171.50 172.68 -1.18 (-0.68%)
scan_after_filter q02 156.42 157.25 -0.83 (-0.52%)
shortest_path_ldbc100 q37 93.85 82.22 11.63 (14.15%)
shortest_path_ldbc100 q38 376.85 325.19 51.66 (15.89%)
shortest_path_ldbc100 q39 62.96 60.50 2.46 (4.07%)
shortest_path_ldbc100 q40 375.55 299.15 76.39 (25.54%)
var_size_expr_evaluator q03 2063.16 2073.31 -10.14 (-0.49%)
var_size_expr_evaluator q04 2233.53 2212.19 21.34 (0.96%)
var_size_expr_evaluator q05 2651.31 2644.54 6.77 (0.26%)
var_size_expr_evaluator q06 1325.27 1329.93 -4.65 (-0.35%)
var_size_seq_scan q19 1453.51 1470.74 -17.23 (-1.17%)
var_size_seq_scan q20 2724.49 2772.24 -47.75 (-1.72%)
var_size_seq_scan q21 2381.19 2392.45 -11.26 (-0.47%)
var_size_seq_scan q22 126.49 125.08 1.41 (1.13%)

@andyfengHKU andyfengHKU merged commit fc33270 into master Feb 20, 2025
@andyfengHKU andyfengHKU deleted the all-wsp branch February 20, 2025 07:25
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.

2 participants