Permalink
Browse files

Revert the spu samples changes that I added from hermes tarball.

  • Loading branch information...
1 parent 3d23aa8 commit ccedd1b0ad8baf7b875ac924a5d1b21cbcece21c Miigotu committed Mar 17, 2011
@@ -34,9 +34,6 @@
int main(int argc, const char* argv[])
{
sysSpuImage image;
- u32 entry = 0;
- u32 segmentcount = 0;
- sysSpuSegment* segments;
u32 group_id;
Lv2SpuThreadAttributes attr = { ptr2ea("mythread"), 8+1, LV2_SPU_THREAD_ATTRIBUTE_NONE };
Lv2SpuThreadGroupAttributes grpattr = { 7+1, ptr2ea("mygroup"), 0, 0 };
@@ -49,17 +46,6 @@ int main(int argc, const char* argv[])
printf("Initializing 6 SPUs... ");
printf("%08x\n", lv2SpuInitialize(6, 0));
- printf("Getting ELF information... ");
- printf("%08x\n", sysSpuElfGetInformation(spu_bin, &entry, &segmentcount));
- printf("\tEntry Point: %08x\n\tSegment Count: %08x\n", entry, segmentcount);
-
- size_t segmentsize = sizeof(sysSpuSegment) * segmentcount;
- segments = (sysSpuSegment*)malloc(segmentsize);
- memset(segments, 0, segmentsize);
-
- printf("Getting ELF segments... ");
- printf("%08x\n", sysSpuElfGetSegments(spu_bin, segments, segmentcount));
-
printf("Loading ELF image... ");
printf("%08x\n", sysSpuImageImport(&image, spu_bin, 0));
@@ -13,9 +13,6 @@
int main(int argc, const char* argv[])
{
sysSpuImage image;
- u32 entry = 0;
- u32 segmentcount = 0;
- sysSpuSegment* segments;
u32 thread_id;
u32 group_id;
Lv2SpuThreadAttributes attr = { ptr2ea("mythread"), 8+1, LV2_SPU_THREAD_ATTRIBUTE_NONE };
@@ -29,17 +26,6 @@ int main(int argc, const char* argv[])
printf("Initializing 6 SPUs... ");
printf("%08x\n", lv2SpuInitialize(6, 0));
- printf("Getting ELF information... ");
- printf("%08x\n", sysSpuElfGetInformation(spu_bin, &entry, &segmentcount));
- printf("\tEntry Point: %08x\n\tSegment Count: %08x\n", entry, segmentcount);
-
- size_t segmentsize = sizeof(sysSpuSegment) * segmentcount;
- segments = (sysSpuSegment*)malloc(segmentsize);
- memset(segments, 0, segmentsize);
-
- printf("Getting ELF segments... ");
- printf("%08x\n", sysSpuElfGetSegments(spu_bin, segments, segmentcount));
-
printf("Loading ELF image... ");
printf("%08x\n", sysSpuImageImport(&image, spu_bin, 0));
@@ -42,9 +42,6 @@
int main(int argc, const char* argv[])
{
sysSpuImage image;
- u32 entry = 0;
- u32 segmentcount = 0;
- sysSpuSegment* segments;
u32 group_id;
Lv2SpuThreadAttributes attr = { ptr2ea("mythread"), 8+1, LV2_SPU_THREAD_ATTRIBUTE_NONE };
Lv2SpuThreadGroupAttributes grpattr = { 7+1, ptr2ea("mygroup"), 0, 0 };
@@ -57,17 +54,6 @@ int main(int argc, const char* argv[])
printf("Initializing 6 SPUs... ");
printf("%08x\n", lv2SpuInitialize(6, 0));
- printf("Getting ELF information... ");
- printf("%08x\n", sysSpuElfGetInformation(spu_bin, &entry, &segmentcount));
- printf("\tEntry Point: %08x\n\tSegment Count: %08x\n", entry, segmentcount);
-
- size_t segmentsize = sizeof(sysSpuSegment) * segmentcount;
- segments = (sysSpuSegment*)malloc(segmentsize);
- memset(segments, 0, segmentsize);
-
- printf("Getting ELF segments... ");
- printf("%08x\n", sysSpuElfGetSegments(spu_bin, segments, segmentcount));
-
printf("Loading ELF image... ");
printf("%08x\n", sysSpuImageImport(&image, spu_bin, 0));
@@ -12,26 +12,12 @@ int main(int argc, const char* argv[])
{
u32 spu = 0;
sysSpuImage image;
- u32 entry = 0;
- u32 segmentcount = 0;
- sysSpuSegment* segments;
printf("Initializing 6 SPUs... ");
printf("%08x\n", lv2SpuInitialize(6, 5));
printf("Initializing raw SPU... ");
printf("%08x\n", lv2SpuRawCreate(&spu, NULL));
- printf("Getting ELF information... ");
- printf("%08x\n", sysSpuElfGetInformation(spu_bin, &entry, &segmentcount));
- printf("\tEntry Point: %08x\n\tSegment Count: %08x\n", entry, segmentcount);
-
- size_t segmentsize = sizeof(sysSpuSegment) * segmentcount;
- segments = (sysSpuSegment*)malloc(segmentsize);
- memset(segments, 0, segmentsize);
-
- printf("Getting ELF segments... ");
- printf("%08x\n", sysSpuElfGetSegments(spu_bin, segments, segmentcount));
-
printf("Loading ELF image... ");
printf("%08x\n", sysSpuImageImport(&image, spu_bin, 0));
@@ -13,9 +13,6 @@
int main(int argc, const char* argv[])
{
sysSpuImage image;
- u32 entry = 0;
- u32 segmentcount = 0;
- sysSpuSegment* segments;
u32 thread_id;
u32 group_id;
Lv2SpuThreadAttributes attr = { ptr2ea("mythread"), 8+1, LV2_SPU_THREAD_ATTRIBUTE_NONE };
@@ -28,17 +25,6 @@ int main(int argc, const char* argv[])
printf("Initializing 6 SPUs... ");
printf("%08x\n", lv2SpuInitialize(6, 0));
- printf("Getting ELF information... ");
- printf("%08x\n", sysSpuElfGetInformation(spu_bin, &entry, &segmentcount));
- printf("\tEntry Point: %08x\n\tSegment Count: %08x\n", entry, segmentcount);
-
- size_t segmentsize = sizeof(sysSpuSegment) * segmentcount;
- segments = (sysSpuSegment*)malloc(segmentsize);
- memset(segments, 0, segmentsize);
-
- printf("Getting ELF segments... ");
- printf("%08x\n", sysSpuElfGetSegments(spu_bin, segments, segmentcount));
-
printf("Loading ELF image... ");
printf("%08x\n", sysSpuImageImport(&image, spu_bin, 0));

0 comments on commit ccedd1b

Please sign in to comment.