Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: computational efficiency

by roboticus (Chancellor)
on Oct 05, 2011 at 11:04 UTC ( #929757=note: print w/replies, xml ) Need Help??

in reply to computational efficiency


Are you even sure it's a problem? You're talking about a couple hundred thousand times, but BrowserUk's benchmark shows that even the slower one is capable of well over a million per second. I'd suggest that if your code is running too slowly, profile it and see which parts take enough time to be worth optimizing. After all, if you can generate a million random sin/cos pairs in a second with the slow method, and need only a few hundred thousand per run, you can't even shave a second off your runtime even if your new version takes *no time at all*.


When your only tool is a hammer, all problems look like your thumb.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://929757]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (8)
As of 2018-03-24 13:02 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (298 votes). Check out past polls.