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
struct CollisionTask_LocalStoreMemory * m_lsMemory
int cellDmaGet(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
#define ATTRIBUTE_ALIGNED128(a)
ppu_address_t m_inPairPtr
Task Description for SPU collision detection.
void * createCollisionLocalStoreMemory()
int cellDmaLargePut(const void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
cellDmaLargePut Win32 replacements for Cell DMA to allow simulating most of the SPU code (just memcpy...
uint32_t m_someMutexVariableInMainMemory
void deleteCollisionLocalStoreMemory()
void cellDmaWaitTagStatusAll(int ignore)
cellDmaWaitTagStatusAll Win32 replacements for Cell DMA to allow simulating most of the SPU code (jus...
#define ATTRIBUTE_ALIGNED16(a)
Make sure no destructors are called on this memory.
This file provides some platform/compiler checks for common definitions.
void processCollisionTask(void *userPtr, void *lsMemory)
ppu_address_t m_dispatcher