On Wed, Dec 16, 2009 at 11:09 PM, UNIX admin <[email protected]> wrote:

> > What would the benefit of that be?
>
> The target audience, which is sysadmins and system engineers, is familiar
> with C, and the project stands to benefit from that expertise.
>
> Not to mention that C will give you maximum performance, short of writing
> IPS in assembler.
>
> The fact that some portions already had to be (re)written in C is proof
> enough that Python is not the best solution for the end product.
> --


You find optimizing Python with C as "Proof enough"?  An unfortunate
statement of ignorance (meant literally, not as an insult).

Optimizing Python (or better called CPython in this case, because that is
what it is) with C code is standard practice when performance of the running
application is significantly improved.  This is not a "proof" of anything
other than CPython being used as is common.

The time from development to deployment with Python is generally very low
and the code is also generally very easy to maintain.  This hopefully means
faster development with more stable, more maintainable, and less buggy
software and is the reason, I imagine, that it was chosen and accepted.
 Performance is a trade-off, but with C-optimizations (Pythonic C libraries)
the trade-off can be reduced significantly where needed.

As you mentioned, development in assembler would perform better, but it
would certainly be harder to maintain, improve, and port to other
architectures.  C is a maintainability and portability step up from
assembler, but with some performance loss.  Python is another step up from C
in maintainability (and possibly portability), but with some additional
performance loss.  Again, the C optimizations remove some of that loss, but
not all, and if there were assembler optimizations I doubt they would even
be considered regardless of performance improvements due to the
maintainability issue.  There are reasons higher level languages exist, and
they are good reasons.

To paraphrase someone else:  "Performance means a lot.  More than some
things, but not nearly as much as others."

And lastly, to hopefully remove a little of that ignorance:  Python is
basically just a language specification.  The main development
implementation is called CPython because it is written in C and this is the
Python most of us are familiar with.  There are others, such as Jython
(written in Java) and IronPython (written in C#).  There is even a PyPy
which is a Python implementation written in Python (which claims to be
exceeding C in performance for some uses).  For at least the C, Java, and C#
versions python will be able to use libraries in their native languages
(with some exceptions).
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to