Skip to content

GH-47564: [C++] Update expected L2 CPU cache range to 32KiB-64MiB - #47563

Merged
kou merged 1 commit into
apache:mainfrom
matshch:increase-l2-cache
Oct 10, 2025
Merged

kou merged 1 commit into
apache:mainfrom
matshch:increase-l2-cache

Conversation

@matshch

@matshch matshch commented Sep 15, 2025 •

Copy link
Copy Markdown
Contributor

Rationale for this change

On newer Apple silicon CPUs there is more L2 CPU cache than expected by the current unit tests. This results in the unit test failing:

/tmp/nix-build-arrow-cpp-20.0.0.drv-0/source/cpp/src/arrow/util/io_util_test.cc:1099: Failure
Value of: l2 >= 32 * 1024 && l2 <= 12 * 1024 * 1024
  Actual: false
Expected: true
unexpected L2 size: 16777216
[  FAILED  ] CpuInfo.Basic (0 ms)

What changes are included in this PR?

The expected L2 CPU cache range is increased to 32KiB-64MiB to accommodate newer CPUs.

Are these changes tested?

Yes.

Are there any user-facing changes?

No.

@github-actions

Copy link
Copy Markdown

Thanks for opening a pull request!

If this is not a minor PR. Could you open an issue for this pull request on GitHub? https://github.com/apache/arrow/issues/new/choose

Opening GitHub issues ahead of time contributes to the Openness of the Apache Arrow project.

Then could you also rename the pull request title in the following format?

GH-${GITHUB_ISSUE_ID}: [${COMPONENT}] ${SUMMARY}

or

MINOR: [${COMPONENT}] ${SUMMARY}

See also:

@matshch matshch changed the title Update expected L2 CPU cache range to 32KiB-64MiB GH-47564: [C++] Update expected L2 CPU cache range to 32KiB-64MiB Sep 15, 2025
@github-actions

Copy link
Copy Markdown

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

@kou kou left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

+1

@matshch

matshch commented Sep 19, 2025

Copy link
Copy Markdown
Contributor Author

Do we need to do anything else there to merge this PR?

@kou

kou commented Sep 19, 2025

Copy link
Copy Markdown
Member

I'll merge this in a few days if nobody objects it.

@matshch

matshch commented Oct 9, 2025

Copy link
Copy Markdown
Contributor Author

@kou ping

@kou

kou commented Oct 10, 2025

Copy link
Copy Markdown
Member

Oh, sorry. I forgot this... I'll merge this.

@conbench-apache-arrow

Copy link
Copy Markdown

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

There were no benchmark performance regressions. 🎉

The full Conbench report has more details.

@matshch
matshch deleted the increase-l2-cache branch October 13, 2025 21:26
zanmato1984 pushed a commit to zanmato1984/arrow that referenced this pull request Oct 15, 2025
…iB (apache#47563)

### Rationale for this change
On newer Apple silicon CPUs there is more L2 CPU cache than expected by the current unit tests. This results in the unit test failing:
```
/tmp/nix-build-arrow-cpp-20.0.0.drv-0/source/cpp/src/arrow/util/io_util_test.cc:1099: Failure
Value of: l2 >= 32 * 1024 && l2 <= 12 * 1024 * 1024
  Actual: false
Expected: true
unexpected L2 size: 16777216
[  FAILED  ] CpuInfo.Basic (0 ms)
```

### What changes are included in this PR?
The expected L2 CPU cache range is increased to 32KiB-64MiB to accommodate newer CPUs.

### Are these changes tested?
Yes.

### Are there any user-facing changes?
No.
* GitHub Issue: apache#47564

Authored-by: Artem Leshchev <matshch@avride.ai>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
Mottl pushed a commit to Mottl/arrow that referenced this pull request May 26, 2026
…iB (apache#47563)

### Rationale for this change
On newer Apple silicon CPUs there is more L2 CPU cache than expected by the current unit tests. This results in the unit test failing:
```
/tmp/nix-build-arrow-cpp-20.0.0.drv-0/source/cpp/src/arrow/util/io_util_test.cc:1099: Failure
Value of: l2 >= 32 * 1024 && l2 <= 12 * 1024 * 1024
  Actual: false
Expected: true
unexpected L2 size: 16777216
[  FAILED  ] CpuInfo.Basic (0 ms)
```

### What changes are included in this PR?
The expected L2 CPU cache range is increased to 32KiB-64MiB to accommodate newer CPUs.

### Are these changes tested?
Yes.

### Are there any user-facing changes?
No.
* GitHub Issue: apache#47564

Authored-by: Artem Leshchev <matshch@avride.ai>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
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