bug-gnulib@gnu.org mirror (unofficial)
 help / color / mirror / Atom feed
From: Bruno Haible <bruno@clisp.org>
To: bug-gnulib@gnu.org
Cc: "Marc Nieper-Wißkirchen" <marc.nieper+gnu@gmail.com>
Subject: Re: Module suggestion: Atomic operations
Date: Wed, 01 Jul 2020 23:37:11 +0200	[thread overview]
Message-ID: <7592307.AFZmgL042g@omega> (raw)
In-Reply-To: <CAEYrNrSGU4WVHS7UUPNzhjtaR-6eHTQjWuKPVUvBHaJSLgmb7g@mail.gmail.com>

Marc Nieper-Wißkirchen wrote in
<https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00289.html>:
> C11 has introduced atomic types and atomic operations.  When they are not
> available, one can use locks/mutexes instead.
> 
> It would be nice if there was a Gnulib module that abstracts over this,
> much like the threadlib module and friends abstract over a specific
> threading implementation.

Practically speaking, the GCC built-ins available since GCC 4.1, and then
later extended on GCC 4.7, fulfill most of the needs regarding atomics. Only
AIX and SUNpro C on Solaris need to be handled on a case-by-case basis.

Bruno



      parent reply	other threads:[~2020-07-01 21:39 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-24 13:36 Module suggestion: Atomic operations Marc Nieper-Wißkirchen
2020-05-24 20:54 ` Bruno Haible
2020-05-25  7:03   ` Marc Nieper-Wißkirchen
2020-05-25  7:24     ` Bruno Haible
2020-05-25 20:11       ` Marc Nieper-Wißkirchen
2020-05-27  8:30         ` Bruno Haible
2020-07-01 21:37 ` Bruno Haible [this message]

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

  List information: https://lists.gnu.org/mailman/listinfo/bug-gnulib

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7592307.AFZmgL042g@omega \
    --to=bruno@clisp.org \
    --cc=bug-gnulib@gnu.org \
    --cc=marc.nieper+gnu@gmail.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).