4 ms·
Not naively: this kind of pipelining is partial function application, not coordinated parallelism (the way Unix pipeliens are).
by woodruffw 4y ago
Not naively: this kind of pipelining is partial function application, not coordinated parallelism (the way Unix pipeliens are).
- AtlasBarfed 4y agoDoes anyone know any documentation on how UNIX achieves parallelism in pipelines, especially modern implementations? Is each stage of a piped command just another spun off process?
- woodruffw 4y agoYes, it's just that: each process in the pipeline is spawned, and then blocks as it waits for input from the previous step in the pipeline. I think a better way to think about it is that the UNIX model requires parallelism: without parallelism, each stage in the pipeline would need to fully buffer its intermediate state before forwarding it to the next stage.
- superdisk 4y ago> without parallelism, each stage in the pipeline would need to fully buffer its intermediate state before forwarding it to the next stage. That's how DOS implemented the pipe syntax I believe.
- masklinn 4y ago> Is each stage of a piped command just another spun off process? Yes. With, as the name says, a pipe inbetween.