Skip to content

perf: Use Cow in get_format_string in FFI_ArrowSchema#6853

Merged
andygrove merged 6 commits intoapache:mainfrom
andygrove:ffi-schema-bench
Dec 7, 2024
Merged

perf: Use Cow in get_format_string in FFI_ArrowSchema#6853
andygrove merged 6 commits intoapache:mainfrom
andygrove:ffi-schema-bench

Conversation

@andygrove
Copy link
Member

Which issue does this PR close?

N/A

Rationale for this change

We're using a lot of FFI in Comet and are looking for any performance wins we can get.

ffi_arrow_schema_try_from
                        time:   [497.34 ns 499.01 ns 500.56 ns]
                        change: [-11.996% -11.725% -11.490%] (p = 0.00 < 0.05)
                        Performance has improved.

What changes are included in this PR?

Use Cow in get_format_string to reduce some string allocations.

Are there any user-facing changes?

No

Loading
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.

3 participants