From 8eb50166a6251935fb87c70c1187d7438e5470cc Mon Sep 17 00:00:00 2001 From: Zoltan Varga Date: Wed, 30 Oct 2019 10:08:50 -0400 Subject: [PATCH] Remove some unused icalls. (mono/mono#17612) Commit migrated from https://github.com/mono/mono/commit/79f5e6c288a542aa67a7626c0e6b7e873b6ba78d --- src/mono/mono/metadata/threads-types.h | 6 ------ src/mono/mono/metadata/threads.c | 18 ------------------ 2 files changed, 24 deletions(-) diff --git a/src/mono/mono/metadata/threads-types.h b/src/mono/mono/metadata/threads-types.h index 292407f..9f4ddd8 100644 --- a/src/mono/mono/metadata/threads-types.h +++ b/src/mono/mono/metadata/threads-types.h @@ -192,12 +192,6 @@ ICALL_EXPORT gdouble ves_icall_System_Threading_Interlocked_CompareExchange_Double(gdouble *location, gdouble value, gdouble comparand); ICALL_EXPORT -void ves_icall_System_Threading_Interlocked_CompareExchange_T (MonoObject *volatile*location, MonoObject *volatile*value, MonoObject *volatile*comparand, MonoObject *volatile*res); - -ICALL_EXPORT -void ves_icall_System_Threading_Interlocked_Exchange_T (MonoObject *volatile*location, MonoObject *volatile*value, MonoObject *volatile*res); - -ICALL_EXPORT gint32 ves_icall_System_Threading_Interlocked_Add_Int(gint32 *location, gint32 value); ICALL_EXPORT diff --git a/src/mono/mono/metadata/threads.c b/src/mono/mono/metadata/threads.c index e5f7e16..d2db161 100644 --- a/src/mono/mono/metadata/threads.c +++ b/src/mono/mono/metadata/threads.c @@ -2468,12 +2468,6 @@ ves_icall_System_Threading_Interlocked_CompareExchange_Object (MonoObject *volat mono_gc_wbarrier_generic_nostore_internal ((gpointer)location); // FIXME volatile } -void -ves_icall_System_Threading_Interlocked_CompareExchange_T (MonoObject *volatile*location, MonoObject *volatile*value, MonoObject *volatile*comparand, MonoObject *volatile* res) -{ - ves_icall_System_Threading_Interlocked_CompareExchange_Object (location, value, comparand, res); -} - gpointer ves_icall_System_Threading_Interlocked_CompareExchange_IntPtr(gpointer *location, gpointer value, gpointer comparand) { return mono_atomic_cas_ptr(location, value, comparand); @@ -2531,18 +2525,6 @@ ves_icall_System_Threading_Interlocked_CompareExchange_Long (gint64 *location, g return mono_atomic_cas_i64 (location, value, comparand); } -void -ves_icall_System_Threading_Interlocked_Exchange_T (MonoObject *volatile*location, MonoObject *volatile*value, MonoObject *volatile*res) -{ - // Coop-equivalency here via pointers to pointers. - // value and res are to managed frames, location ought to be (or member or global) but it cannot be guaranteed. - // - // This is not entirely convincing due to lack of volatile in the caller. - // - MONO_CHECK_NULL (location, ); - ves_icall_System_Threading_Interlocked_Exchange_Object (location, value, res); -} - gint32 ves_icall_System_Threading_Interlocked_Add_Int (gint32 *location, gint32 value) { -- 2.7.4