[all-commits] [llvm/llvm-project] 79095b: [ELF] --compress-debug-sections=zstd: replace ZSTD...

Fangrui Song via All-commits all-commits at lists.llvm.org
Mon Apr 29 22:05:59 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 79095b4079e8d4f8176bcc53fdacd2765f310cdb
      https://github.com/llvm/llvm-project/commit/79095b4079e8d4f8176bcc53fdacd2765f310cdb
  Author: Fangrui Song <i at maskray.me>
  Date:   2024-04-29 (Mon, 29 Apr 2024)

  Changed paths:
    M lld/ELF/OutputSections.cpp

  Log Message:
  -----------
  [ELF] --compress-debug-sections=zstd: replace ZSTD_c_nbWorkers parallelism with multi-frame parallelism

https://reviews.llvm.org/D133679 utilizes zstd's multithread API to
create one single frame. This provides a higher compression ratio but is
significantly slower than concatenating multiple frames.

With manual parallelism, it is easier to parallelize memcpy in
OutputSection::writeTo for parallel memcpy.

In addition, as the individual allocated decompression buffers are much
smaller, we can make a wild guess (compressed_size/4) without worrying
about a resize (due to wrong guess) would waste memory.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list