Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepare 2.2.0 release #1741

Closed
wants to merge 130 commits into from
Closed

Prepare 2.2.0 release #1741

wants to merge 130 commits into from

Conversation

Dead2
Copy link
Member

@Dead2 Dead2 commented May 30, 2024

Due to the amount of refactoring changes and changes to memory allocations, this will be released as a new version branch 2.2.x.

Changes

Buildsystem

CI/Test

Cleanup

Refactoring and Optimizations

ARM

Power

RVV

S390x

x86

Misc

nmoinvaz and others added 30 commits January 15, 2024 13:00
We need to turn off support all higher instruction sets in order to hit code
for a lower instruction set.
Also add missing insert_string dependencies to windows makefiles.
…g and

avoid attempting to parse the includes more times than needed.
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
These were left on my part, the inline copy + checksum is the very
thing the function is doing.
* POWER8/9 feature checks were enabled even if the toolchain didn't support AT_HWCAP2
* Add detection if we need to include <linux/auxvec.h>
* For COMPAT mode, zlib-config.cmake and zlib-config-version.cmake
* For non-COMPAT mode, zlib-ng-config.cmake and zlib-ng-config-version.cmake
phprus and others added 25 commits May 6, 2024 22:50
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Currently the DFLTCC sanitizer instrumentation is limited to
MSAN-unpoisoning the parameter block. Add ASAN and MSAN checks;
also MSAN-unpoison the window.

Introduce the generic instrument_read(), instrument_write() and
instrument_read_write() macros, that are modeled after the repsective
functions in the Linux kernel.
Currently DFLTCC states are allocated using hook macros, complicating
memory management. Inline them into zlib states and remove the hooks.
- New dockerfile
  - Using native actions-runner instead of relying on qemu.
  - To support s390x, we include patches to actions-runner.
  - Using Almalinux 9 instead of Ubuntu, with functional .Net.
- Update CI workflow.
- Update readme guide.
Disable unneccessary compilation of tests, benchmarks, docs.
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
The Xeon Phi x200 family of processors (Knights Landing) supports
AVX512 (F, CD, ER, PF) but does not support AVX512 (VL, DQ, BW).

Because of processors like this, the Intel Software Developer's Manual
suggests the bits AVX512 (DQ,BW,VL) are also tested in EBX together with
AVX512F before deciding to run AVX512 (DQ,BW,VL) instructions.

This also adds a new x86 feature called avx512_common that indicates
that AVX512 (F,DQ,BW,VL) are all available and start using this for both
adler32_avx512 and crc32_vpclmulqdq implementations because they are
both built with -mavx512dq -mavx512bw -mavx512vl.

This has been reported downstream as
https://bugzilla.redhat.com/show_bug.cgi?id=2280347 .
The benchmarks fail to compile properly when built with ZLIB_COMPAT.
The name of the class cannot have the same name as the function.
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Check that calling inflateCopy() twice does not result in memory
corruption.
- Fix error in generating list of reports to upload.
- Clean up the implementation a bit.
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
Deflate used to call allocate 5 times during init.

- 5 calls to external alloc function now becomes 1
- Handling alignment of allocated buffers is simplified
  - Efforts to align the allocated buffer now needs to happen only once.
  - Individual buffers are ordered so that they have natural sequential alignment.
- Due to reduced losses to alignment, we allocate less memory in total.
- While doing alloc(), we now store pointer to corresponding free(), avoiding crashes
  with applications that incorrectly set alloc/free pointers after running init function.
- Removed need for extra padding after window, chunked reads can now go beyond the window
  buffer without causing a segfault.

Co-authored-by: Ilya Leoshkevich <iii@linux.ibm.com>
Inflate used to allocate state during init, but window would be allocated
when/if needed and could be resized and that required a new free/alloc round.

- Now, we allocate state and a 32K window during init, allowing the latency cost
  of allocs to be done during init instead of at one or more times later.
- Total memory allocation is about the same when requesting a 32K window, but
  if now window or a smaller window was requested, then it is an increase.
- While doing alloc(), we now store pointer to corresponding free(), avoiding crashes
  with applications that incorrectly set alloc/free pointers after running init function.
- After init has succeeded, inflate will no longer possibly fail due to a failing malloc.

Co-authored-by: Ilya Leoshkevich <iii@linux.ibm.com>
… tests.

Co-authored-by: Ilya Leoshkevich <iii@linux.ibm.com>
worry about failed allocs other than during init.
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
/* ===========================================================================
* Free all allocated deflate buffers
*/
static inline void free_deflate(PREFIX3(stream) *strm) {

Check notice

Code scanning / CodeQL

Unused static function Note

Static function free_deflate is unreachable
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
inflate.c Fixed Show fixed Hide fixed
@Dead2 Dead2 closed this Jun 12, 2024
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.

None yet