4 ms·
To all the haters: the GIL is just a constraint that can be worked around. Clever ways of starting more than one interpreter is a solid way to do that. If you c
by abotsis 10y ago
To all the haters: the GIL is just a constraint that can be worked around. Clever ways of starting more than one interpreter is a solid way to do that. If you can't think of a way to do that, then maybe you shouldn't be working on distributed systems.
For example, I wrote a high-speed distributed database load tool, a perfect python use-case. It did some transforms, but nothing heavy. The database (Vertica) could generally keep up. For large files (multiple TB) I'd divide the file into a number of chunks and each interpreter would just seek into an offset, read to EOL, then load until it reached the next interpreter's offset. I built it in a few hours.
Just trying to say that there are very few real-world workloads (were python is extremely useful) that the GIL really gets in the way. It certainly doesn't offset the time and ease of developing a solution.
- dang 10y ago> To all the haters This is a form of name-calling, which the HN guidelines ask you not to do in arguments. And the "if you can't think of... maybe you shouldn't be" is also a jab. Please don't do these things in HN comments. They add no information, just provocation. Consider how much better your otherwise fine comment would be without them. https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newswelcome.html https://news.ycombinator.com/newswelcome.html
- ixtli 10y agoI worry that you would not have posted this response if the top comment had said "Dear dissenters,". However I think you're right about the extraneous and specious "maybe you shouldn't be working in distributed systems" claim.
- scott_s 10y agoPerhaps not, but for good reason: "dear haters" and "dear dissenters" mean different things. As does, "To everyone who disagrees, please consider ..." The word "haters" is combative.
- abotsis 10y agoThe point was to be used as a colloquialism to address people who disagree and encourage them to stop, think and remember everything has tradeoffs and compromises. Then to think about those before simply saying "this isn't a GIL workaround". Maybe it had the opposite effect. :) I mean, I'm a python fan and this has tradeoffs too (external dependency, task dispatch latency) which doesn't make it suitable every time the GIL gets in the way. In any case, I don't believe either of these were any more sensational than some of the content in this post.
- scott_s 10y agoReturning-in-kind is actively discouraged on HN.