public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline
@ 2024-02-11 18:21 hjl.tools at gmail dot com
  2024-02-11 19:38 ` [Bug dynamic-link/31371] " fweimer at redhat dot com
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2024-02-11 18:21 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

            Bug ID: 31371
           Summary: APX registers aren't preserved in ld.so trampoline
           Product: glibc
           Version: 2.40
            Status: NEW
          Severity: normal
          Priority: P2
         Component: dynamic-link
          Assignee: unassigned at sourceware dot org
          Reporter: hjl.tools at gmail dot com
                CC: fweimer at redhat dot com
  Target Milestone: ---
            Target: x86-64

Because of:

/* Save SSE, AVX, AVX512, mask and bound registers.  */
#define STATE_SAVE_MASK \
  ((1 << 1) | (1 << 2) | (1 << 3) | (1 << 5) | (1 << 6) | (1 << 7))

APX registers aren't preserved.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] APX registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
@ 2024-02-11 19:38 ` fweimer at redhat dot com
  2024-02-11 19:39 ` [Bug dynamic-link/31371] x86-64: " fweimer at redhat dot com
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: fweimer at redhat dot com @ 2024-02-11 19:38 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #1 from Florian Weimer <fweimer at redhat dot com> ---
This only matters if BIND_NOW is used with a non-psABI calling convention,
right?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
  2024-02-11 19:38 ` [Bug dynamic-link/31371] " fweimer at redhat dot com
@ 2024-02-11 19:39 ` fweimer at redhat dot com
  2024-02-11 19:44 ` hjl.tools at gmail dot com
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: fweimer at redhat dot com @ 2024-02-11 19:39 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|APX registers aren't        |x86-64: APX registers
                   |preserved in ld.so          |aren't preserved in ld.so
                   |trampoline                  |trampoline
              Flags|                            |security-

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
  2024-02-11 19:38 ` [Bug dynamic-link/31371] " fweimer at redhat dot com
  2024-02-11 19:39 ` [Bug dynamic-link/31371] x86-64: " fweimer at redhat dot com
@ 2024-02-11 19:44 ` hjl.tools at gmail dot com
  2024-02-11 20:56 ` fw at deneb dot enyo.de
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2024-02-11 19:44 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Florian Weimer from comment #1)
> This only matters if BIND_NOW is used with a non-psABI calling convention,
> right?

Did you mean "BIND_NOW isn't used"?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (2 preceding siblings ...)
  2024-02-11 19:44 ` hjl.tools at gmail dot com
@ 2024-02-11 20:56 ` fw at deneb dot enyo.de
  2024-02-11 22:21 ` hjl.tools at gmail dot com
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: fw at deneb dot enyo.de @ 2024-02-11 20:56 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

Florian Weimer <fw at deneb dot enyo.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fw at deneb dot enyo.de

--- Comment #3 from Florian Weimer <fw at deneb dot enyo.de> ---
(In reply to H.J. Lu from comment #2)
> (In reply to Florian Weimer from comment #1)
> > This only matters if BIND_NOW is used with a non-psABI calling convention,
> > right?
> 
> Did you mean "BIND_NOW isn't used"?

Yes, indeed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (3 preceding siblings ...)
  2024-02-11 20:56 ` fw at deneb dot enyo.de
@ 2024-02-11 22:21 ` hjl.tools at gmail dot com
  2024-02-15 21:14 ` [Bug dynamic-link/31371] x86-64: APX and Tile " hjl.tools at gmail dot com
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2024-02-11 22:21 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #4 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Florian Weimer from comment #3)
> (In reply to H.J. Lu from comment #2)
> > (In reply to Florian Weimer from comment #1)
> > > This only matters if BIND_NOW is used with a non-psABI calling convention,
> > > right?
> > 
> > Did you mean "BIND_NOW isn't used"?
> 
> Yes, indeed.

Then it is correct.  I am testing a simple fix.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (4 preceding siblings ...)
  2024-02-11 22:21 ` hjl.tools at gmail dot com
@ 2024-02-15 21:14 ` hjl.tools at gmail dot com
  2024-02-25 17:22 ` cvs-commit at gcc dot gnu.org
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2024-02-15 21:14 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

H.J. Lu <hjl.tools at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|x86-64: APX registers       |x86-64: APX and Tile
                   |aren't preserved in ld.so   |registers aren't preserved
                   |trampoline                  |in ld.so trampoline

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (5 preceding siblings ...)
  2024-02-15 21:14 ` [Bug dynamic-link/31371] x86-64: APX and Tile " hjl.tools at gmail dot com
@ 2024-02-25 17:22 ` cvs-commit at gcc dot gnu.org
  2024-03-08 19:58 ` carlos at redhat dot com
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-02-25 17:22 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #5 from Sourceware Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by H.J. Lu <hjl@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=dfb05f8e704edac70db38c4c8ee700769d91a413

commit dfb05f8e704edac70db38c4c8ee700769d91a413
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Feb 16 07:17:10 2024 -0800

    x86-64: Save APX registers in ld.so trampoline

    Add APX registers to STATE_SAVE_MASK so that APX registers are saved in
    ld.so trampoline.  This fixes BZ #31371.

    Also update STATE_SAVE_OFFSET and STATE_SAVE_MASK for i386 which will
    be used by i386 _dl_tlsdesc_dynamic.
    Reviewed-by: Noah Goldstein <goldstein.w.n@gmail.com>

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (6 preceding siblings ...)
  2024-02-25 17:22 ` cvs-commit at gcc dot gnu.org
@ 2024-03-08 19:58 ` carlos at redhat dot com
  2024-03-08 19:59 ` hjl.tools at gmail dot com
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: carlos at redhat dot com @ 2024-03-08 19:58 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

Carlos O'Donell <carlos at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |carlos at redhat dot com

--- Comment #6 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Sourceware Commits from comment #5)
> The master branch has been updated by H.J. Lu <hjl@sourceware.org>:
> 
> https://sourceware.org/git/gitweb.cgi?p=glibc.git;
> h=dfb05f8e704edac70db38c4c8ee700769d91a413
> 
> commit dfb05f8e704edac70db38c4c8ee700769d91a413
> Author: H.J. Lu <hjl.tools@gmail.com>
> Date:   Fri Feb 16 07:17:10 2024 -0800
> 
>     x86-64: Save APX registers in ld.so trampoline
>     
>     Add APX registers to STATE_SAVE_MASK so that APX registers are saved in
>     ld.so trampoline.  This fixes BZ #31371.
>     
>     Also update STATE_SAVE_OFFSET and STATE_SAVE_MASK for i386 which will
>     be used by i386 _dl_tlsdesc_dynamic.
>     Reviewed-by: Noah Goldstein <goldstein.w.n@gmail.com>

Is this bug considered fixed now?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (7 preceding siblings ...)
  2024-03-08 19:58 ` carlos at redhat dot com
@ 2024-03-08 19:59 ` hjl.tools at gmail dot com
  2024-03-08 20:02 ` fweimer at redhat dot com
  2024-04-01 17:39 ` cvs-commit at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: hjl.tools at gmail dot com @ 2024-03-08 19:59 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #7 from H.J. Lu <hjl.tools at gmail dot com> ---
(In reply to Carlos O'Donell from comment #6)
> (In reply to Sourceware Commits from comment #5)
> > The master branch has been updated by H.J. Lu <hjl@sourceware.org>:
> > 
> > https://sourceware.org/git/gitweb.cgi?p=glibc.git;
> > h=dfb05f8e704edac70db38c4c8ee700769d91a413
> > 
> > commit dfb05f8e704edac70db38c4c8ee700769d91a413
> > Author: H.J. Lu <hjl.tools@gmail.com>
> > Date:   Fri Feb 16 07:17:10 2024 -0800
> > 
> >     x86-64: Save APX registers in ld.so trampoline
> >     
> >     Add APX registers to STATE_SAVE_MASK so that APX registers are saved in
> >     ld.so trampoline.  This fixes BZ #31371.
> >     
> >     Also update STATE_SAVE_OFFSET and STATE_SAVE_MASK for i386 which will
> >     be used by i386 _dl_tlsdesc_dynamic.
> >     Reviewed-by: Noah Goldstein <goldstein.w.n@gmail.com>
> 
> Is this bug considered fixed now?

Do we need to backport the fixes to release branches?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (8 preceding siblings ...)
  2024-03-08 19:59 ` hjl.tools at gmail dot com
@ 2024-03-08 20:02 ` fweimer at redhat dot com
  2024-04-01 17:39 ` cvs-commit at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: fweimer at redhat dot com @ 2024-03-08 20:02 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #8 from Florian Weimer <fweimer at redhat dot com> ---
(In reply to H.J. Lu from comment #7)
> Do we need to backport the fixes to release branches?

I think it's a necessary correctness fix, but it's not risk-free due to
increased stack size requirement. But it's the same as with lazy binding, so
hopefully it should be okay.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug dynamic-link/31371] x86-64: APX and Tile registers aren't preserved in ld.so trampoline
  2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
                   ` (9 preceding siblings ...)
  2024-03-08 20:02 ` fweimer at redhat dot com
@ 2024-04-01 17:39 ` cvs-commit at gcc dot gnu.org
  10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-04-01 17:39 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=31371

--- Comment #9 from Sourceware Commits <cvs-commit at gcc dot gnu.org> ---
The release/2.39/master branch has been updated by H.J. Lu
<hjl@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=7fc8242bf87828c935ac5df5cafb9dc7ab635fd9

commit 7fc8242bf87828c935ac5df5cafb9dc7ab635fd9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Feb 16 07:17:10 2024 -0800

    x86-64: Save APX registers in ld.so trampoline

    Add APX registers to STATE_SAVE_MASK so that APX registers are saved in
    ld.so trampoline.  This fixes BZ #31371.

    Also update STATE_SAVE_OFFSET and STATE_SAVE_MASK for i386 which will
    be used by i386 _dl_tlsdesc_dynamic.
    Reviewed-by: Noah Goldstein <goldstein.w.n@gmail.com>

    (cherry picked from commit dfb05f8e704edac70db38c4c8ee700769d91a413)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

end of thread, other threads:[~2024-04-01 17:39 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-11 18:21 [Bug dynamic-link/31371] New: APX registers aren't preserved in ld.so trampoline hjl.tools at gmail dot com
2024-02-11 19:38 ` [Bug dynamic-link/31371] " fweimer at redhat dot com
2024-02-11 19:39 ` [Bug dynamic-link/31371] x86-64: " fweimer at redhat dot com
2024-02-11 19:44 ` hjl.tools at gmail dot com
2024-02-11 20:56 ` fw at deneb dot enyo.de
2024-02-11 22:21 ` hjl.tools at gmail dot com
2024-02-15 21:14 ` [Bug dynamic-link/31371] x86-64: APX and Tile " hjl.tools at gmail dot com
2024-02-25 17:22 ` cvs-commit at gcc dot gnu.org
2024-03-08 19:58 ` carlos at redhat dot com
2024-03-08 19:59 ` hjl.tools at gmail dot com
2024-03-08 20:02 ` fweimer at redhat dot com
2024-04-01 17:39 ` cvs-commit at gcc dot gnu.org

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