[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and to
From: |
Klaus Treichel |
Subject: |
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and tools (pnet) branch, master, updated. 34ba84934e6bd990c01fe4e6219632a3fdfd44fe |
Date: |
Sat, 27 Mar 2010 11:22:58 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "DotGNU Portable.NET engine, compilers and tools (pnet)".
The branch, master has been updated
via 34ba84934e6bd990c01fe4e6219632a3fdfd44fe (commit)
from 00944635fd6fc8748b054ad88900bdb046b1b738 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/pnet.git/commit/?id=34ba84934e6bd990c01fe4e6219632a3fdfd44fe
commit 34ba84934e6bd990c01fe4e6219632a3fdfd44fe
Author: Klaus Treichel <address@hidden>
Date: Sat Mar 27 11:18:45 2010 +0100
Fix interlocked slist append.
diff --git a/ChangeLog b/ChangeLog
index 44e0933..c19cfd1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2010-03-27 Klaus Treichel <address@hidden>
+
+ * support/interlocked_slist.c (ILInterlockedSListAppend): Exchange the
+ list's tail with release semantics to make sure all changes done before
+ are visible by other cpus at the time the exchange is done.
+
2010-03-06 Klaus Treichel <address@hidden>
* support/interlocked_slist.c, support/interlocked_slist.h: Add a
diff --git a/support/interlocked_slist.c b/support/interlocked_slist.c
index b8e0eae..c2a6fac 100644
--- a/support/interlocked_slist.c
+++ b/support/interlocked_slist.c
@@ -35,7 +35,12 @@ void ILInterlockedSListAppend(ILInterlockedSListHead *head,
tail = &(head->tail);
elem->next = &(head->tail);
/* Exchange the current tail with the element to append. */
- prev_tail = (ILInterlockedSListElement
*)ILInterlockedExchangeP_Acquire((void **)&(tail->next), elem);
+ /*
+ * We have to make sure that the next pointer is visible by other cpus
+ * at the time the tail is exchanged so we have to use release semantics
+ * here.
+ */
+ prev_tail = (ILInterlockedSListElement
*)ILInterlockedExchangeP_Release((void **)&(tail->next), elem);
/* set the next pointer of the previous tail to the new element */
prev_tail->next = elem;
/* and make sure this is seen by all other threads */
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 6 ++++++
support/interlocked_slist.c | 7 ++++++-
2 files changed, 12 insertions(+), 1 deletions(-)
hooks/post-receive
--
DotGNU Portable.NET engine, compilers and tools (pnet)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and tools (pnet) branch, master, updated. 34ba84934e6bd990c01fe4e6219632a3fdfd44fe,
Klaus Treichel <=
- Prev by Date:
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET branch, master, updated. df8e7059bd798d1b87582108132f7eadef361a8c
- Next by Date:
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and tools (pnet) branch, master, updated. f339bfb01915e953ddb43978ebd49095759f55d3
- Previous by thread:
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET branch, master, updated. df8e7059bd798d1b87582108132f7eadef361a8c
- Next by thread:
[dotgnu-pnet-commits] [SCM] DotGNU Portable.NET engine, compilers and tools (pnet) branch, master, updated. f339bfb01915e953ddb43978ebd49095759f55d3
- Index(es):