From: Ludwig Rydberg <ludwig.rydberg@gaisler.com>
To: libc-alpha@sourceware.org
Cc: adhemerval.zanella@linaro.org, software@gaisler.com,
Andreas Larsson <andreas@gaisler.com>,
Ludwig Rydberg <ludwig.rydberg@gaisler.com>
Subject: [PATCH] sparc: Fix broken memset for sparc32 [BZ #31068]
Date: Wed, 15 Nov 2023 13:29:43 +0100 [thread overview]
Message-ID: <20231115122943.22799-1-ludwig.rydberg@gaisler.com> (raw)
From: Andreas Larsson <andreas@gaisler.com>
Fixes commit a61933fe27df ("sparc: Remove bzero optimization") that
after moving code jumped to the wrong label 4.
Verfied by successfully running string/test-memset on sparc32.
Signed-off-by: Andreas Larsson <andreas@gaisler.com>
Signed-off-by: Ludwig Rydberg <ludwig.rydberg@gaisler.com>
---
sysdeps/sparc/sparc32/memset.S | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sysdeps/sparc/sparc32/memset.S b/sysdeps/sparc/sparc32/memset.S
index ca29ff568501..1dc3a640e874 100644
--- a/sysdeps/sparc/sparc32/memset.S
+++ b/sysdeps/sparc/sparc32/memset.S
@@ -55,7 +55,7 @@ ENTRY(memset)
andcc %o0, 3, %o2
bne 3f
-4: andcc %o0, 4, %g0
+5: andcc %o0, 4, %g0
be 2f
mov %g3, %g2
@@ -139,7 +139,7 @@ ENTRY(memset)
stb %g3, [%o0 + 0x02]
2: sub %o2, 4, %o2
add %o1, %o2, %o1
- b 4b
+ b 5b
sub %o0, %o2, %o0
END(memset)
libc_hidden_builtin_def (memset)
base-commit: 8f22e36238c94e2a89da624e03c224895f9dd691
--
2.35.3
next reply other threads:[~2023-11-15 12:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-15 12:29 Ludwig Rydberg [this message]
2023-11-15 13:26 ` Adhemerval Zanella Netto
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231115122943.22799-1-ludwig.rydberg@gaisler.com \
--to=ludwig.rydberg@gaisler.com \
--cc=adhemerval.zanella@linaro.org \
--cc=andreas@gaisler.com \
--cc=libc-alpha@sourceware.org \
--cc=software@gaisler.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).