- Package:
- libatomic-ops-dev
- Source:
- libatomic-ops
- Description:
- A library for atomic operations (development files)
- Submitter:
- Adam C Powell IV
- Date:
- 2010-01-25 17:42:11 UTC
- Severity:
- wishlist
Package: libatomic-ops-dev
Version: 1.2-4
Severity: wishlist
Please add (or request from upstream) 32-bit operations on 64-bit
platforms. For example, right now AO_HAVE_int_compare_and_swap is only
defined on ia64, not amd64 or any other 64-bit platform.
I think this should be possible to do in a non-arch-dependent header as
follows:
* Block the 64-bit aligned address of the 32-bit object
* Load, compare, and swap just the 32-bit portion in question
(using 32-bit fields in standard_ao_double_t.h)
* Unblock the 64-bit aligned address
The only thing this approach would lose is the ability to simultaneously
compare-and-swap two adjacent 32-bit values, but right now that's not
possible anyway. But it may be less straightforward, and in any case, I
don't know how to do it.
Background: OpenMPI requires 32-bit atomic operations for several
functions. It implements these in assembly on about half of the
architectures in Debian. To get it to work, one approach is to use
libatomic-ops-dev instead of upstream assembler. But that doesn't work
on non-ia64 64-bit architectures for the reason above.
Thank you,
-Adam
Hi, Upstream recently told me that the canonical source for libatomic-ops is the Boehm garbage collector, so your request would be appropriate on their mailing list. http://www.hpl.hp.com/personal/Hans_Boehm/gc/ gc@linux.hpl.hp.com Do you mind taking it up there? Cheers,
Hi, If I understand correctly, libatomic-ops was found not completly adequate for openmpi? Was this information passed to libatomic-ops upstream (which is boehm gc?).
Hi Riku! Am Samstag, den 04.04.2009, 23:17 +0300 schrieb Riku Voipio: We passed it to upstream a while ago. There was some preliminary patch which added some support to it but that was never finished or updated. I wanted to have a closer look at it once the other bugs are fixed and the transition is done. But it is currently not very high on my TODO list. If you can offer some help I would be very happy. Most of the work done so far should have references in the bug reports and/or the team mailing list. I can dig that out for you, if you like to. But it will be a few weeks until I can work on that. Best regards Manuel