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

GH-43444: [C++] Add benchmark for binary view builder #43445

Merged
merged 5 commits into from
Jul 31, 2024

Conversation

mapleFU
Copy link
Member

@mapleFU mapleFU commented Jul 27, 2024

Rationale for this change

Adding benchmark for BinaryViewBuilder

What changes are included in this PR?

Adding benchmark for BinaryViewBuilder

Are these changes tested?

No

Are there any user-facing changes?

No

Copy link

⚠️ GitHub issue #43444 has been automatically assigned in GitHub to PR creator.

@@ -26,6 +26,7 @@
namespace arrow::util {

inline BinaryViewType::c_type ToInlineBinaryView(const void* data, int32_t size) {
assert(size <= BinaryViewType::kInlineSize);
Copy link
Member Author

Choose a reason for hiding this comment

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

https://godbolt.org/z/q8xjb8Ehe
From here, COMPILER ASSUMER might generate better code in C++

Copy link
Contributor

Choose a reason for hiding this comment

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

Which I think we be assumed when this is inlined from the if below.

@mapleFU
Copy link
Member Author

mapleFU commented Jul 27, 2024

@felipecrv Would you mind take a look?

@mapleFU mapleFU changed the title GH-43444: [C++][Parquet] Add benchmark for binary view builder GH-43444: [C++] Add benchmark for binary view builder Jul 27, 2024
@github-actions github-actions bot added awaiting committer review Awaiting committer review and removed awaiting review Awaiting review labels Jul 27, 2024
Copy link
Contributor

@felipecrv felipecrv left a comment

Choose a reason for hiding this comment

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

just nitpicks

return ToInlineBinaryView(data, size);
}

inline BinaryViewType::c_type ToLargeBinaryView(const void* data, int32_t size,
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: call this ToNonInlineBinaryView to not confuse people that might think a LARGE_BINARY_VIEW type exists. [I misread it like this at first :)]

@@ -26,6 +26,7 @@
namespace arrow::util {

inline BinaryViewType::c_type ToInlineBinaryView(const void* data, int32_t size) {
assert(size <= BinaryViewType::kInlineSize);
Copy link
Contributor

Choose a reason for hiding this comment

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

Which I think we be assumed when this is inlined from the if below.

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting committer review Awaiting committer review labels Jul 30, 2024
@github-actions github-actions bot added awaiting change review Awaiting change review and removed awaiting changes Awaiting changes labels Jul 30, 2024
@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting change review Awaiting change review labels Jul 30, 2024
@github-actions github-actions bot added awaiting change review Awaiting change review and removed awaiting changes Awaiting changes labels Jul 31, 2024
@felipecrv felipecrv merged commit c6be2df into apache:main Jul 31, 2024
39 checks passed
@felipecrv felipecrv removed the awaiting change review Awaiting change review label Jul 31, 2024
@github-actions github-actions bot added the awaiting merge Awaiting merge label Jul 31, 2024
@mapleFU mapleFU deleted the add-benchmark-for-binary-view-builder branch July 31, 2024 18:14
Copy link

After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit c6be2df.

There was 1 benchmark result indicating a performance regression:

The full Conbench report has more details. It also includes information about 29 possible false positives for unstable benchmarks that are known to sometimes produce them.

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

Successfully merging this pull request may close these issues.

2 participants