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

Directly write to MutableBuffer in substring #1423

Merged
merged 2 commits into from
Mar 11, 2022

Conversation

viirya
Copy link
Member

@viirya viirya commented Mar 10, 2022

Which issue does this PR close?

Closes #1422.

Rationale for this change

substring               time:   [30.604 ms 30.681 ms 30.767 ms]                   
                        change: [-64.758% -64.555% -64.358%] (p = 0.00 < 0.05)
                        Performance has improved.
Found 13 outliers among 100 measurements (13.00%)
  6 (6.00%) high mild
  7 (7.00%) high severe

What changes are included in this PR?

Are there any user-facing changes?

@github-actions github-actions bot added the arrow Changes to the arrow crate label Mar 10, 2022
@viirya
Copy link
Member Author

viirya commented Mar 10, 2022

cc @sunchao @alamb

Copy link
Member

@sunchao sunchao left a comment

Choose a reason for hiding this comment

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

LGTM with one nit

create_string_array_with_len(size, null_density, 4)
}

/// Creates an random (but fixed-seeded) array of a given size, null density and length of string
Copy link
Member

Choose a reason for hiding this comment

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

nit: "a random"

Maybe: "Creates a random (but fixed-seeded) array of strings with given size, null density and length"

Copy link
Member Author

Choose a reason for hiding this comment

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

Fixed.

Copy link
Member Author

Choose a reason for hiding this comment

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

Actually I copied from other functions here. 😄

@codecov-commenter
Copy link

Codecov Report

Merging #1423 (9de478b) into master (1fbe618) will increase coverage by 0.03%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1423      +/-   ##
==========================================
+ Coverage   83.13%   83.17%   +0.03%     
==========================================
  Files         182      182              
  Lines       53321    53439     +118     
==========================================
+ Hits        44330    44449     +119     
+ Misses       8991     8990       -1     
Impacted Files Coverage Δ
arrow/src/compute/kernels/substring.rs 98.24% <100.00%> (-0.04%) ⬇️
arrow/src/util/bench_util.rs 95.45% <100.00%> (+0.21%) ⬆️
arrow/src/datatypes/datatype.rs 66.40% <0.00%> (-0.40%) ⬇️
arrow/src/array/ffi.rs 100.00% <0.00%> (ø)
arrow-flight/src/utils.rs 0.00% <0.00%> (ø)
parquet_derive/src/parquet_field.rs 66.21% <0.00%> (ø)
...ng/src/flight_server_scenarios/integration_test.rs 0.00% <0.00%> (ø)
arrow/src/array/array_binary.rs 93.28% <0.00%> (+0.05%) ⬆️
arrow/src/array/equal/mod.rs 93.24% <0.00%> (+0.33%) ⬆️
arrow/src/ipc/reader.rs 87.79% <0.00%> (+0.94%) ⬆️
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1fbe618...9de478b. Read the comment docs.

@sunchao sunchao merged commit 0d24777 into apache:master Mar 11, 2022
@sunchao
Copy link
Member

sunchao commented Mar 11, 2022

Merged, thanks!

@viirya
Copy link
Member Author

viirya commented Mar 11, 2022

Thanks @sunchao !

@viirya viirya deleted the improve_substring branch March 11, 2022 02:37
@alamb
Copy link
Contributor

alamb commented Mar 12, 2022

This is a nice change

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

Successfully merging this pull request may close these issues.

Improve substring kernel performance
4 participants