29 #if defined (__SPU__) || defined (USE_LIBSPE2)
39 #if defined (__SPU__) || defined (USE_LIBSPE2)
40 mfc_get(ls,ea,size,tag,0,0);
52 #if defined (__SPU__) || defined (USE_LIBSPE2)
70 char* localStore = (
char*)ls;
75 uint32_t last4BitsOffset = ea & 0x0f;
76 char* tmpTarget = tmpBuffer + last4BitsOffset;
78 #if defined (__SPU__) || defined (USE_LIBSPE2)
80 int remainingSize =
size;
83 #ifdef FORCE_cellDmaUnalignedGet
84 cellDmaUnalignedGet(tmpTarget,ea,size,
DMA_TAG(1),0,0);
86 char* remainingTmpTarget = tmpTarget;
91 switch (remainingSize)
99 mfc_get(remainingTmpTarget,remainingEa,remainingSize,
DMA_TAG(1),0,0);
108 if (remainingSize > 16)
111 if (remainingSize >8)
114 if (remainingSize >4)
117 if (remainingSize >2)
119 mfc_get(remainingTmpTarget,remainingEa,actualSize,
DMA_TAG(1),0,0);
120 remainingSize-=actualSize;
121 remainingTmpTarget+=actualSize;
122 remainingEa += actualSize;
126 #endif//FORCE_cellDmaUnalignedGet
129 char* mainMem = (
char*)ea;
133 memcpy(tmpTarget,mainMem,size);
135 for ( i=0;i<
size;i++)
137 tmpTarget[i] = mainMem[i];
148 localStore[i] = tmpTarget[i];
154 #if defined (__SPU__) || defined (USE_LIBSPE2)
159 char* mainMem = (
char*)ea;
160 char* localStore = (
char*)ls;
163 memcpy(localStore,mainMem,size);
167 localStore[i] = mainMem[i];
175 char* mainMem = (
char*)ea;
176 char* localStore = (
char*)ls;
181 memcpy(localStore,mainMem,size);
185 localStore[i] = mainMem[i];
187 #endif //#ifdef USE_MEMCPY
194 char* mainMem = (
char*)ea;
195 const char* localStore = (
const char*)ls;
197 memcpy(mainMem,localStore,size);
201 mainMem[i] = localStore[i];
203 #endif //#ifdef USE_MEMCPY
int cellDmaGet(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
void * cellDmaLargeGetReadOnly(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
static DBVT_INLINE btScalar size(const btDbvtVolume &a)
int cellDmaLargeGet(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
cellDmaLargeGet Win32 replacements for Cell DMA to allow simulating most of the SPU code (just memcpy...
int stallingUnalignedDmaSmallGet(void *ls, uint64_t ea, uint32_t size)
this unalignedDma should not be frequently used, only for small data. It handles alignment and perfor...
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...
void * cellDmaGetReadOnly(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
void cellDmaWaitTagStatusAll(int ignore)
cellDmaWaitTagStatusAll Win32 replacements for Cell DMA to allow simulating most of the SPU code (jus...
void * cellDmaSmallGetReadOnly(void *ls, uint64_t ea, uint32_t size, uint32_t tag, uint32_t tid, uint32_t rid)
#define ATTRIBUTE_ALIGNED16(a)