Re: [PATCH] testsuite: Fix vfprintf-chk-1.c with -fhardened

2024-03-13 Thread Jakub Jelinek
On Wed, Mar 13, 2024 at 06:05:29PM +0800, Xi Ruoyao wrote: > On Tue, 2024-03-12 at 17:19 +0100, Jakub Jelinek wrote: > > On Thu, Feb 15, 2024 at 10:53:08PM +, Sam James wrote: > > > With _FORTIFY_SOURCE >= 2 (enabled by -fhardened), vfprintf-chk-1.c's > > > __vfprintf_chk ends up calling

Re: [PATCH] testsuite: Fix vfprintf-chk-1.c with -fhardened

2024-03-13 Thread Xi Ruoyao
On Tue, 2024-03-12 at 17:19 +0100, Jakub Jelinek wrote: > On Thu, Feb 15, 2024 at 10:53:08PM +, Sam James wrote: > > With _FORTIFY_SOURCE >= 2 (enabled by -fhardened), vfprintf-chk-1.c's > > __vfprintf_chk ends up calling __vprintf_chk rather than vprintf. Do we really want to support adding

Re: [PATCH] testsuite: Fix vfprintf-chk-1.c with -fhardened

2024-03-12 Thread Jakub Jelinek
On Thu, Feb 15, 2024 at 10:53:08PM +, Sam James wrote: > With _FORTIFY_SOURCE >= 2 (enabled by -fhardened), vfprintf-chk-1.c's > __vfprintf_chk ends up calling __vprintf_chk rather than vprintf. s/__vprintf_chk/__vfprintf_chk/ above > > ``` > --- a/fortify.s > +++ b/no-fortify.s > @@ -8,27

Re: [PATCH] testsuite: Fix vfprintf-chk-1.c with -fhardened

2024-03-12 Thread Sam James
Sam James writes: > With _FORTIFY_SOURCE >= 2 (enabled by -fhardened), vfprintf-chk-1.c's > __vfprintf_chk ends up calling __vprintf_chk rather than vprintf. > > ``` > --- a/fortify.s > +++ b/no-fortify.s > @@ -8,27 +8,28 @@ > [...] > __vfprintf_chk: > [...] > movl$1,

[PATCH] testsuite: Fix vfprintf-chk-1.c with -fhardened

2024-02-15 Thread Sam James
With _FORTIFY_SOURCE >= 2 (enabled by -fhardened), vfprintf-chk-1.c's __vfprintf_chk ends up calling __vprintf_chk rather than vprintf. ``` --- a/fortify.s +++ b/no-fortify.s @@ -8,27 +8,28 @@ [...] __vfprintf_chk: [...] movl$1, should_optimize(%rip) - jmp __vfprintf_chk +