public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/28703] New: RISC-V: _dl_init might be called with unaligned stack
@ 2021-12-15 23:11 aurelien at aurel32 dot net
  2021-12-17 19:30 ` [Bug libc/28703] " cvs-commit at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: aurelien at aurel32 dot net @ 2021-12-15 23:11 UTC (permalink / raw)
  To: glibc-bugs

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

            Bug ID: 28703
           Summary: RISC-V: _dl_init might be called with unaligned stack
           Product: glibc
           Version: 2.35
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
          Assignee: unassigned at sourceware dot org
          Reporter: aurelien at aurel32 dot net
                CC: drepper.fsp at gmail dot com
  Target Milestone: ---

On RISC-V, _dl_init should be called with the stack aligned to 128 bits or 16
bytes as per RISC-V ABI [1].

This is detected by:

FAIL: elf/tst-align2


[1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc

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

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

* [Bug libc/28703] RISC-V: _dl_init might be called with unaligned stack
  2021-12-15 23:11 [Bug libc/28703] New: RISC-V: _dl_init might be called with unaligned stack aurelien at aurel32 dot net
@ 2021-12-17 19:30 ` cvs-commit at gcc dot gnu.org
  2021-12-17 19:30 ` aurelien at aurel32 dot net
  2021-12-17 21:50 ` cvs-commit at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-17 19:30 UTC (permalink / raw)
  To: glibc-bugs

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

--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Aurelien Jarno <aurel32@sourceware.org>:

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

commit 225da459cebef1037dcd78b56471edc0721e1c41
Author: Aurelien Jarno <aurelien@aurel32.net>
Date:   Thu Dec 16 00:06:28 2021 +0100

    riscv: align stack before calling _dl_init [BZ #28703]

    Align the stack pointer to 128 bits during the call to _dl_init() as
    specified by the RISC-V ABI [1]. This fixes the elf/tst-align2 test.

    Fixes bug 28703.

    [1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc

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

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

* [Bug libc/28703] RISC-V: _dl_init might be called with unaligned stack
  2021-12-15 23:11 [Bug libc/28703] New: RISC-V: _dl_init might be called with unaligned stack aurelien at aurel32 dot net
  2021-12-17 19:30 ` [Bug libc/28703] " cvs-commit at gcc dot gnu.org
@ 2021-12-17 19:30 ` aurelien at aurel32 dot net
  2021-12-17 21:50 ` cvs-commit at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: aurelien at aurel32 dot net @ 2021-12-17 19:30 UTC (permalink / raw)
  To: glibc-bugs

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

Aurelien Jarno <aurelien at aurel32 dot net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|NEW                         |RESOLVED

--- Comment #2 from Aurelien Jarno <aurelien at aurel32 dot net> ---
Fixed in 2.35.

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

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

* [Bug libc/28703] RISC-V: _dl_init might be called with unaligned stack
  2021-12-15 23:11 [Bug libc/28703] New: RISC-V: _dl_init might be called with unaligned stack aurelien at aurel32 dot net
  2021-12-17 19:30 ` [Bug libc/28703] " cvs-commit at gcc dot gnu.org
  2021-12-17 19:30 ` aurelien at aurel32 dot net
@ 2021-12-17 21:50 ` cvs-commit at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2021-12-17 21:50 UTC (permalink / raw)
  To: glibc-bugs

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

--- Comment #3 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
The release/2.34/master branch has been updated by Aurelien Jarno
<aurel32@sourceware.org>:

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

commit aa3a97496c82a8443039248ebee650322c9480f4
Author: Aurelien Jarno <aurelien@aurel32.net>
Date:   Thu Dec 16 00:06:28 2021 +0100

    riscv: align stack before calling _dl_init [BZ #28703]

    Align the stack pointer to 128 bits during the call to _dl_init() as
    specified by the RISC-V ABI [1]. This fixes the elf/tst-align2 test.

    Fixes bug 28703.

    [1] https://github.com/riscv-non-isa/riscv-elf-psabi-doc

    (cherry picked from commit 225da459cebef1037dcd78b56471edc0721e1c41)

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

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

end of thread, other threads:[~2021-12-17 21:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-15 23:11 [Bug libc/28703] New: RISC-V: _dl_init might be called with unaligned stack aurelien at aurel32 dot net
2021-12-17 19:30 ` [Bug libc/28703] " cvs-commit at gcc dot gnu.org
2021-12-17 19:30 ` aurelien at aurel32 dot net
2021-12-17 21:50 ` 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).