public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Sam James <sam@gentoo.org>
To: Xi Ruoyao <xry111@xry111.site>
Cc: gcc-patches@gcc.gnu.org, Gerald Pfeifer <gerald@pfeifer.com>,
	Jakub Jelinek <jakub@redhat.com>,
	Jeff Law <jlaw@ventanamicro.com>
Subject: Re: [PATCH] maintainer-scripts/gcc_release: compress xz in parallel
Date: Tue, 8 Nov 2022 07:40:02 +0000	[thread overview]
Message-ID: <9E6C1D21-0F77-4740-A9D3-9EE415D0AABD@gentoo.org> (raw)
In-Reply-To: <6e8d39e1e3e9d6ce5f0be5781023127187bcb995.camel@xry111.site>

[-- Attachment #1: Type: text/plain, Size: 1765 bytes --]



> On 8 Nov 2022, at 07:33, Xi Ruoyao <xry111@xry111.site> wrote:
> 
> On Tue, 2022-11-08 at 07:14 +0000, Sam James via Gcc-patches wrote:
>> 1. This should speed up decompression for folks, as parallel xz
>>    creates a different archive which can be decompressed in parallel.
>> 
>>    Note that this different method is enabled by default in a new
>>    xz release coming shortly anyway (>= 5.3.3_alpha1).
>> 
>>    I build GCC regularly from the weekly snapshots
>>    and so the decompression time adds up.
>> 
>> 2. It should speed up compression on the webserver a bit.
>> 
>>    Note that -T0 won't be the default in the new xz release,
>>    only the parallel compression mode (which enables parallel
>>    decompression).
>> 
>>    -T0 detects the number of cores available.
>> 
>>    So, if a different number of threads is preferred, it's fine
>>    to set e.g. -T2, etc.
> 
> I'm wondering if running xz -T0 on different machines (with different
> core numbers) may produce different compressed data.  The difference can
> cause trouble distributing checksums.
> 

Your question is a good one - xz -T0 produces different results to xz -T1
but:
1. The tarballs for GCC are only created on one machine and aren't
created repeatedly then compared with each other wrt mirroring;

2. Decompression still gives the same result;

3. xz is going to switch to this threaded decompressor output mode
shortly anyway. i.e. there's a slight change in output, but it's
what future versions are going to use anyway. It's deterministic
wrt -T1 and -Tn > 1.

i.e. it's about the compressor method (it produces chunks) rather
than anything else.

Plenty of other projects like LLVM (which also has a large distribution
tarball) use it without any problems.

Best,
sam

[-- Attachment #2: Message signed with OpenPGP --]
[-- Type: application/pgp-signature, Size: 358 bytes --]

  reply	other threads:[~2022-11-08  7:40 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-08  7:14 Sam James
2022-11-08  7:33 ` Xi Ruoyao
2022-11-08  7:40   ` Sam James [this message]
2022-11-08  8:52     ` Jakub Jelinek
2022-11-08  8:53       ` Sam James
2022-11-09  1:52   ` Joseph Myers
2022-11-09  2:06     ` Xi Ruoyao
2022-11-10 14:16       ` Martin Liška
2022-11-08  7:34 ` Eric Botcazou
2022-11-08  7:36   ` Sam James
2022-11-08  7:45     ` Sam James
2022-11-11 21:48 ` Sam James
2022-11-22 11:54   ` Richard Sandiford
2022-11-17 17:42 ` Sam James

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9E6C1D21-0F77-4740-A9D3-9EE415D0AABD@gentoo.org \
    --to=sam@gentoo.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=gerald@pfeifer.com \
    --cc=jakub@redhat.com \
    --cc=jlaw@ventanamicro.com \
    --cc=xry111@xry111.site \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).