public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] INSTALL: Default to --enable-cet=auto
@ 2020-11-27 13:42 H.J. Lu
  2020-11-27 14:24 ` Richard Biener
  0 siblings, 1 reply; 9+ messages in thread
From: H.J. Lu @ 2020-11-27 13:42 UTC (permalink / raw)
  To: gcc-patches; +Cc: Richard Biener

	PR other/98027
	* doc/install: Default to --enable-cet=auto.
---
 gcc/doc/install.texi | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
index 5f879ca4cea..021c347cc09 100644
--- a/gcc/doc/install.texi
+++ b/gcc/doc/install.texi
@@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
 to add @option{-fcf-protection} and, if needed, other target
 specific options to a set of building options.
 
-The option is disabled by default.  When @code{--enable-cet=auto}
-is used, it is enabled on Linux/x86 if target binutils
-supports @code{Intel CET} instructions and disabled otherwise.
-In this case the target libraries are configured to get additional
-@option{-fcf-protection} option.
+@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
+target binutils supports @code{Intel CET} instructions and disabled
+otherwise.  In this case, the target libraries are configured to get
+additional @option{-fcf-protection} option.
 
 @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
 Generate RISC-V attribute by default, in order to record extra build
-- 
2.28.0


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 13:42 [PATCH] INSTALL: Default to --enable-cet=auto H.J. Lu
@ 2020-11-27 14:24 ` Richard Biener
  2020-11-27 14:54   ` H.J. Lu
  0 siblings, 1 reply; 9+ messages in thread
From: Richard Biener @ 2020-11-27 14:24 UTC (permalink / raw)
  To: H.J. Lu; +Cc: gcc-patches

OK.

On Fri, 27 Nov 2020, H.J. Lu wrote:

> 	PR other/98027
> 	* doc/install: Default to --enable-cet=auto.
> ---
>  gcc/doc/install.texi | 9 ++++-----
>  1 file changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
> index 5f879ca4cea..021c347cc09 100644
> --- a/gcc/doc/install.texi
> +++ b/gcc/doc/install.texi
> @@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
>  to add @option{-fcf-protection} and, if needed, other target
>  specific options to a set of building options.
>  
> -The option is disabled by default.  When @code{--enable-cet=auto}
> -is used, it is enabled on Linux/x86 if target binutils
> -supports @code{Intel CET} instructions and disabled otherwise.
> -In this case the target libraries are configured to get additional
> -@option{-fcf-protection} option.
> +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> +target binutils supports @code{Intel CET} instructions and disabled
> +otherwise.  In this case, the target libraries are configured to get
> +additional @option{-fcf-protection} option.
>  
>  @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
>  Generate RISC-V attribute by default, in order to record extra build
> 

-- 
Richard Biener <rguenther@suse.de>
SUSE Software Solutions Germany GmbH, Maxfeldstrasse 5, 90409 Nuernberg,
Germany; GF: Felix Imend

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 14:24 ` Richard Biener
@ 2020-11-27 14:54   ` H.J. Lu
  2020-11-27 16:22     ` Gerald Pfeifer
  2020-11-27 19:01     ` Matthias Klose
  0 siblings, 2 replies; 9+ messages in thread
From: H.J. Lu @ 2020-11-27 14:54 UTC (permalink / raw)
  To: Richard Biener; +Cc: GCC Patches

On Fri, Nov 27, 2020 at 6:24 AM Richard Biener <rguenther@suse.de> wrote:
>
> OK.
>
> On Fri, 27 Nov 2020, H.J. Lu wrote:
>
> >       PR other/98027
> >       * doc/install: Default to --enable-cet=auto.
> > ---
> >  gcc/doc/install.texi | 9 ++++-----
> >  1 file changed, 4 insertions(+), 5 deletions(-)
> >
> > diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
> > index 5f879ca4cea..021c347cc09 100644
> > --- a/gcc/doc/install.texi
> > +++ b/gcc/doc/install.texi
> > @@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
> >  to add @option{-fcf-protection} and, if needed, other target
> >  specific options to a set of building options.
> >
> > -The option is disabled by default.  When @code{--enable-cet=auto}
> > -is used, it is enabled on Linux/x86 if target binutils
> > -supports @code{Intel CET} instructions and disabled otherwise.
> > -In this case the target libraries are configured to get additional
> > -@option{-fcf-protection} option.
> > +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> > +target binutils supports @code{Intel CET} instructions and disabled
> > +otherwise.  In this case, the target libraries are configured to get
> > +additional @option{-fcf-protection} option.
> >
> >  @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
> >  Generate RISC-V attribute by default, in order to record extra build
> >
>

OK for backport to GCC 10?

-- 
H.J.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 14:54   ` H.J. Lu
@ 2020-11-27 16:22     ` Gerald Pfeifer
  2020-11-27 18:34       ` H.J. Lu
  2020-11-27 19:01     ` Matthias Klose
  1 sibling, 1 reply; 9+ messages in thread
From: Gerald Pfeifer @ 2020-11-27 16:22 UTC (permalink / raw)
  To: H.J. Lu; +Cc: GCC Patches, Richard Biener

On Fri, 27 Nov 2020, H.J. Lu via Gcc-patches wrote:
> +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> +target binutils supports @code{Intel CET} instructions and disabled
> +otherwise.  In this case, the target libraries are configured to get
> +additional @option{-fcf-protection} option.

Does that refer to the Linux kernel or GNU/Linux?

THe last sentence does not appear complete.  What do you want to say?

"...target libraries are built with @option{-fcf-protection}"?

On Fri, 27 Nov 2020, H.J. Lu via Gcc-patches wrote:
> OK for backport to GCC 10?

Yes, once we have resolved the above.

Gerald

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 16:22     ` Gerald Pfeifer
@ 2020-11-27 18:34       ` H.J. Lu
  2023-01-07 22:42         ` Gerald Pfeifer
  0 siblings, 1 reply; 9+ messages in thread
From: H.J. Lu @ 2020-11-27 18:34 UTC (permalink / raw)
  To: Gerald Pfeifer; +Cc: GCC Patches, Richard Biener

On Fri, Nov 27, 2020 at 8:22 AM Gerald Pfeifer <gerald@pfeifer.com> wrote:
>
> On Fri, 27 Nov 2020, H.J. Lu via Gcc-patches wrote:
> > +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> > +target binutils supports @code{Intel CET} instructions and disabled
> > +otherwise.  In this case, the target libraries are configured to get
> > +additional @option{-fcf-protection} option.
>
> Does that refer to the Linux kernel or GNU/Linux?
>
> THe last sentence does not appear complete.  What do you want to say?
>
> "...target libraries are built with @option{-fcf-protection}"?

The new wording is

---
@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
target binutils supports @code{Intel CET} instructions and disabled
otherwise.  In this case, the target libraries are configured to get
additional @option{-fcf-protection} option.
---

On Linux/x86, if binutils supports CET, target libraries will be compiled
with -fcf-protection}.

> On Fri, 27 Nov 2020, H.J. Lu via Gcc-patches wrote:
> > OK for backport to GCC 10?
>
> Yes, once we have resolved the above.
>
> Gerald



-- 
H.J.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 14:54   ` H.J. Lu
  2020-11-27 16:22     ` Gerald Pfeifer
@ 2020-11-27 19:01     ` Matthias Klose
  2020-11-27 19:28       ` H.J. Lu
  1 sibling, 1 reply; 9+ messages in thread
From: Matthias Klose @ 2020-11-27 19:01 UTC (permalink / raw)
  To: H.J. Lu, Richard Biener, Iain Buclaw; +Cc: GCC Patches

On 11/27/20 3:54 PM, H.J. Lu via Gcc-patches wrote:
> On Fri, Nov 27, 2020 at 6:24 AM Richard Biener <rguenther@suse.de> wrote:
>>
>> OK.
>>
>> On Fri, 27 Nov 2020, H.J. Lu wrote:
>>
>>>       PR other/98027
>>>       * doc/install: Default to --enable-cet=auto.
>>> ---
>>>  gcc/doc/install.texi | 9 ++++-----
>>>  1 file changed, 4 insertions(+), 5 deletions(-)
>>>
>>> diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
>>> index 5f879ca4cea..021c347cc09 100644
>>> --- a/gcc/doc/install.texi
>>> +++ b/gcc/doc/install.texi
>>> @@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
>>>  to add @option{-fcf-protection} and, if needed, other target
>>>  specific options to a set of building options.
>>>
>>> -The option is disabled by default.  When @code{--enable-cet=auto}
>>> -is used, it is enabled on Linux/x86 if target binutils
>>> -supports @code{Intel CET} instructions and disabled otherwise.
>>> -In this case the target libraries are configured to get additional
>>> -@option{-fcf-protection} option.
>>> +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
>>> +target binutils supports @code{Intel CET} instructions and disabled
>>> +otherwise.  In this case, the target libraries are configured to get
>>> +additional @option{-fcf-protection} option.
>>>
>>>  @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
>>>  Generate RISC-V attribute by default, in order to record extra build
>>>
>>
> 
> OK for backport to GCC 10?

I only found that because of failing package builds in a test rebuild. See
PR98025. Is it safe to backport that, if it breaks the ABI of a runtime library
shipped with GCC 10?

Matthias

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 19:01     ` Matthias Klose
@ 2020-11-27 19:28       ` H.J. Lu
  2020-11-27 20:26         ` Iain Buclaw
  0 siblings, 1 reply; 9+ messages in thread
From: H.J. Lu @ 2020-11-27 19:28 UTC (permalink / raw)
  To: Matthias Klose; +Cc: Richard Biener, Iain Buclaw, GCC Patches

On Fri, Nov 27, 2020 at 11:02 AM Matthias Klose <doko@ubuntu.com> wrote:
>
> On 11/27/20 3:54 PM, H.J. Lu via Gcc-patches wrote:
> > On Fri, Nov 27, 2020 at 6:24 AM Richard Biener <rguenther@suse.de> wrote:
> >>
> >> OK.
> >>
> >> On Fri, 27 Nov 2020, H.J. Lu wrote:
> >>
> >>>       PR other/98027
> >>>       * doc/install: Default to --enable-cet=auto.
> >>> ---
> >>>  gcc/doc/install.texi | 9 ++++-----
> >>>  1 file changed, 4 insertions(+), 5 deletions(-)
> >>>
> >>> diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
> >>> index 5f879ca4cea..021c347cc09 100644
> >>> --- a/gcc/doc/install.texi
> >>> +++ b/gcc/doc/install.texi
> >>> @@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
> >>>  to add @option{-fcf-protection} and, if needed, other target
> >>>  specific options to a set of building options.
> >>>
> >>> -The option is disabled by default.  When @code{--enable-cet=auto}
> >>> -is used, it is enabled on Linux/x86 if target binutils
> >>> -supports @code{Intel CET} instructions and disabled otherwise.
> >>> -In this case the target libraries are configured to get additional
> >>> -@option{-fcf-protection} option.
> >>> +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> >>> +target binutils supports @code{Intel CET} instructions and disabled
> >>> +otherwise.  In this case, the target libraries are configured to get
> >>> +additional @option{-fcf-protection} option.
> >>>
> >>>  @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
> >>>  Generate RISC-V attribute by default, in order to record extra build
> >>>
> >>
> >
> > OK for backport to GCC 10?
>
> I only found that because of failing package builds in a test rebuild. See
> PR98025. Is it safe to backport that, if it breaks the ABI of a runtime library

libphobos has some CET issues which have been fixed in GCC 11.

> shipped with GCC 10?
>

It is just a documentation change.


-- 
H.J.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 19:28       ` H.J. Lu
@ 2020-11-27 20:26         ` Iain Buclaw
  0 siblings, 0 replies; 9+ messages in thread
From: Iain Buclaw @ 2020-11-27 20:26 UTC (permalink / raw)
  To: Matthias Klose, H.J. Lu; +Cc: GCC Patches, Richard Biener

Excerpts from H.J. Lu's message of November 27, 2020 8:28 pm:
> On Fri, Nov 27, 2020 at 11:02 AM Matthias Klose <doko@ubuntu.com> wrote:
>>
>> On 11/27/20 3:54 PM, H.J. Lu via Gcc-patches wrote:
>> > On Fri, Nov 27, 2020 at 6:24 AM Richard Biener <rguenther@suse.de> wrote:
>> >>
>> >> OK.
>> >>
>> >> On Fri, 27 Nov 2020, H.J. Lu wrote:
>> >>
>> >>>       PR other/98027
>> >>>       * doc/install: Default to --enable-cet=auto.
>> >>> ---
>> >>>  gcc/doc/install.texi | 9 ++++-----
>> >>>  1 file changed, 4 insertions(+), 5 deletions(-)
>> >>>
>> >>> diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi
>> >>> index 5f879ca4cea..021c347cc09 100644
>> >>> --- a/gcc/doc/install.texi
>> >>> +++ b/gcc/doc/install.texi
>> >>> @@ -2259,11 +2259,10 @@ instrumentation, see @option{-fcf-protection} option.  When
>> >>>  to add @option{-fcf-protection} and, if needed, other target
>> >>>  specific options to a set of building options.
>> >>>
>> >>> -The option is disabled by default.  When @code{--enable-cet=auto}
>> >>> -is used, it is enabled on Linux/x86 if target binutils
>> >>> -supports @code{Intel CET} instructions and disabled otherwise.
>> >>> -In this case the target libraries are configured to get additional
>> >>> -@option{-fcf-protection} option.
>> >>> +@code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
>> >>> +target binutils supports @code{Intel CET} instructions and disabled
>> >>> +otherwise.  In this case, the target libraries are configured to get
>> >>> +additional @option{-fcf-protection} option.
>> >>>
>> >>>  @item --with-riscv-attribute=@samp{yes}, @samp{no} or @samp{default}
>> >>>  Generate RISC-V attribute by default, in order to record extra build
>> >>>
>> >>
>> >
>> > OK for backport to GCC 10?
>>
>> I only found that because of failing package builds in a test rebuild. See
>> PR98025. Is it safe to backport that, if it breaks the ABI of a runtime library
> 
> libphobos has some CET issues which have been fixed in GCC 11.
> 

There's still a remaining issue (see PR 98025) that I'm about to push a
fix for.

>> shipped with GCC 10?
>>
> 
> It is just a documentation change.
> 

I don't think the backport is necessary, as it is default disabled in
GCC 10.  It was only at the beginning of the GCC 11 development cycle
that it got changed to default auto.

Iain.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH] INSTALL: Default to --enable-cet=auto
  2020-11-27 18:34       ` H.J. Lu
@ 2023-01-07 22:42         ` Gerald Pfeifer
  0 siblings, 0 replies; 9+ messages in thread
From: Gerald Pfeifer @ 2023-01-07 22:42 UTC (permalink / raw)
  To: H.J. Lu; +Cc: gcc-patches, Richard Biener

On Fri, 27 Nov 2020, H.J. Lu wrote:
> The new wording is
> 
> ---
> @code{--enable-cet=auto} is default.  CET is enabled on Linux/x86 if
> target binutils supports @code{Intel CET} instructions and disabled
> otherwise.  In this case, the target libraries are configured to get
> additional @option{-fcf-protection} option.
> ---
> 
> On Linux/x86, if binutils supports CET, target libraries will be compiled
> with -fcf-protection}.

I'm afraid this (the last sentence) is not really clear reading what is in 
install.texi.

Maybe instead of 

  "In this case, the target libraries are configured to get additional 
  @option{-fcf-protection} option."

something like

  "In the former case the target libraries are additionally configured 
  with @option{-fcf-protection}." ?

Gerald

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-01-07 22:42 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-27 13:42 [PATCH] INSTALL: Default to --enable-cet=auto H.J. Lu
2020-11-27 14:24 ` Richard Biener
2020-11-27 14:54   ` H.J. Lu
2020-11-27 16:22     ` Gerald Pfeifer
2020-11-27 18:34       ` H.J. Lu
2023-01-07 22:42         ` Gerald Pfeifer
2020-11-27 19:01     ` Matthias Klose
2020-11-27 19:28       ` H.J. Lu
2020-11-27 20:26         ` Iain Buclaw

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).