Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

There's a comment in the post:

"As of right now, it ends up that about 75% of our code is C++ and 17% is Python (link) since it turns out that a lot of BIND 10 is performance-critical."

Which could easily be taken the wrong way. I believe the right way to think about it is "How much _more_ C++ code would there be, if there wasn't that 17% in Python?".



Hum, I don't think interpreting this comment as Python is not adequate for performance critical applications is misinterpretation. The author makes it very clear in some other part of the text:

> [Python] has all of the features that we were looking for… except performance.

Now your interpretation is also valid since they could have written everything in C++ but they didn't.


There is a python DNS server running on pypy that seems to get a pretty big speedup over CPython.

Here is the benchmark result: http://speed.pypy.org/timeline/#/?exe=3,6,1,5&base=2+472...

0.002 for pypy VS 0.015 for CPython, which is 6.66 times faster.

So, for the last couple of years they have been wrong - since PyPy has shown pretty good performance in a DNS benchmark, so Python can have pretty good performance ;)


As much as I respect and appreciate Pypy, BIND is one of the core foundational pieces of the internet. It needs to be bulletproof and robust. I don't think Pypy itself qualifies as a mainstream enough language for them to build BIND on. This isn't a slight on Pypy, because the core problem is simply that it hasn't been around for long enough and subjected to enough stress to earn entry into the highest of the high tiers of reliable software. That's not a bad thing per se, and it can be fixed, but in the meantime, ISC has to take the situation as it is now, not how it might be in five years.


> I don't think Pypy itself qualifies as a mainstream enough language for them to build BIND on.

Minor pedantry: PyPy is not a language. It's an alternative compiler/runtime for Python.


I was echoing the terms used in the post. I thought it was clearer than going into a long comment about how Python is mature, at least in its CPython implementation, but the PyPy implementation is not, and when the blog post said "language" they really meant "implementation" because language is not implementation, yada yada yada.


Performance isn't a quality that is either present or not present, it's a quantity you can measure with a number as you did. It's true that pypy is much faster than CPython, but it's also true that C++ is much faster than pypy. Cpython is normally about 2 orders of magnitude slower than C++ on computationally intensive workloads, and if pypy get that down to a single order of magnitude that's great... but not enough here.


[citation needed] You're mostly talking nonsense. PyPy is usually 20-100x faster on the numeric workloads I measured than CPython, while the difference is significantly smaller on non-numeric workloads. The difference between C++ and CPython is also smaller.


I think the issue is that the percentages may be measured in lines of code.

If one language is more verbose, counting lines of code will throw off conclusions about how much functionality is implemented using each language.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: