Recently, my girlfriend and I were trying to get out of the house, when I encountered a phenomenon which I thought might be analogous to a tradeoff in concurrent systems.
Here's the real world setup.
Process A: Girlfriend orders coffee on phone.
Process B: Girlfriend gets ready at apartment, and ideally drives car to pick me up at coffee shop.
Process C: I fetch coffee, and ideally get picked up by girlfriend at coffee shop.
Process D: We commute together.
Process Amust complete before
Processes B and C.
Process B and Cmust complete before
On the day:
- My girlfriend orders coffee (
Process A) and begins getting ready (
- I leave the apartment to fetch coffee while my girlfriend is getting ready (
- However, my girlfriend takes longer than expected to get ready, so instead of getting picked up at the coffee shop shortly after dealing with payment, I wait.
- Then, we commute (
Resources, namely me walking, are not used minimally. In retrospect, we determine the optimal solution given the knowledge that my girlfriend will take longer to get ready is to simply wait. Once she finishes getting ready, we ought to drive to the coffee shop together to fetch the coffee and commute from there.
Processes are appropriately recognized as able to be parallelized. But, because of resource sharing, will only yield the desired improvements under ideal circumstances wherein girlfriend arrives by car at coffee shop shortly after coffee has been fetched. Unless this circumstance is realized, the time to complete
Processes A - D becomes primarily determined by
Process B and optimization of
Process C is not concerning.
More generally, we determine a sequential solution makes better use of resources than the concurrent solution.
If processes are performed...
A -> B -> C -> D
we will most likely prefer that outcome to the original...
-> B - A - | | -> D -> C -
... (in part) because, even though time is slightly less optimized, work is better shared.
Does this phenomenon have a name? In what areas of computing might this tradeoff be more common or concerning? What are common software analysis strategies that may help?
Note: I can contrive examples with more significant effects, even ones that do not produce optimal runtime (though that may be another phenomenon). But, (a) this is partially a playful barb at my gf's planning and (b) I thought this might resonate with some folks.