public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* [RFC][PATCH 0/2] Make sparcv8 work again on cas enabled hardware
@ 2016-11-01 15:08 Andreas Larsson
  2016-11-01 15:08 ` [RFC][PATCH 1/2] sparc32: Mark sendmsg and recvmsg system calls as unsupported Andreas Larsson
                   ` (2 more replies)
  0 siblings, 3 replies; 30+ messages in thread
From: Andreas Larsson @ 2016-11-01 15:08 UTC (permalink / raw)
  To: GNU C Library
  Cc: Adhemerval Zanella, Carlos O'Donell, David Miller,
	Torvald Riegel, software

This patch series:

1) Fixes a sparcv8 bug introduced since the #error was added to
sysdeps/sparc/sparc32/pthread_barrier_wait.c in 2.23. This fix stops
incorrect usage of sendmsg and recvmsg Linux system calls for sparcv8.

2) Makes use of the CASA compare and swap instruction for atomic_*
functions sparcv8, that is available for most LEON3 and LEON4 designs
and implied by -mcpu=leon3, but not part of the sparcv8 standard. To
allow for easy kernel emulation on systems that lack the instruction,
the CASA instruction is used for all writing atomic_* functions. This
approach is discussed in thread [1].

Any comments are most welcome. The spin lock based sparcv8 semaphore
implementation is currently unchanged by this patchset, but I would say
that that should go as well. I will look into that as well, but I have
not tested that yet.

[1] https://sourceware.org/ml/libc-alpha/2016-10/msg00344.html

Andreas Larsson (2):
  sparc32: Mark sendmsg and recvmsg system calls as unsupported
  sparc32: Use cas for atomic_* operations and use general
    pthread_barrier_wait

 sysdeps/sparc/sparc32/atomic-machine.h          |  228 +++++------------------
 sysdeps/sparc/sparc32/pthread_barrier_wait.c    |    1 -
 sysdeps/unix/sysv/linux/sparc/kernel-features.h |    4 +-
 3 files changed, 53 insertions(+), 180 deletions(-)
 delete mode 100644 sysdeps/sparc/sparc32/pthread_barrier_wait.c

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

end of thread, other threads:[~2016-11-04 18:44 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-01 15:08 [RFC][PATCH 0/2] Make sparcv8 work again on cas enabled hardware Andreas Larsson
2016-11-01 15:08 ` [RFC][PATCH 1/2] sparc32: Mark sendmsg and recvmsg system calls as unsupported Andreas Larsson
2016-11-01 17:28   ` Adhemerval Zanella
2016-11-02 11:38     ` Andreas Larsson
2016-11-02 12:49       ` Adhemerval Zanella
2016-11-04 18:36   ` David Miller
2016-11-01 15:08 ` [RFC][PATCH 2/2] sparc32: Use cas for atomic_* operations and use general pthread_barrier_wait Andreas Larsson
2016-11-04 18:37   ` David Miller
2016-11-04 18:44     ` David Miller
2016-11-01 16:00 ` [RFC][PATCH 0/2] Make sparcv8 work again on cas enabled hardware Torvald Riegel
2016-11-01 16:09   ` David Miller
2016-11-01 16:46     ` Torvald Riegel
2016-11-01 16:51       ` David Miller
2016-11-02 10:05         ` Torvald Riegel
2016-11-02 11:29           ` Andreas Larsson
2016-11-02 15:32           ` David Miller
2016-11-02 22:33             ` Torvald Riegel
2016-11-03  2:52               ` David Miller
2016-11-03 15:39                 ` Torvald Riegel
2016-11-03 17:22                   ` David Miller
2016-11-03 18:41                     ` Adhemerval Zanella
2016-11-03 20:33                       ` David Miller
2016-11-03 21:29                         ` Adhemerval Zanella
2016-11-03 22:25                         ` Torvald Riegel
2016-11-04 10:28                     ` Andreas Larsson
2016-11-04 15:23                       ` David Miller
2016-11-04 13:55                     ` Richard Henderson
2016-11-04 15:31                       ` David Miller
2016-11-04 16:10                         ` Richard Henderson
2016-11-04 14:04                     ` Richard Henderson

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