Has anyone seen that presentation ?
http://gamesfromwithin.com/360idev-cranking-up-floating-point-performance-to-11
Could some of this stuff be used to improve the speed of Cocos2D ?
A fast, easy to use, free, and community supported 2D game engine
Has anyone seen that presentation ?
http://gamesfromwithin.com/360idev-cranking-up-floating-point-performance-to-11
Could some of this stuff be used to improve the speed of Cocos2D ?
That was an interesting link, thanks for sharing.
I think if a game is slow, it's generally due to the rendering being too long (drawing bottleneck on OpenGL side) and not the game logic requiring too much processing. But if game logic executes faster, it gives more time to the rendering process. I'm not familiar with all the cocos inner implementation details, so I can't really tell where such an optimization could be applied. I think the particle systems would be a good candidate, as in the presentation example.
Physics engines like Chipmunk and Box2d are more likely to benefit from that (if they don't already).
Now it would require some good asm skills. And the cocos code would become a (hell of a) lot harder to read/write/debug. A lot of people don't even know Obj-C when they first start playing around with cocos, there's hardly no chance they know asm.
Riq, if you read this thread, what do you think about this ?
Hi, I agree with Clain that for most games you're really not going to gain much from VFP/NEON acceleration or from using fat binaries to compile for ARMv7. The code in that presentation was developed by the Oolong folks to optimize the matrix math functions in the Bullet 3d physics engine. If you use the Bullet engine, you'll get these optimizations "for free." However, I've tested the VFP matrix math code it gives a few FPS bump up but not as much as smart compiler options choices. Not sure about NEON yet. Will test soon.
You can try to port the Box2d math library (Common/b2Math.h & b2Math.cpp) over to inline ASM, or check with Erin Catto himself. I don't think it's fair to ask Riq to optimize physics engines, he's busy enough! :-)
--yarri
Nice link, thanks.
I opened a topic about this in the chipmunk forum.
- zombie
Ahhh... I read it a week ago, and my mind was blown away, I didn't understand anything. I tried tinkering with ASM like 3 years ago, and I have a trauma since (I was 13 lol).
I agree with Clain, it will make any calculation alot longer and debugging would become hell...
~ Natanavra.
can I thread-jack a moment (and also reveal that Im an old old man) to just say I have fond memories of programming my Apple ][+ in 6502 ASM as a kid. Good gravy was it simple compared to ASM on today's chips!!
Ohh man, The Apple II ??? The Apple II was like what, 1978? That's a long time ago...
it ran at 1 mhz man... one!
Hahaha!!! Holy crap, 1 mh/z, it's hard to believe. My first computer was like 100 mh/z, 1995, I was 2 years old.
There was a time Bill Gates (If I'm not mistaken) said that 640K RAM was all we need, well, times change...
The first game I ever played was Quake 1, and I was hooked. From that point I kept asking my dad how people create computer games, and started to 'program' in Visual Basic (hah!). I kept 'programming' through high school, but when it came time to go to college I started out as an electrical engineering major cause I was told by various people computer science 'was not real engineering' and 'everything is just outsourced these days, there is no money in it'. Now, I chuckle at them quietly to myself....
EDIT: attempting to add a point relevant to the original thread...
I'd agree assembly code would be awesome, especially perhaps in the physics engines, but after learning assembly for 10+ hours while trying to write something that would be 5 lines in C, I feel you need people with some real experience to make it work. A lot of times rewriting in assembly doesn't actually gain you much performance, rather you just need somebody who can read it well to find spots where the complier is doing a bad job of optimizing.
Me too. My older brother and I wrote a lot of "cracks" in assembly back then, and even wrote a "character editor" for Ultima. We ran a BBS for a while...I think we used software called ASCII-Express.
I still have my Beagle Brothers peak and poke chart:
Sorry for thread-jacking, but your comment brought up some nice memories.
You must log in to post.