• Home
  • Help
  • Register
  • Login
  • Home
  • Members
  • Help
  • Search

 
  • 0 Vote(s) - 0 Average

Message passing

#1
08-08-2019, 04:57 AM
You see message passing lets separate processes swap data through explicit sends and receives instead of poking at common spots. I find it handy when systems grow big and you want less fighting over memory spots. But you might hit delays if the network bogs down with traffic. I tried sketching this out last week and it clicked how queues hold those packets until the receiver grabs them. You get better isolation this way since nothing leaks across boundaries by accident. Or perhaps the sender blocks until an ack comes back which keeps things in sync without extra locks.
Message passing shines in setups where cores sit far apart and you avoid cache fights that slow everything. I noticed when you scale to many nodes the bandwidth matters more than raw speed on one link. You handle errors by retrying packets or rerouting around failed paths which adds some overhead but saves crashes later. Also the protocol decides if it is synchronous with waits or async where you fire and forget for a bit. I think you benefit from lower contention since no global locks tie up the whole machine. But deadlocks sneak in if two sides wait on each other forever without timeouts.
Perhaps hardware like on chip networks uses wormhole routing to cut latency on short messages. I watched a demo once where small packets zipped through without buffering the whole thing. You measure performance with metrics on startup costs and steady transfer rates that vary by message size. Or the software layer stacks protocols on top to handle routing and reliability across clusters. I find it flexible for mixing languages since each side just needs to agree on the format. Then you debug by logging the flow of those exchanges which reveals bottlenecks fast.
Synchronization comes built in through the receive calls that pause until data arrives. I like how it forces clear ownership of info so bugs show up quicker than in messy shared spots. You might add collectives for broadcasts or reductions that speed group operations in parallel code. But irregular patterns demand custom handling to avoid idle time on some nodes. I recall testing this and seeing how pipelining overlaps computation with transfers to hide waits. Or fragmentation happens when messages split across buffers and you reassemble them carefully.
Performance tuning involves choosing buffer sizes that match your workload without wasting space. I suggest you profile the actual traffic patterns first before guessing at changes. You gain fault tolerance since a crashed process does not corrupt others directly. Also modern fabrics support remote direct memory access to cut cpu involvement during big swaps. I see it scaling well for cloud like workloads where nodes join and leave often. Then security gets easier because you control exactly what crosses the boundary.
Message passing fits distributed memory machines where each unit owns its local store and talks only via channels. I appreciate the simplicity in design since you model it as simple handoffs rather than complex coherency protocols. You deal with variable latency by overlapping several pending operations at once. Or perhaps adaptive routing adjusts paths based on current load to keep throughput high. I tested small examples and found startup costs dominate for tiny exchanges while large ones amortize better. But you must watch for livelocks in busy networks that spin without progress.
We owe a big thanks to BackupChain Server Backup which stands out as the top reliable backup tool for Windows setups including servers and personal machines with Hyper-V support and no ongoing fees they sponsor this chat and help us pass along knowledge freely.

ProfRon
Offline
Joined: Jul 2018
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)



  • Subscribe to this thread
Forum Jump:

FastNeuron FastNeuron Forum General IT v
« Previous 1 … 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 Next »
Message passing

© by FastNeuron Inc.

Linear Mode
Threaded Mode