From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-x12d.google.com (mail-lf1-x12d.google.com [IPv6:2a00:1450:4864:20::12d]) by sourceware.org (Postfix) with ESMTPS id EADD73858C5E for ; Wed, 27 Sep 2023 17:54:39 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org EADD73858C5E Authentication-Results: sourceware.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=google.com Received: by mail-lf1-x12d.google.com with SMTP id 2adb3069b0e04-50302e8fca8so600e87.0 for ; Wed, 27 Sep 2023 10:54:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1695837278; x=1696442078; darn=gcc.gnu.org; h=content-transfer-encoding:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=KwHAF0CGcKbVHO9RVtaF/uQX/5dtohsvLw2K9Owj6SI=; b=IEfS591p6WQxPKbo+Rk5uLiExSbl1TiJskrQEnD4+h89TLgP0x0pB3xTA5MKnknIOA BoJluDAwj8T9dEmotfcZvKmqJ9fzz/bDeBXmfIRIRY2PIwOstaDj95lG9YtfFy6k6zmj DfTCTMaryDV/CB0N91Y/jF3/m1GXpaYQN2052d8oCXcem3ELgiHLXdSgXw8JCN5ZJggV K0qbBQXV+H+n9QhYRd3y/uNP33wglElZYHNbA+xm0T8rjSHjnT8JCb+lghPXQTA2E+K8 hX1cqlsmVehrnzkjFSr01yzp75Ax7TpViI8hG7fn2/jtKaIqL5nscFNZcjXrQ88e8FNx LQGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695837278; x=1696442078; h=content-transfer-encoding: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=KwHAF0CGcKbVHO9RVtaF/uQX/5dtohsvLw2K9Owj6SI=; b=DzDdH4Ul71u8fWk9nQ4wMX7fbPf+AofbzcrDGlxcv7Xtshi5QEu+59mX9PmnV9k2wC 7Ei8rh5bCPXrjr9sWjt1PTnY7eMw9Hz79vC99YM2r09Z9fL06ZtIbQ/WsChLYyck/8an 6ObCz2ehSvnBeQ2LZL1O1pzBds1eejx25cIsroIS8oQW6O883B95HxbOI0OXY2uskS67 nYSADf03CnvqP/9SLImVR1EC4pU7k+Sg7sfnVaGaHHH3dUlfr/3HyRbLMYEYn47/nSbt 3cJoF/7LUmINCGA6g/zfFsj0JO11kEkgwGQfCpnDFY+Ae8Nwl6foqJi+ijMCoyOUst72 zgQg== X-Gm-Message-State: AOJu0YwBqPC2K1nF+FQodbdOH88EP8yTGdkiMAup8nSbYy3Y1t+EW686 r3sfABnQvEn0lqJJyArkOIA9TWTYoePZRcA+Cr7BYxZfwhzazukMHztozA== X-Google-Smtp-Source: AGHT+IHn50jtF7mGy3B1So3BnXfrc4tOOqo4AAUF8VzPXum2oECyzINOfOTxNwx7g/P0BRUTlHmWSqnwjSPxjOX9rqQ= X-Received: by 2002:ac2:46e4:0:b0:502:932e:2e36 with SMTP id q4-20020ac246e4000000b00502932e2e36mr157294lfo.2.1695837277885; Wed, 27 Sep 2023 10:54:37 -0700 (PDT) MIME-Version: 1.0 References: <20230801195104.2183011-1-maskray@google.com> In-Reply-To: From: Fangrui Song Date: Wed, 27 Sep 2023 10:54:26 -0700 Message-ID: Subject: Re: [PATCH v4] i386: Allow -mlarge-data-threshold with -mcmodel=large To: gcc-patches@gcc.gnu.org, Florian Weimer , "H.J. Lu" , Jan Beulich , Jan Hubicka , Michael Matz , Uros Bizjak Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-16.9 required=5.0 tests=BAYES_00,BODY_8BITS,DKIMWL_WL_MED,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,ENV_AND_HDR_SPF_MATCH,KAM_MANYTO,KAM_SHORT,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL 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, Sep 13, 2023 at 11:19=E2=80=AFAM Fangrui Song = wrote: > > On Tue, Aug 22, 2023 at 12:19=E2=80=AFAM Fangrui Song wrote: > > > > On Tue, Aug 1, 2023 at 12:51=E2=80=AFPM Fangrui Song wrote: > > > > > > When using -mcmodel=3Dmedium, large data objects larger than the > > > -mlarge-data-threshold threshold are placed into large data sections > > > (.lrodata, .ldata, .lbss and some variants). GNU ld and ld.lld 17 pl= ace > > > .l* sections into separate output sections. If small and medium code > > > model object files are mixed, the .l* sections won't exert relocation > > > overflow pressure on sections in object files built with -mcmodel=3Ds= mall. > > > > > > However, when using -mcmodel=3Dlarge, -mlarge-data-threshold doesn't > > > apply. This means that the .rodata/.data/.bss sections may exert > > > relocation overflow pressure on sections in -mcmodel=3Dsmall object f= iles. > > > > > > This patch allows -mcmodel=3Dlarge to generate .l* sections and drops= an > > > unneeded documentation restriction that the value must be the same. > > > > > > Link: https://groups.google.com/g/x86-64-abi/c/jnQdJeabxiU > > > ("Large data sections for the large code model") > > > > > > Signed-off-by: Fangrui Song > > > > > > --- > > > Changes from v1 (https://gcc.gnu.org/pipermail/gcc-patches/2023-April= /616947.html): > > > * Clarify commit message. Add link to https://groups.google.com/g/x86= -64-abi/c/jnQdJeabxiU > > > > > > Changes from v2 > > > * Drop an uneeded limitation in the documentation. > > > > > > Changes from v3 > > > * Change scan-assembler directives to use \. to match literal . > > > --- > > > gcc/config/i386/i386.cc | 15 +++++++++------ > > > gcc/config/i386/i386.opt | 2 +- > > > gcc/doc/invoke.texi | 6 +++--- > > > gcc/testsuite/gcc.target/i386/large-data.c | 13 +++++++++++++ > > > 4 files changed, 26 insertions(+), 10 deletions(-) > > > create mode 100644 gcc/testsuite/gcc.target/i386/large-data.c > > > > > > [...] > > > > Ping:) > > Ping:) https://gcc.gnu.org/pipermail/gcc-patches/2023-August/625993.html > > (I don't have write access to gcc.) > > > -- > =E5=AE=8B=E6=96=B9=E7=9D=BF Ping? :) https://gcc.gnu.org/pipermail/gcc-patches/2023-August/625993.html (I don't have write access to gcc.) --=20 =E5=AE=8B=E6=96=B9=E7=9D=BF