Skip to content

test: split test_basic_io() in vds.c to fix -Wframe-larger-than - #6737

Open
hyoklee wants to merge 8 commits into
HDFGroup:developfrom
hyoklee:fix-openbsd-arm64-warnings
Open

hyoklee wants to merge 8 commits into
HDFGroup:developfrom
hyoklee:fix-openbsd-arm64-warnings

Conversation

@hyoklee

@hyoklee hyoklee commented Oct 14, 2026

Copy link
Copy Markdown
Member

Describe your changes

Fixes the -Wframe-larger-than=16384 warning for test_basic_io() in test/vds.c on OpenBSD 7.9 arm64 (clang): stack frame size (21824) exceeds limit (16384).

  • Move tests 7-10 of test_basic_io() into a new test_basic_io_2(), which main() calls right after test_basic_io(). The new function sets up its own filenames and DCPL (with the same fill value) and has its own cleanup.
  • Make the large int buffers in both functions static. This alone only brought the frame down to 17184 bytes, so the split is also needed.

Verified with a build-only OpenBSD 7.9 arm64 job (cross-platform-actions), which built vds with no warnings: https://github.com/hyoklee/hdf5/actions/runs/38480526693. Locally (gcc, Linux), the vds test passes and the file is formatted with clang-format 17.

Issue ticket number (GitHub or JIRA)

Fixes #6736

Checklist before requesting a review

  • My code conforms to the guidelines in CONTRIBUTING.md
  • I made an entry in release_docs/CHANGELOG.md (bug fixes, new features) — N/A, test-only change
  • I added a test (bug fixes, new features) — N/A, test-only change

🤖 Generated with Claude Code

On OpenBSD 7.9 arm64 (clang), test_basic_io() had a 21824-byte stack
frame, over the -Wframe-larger-than=16384 limit. Split its tests 7-10
into a new test_basic_io_2() and make the large int buffers static so
each function's stack frame stays well under the limit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Review Checklist

This PR touches the following areas. Each needs a sign-off
from its listed owners before merging.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: To be triaged

Development

Successfully merging this pull request may close these issues.

test/vds.c: test_basic_io() stack frame exceeds -Wframe-larger-than=16384 on OpenBSD arm64

1 participant