Earlier quoted context omitted.
If the author doesn't understand their own code, I probably won't
Vibe coding doesnt mean the author doesnt understand their code. Its likely that they don't want carpal tunnel from typing out trivial code and hence offload that labor to a machine.
Java FFM zero-copy transport using io_uring
21–30 of 59 posts
Re: Java FFM zero-copy transport using io_uring
#22Earlier quoted context omitted.
For your pet project? No. For something you're building for others to use? Almost certainly yes.
You do realize that it's possible to ask AI to write code and then read the code yourself to ensure it's valid, right? I usually try to strip the pointless comments, but it's not the end of the world if people leave them in.
Re: Java FFM zero-copy transport using io_uring
#23Earlier quoted context omitted.
For your pet project? No. For something you're building for others to use? Almost certainly yes.
You do realize that it's possible to ask AI to write code and then read the code yourself to ensure it's valid, right? I usually try to strip the pointless comments, but it's not the end of the world if people leave them in.
You could add your own instead, explaining how things work?
> It's possible to ask AI to write code and then read the code yourself
Sure, but then it would not be vibecoding.
Re: Java FFM zero-copy transport using io_uring
#24Earlier quoted context omitted.
For your pet project? No. For something you're building for others to use? Almost certainly yes.
You do realize that it's possible to ask AI to write code and then read the code yourself to ensure it's valid, right? I usually try to strip the pointless comments, but it's not the end of the world if people leave them in.
That leaves 2 options:
- they didn't read the code themselves to ensure it's valid
- they did read the code themselves but left the useless comments
No matter which happened it shows they're a bad developer and I don't want to run their code.
Re: Java FFM zero-copy transport using io_uring
#25Earlier quoted context omitted.
You do realize that it's possible to ask AI to write code and then read the code yourself to ensure it's valid, right? I usually try to strip the pointless comments, but it's not the end of the world if people leave them in.
> I usually try to strip the pointless comments You could add your own instead, explaining how things work? > It's possible to ask AI to write code and then read the code yourself Sure, but then it would not be vibecoding.
> Sure, but then it would not be vibecoding.
Wait, what?
Re: Java FFM zero-copy transport using io_uring
#26Re: Java FFM zero-copy transport using io_uring
#27Earlier quoted context omitted.
> I usually try to strip the pointless comments You could add your own instead, explaining how things work? > It's possible to ask AI to write code and then read the code yourself Sure, but then it would not be vibecoding.
>> It's possible to ask AI to write code and then read the code yourself > Sure, but then it would not be vibecoding. Wait, what?
Re: Java FFM zero-copy transport using io_uring
#28Earlier quoted context omitted.
> I usually try to strip the pointless comments You could add your own instead, explaining how things work? > It's possible to ask AI to write code and then read the code yourself Sure, but then it would not be vibecoding.
>> It's possible to ask AI to write code and then read the code yourself > Sure, but then it would not be vibecoding. Wait, what?
Now the term has evolved into "using AI in coding" (usually with a hint of non rigor/casualness), but that's not what it originally meant.
Re: Java FFM zero-copy transport using io_uring
#2927us roundtrip is not really state of the art for zero copy IPC, about 1us would be. What is causing this overhead?
Asking for those who, like me, haven't yet taken the time to find technical information on that webpage: What exactly does that roundtrip latency number measure (especially your 1us)? Does zero copy imply mapping pages between processes? Is there an async kernel component involved (like I would infer from "io_uring") or just two user space processes mapping pages?
The actual (one-way cross-core) latency on modern CPUs varies by quite a lot [0], but a good rule of thumb is 100ns + 0.1ns per byte.
This measures the time for core A to write one or more cache lines to a shared memory region, and core B to read them. The latency is determined by the time it takes for the cache coherence protocol to transfer the cache lines between cores, which shows up as a number of L3 cache misses.
Interestingly, at the hardware level, in-process vs inter-process is irrelevant. What matters is the physical location of the cores which are communicating. This repo has some great visualizations and latency numbers for many different CPUs, as well as a benchmark you can run yourself:
Re: Java FFM zero-copy transport using io_uring
#3027us roundtrip is not really state of the art for zero copy IPC, about 1us would be. What is causing this overhead?
It may or may not be good, depending on a number of fact. I did read the original linux zerocopy papers from google for example, and at the time (when using tcp) the juice was worth the squeeze when payload was larger than than 10 kilobytes (or 20? Don’t remember right now and i’m on mobile). Also a common technique is batching, so you amortise the round-trip time (this used to be the cost of sendmmsg/recvmmsg) over,…
Little’s Law applies when the task monopolizes the time of the worker. When it is alternating between IO and compute, it can be off by a factor of two or more. And when it’s only considering IO, things get more muddled still.