Earlier quoted context omitted.
Probably because of memory usage and garbage collection and the fact that java needs to be installed on most systems whereas C++ needs no dependencies and python comes preinstalled on the usual linux server (probably not python3 but i assume it will be some years before bind10 sees adoption for such critical infrastructure). Also he mentions specialized data structures and memory management. Atleast i wouldn't sleep…
Probably because of memory usage and garbage collection and the fact that java needs to be installed on most systems whereas C++ needs no dependencies Well, GCC (as in the compiler collection) has had a ahead-of-time compiler for ages: http://gcc.gnu.org/java/ There is also work in the LLVM camp on AOT Java compilation: http://vmkit.llvm.org/ Atleast i wouldn't sleep well if i know that the heart of the internet was…
Why is BIND 10 written in C++ and Python?
61–70 of 136 posts
Re: Why is BIND 10 written in C++ and Python?
#62Earlier quoted context omitted.
Probably because of memory usage and garbage collection and the fact that java needs to be installed on most systems whereas C++ needs no dependencies and python comes preinstalled on the usual linux server (probably not python3 but i assume it will be some years before bind10 sees adoption for such critical infrastructure). Also he mentions specialized data structures and memory management. Atleast i wouldn't sleep…
Probably because of memory usage and garbage collection and the fact that java needs to be installed on most systems whereas C++ needs no dependencies Well, GCC (as in the compiler collection) has had a ahead-of-time compiler for ages: http://gcc.gnu.org/java/ There is also work in the LLVM camp on AOT Java compilation: http://vmkit.llvm.org/ Atleast i wouldn't sleep well if i know that the heart of the internet was…
Apparently you are talking about the "Web", i was talking about the internet or networks in general.. I'm aware that tomcat may have a very large installation base. There is no use for your tomcat if the DNS is down, though :P
Re: Why is BIND 10 written in C++ and Python?
#63Earlier quoted context omitted.
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 ;)
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…
Re: Why is BIND 10 written in C++ and Python?
#64Earlier quoted context omitted.
Why doesn't it look good for python? As far as I'm aware, Python has never been advertised as a top-performance language, and part of the advantage has always been that you can rewrite performance-critical paths in c. Adding to this, the fact that BIND is something pretty performance-intensive, I don't think this makes it look bad at all.
>Why doesn't it look good for python? Because it directly contradicts the "only 20% of your code is performance sensitive and the other 80% can be scripting language X" nonsense that scripting language apologists constantly parrot with no evidence. This is a good example of how scripting languages are in fact not well suited to application development, and should instead be used for scripting.
Re: Why is BIND 10 written in C++ and Python?
#65Why isn't it written in Node.js?
Re: Why is BIND 10 written in C++ and Python?
#66> "C lacks good memory management" C lets you manage memory without possibly inefficient or even broken magical black box automated processes or garbage collectors. Maybe what the author meant to say was "C lacks easy memory management."
Funny you mention "black box automated process" because, what do you think malloc is? There are two ways of allocating memory directly from the kernel (IIRC), brk and mmap. There's some management malloc does, and if it's good or not depends on you application. For example, size, number and behaviour of your allocations. Depending on your situation you may want to do your own memory management.
Re: Why is BIND 10 written in C++ and Python?
#67Re: Why is BIND 10 written in C++ and Python?
#68Earlier quoted context omitted.
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 ti…
> 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.
Re: Why is BIND 10 written in C++ and Python?
#69Re: Why is BIND 10 written in C++ and Python?
#70Earlier quoted context omitted.
I can see what you're saying but it's worth contemplating what percentage of the total codebase that Python code would represent if it were replaced by C++ code.
I'm working on a project right now where we're replacing a Qt interface written in Python (PyQt) with C++ Qt as it's way too slow (interface is really laggy), and other than things like having to occasionally delete objects manually (often, if you just add a widget to a layout, Qt does the deletion for you), it's pretty much a 1-1 mapping. We're also replacing core op-graph and geometry processing from Python to C++,…
Can you give an example of what this looks like?