Python speed

Paul Winkler slinkp23 at yahoo.com
Tue Jul 10 15:29:45 EDT 2001


jcm wrote:
> 
> Pete Shinners <shredwheat at mediaone.net> wrote:
> ...
> 
> > for doing a MUD, the language speed is not going to have
> > much noticeable effect, since network speed is far slower
> > than any of the languages can handle.
> 
> This isn't necessarily true.  If you have a lot of objects with state
> that changes often (wandering monsters, etc), computation-speed can
> become an issue.

I still don't see why python wouldn't be up to the job.
If things are working well but too slowly, it's time to think about
optimization.

A good quote:
 "Optimization is simply waste of programmer time if any of these statements are
true: 

    parts of the program haven't been written yet 
    the program is not fully tested and debugged 
    it seems to run fast enough already" 

I forget where I got that quote.

So, first, make sure everything works.
Then write a test script that hits the server hard, and run the server under the
python profiler.

Then, once you know what the slow parts are, go to the FAQ wizard:
http://www.python.org/cgi-bin/faqw.py

...and search for "optimize". There's lots of good info in there.

-- 
...................    paul winkler   ....................
custom calendars & printing: http://www.calendargalaxy.com
       A member of ARMS:   http://www.reacharms.com
            home page:  http://www.slinkp.com



More information about the Python-list mailing list