Processor Consistency is one of the consistency models used in the domain of concurrent computing (e.g. in distributed shared memory, distributed transactions, etc.).
A system exhibits Processor Consistency if the order in which other processors see the writes from any individual processor is the same as the order they were issued. Because of this, Processor Consistency is only applicable to systems with multiple processors. It is weaker than the Causal Consistency model because it does not require writes from all processors to be seen in the same order, but stronger than the PRAM Consistency model because it requires Cache Coherence. Another difference between Causal Consistency and Processor Consistency is that Processor Consistency removes the requirements for loads to wait for stores to complete, and for Write Atomicity. Processor Consistency is also stronger than Cache Consistency because Processor Consistency requires all writes by a processor to be seen in order, not just writes to the same memory location.
In Example 1 to the right, the simple system follows Processor Consistency, as all the writes by each processor are seen in the order they occurred in by the other processors, and the transactions are coherent. Example 2 is NOT Processor Consistent, as the writes by P1 and P3 are seen out of order by P2 and P4 respectively.
In Example 3 below, the strongest applicable consistency model is Processor Consistency. This is trivial to determine because there is only at most one write per processor. This example is not causally consistent, however, because with R(x)1 occurring before W(x)2, the value written in W(x)2 might differ, assuming W(x)2 is dependent on R(x)1.
The system in Example 4 is not processor consistent, because some writes by the same processor are seen out of order by other processors. More specifically, writes to a single location are seen in order, but the write to x by P1 is not seen by P2 before the write to y. The fact that the only writes seen in order are writes to the same memory location limits this example to Cache Consistency.
Processor Consistency (PC) relaxes the ordering between older stores and younger loads that is enforced in Sequential consistency (SC). This allows loads to be issued to the cache and potentially complete before older stores, meaning that stores can be queued in a write buffer without the need for load speculation to be implemented (the loads can continue freely). In this regard, PC performs better than SC because recovery techniques for failed speculations aren’t necessary, which means fewer pipeline flushes. The prefetching optimization that SC systems employ is also applicable to PC systems.Prefetching is the act of fetching data in advance for upcoming loads and stores before it is actually needed, to cut down on load/store latency. Since PC reduces load latency by allowing loads to be re-ordered before corresponding stores, the need for prefetching is somewhat reduced, as the prefetched data will be used more for stores than for loads.