Fix the build for Orbis and PSP2
authorJosh Peterson <petersonjm1@gmail.com>
Wed, 1 Aug 2018 19:27:59 +0000 (22:27 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Wed, 1 Aug 2018 19:27:59 +0000 (22:27 +0300)
(part of commit 0f9ef2d from Unity-Technologies/bdwgc)

Issue #173 (bdwgc).

* include/private/pthread_stop_world.h [!GC_OPENBSD_UTHREADS && !NACL]
(thread_stop_info): Do not define last_stop_count if SN_TARGET_ORBIS
or SN_TARGET_PSP2.
* include/private/pthread_stop_world.h [!NACL && SN_TARGET_ORBIS]
(thread_stop_info): Declare registers field.

include/private/pthread_stop_world.h

index 080b682..4192737 100644 (file)
@@ -21,7 +21,8 @@
 EXTERN_C_BEGIN
 
 struct thread_stop_info {
-#   if !defined(GC_OPENBSD_UTHREADS) && !defined(NACL)
+#   if !defined(GC_OPENBSD_UTHREADS) && !defined(NACL) \
+       && !defined(SN_TARGET_ORBIS) && !defined(SN_TARGET_PSP2)
       volatile AO_t last_stop_count;
                         /* The value of GC_stop_count when the thread   */
                         /* last successfully handled a suspend signal.  */
@@ -43,6 +44,9 @@ struct thread_stop_info {
 #       define NACL_GC_REG_STORAGE_SIZE 20
 #     endif
       ptr_t reg_storage[NACL_GC_REG_STORAGE_SIZE];
+#   elif defined(SN_TARGET_ORBIS)
+#     define ORBIS_GC_REG_STORAGE_SIZE 27
+      word registers[ORBIS_GC_REG_STORAGE_SIZE]; /* used externally */
 #   endif
 };