Distributed shared memory
Distributed shared memory
Main page

Distributed shared memory

logo
Community Hub0 subscribers
What are your thoughts?
Be the first to start a discussion here.
Be the first to start a discussion here.
Distributed shared memory

In computer science, distributed shared memory (DSM) is a form of memory architecture where physically separated memories can be addressed as a single shared address space. The term "shared" does not mean that there is a single centralized memory, but that the address space is shared—i.e., the same physical address on two processors refers to the same location in memory. Distributed global address space (DGAS), is a similar term for a wide class of software and hardware implementations, in which each node of a cluster has access to shared memory in addition to each node's private (i.e., not shared) memory.

DSM can be achieved via software as well as hardware. Hardware examples include cache coherence circuits and network interface controllers. There are three ways of implementing DSM: page-based approach using virtual memory, shared-variable approach using routines to access shared variables and object-based approach, ideally accessing shared data through object-oriented discipline.

DSM scales well with a large number of nodes and its message passing is hidden. It can handle complex and large databases without replication or sending the data to processes and is generally cheaper than using a multiprocessor system. It provides large virtual memory space, programs are more portable due to common programming interfaces and shield programmers from sending or receiving primitives.

It is generally slower to access than non-distributed shared memory and must provide additional protection against simultaneous accesses to shared data. DSM may incur a performance penalty, there is little programmer control over actual messages being generated and consistency models are needed to write correct programs.

Software DSM systems also have the flexibility to organize the shared memory region in different ways. The page-based approach organizes shared memory into pages of fixed size. In contrast, the object based approach organizes the shared memory region as an abstract space for storing shareable objects of variable sizes. Another commonly seen implementation uses a tuple space, in which the unit of sharing is a tuple.

Shared memory architecture may involve separating memory into shared parts distributed amongst nodes and main memory, or distributing all memory between nodes. A coherence protocol, chosen in accordance with a consistency model, maintains memory coherence.

Memory coherence is necessary such that the system which organizes the DSM is able to track and maintain the state of data blocks in nodes across the memories comprising the system. A directory is one such mechanism which maintains the state of cache blocks moving around the system.

A basic DSM will track at least three states among nodes for any given block in the directory. There will be some state to dictate the block as uncached (U), a state to dictate a block as exclusively owned or modified owned (EM), and a state to dictate a block as shared (S). As blocks come into the directory organization, they will transition from U to EM (ownership state) in the initial node. The state can transition to S when other nodes begin reading the block.

See all
User Avatar
No comments yet.