shams said:
Cool, thanks for the info. So it should be possible to offload the same AI to the SPUs - just not particularly efficient (which should matter). Even at 10% efficiency, a couple of SPUs should be able to handle all the AI requirements (constant random main memory accesses might kill the data cache though). Its just a question of difficulty anyway - as it always is (i.e. you can port anything to any device - just a question of results... i.e. Assassins Creed on the DS, but not on the Wii!). |
Yeah, it is a question of difficulty. For example, you could create a data structure with a special memory allocator, and allocate, say, a contiguous 100-200kB or so block of memory to be used just by that data structure. Then the special allocator uses space from that block when you need to create a new node in your structure. An SPE could then copy the block into its local store, and traverse it quickly and easily. It would have a limited use, but there are a lot of structures I could see being used this way, especially in a console environment where memory management is so important already. Like I said, it's all about clever programming and not being afraid to get your hands dirty.
You can't come up with a good SPE code for everything, but you can come up with a good SPE code for more than just the obvious things.







