From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yb1-xb30.google.com (mail-yb1-xb30.google.com [IPv6:2607:f8b0:4864:20::b30]) by sourceware.org (Postfix) with ESMTPS id 00C4F3858C83 for ; Wed, 19 Oct 2022 19:54:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 00C4F3858C83 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-yb1-xb30.google.com with SMTP id j130so1872074ybj.9 for ; Wed, 19 Oct 2022 12:54:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=sUCA+jKfCmabs9JFmh60zN1yt8QvJ7kMA+Xv0TryqvM=; b=Jl2IKmjlNxSFNiEOEsPuYonlZTTgBvgDQLzPtpbSeAqsyOI3CFdqa+GSyQDuXVYa5L LSgOq2Q2KewhmiWSAZq4Yd+eeb4xWVr1pUZHJHqAlIiZrU+nDJboprkRCjFmSU3HCHM5 O0OkF38OgHhyP4uHq7WKFqk5h7JF7952KpADqWQSZIrzZm5/Jg5r+5/CrJiDnBQQFHUo H16qvA8rI56uqW6lXQX+sZi6SJHU3iPDqxIS59615MdWmrymy/H9A4lklTLwkYQTJtjc kggcLz2oLIymrh0Xv4G2a5n+Np2DWsutNyWKSniz1V0sEp9y6ButoQB0eulo4YWetcs/ lmEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=sUCA+jKfCmabs9JFmh60zN1yt8QvJ7kMA+Xv0TryqvM=; b=j/bNVfHy+CzMk8mIRzWwP5k4PccQ18ov/fYzUDJIC5FbanIEvJS6CwbL9c7fvDpzOQ hLXQ2lszyfItmKwY/PdI/Pjq56hlBkOAdNWQQonWKnSAMr8Z6nsCmWsA59PHUhptpcmh TTQsLKy1NTnV+Q0/4/jyxiGHtShAVYHFNEiUT0cFamTZN21sbKrTkVuxGjXtq3v1m8vc x6G0ZaCpjvUISkWZrciGs0eCAVxrzIz/cssyEvv/I5OwvKDPJ3DlFWz09VVGMLbdlACO J1IkOKzbfBzwmANSw2XgxnRHwFEVgD+HW4+bXS3G46g9giBPIba4bM5qkZdKBkCxndb4 VGPA== X-Gm-Message-State: ACrzQf2NFVG1mqOPLQDvMI7InzH2FtZKaCayyEbdt5+hGpLpHz6Oc7E2 wHgCOlD+c+cHQJ6Xll4LdbgmL/0Ys3F5EdHAU/0= X-Google-Smtp-Source: AMsMyM7sxRVDPUJtE99w0TDU6eWkfnknQvb5OGY8/3LeemtK8hjvF8THvq5KGKKYi7bkpK40ejTiYSdBgFi6WJXuz3A= X-Received: by 2002:a05:6902:1387:b0:6b7:c393:63d1 with SMTP id x7-20020a056902138700b006b7c39363d1mr8440526ybu.34.1666209240318; Wed, 19 Oct 2022 12:54:00 -0700 (PDT) MIME-Version: 1.0 References: <0f1f223a-3756-1da3-bd1d-b87edd34e1f9@126.com> <7116A6F3-3968-4720-A65C-FFB05BFE181D@gmail.com> <7c519f0b-2a6d-e9bf-993a-2eff2cdad418@126.com> <0F33BB41-41EC-4068-84F1-9AD6DCCF190A@gmail.com> <0e667bcd-f8e0-2241-ee88-7a7cc883cba5@126.com> <5178a58a-816e-2f9e-e76d-361550674d67@gmail.com> <5bb8d79d-5262-6212-2846-f717f6337073@gmail.com> In-Reply-To: <5bb8d79d-5262-6212-2846-f717f6337073@gmail.com> From: Bernhard Reutner-Fischer Date: Wed, 19 Oct 2022 21:53:49 +0200 Message-ID: Subject: Re: Adding a new thread model to GCC To: Jonathan Yong <10walls@gmail.com> Cc: LIU Hao , GCC Patches , Bernhard Reutner-Fischer Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Wed, 19 Oct 2022 at 15:56, Jonathan Yong via Gcc-patches wrote: > Just pushed to master branch. Wouldn't you want to cut down on the libs respectively refine the order of the libs, though? You've now got: +#define MCFGTHREAD_SPEC " -lmcfgthread -lkernel32 -lntdll " +#else +#define MCFGTHREAD_SPEC "" +#endif #undef REAL_LIBGCC_SPEC #define REAL_LIBGCC_SPEC \ "%{mthreads:-lmingwthrd} -lmingw32 \ " SHARED_LIBGCC_SPEC " \ - -lmoldname -lmingwex -lmsvcrt -lkernel32" + -lmoldname -lmingwex -lmsvcrt -lkernel32 " MCFGTHREAD_SPEC which has kernel32 twice, which might not be ideal for the speed of linking? I'm not familiar with the content of ntdll so cannot judge if you'd put that in MCFGTHREAD_SPEC and drop kernel32 there, though, and put the whole MCFG spec simply before the kernel32 in the REAL_LIBGCC_SPEC. i.e. +#define MCFGTHREAD_SPEC " -lmcfgthread -lntdll " ... + -lmoldname -lmingwex -lmsvcrt " MCFGTHREAD_SPEC " -lkernel32 " I hope this is constructive. thanks,