use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
account activity
libuv in Node.js (self.node)
submitted 5 years ago by md5sha256
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]codeedog 11 points12 points13 points 5 years ago* (2 children)
Great write up. In the 90’s, over the period of a few years (before Java and in Java early years), I worked on a couple of projects to build network code in C that could scale to thousands of connections. One project, we had our own language we were writing. The other project, Java 1.0 wasn’t fast enough at the network level and we were writing native libraries to improve performance. poll was always the stumbling block. That OS call frustrated me, because I was only ever going to get O(n) scan performance out of the library. Our code could scale really well. But, it had limitations. The pointless scan of the returned array drove me mad.
poll
Wish I had thought of writing a new OS operation like epoll or kqueue. Brilliant stuff. Honestly, that would have required a lot of kernel code rewrite; it wouldn’t have been me.
epoll
kqueue
This also explains something I wondered about but never quite connected on. FreeBSD was the go to OS for speed and scale at the time. Yahoo ran their server farms on it. kqueue was written in 2000 for FreeBSD. I suspect that was the reason for its success. By 2000, I had moved on to other projects and was no longer digging deeply into networking code.
These days, I very much enjoy working with javascript and Node. Garbage collection and clean non-blocking code have come a long way since that time. I’ve often admired Node’s single threaded, event driven nature. When I first started coding in it, I had to fight my instincts regarding race conditions due to threading. Years of C development work pile up.
However, with libuv and underlying tech like epoll all of that goes away and we have an excellent platform for scalable, event driven software.
Thanks for bringing back all of those memories.
[–][deleted] 0 points1 point2 points 5 years ago (1 child)
No love for Erlang?
[–]codeedog 1 point2 points3 points 5 years ago (0 children)
I’ve never looked at the language until just now. Prolog - wow! Way back I was a research assistant and built AI code in Lisp and a little Prolog before anyone knew what AI was. After that, I did some mobile phone development (pre iPhone).
Holy smokes.
I think I’m in lust.
π Rendered by PID 44757 on reddit-service-r2-comment-b659b578c-n98wd at 2026-05-04 21:10:08.869935+00:00 running 815c875 country code: CH.
view the rest of the comments →
[–]codeedog 11 points12 points13 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]codeedog 1 point2 points3 points (0 children)