[Pkg-mono-svn-commits] [mono] 12/23: Use InterlockedRead64 () for Interlocked.Read (long&). (cherry picked from commit ab90040305d003b6c06c842e788e682495117514)
Jo Shields
directhex at alioth.debian.org
Wed Oct 23 22:14:30 UTC 2013
This is an automated email from the git hooks/post-receive script.
directhex pushed a commit to branch master-experimental-patches/atomics_support_on_fringe_32bit_platforms
in repository mono.
commit 8d36fd126439b17471c4d1dc12cdcfed06c8a4e0
Author: Alex Rønne Petersen <alexrp at xamarin.com>
Date: Wed Sep 25 20:19:18 2013 +0200
Use InterlockedRead64 () for Interlocked.Read (long&).
(cherry picked from commit ab90040305d003b6c06c842e788e682495117514)
---
mono/metadata/threads.c | 13 +------------
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a/mono/metadata/threads.c b/mono/metadata/threads.c
index 7ffb1ab..bd95303 100755
--- a/mono/metadata/threads.c
+++ b/mono/metadata/threads.c
@@ -2023,18 +2023,7 @@ ves_icall_System_Threading_Interlocked_Add_Long (gint64 *location, gint64 value)
gint64
ves_icall_System_Threading_Interlocked_Read_Long (gint64 *location)
{
-#if SIZEOF_VOID_P == 8
- /* 64 bit reads are already atomic */
- return *location;
-#else
- gint64 res;
-
- mono_interlocked_lock ();
- res = *location;
- mono_interlocked_unlock ();
-
- return res;
-#endif
+ return InterlockedRead64 (location);
}
void
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mono/packages/mono.git
More information about the Pkg-mono-svn-commits
mailing list