manuzhang opened a new pull request, #4043: URL: https://github.com/apache/avro/pull/4043
## What is the purpose of the change Avro C++ copies native memory bytes when encoding and decoding float/double values. On big-endian hosts such as s390x, encoding float `1.0` produces `3f 80 00 00` instead of the required `00 00 80 3f`, and decoding valid little-endian Avro bytes returns the wrong value. Normalize the four binary floating-point methods to little-endian byte order while preserving raw IEEE 754 bits. Jira issue: pending creation because API authentication is unavailable. This PR remains a draft until the issue is linked and its ID is added to the PR title and commit subject. ## Verifying this change Added independent golden-byte checks for float and double encoding and decoding, covering signed zero, finite and subnormal limits, infinities, and quiet NaN payloads with stream chunk sizes of 1, 3, and 16 bytes. Local validation on the exact published source: - Full `CodecTests` suite passes on macOS and Linux ARM64: 852 test cases and 103,659 assertions on each. - GCC 14 s390x cross-build under QEMU: all 132 new assertions pass; the original codec fails 120 of the same 132 assertions. - Patch applicability with strict whitespace checks and formatting of changed regions pass. The s390x result is emulated, rather than a physical s390x run. ## Documentation - Does this pull request introduce a new feature? No; it fixes binary-format compliance. - Documentation changes: not applicable. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
