The REALLY bad thing about Python lists ..

Glyph Lefkowitz glyph at twistedmatrix.com
Mon May 15 17:53:23 EDT 2000


Russell Turpin <noone at do.not.use> writes:

>   Should Python lists be as fast on other platforms as they are on
>   Linux, where good OS memory management turned the second strategy
>   into the first?

Personally, I see Python as "C with foam padding", an expression which
I believe has been used before on this list.  As such, I don't believe
it should include a complete reimplimentation of libc.  If a platform
doesn't adhere to a standard or does something in a really
brain-damaged way, it should be fixed on that platform.  I had this
brought to my attention earlier today when someone on IRC was
commenting that the % operator in perl and python carries the
symantics from the C library of the platform in question, and
sometimes that's wrong (off-by-one errors when it was being treated as
'remainder' rather than 'modulus' in negative numbers).

This is a simpler fix than reimplementing list allocation, but I
*still* don't think it's python's bug: tell your libc maintainer to
fix it.  If they don't, switch platforms.  There are plenty of free
ones out there with correctly-functioning libcs, or ones that you can
patch yourself.

> Personally, I think those who have to develop under Windows suffer
> enough already, and they should at least enjoy the same reasonably
> fast Python as the rest of us!

If you make dumb choices, you're likely to suffer.  Most POSIX
functionality is severely crippled (fork...) in Windows, and I
wouldn't expect windows memory management to be much different.  I
don't think it's worth anyone's time to improve this situation.  Of
course, I wouldn't have thought it was worth anyone's time to port
python in the first place, and I am SO glad that others disagree with
me! :-)

> Grateful-to-develop-on-a-real-OS'ly yrs,
> Russell

let-me-sing-in-the-same-chorous-with-you-ly y'rs,

-- 
                  __________________________________________
                 |    ______      __   __  _____  _     _   |
                 |   |  ____ |      \_/   |_____] |_____|   |
                 |   |_____| |_____  |    |       |     |   |
                 |   @ t w i s t e d m a t r i x  . c o m   |
                 |   http://www.twistedmatrix.com/~glyph/   |
                 `__________________________________________'




More information about the Python-list mailing list