From: Matthias Clasen Date: Thu, 15 Dec 2005 04:37:32 +0000 (+0000) Subject: Document new atomic operations. X-Git-Tag: GLIB_2_9_2~51 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=28dd7200d6aec8ccdd89c003ce4d29b299e730b4;p=platform%2Fupstream%2Fglib.git Document new atomic operations. 2005-12-14 Matthias Clasen * glib/glib-sections.txt: * glib/tmpl/atomic_operations.sgml: Document new atomic operations. --- diff --git a/docs/reference/ChangeLog b/docs/reference/ChangeLog index 2a4ed64..5bbf5b7 100644 --- a/docs/reference/ChangeLog +++ b/docs/reference/ChangeLog @@ -1,3 +1,9 @@ +2005-12-14 Matthias Clasen + + * glib/glib-sections.txt: + * glib/tmpl/atomic_operations.sgml: Document new atomic + operations. + 2005-12-14 Federico Mena Quintero * glib/building.sgml: Clarify exactly what happens when you use --enable-gc-friendly. diff --git a/docs/reference/glib/glib-sections.txt b/docs/reference/glib/glib-sections.txt index efa960e..65d7634 100644 --- a/docs/reference/glib/glib-sections.txt +++ b/docs/reference/glib/glib-sections.txt @@ -670,12 +670,14 @@ g_async_queue_sort_unlocked
Atomic Operations -atomic_operations +atomic_operationsg g_atomic_int_get +g_atomic_int_set g_atomic_int_add g_atomic_int_exchange_and_add g_atomic_int_compare_and_exchange g_atomic_pointer_get +g_atomic_pointer_set g_atomic_pointer_compare_and_exchange g_atomic_int_inc g_atomic_int_dec_and_test diff --git a/docs/reference/glib/tmpl/atomic_operations.sgml b/docs/reference/glib/tmpl/atomic_operations.sgml index 7025080..231fc73 100644 --- a/docs/reference/glib/tmpl/atomic_operations.sgml +++ b/docs/reference/glib/tmpl/atomic_operations.sgml @@ -69,11 +69,22 @@ Reads the value of the integer pointed to by @atomic. Also acts as a memory barrier. -@atomic: a pointer to an integer. -@Returns: the value of *@atomic. +@atomic: a pointer to an integer +@Returns: the value of *@atomic @Since: 2.4 + + +Sets the value of the integer pointed to by @atomic. +Also acts as a memory barrier. + + +@atomic: a pointer to an integer +@newval: the new value +@Since: 2.10 + + Atomically adds @val to the integer pointed to by @atomic. @@ -123,6 +134,17 @@ a memory barrier. @Since: 2.4 + + +Sets the value of the pointer pointed to by @atomic. +Also acts as a memory barrier. + + +@atomic: a pointer to a #gpointer +@newval: the new value +@Since: 2.10 + + Compares @oldval with the pointer pointed to by @atomic and diff --git a/glib/glib.symbols b/glib/glib.symbols index cdf5bc5..da3120d 100644 --- a/glib/glib.symbols +++ b/glib/glib.symbols @@ -91,6 +91,8 @@ g_atomic_pointer_compare_and_exchange g_atomic_int_get g_atomic_pointer_get #endif +g_atomic_int_set +g_atomic_pointer_set #endif #endif