In our previous discussions on PCI Express (PCIe) architecture, we saw how the system relies on a split-transaction protocol. In this model, a target device receives a request and, when it is ready, responds with a separate Completion packet. While this prevents devices from holding the bus hostage while fetching data, sending a Request and waiting for a Completion for every transaction would introduce unwanted latency.
To mitigate this latency and maximize bus efficiency, the PCIe Transaction Layer divides all requests into two distinct categories: Non-Posted and Posted transactions,. Here is a breakdown of the differences between them.
Non-Posted Transactions: Waiting for Confirmation
For a non-posted transaction, the Requester sends a Transaction Layer Packet (TLP) and explicitly expects the Completer to generate a response in the form of a Completion packet.
- Reads: Naturally, all read requests (Memory Reads, IO Reads, and Configuration Reads) are non-posted. The Requester needs the Completer to return the requested data, along with the status of the read, in a Completion packet,.
- IO and Configuration Writes: Surprisingly, IO writes and Configuration writes are also non-posted. Even though the Requester is delivering data to the target, it still expects a Completion packet back. Why? Because writes to IO and configuration space almost always alter device behavior and have strict timeliness requirements. The system’s software cannot logically proceed to the next instruction until it receives definitive confirmation that the write arrived successfully without error.
Posted Transactions: “Fire and Forget”
Posted transactions are designed for maximum speed. In a posted transaction, the targeted device does not return a Completion packet to the Requester.
- Memory Writes and Messages: Memory Writes and Message TLPs are always treated as posted requests.
- Maximizing Efficiency: By not requiring a Completion packet, posted transactions drastically improve performance. Once a memory write request is sent out, the Requester does not wait for any feedback before immediately moving on to its next task. Furthermore, no valuable bus bandwidth or time is wasted sending a Completion packet back through the fabric.
- The Postal Analogy: The term “posted” can be associated with the postal mail system. Posting a memory write is like dropping a letter in a mailbox: you put your faith in the system to deliver it, and you don’t stall your day waiting for a delivery receipt.
The Trade-Off: Speed vs. Feedback
The primary trade-off of using posted transactions is uncertainty. Because no Completion is sent, the Requester gets no direct feedback regarding whether the memory write successfully finished or encountered an error at the ultimate recipient,.
However, this minor uncertainty is considered an acceptable exchange for the massive performance gains. Furthermore, even though Memory Writes do not generate End-to-End Completions, they still fully participate in the Data Link Layer’s Ack/Nak protocol. This hardware-level mechanism guarantees that the packet is reliably delivered across each individual physical Link along its journey.
