[Openmp-commits] [openmp] r256790 - Removed unused __kmp_*_i8 functions.

Jonathan Peyton via Openmp-commits openmp-commits at lists.llvm.org
Mon Jan 4 15:20:57 PST 2016


Author: jlpeyton
Date: Mon Jan  4 17:20:26 2016
New Revision: 256790

URL: http://llvm.org/viewvc/llvm-project?rev=256790&view=rev
Log:
Removed unused __kmp_*_i8 functions.

Modified:
    openmp/trunk/runtime/src/dllexports
    openmp/trunk/runtime/src/exports_so.txt
    openmp/trunk/runtime/src/kmp.h
    openmp/trunk/runtime/src/kmp_config.h.cmake
    openmp/trunk/runtime/src/kmp_dispatch.cpp
    openmp/trunk/runtime/src/kmp_gsupport.c
    openmp/trunk/runtime/src/kmp_lock.cpp
    openmp/trunk/runtime/src/kmp_os.h
    openmp/trunk/runtime/src/kmp_platform.h

Modified: openmp/trunk/runtime/src/dllexports
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/dllexports?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/dllexports (original)
+++ openmp/trunk/runtime/src/dllexports Mon Jan  4 17:20:26 2016
@@ -160,7 +160,6 @@
 
     # Regular entry points
         __kmp_wait_yield_4
-        __kmp_wait_yield_8
         __kmp_fork_call
         __kmp_invoke_microtask
         __kmp_launch_monitor

Modified: openmp/trunk/runtime/src/exports_so.txt
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/exports_so.txt?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/exports_so.txt (original)
+++ openmp/trunk/runtime/src/exports_so.txt Mon Jan  4 17:20:26 2016
@@ -96,7 +96,6 @@ VERSION {
         __kmp_wait_64;
         __kmp_wait_oncore;
         __kmp_wait_yield_4;
-        __kmp_wait_yield_8;
 
         # ittnotify symbols to be used by debugger
         __kmp_itt_fini_ittlib;

Modified: openmp/trunk/runtime/src/kmp.h
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp.h?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp.h (original)
+++ openmp/trunk/runtime/src/kmp.h Mon Jan  4 17:20:26 2016
@@ -2998,15 +2998,7 @@ extern kmp_uint32 __kmp_neq_4( kmp_uint3
 extern kmp_uint32 __kmp_lt_4(  kmp_uint32 value, kmp_uint32 checker );
 extern kmp_uint32 __kmp_ge_4(  kmp_uint32 value, kmp_uint32 checker );
 extern kmp_uint32 __kmp_le_4(  kmp_uint32 value, kmp_uint32 checker );
-
-extern kmp_uint32 __kmp_eq_8(  kmp_uint64 value, kmp_uint64 checker );
-extern kmp_uint32 __kmp_neq_8( kmp_uint64 value, kmp_uint64 checker );
-extern kmp_uint32 __kmp_lt_8(  kmp_uint64 value, kmp_uint64 checker );
-extern kmp_uint32 __kmp_ge_8(  kmp_uint64 value, kmp_uint64 checker );
-extern kmp_uint32 __kmp_le_8(  kmp_uint64 value, kmp_uint64 checker );
-
 extern kmp_uint32 __kmp_wait_yield_4( kmp_uint32 volatile * spinner, kmp_uint32 checker, kmp_uint32 (*pred) (kmp_uint32, kmp_uint32), void * obj );
-extern kmp_uint64 __kmp_wait_yield_8( kmp_uint64 volatile * spinner, kmp_uint64 checker, kmp_uint32 (*pred) (kmp_uint64, kmp_uint64), void * obj );
 
 class kmp_flag_32;
 class kmp_flag_64;

Modified: openmp/trunk/runtime/src/kmp_config.h.cmake
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_config.h.cmake?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_config.h.cmake (original)
+++ openmp/trunk/runtime/src/kmp_config.h.cmake Mon Jan  4 17:20:26 2016
@@ -76,6 +76,10 @@
 # define CACHE_LINE 64
 #endif
 
+#if ! KMP_32_BIT_ARCH
+# define BUILD_I8 1
+#endif
+
 #define KMP_DYNAMIC_LIB 1
 #define KMP_NESTED_HOT_TEAMS 1
 #define KMP_ADJUST_BLOCKTIME 1

Modified: openmp/trunk/runtime/src/kmp_dispatch.cpp
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_dispatch.cpp?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_dispatch.cpp (original)
+++ openmp/trunk/runtime/src/kmp_dispatch.cpp Mon Jan  4 17:20:26 2016
@@ -2515,25 +2515,6 @@ kmp_uint32 __kmp_ge_4( kmp_uint32 value,
 kmp_uint32 __kmp_le_4( kmp_uint32 value, kmp_uint32 checker) {
     return value <= checker;
 }
-kmp_uint32 __kmp_eq_8( kmp_uint64 value, kmp_uint64 checker) {
-    return value == checker;
-}
-
-kmp_uint32 __kmp_neq_8( kmp_uint64 value, kmp_uint64 checker) {
-    return value != checker;
-}
-
-kmp_uint32 __kmp_lt_8( kmp_uint64 value, kmp_uint64 checker) {
-    return value < checker;
-}
-
-kmp_uint32 __kmp_ge_8( kmp_uint64 value, kmp_uint64 checker) {
-    return value >= checker;
-}
-
-kmp_uint32 __kmp_le_8( kmp_uint64 value, kmp_uint64 checker) {
-    return value <= checker;
-}
 
 kmp_uint32
 __kmp_wait_yield_4(volatile kmp_uint32 * spinner,
@@ -2564,41 +2545,6 @@ __kmp_wait_yield_4(volatile kmp_uint32 *
         KMP_YIELD( TCR_4(__kmp_nth) > __kmp_avail_proc );
         KMP_YIELD_SPIN( spins );
     }
-    KMP_FSYNC_SPIN_ACQUIRED( obj );
-    return r;
-}
-
-kmp_uint64
-__kmp_wait_yield_8( volatile kmp_uint64 * spinner,
-                    kmp_uint64            checker,
-                    kmp_uint32 (* pred)( kmp_uint64, kmp_uint64 )
-                    , void        * obj    // Higher-level synchronization object, or NULL.
-                    )
-{
-    // note: we may not belong to a team at this point
-    register volatile kmp_uint64         * spin          = spinner;
-    register          kmp_uint64           check         = checker;
-    register          kmp_uint32   spins;
-    register          kmp_uint32 (*f) ( kmp_uint64, kmp_uint64 ) = pred;
-    register          kmp_uint64           r;
-
-    KMP_FSYNC_SPIN_INIT( obj, (void*) spin );
-    KMP_INIT_YIELD( spins );
-    // main wait spin loop
-    while(!f(r = *spin, check))
-    {
-        KMP_FSYNC_SPIN_PREPARE( obj );
-        /* GEH - remove this since it was accidentally introduced when kmp_wait was split.
-           It causes problems with infinite recursion because of exit lock */
-        /* if ( TCR_4(__kmp_global.g.g_done) && __kmp_global.g.g_abort)
-            __kmp_abort_thread(); */
-
-        // if we are oversubscribed,
-        // or have waited a bit (and KMP_LIBARRY=throughput, then yield
-        // pause is in the following code
-        KMP_YIELD( TCR_4(__kmp_nth) > __kmp_avail_proc );
-        KMP_YIELD_SPIN( spins );
-    }
     KMP_FSYNC_SPIN_ACQUIRED( obj );
     return r;
 }

Modified: openmp/trunk/runtime/src/kmp_gsupport.c
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_gsupport.c?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_gsupport.c (original)
+++ openmp/trunk/runtime/src/kmp_gsupport.c Mon Jan  4 17:20:26 2016
@@ -13,9 +13,6 @@
 //===----------------------------------------------------------------------===//
 
 
-#if defined(__x86_64) || defined (__powerpc64__) || defined(__aarch64__)
-# define KMP_I8
-#endif
 #include "kmp.h"
 #include "kmp_atomic.h"
 

Modified: openmp/trunk/runtime/src/kmp_lock.cpp
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_lock.cpp?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_lock.cpp (original)
+++ openmp/trunk/runtime/src/kmp_lock.cpp Mon Jan  4 17:20:26 2016
@@ -729,7 +729,7 @@ __kmp_is_ticket_lock_nestable( kmp_ticke
 }
 
 static kmp_uint32
-__kmp_bakery_check(kmp_uint value, kmp_uint checker)
+__kmp_bakery_check(kmp_uint32 value, kmp_uint32 checker)
 {
     register kmp_uint32 pause;
 
@@ -1576,7 +1576,7 @@ __kmp_release_queuing_lock( kmp_queuing_
 
                 KMP_MB();
                 /* make sure enqueuing thread has time to update next waiting thread field */
-                *head_id_p = (kmp_int32) KMP_WAIT_YIELD((volatile kmp_uint*) waiting_id_p, 0, KMP_NEQ, NULL);
+                *head_id_p = KMP_WAIT_YIELD((volatile kmp_uint32*)waiting_id_p, 0, KMP_NEQ, NULL);
 #ifdef DEBUG_QUEUING_LOCKS
                 TRACE_LOCK( gtid+1, "rel deq: (h,t)->(h',t)" );
 #endif

Modified: openmp/trunk/runtime/src/kmp_os.h
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_os.h?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_os.h (original)
+++ openmp/trunk/runtime/src/kmp_os.h Mon Jan  4 17:20:26 2016
@@ -173,21 +173,15 @@ typedef double  kmp_real64;
 # define KMP_UINTPTR_SPEC  "lu"
 #endif
 
-#ifdef KMP_I8
+#ifdef BUILD_I8
   typedef kmp_int64      kmp_int;
   typedef kmp_uint64     kmp_uint;
-# define  KMP_INT_SPEC	 KMP_INT64_SPEC
-# define  KMP_UINT_SPEC	 KMP_UINT64_SPEC
-# define  KMP_INT_MAX    ((kmp_int64)0x7FFFFFFFFFFFFFFFLL)
-# define  KMP_INT_MIN    ((kmp_int64)0x8000000000000000LL)
 #else
   typedef kmp_int32      kmp_int;
   typedef kmp_uint32     kmp_uint;
-# define  KMP_INT_SPEC	 KMP_INT32_SPEC
-# define  KMP_UINT_SPEC	 KMP_UINT32_SPEC
-# define  KMP_INT_MAX    ((kmp_int32)0x7FFFFFFF)
-# define  KMP_INT_MIN    ((kmp_int32)0x80000000)
-#endif /* KMP_I8 */
+#endif /* BUILD_I8 */
+#define  KMP_INT_MAX     ((kmp_int32)0x7FFFFFFF)
+#define  KMP_INT_MIN     ((kmp_int32)0x80000000)
 
 #ifdef __cplusplus
     //-------------------------------------------------------------------------
@@ -651,21 +645,12 @@ typedef void    (*microtask_t)( int *gti
 # define VOLATILE_CAST(x)        (x)
 #endif
 
-#ifdef KMP_I8
-# define KMP_WAIT_YIELD           __kmp_wait_yield_8
-# define KMP_EQ                   __kmp_eq_8
-# define KMP_NEQ                  __kmp_neq_8
-# define KMP_LT                   __kmp_lt_8
-# define KMP_GE                   __kmp_ge_8
-# define KMP_LE                   __kmp_le_8
-#else
-# define KMP_WAIT_YIELD           __kmp_wait_yield_4
-# define KMP_EQ                   __kmp_eq_4
-# define KMP_NEQ                  __kmp_neq_4
-# define KMP_LT                   __kmp_lt_4
-# define KMP_GE                   __kmp_ge_4
-# define KMP_LE                   __kmp_le_4
-#endif /* KMP_I8 */
+#define KMP_WAIT_YIELD           __kmp_wait_yield_4
+#define KMP_EQ                   __kmp_eq_4
+#define KMP_NEQ                  __kmp_neq_4
+#define KMP_LT                   __kmp_lt_4
+#define KMP_GE                   __kmp_ge_4
+#define KMP_LE                   __kmp_le_4
 
 /* Workaround for Intel(R) 64 code gen bug when taking address of static array (Intel(R) 64 Tracker #138) */
 #if (KMP_ARCH_X86_64 || KMP_ARCH_PPC64) && KMP_OS_LINUX

Modified: openmp/trunk/runtime/src/kmp_platform.h
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_platform.h?rev=256790&r1=256789&r2=256790&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_platform.h (original)
+++ openmp/trunk/runtime/src/kmp_platform.h Mon Jan  4 17:20:26 2016
@@ -160,6 +160,9 @@
 # define KMP_MIC2 0
 #endif
 
+/* Specify 32 bit architectures here */
+#define KMP_32_BIT_ARCH (KMP_ARCH_X86 || KMP_ARCH_ARM)
+
 // TODO: Fixme - This is clever, but really fugly
 #if (1 != KMP_ARCH_X86 + KMP_ARCH_X86_64 + KMP_ARCH_ARM + KMP_ARCH_PPC64 + KMP_ARCH_AARCH64)
 # error Unknown or unsupported architecture




More information about the Openmp-commits mailing list