←back to thread

67 points anon6362 | 1 comments | | HN request time: 0s | source
Show context
alexdns ◴[] No.45074520[source]
It was considered innovative when it was first shared here eight years ago.
replies(1): >>45074700 #
nurumaik ◴[] No.45074700[source]
Anything more innovative happened since (honestly curious)?
replies(4): >>45075146 #>>45075479 #>>45075495 #>>45077234 #
js4ever ◴[] No.45075146[source]
I don't think so, but my guess is raw performance rarely matters in the real world.

I once explored this, hitting around 125K RPS per core on Node.js. Then I realized it was pointless, the moment you add any real work (database calls, file I/O, etc.), throughput drops below 10K RPS.

replies(3): >>45075358 #>>45075454 #>>45075994 #
rivetfasten ◴[] No.45075994[source]
It's always a matter of chasing the bottleneck. It's fair to say that network isn't the bottleneck for most applications. Heuristically, if you're willing to take on the performance impacts of a GC'd language you're probably already not the target audience.

Zero copy is the important part for applications that need to saturate the NIC. For example Netflix integrated encryption into the FreeBSD kernel so they could use sendfile for zero-copy transfers from SSD (in the case of very popular titles) to a TLS stream. Otherwise they would have had two extra copies of every block of video just to encrypt it.

Note however that their actual streaming stack is very different from the application stack. The constraint isn't strictly technical: ISP colocation space is expensive, so they need to have the most juiced machines they can possibly fit in the rack to control costs.

There's an obvious appeal to accomplishing zero-copy by pushing network functionality into user space instead of application functionality into kernel space, so the DPDK evolution is natural.

replies(1): >>45077821 #
1. pclmulqdq ◴[] No.45077821[source]
TCP is generally zero-copy now. Zero-copy with io_uring is also possible.

AF_XDP is also another way to do high-performance networking in the kernel, and it's not bad.

DPDK still has a ~30% advantage over an optimized kernel-space application with a huge maintenance burden. A lot of people reach for it, though, without optimizing kernel interfaces first.