Menu

#1666 Allow to specify sliding window size for deflate and deflate64

open
nobody
None
5
2025-08-02
2025-08-01
Sam Tansy
No

Allow to specify sliding window/dictionary size for Deflate and Deflate64.
It can be fine tuned down do 4096 B for Lzma but not for Deflate. There is no good reason for it.

$ 7z a -m0=deflate -md=16k archive.7z files

$ 7z a -m0=deflate -md=16k archive.zip files

$ 7z a -m0=deflate64 -md=16k archive.zip files

(...)

System ERROR:
E_INVALIDARG : One or more arguments are invalid

I understand most people use 32 KiB window as, for the mos part, it gives higher compression ratio, but as it's on of two, the most important parameters for LZSS compression it should be available for tuning.

Discussion

  • Sam Tansy

    Sam Tansy - 2025-08-02

    It should be `-mm=...' for zip

    $ 7z a -mm=deflate -md16k archive.zip files
    
    $ 7z a -mm=deflate64 -md16k archive.zip files
    
    System ERROR:
    E_INVALIDARG
    

    But it still remains the same problem.

     
    • AlexS

      AlexS - 2025-08-02

      But it still remains the same problem.
      d={Size}[b|k|m] 900000 Sets Dictionary size for BZip2

       
      • Sam Tansy

        Sam Tansy - 2025-08-02

        I did not say anything about bzip2.
        Read a title of this ticket, read a command line provided, and show me where do you see `bzip2' there.

         
  • Igor Pavlov

    Igor Pavlov - 2025-08-02

    Small dictionary for deflate is useless.
    And there is no field in any archive container that stores dictionary size for deflate.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.