CVSROOT: /cvs Module name: src Changes by: d...@cvs.openbsd.org 2014/01/29 17:44:20
Modified files: share/man/man9 : Makefile atomic.9 Added files: share/man/man9 : atomic_add.9 atomic_cas.9 atomic_dec.9 atomic_inc.9 atomic_sub.9 atomic_swap.9 membar.9 sys/sys : atomic.h Log message: add an MI api for atomic ops in the kernel. this api has its origins in solaris, but we found it via netbsd. this provides an MI implementation by using gccs atomic builtins. if an arch wants to provide a better implementation it can simply provide the specific bit of the api it wants to replace as a macro. we're being conservative with this API and only providing it in the kernel, and only for uints, ulongs, and pointers. discussed at n2k14 and with hackers at length. ok kettenis@