Sign in to follow this  
dave

WARNING: memcpy() is slow, or at least it seems that way.

Recommended Posts

Quote:
Original post by Shard
You can use asm to code a 32 or 64 bit copy fumction that copys more than one byte at a time, if you need extra speed. What are you copying?


Most modern memcpy implementations will do that too, though it never hurts to check - if that's really your bottleneck.

Share this post


Link to post
Share on other sites
1000 times per frame seems a little excessive IMHO. It may be worth examining how you're storing your data and attempting to precache it in a buffer before the level loads. I'd say that one call to memcpy on a large buffer would be better than many calls on smaller buffers. Plus look into 32/64bit asm versions as the other have said.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this