16 #ifndef SPU_GATHERING_COLLISION_TASK_H
17 #define SPU_GATHERING_COLLISION_TASK_H
19 #include "../PlatformDefinitions.h"
41 #if defined(__CELLOS_LV2__) || defined(USE_LIBSPE2)
52 #if defined(USE_LIBSPE2) && defined(__SPU__)
53 #include "../SpuLibspe2Support.h"
54 #include <spu_intrinsics.h>
55 #include <spu_mfcio.h>
62 int main(
unsigned long long speid,
addr64 argp,
addr64 envp)
64 printf(
"SPU: hello \n");
68 unsigned int received_message = Spu_Mailbox_Event_Nothing;
69 bool shutdown =
false;
74 status.m_status = Spu_Status_Free;
84 received_message = spu_read_in_mbox();
86 if(
btLikely( received_message == Spu_Mailbox_Event_Task ))
88 #ifdef DEBUG_LIBSPE2_SPU_TASK
89 printf(
"SPU: received Spu_Mailbox_Event_Task\n");
90 #endif //DEBUG_LIBSPE2_SPU_TASK
96 btAssert(status.m_status==Spu_Status_Occupied);
100 #ifdef DEBUG_LIBSPE2_SPU_TASK
101 printf(
"SPU:processCollisionTask\n");
102 #endif //DEBUG_LIBSPE2_SPU_TASK
105 #ifdef DEBUG_LIBSPE2_SPU_TASK
106 printf(
"SPU:finished processCollisionTask\n");
107 #endif //DEBUG_LIBSPE2_SPU_TASK
111 #ifdef DEBUG_LIBSPE2_SPU_TASK
112 printf(
"SPU: received ShutDown\n");
113 #endif //DEBUG_LIBSPE2_SPU_TASK
114 if(
btLikely( received_message == Spu_Mailbox_Event_Shutdown ) )
125 status.m_status = Spu_Status_Free;
132 printf(
"SPU: shutdown\n");
135 #endif // USE_LIBSPE2
138 #endif //SPU_GATHERING_COLLISION_TASK_H