The programs are portable across a wide variety of architectures. For the shared-memory model, p4 provides a set of primitives from which monitors can be constructed. For the distributed memory model, p4 provides typed send and receive operations. These two models can be combined to form the 'cluster' model.