Skip to content

Conversation

@eisenhauer
Copy link
Member

This fixes BP5 files written on big-endian architectures (like s390x) to be readable on little-endian architectures (like x86) and vice versa.

Tested with BP5 files written on s390x (big-endian) and read on x86 (little-endian).

Bumps the all-actions group with 1 update: [github/codeql-action](https://github.com/github/codeql-action).


Updates `github/codeql-action` from 4.31.9 to 4.31.10
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@5d4e8d1...cdefb33)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.10
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-actions
...

Signed-off-by: dependabot[bot] <[email protected]>
@eisenhauer eisenhauer force-pushed the fix-bp5-cross-endian branch 4 times, most recently from 269938b to ba73f6e Compare January 14, 2026 21:21
@eisenhauer eisenhauer requested review from a team and caitlinross as code owners January 14, 2026 21:21
This fixes BP5 files written on big-endian architectures (like s390x) to be
readable on little-endian architectures (like x86) and vice versa.

Key fixes:

1. BP5Helper.cpp: Fix MetaMetaInfo buffer reversal on big-endian systems
   - helper::ReadArray() defaults isLittleEndian=true, which caused
     ReverseCopyFromBuffer to be called incorrectly on big-endian systems
   - Changed to helper::CopyFromBuffer() since data comes from MPI
     communication within the same architecture (native endian format)
   - This was the root cause of FFS format descriptors being reversed

2. BP5Deserializer: Add proper endianness tracking and byte-swapping
   - Track source and reader endianness via m_SourceIsLittleEndian and
     m_ReaderIsLittleEndian members
   - Add byte-swapping for primitive attributes when reading cross-endian
   - Fix complex number handling by halving element size and doubling
     the fastest-changing dimension, so NdCopy swaps real/imag separately
   - Pass endianness flags to NdCopy operations

3. BP5Reader.cpp: Pass endianness info from Minifooter to BP5Deserializer

4. CMakeLists.txt: Change Endian_Reverse default from AUTO to ON

5. Add s390x test archives for cross-endian compatibility testing

Tested with BP5 files written on s390x (big-endian) and read on x86
(little-endian).

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@eisenhauer eisenhauer force-pushed the fix-bp5-cross-endian branch from ba73f6e to ca8b388 Compare January 14, 2026 21:23
eisenhauer and others added 5 commits January 14, 2026 17:24
…tions/all-actions-e42aeb3dac

build(deps): bump github/codeql-action from 4.31.9 to 4.31.10 in the all-actions group
This fixes BP5 files written on big-endian architectures (like s390x) to be
readable on little-endian architectures (like x86) and vice versa.

Key fixes:

1. BP5Helper.cpp: Fix MetaMetaInfo buffer reversal on big-endian systems
   - helper::ReadArray() defaults isLittleEndian=true, which caused
     ReverseCopyFromBuffer to be called incorrectly on big-endian systems
   - Changed to helper::CopyFromBuffer() since data comes from MPI
     communication within the same architecture (native endian format)
   - This was the root cause of FFS format descriptors being reversed

2. BP5Deserializer: Add proper endianness tracking and byte-swapping
   - Track source and reader endianness via m_SourceIsLittleEndian and
     m_ReaderIsLittleEndian members
   - Add byte-swapping for primitive attributes when reading cross-endian
   - Fix complex number handling by halving element size and doubling
     the fastest-changing dimension, so NdCopy swaps real/imag separately
   - Pass endianness flags to NdCopy operations

3. BP5Reader.cpp: Pass endianness info from Minifooter to BP5Deserializer

4. CMakeLists.txt: Change Endian_Reverse default from AUTO to ON

5. Add s390x test archives for cross-endian compatibility testing

Tested with BP5 files written on s390x (big-endian) and read on x86
(little-endian).

Co-Authored-By: Claude Opus 4.5 <[email protected]>
…ADIOS2 into fix-bp5-cross-endian

* 'fix-bp5-cross-endian' of https://github.com/eisenhauer/ADIOS2:
  Fix BP5 cross-endian support for big-endian architectures (s390x)
…upport

Cross-endian file interoperability is now unconditionally enabled. This
simplifies the build configuration and ensures files written on big-endian
systems can always be read on little-endian systems and vice versa.

Co-Authored-By: Claude Opus 4.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants