🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Engine Cleanup Optimization

Started by
1 comment, last by WitchLord 9 years, 9 months ago

I discovered a bottleneck in the cleanup process in AngelScript which caused our game to take much longer to shutdown than expected. It seems that all the time was being spent in ClearUnusedTypes() which used a linear search for removing types.

I replaced the vector with a set (emulated with a map, to be able to use the same data structures the library normally uses), removing the bottleneck. We've been using this change for a few weeks without issue.

Advertisement

Thanks.

I've been meaning to refactor the clean-up for quite some time. I'll look into the enhancement that you've provided.

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

I've included this in revision 2005.

Regards,

Andreas

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

This topic is closed to new replies.

Advertisement