Earlier quoted context omitted.
I know that it’s asking a lot, but any chance that you can post a minimum reproducible sample? From what I know it is quite smelly...
I don't have access to this codebase now but I'll try to write some benchmark.
Show HN: ZFS Implementation in Python
51–60 of 97 posts
Re: Show HN: ZFS Implementation in Python
#52Earlier quoted context omitted.
Dont forget, pypy is fast.
PyPy is faster than Python, yes. But Go, C and many other (compiled) languages are way faster than PyPy. Plus, if you use a language like Go or Rust then you avoid Python's GIL and you'll have much more reasonable memory usage. Best of all, deploying is a matter of copying a binary, rather than having to deal with the absolute disaster that is Python packaging.
Re: Show HN: ZFS Implementation in Python
#53Re: Show HN: ZFS Implementation in Python
#54Earlier quoted context omitted.
Faster that CPython doesn't mean it is fast.
I was trying to speed up a log processing service running on PyPy by rewriting it in Java. I was surprised that the result was about twice slower (I know Java quite well and I didn't see obvious optimizations; most of the time was spent in GC). So it can be quite fast even in more absolute terms (VM languages), at least for some types of code.
Re: Show HN: ZFS Implementation in Python
#55Earlier quoted context omitted.
I don't have access to this codebase now but I'll try to write some benchmark.
If you manage to do it would be awesome, otherwise thanks a lot anyway for the effort :) I’m just curious to understand why it happens because it’s exactly the opposite of what I would expect. The only explanation that comes to my mind is excessive gc as someone else already mentioned, but it would be interesting to see the original code.
Re: Show HN: ZFS Implementation in Python
#56Earlier quoted context omitted.
So we port this python to something not slow, and all the kernel-people can shut up about ZFS being terrible ;)
Dont forget, pypy is fast.
A good filesystem implementation requires tight memory management and good control of what happens at the OS level. I am not saying it can't be be done in python, but it clearly isn't the right tool for the job.
I meant that for a production implementation. Python is perfectly fine for a proof of concept, in fact, it may be better than jumping straight down to C. But keeping it for production is foolish IMHO.
Re: Show HN: ZFS Implementation in Python
#57Earlier quoted context omitted.
Dont forget, pypy is fast.
PyPy is faster than Python, yes. But Go, C and many other (compiled) languages are way faster than PyPy. Plus, if you use a language like Go or Rust then you avoid Python's GIL and you'll have much more reasonable memory usage. Best of all, deploying is a matter of copying a binary, rather than having to deal with the absolute disaster that is Python packaging.
Re: Show HN: ZFS Implementation in Python
#58Does someone know whether it would be legal for someone to go through the ZFS code and write a specification of the features this author hasn’t figured out yet? I.e. could someone write a detailed description of the missing functionality that doesn’t include any details about the implementation so other people can implement it in non-CDDL code?
Original comment: I could swear this was actually the standard practice for writing an implementation of an unknown file format or interface without infringing on copyright. But I don't remember the term for it.
Re: Show HN: ZFS Implementation in Python
#59Earlier quoted context omitted.
PyPy is faster than Python, yes. But Go, C and many other (compiled) languages are way faster than PyPy. Plus, if you use a language like Go or Rust then you avoid Python's GIL and you'll have much more reasonable memory usage. Best of all, deploying is a matter of copying a binary, rather than having to deal with the absolute disaster that is Python packaging.
Go? A GC'd language in kernel? (Well, yes, this has been done, from Lua to Haskell, but only experimentally.)
Re: Show HN: ZFS Implementation in Python
#60Does someone know whether it would be legal for someone to go through the ZFS code and write a specification of the features this author hasn’t figured out yet? I.e. could someone write a detailed description of the missing functionality that doesn’t include any details about the implementation so other people can implement it in non-CDDL code?
EDIT: Ninjad because I left the reply in a tab without posting.