HappenLee opened a new pull request, #67727: URL: https://github.com/apache/doris/pull/67727
### What problem does this PR solve? Related PR: https://github.com/StarRocks/starrocks/pull/78566 Doris builds Snappy 1.1.10 without enabling its available SIMD paths. Upgrade to 1.2.1 and enable SSSE3 on x86_64 (within the BE's existing SSE4.2 baseline) and ARM CRC32 through `ARM_MARCH` (default `armv8-a+crc`). Preserve RTTI for `SnappySlicesSource` and remove the sign-compare patch already included upstream. Existing codec interfaces and default compression selection remain unchanged; bRPC's embedded `butil::snappy` is outside this change. Add coverage for binary data, 64 KiB boundaries, empty and uneven slices, truncated and invalid streams, insufficient output capacity, and frozen 1.1.10 compressed data. Use byte-exact comparisons in the existing round-trip tests. On a Xeon Platinum 8457C, with Clang 16.0.6 for both versions, seven-run median CPU-time microbenchmarks gave these results for the upgrade plus build flags: | Input | Compression | Decompression | | --- | ---: | ---: | | 1 MiB repeated binary | +24.2% | +126.7% | | Upstream HTML corpus | -12.4% | +20.4% | | Upstream URL corpus | -7.6% | +12.6% | These are single-threaded, hot-buffer library measurements on a shared host, with preallocated output buffers and at least 0.1 CPU seconds per measurement. They are not SQL or ARM performance claims. Results vary by input, and the larger upstream hash table adds up to 32 KiB of temporary compression memory. ### Release note Upgrade the BE Snappy dependency to 1.2.1 and enable SIMD paths within the existing supported CPU baseline. Snappy data remains format-compatible; performance and compressed bytes can vary by input. ### Check List (For Author) - Test: - [x] Unit Test: `run-be-ut.sh -j 48 --run --filter='BlockCompressionTest.*'` — all 5 tests pass under ASAN. - [x] Manual test: build the final Snappy library through `thirdparty/build-thirdparty.sh -j 48 snappy`; verify 24 inputs in each direction between 1.1.10 and the final library; run compression/decompression microbenchmarks on 12 inputs. - [x] Shell syntax, build hygiene, clang-format 16, and changed-line clang-tidy checks pass. - ARM CRC32 intrinsic code generation checked; no ARM hardware test performed. - Local BE tests ran before cherry-picking onto current Apache master; the codec and test file contents are identical after the cherry-pick. CI will validate integration with the new base. - Behavior changed: - [x] Yes. Compression output and performance can change; the format and codec interfaces remain compatible. - Does this need documentation? - [x] No. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
