Jump to content
  • Advertisement
Sign in to follow this  
Neon2302

Question about speed in STL Containers

This topic is 4010 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm the one who use STL Containers instead of and standard array (not all the time but most of them), I saw frame rate is drop extremely fast. so I try to reconfig it. at the end I found out that container.at(i) is much more slower than contain where this 2 command is giving the same result anyone know how come of this problem Best Regards Chet Chetchaiyan by the way, if anyone know the trick to increase performance by using STL container please tell me, thank you

Share this post


Link to post
Share on other sites
Advertisement
typically in the standard library, the "at" methods perform bounds checking and will throw std::range_error's if you pass in an index that is outside of the accepted range. This can, in some cases, cause a significant performance overhead.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!