localshm attribute
The localshm attribute can be specified at the superclass and the subclass levels.
The localshm attribute is used to prevent memory
segments belonging to one class from migrating to the Shared superclass
or subclass when accessed by processes in other classes. The possible values
for the attribute are yes or no. A value of yes
means that
shared memory segments in this class must remain local to the class and not
migrate to the appropriate Shared class. A value of no
is
the default when the attribute is not specified.
Memory segments are classified on page faults. When a segment is created, it is marked as belonging to the Unclassified superclass. On the first page fault on the segment, this segment is classified into the same class as the faulting process. If, later on, a process belonging to a different class than the segment page faults on this segment, WLM considers whether the segment needs to be reclassified into the appropriate Shared class (superclass or subclass). If the faulting process and the segment belong to different superclasses, one of the following occurs:
- If the segment's superclass has the localshm attribute
set to
yes
, the segment remains in its current superclass. If the segment's subclass has the localshm attribute set toyes
, the segment remains in its current subclass. If the superclass localshm attribute is set toyes
but its subclass attribute is set tono
, it goes into the Shared subclass of the current superclass. - If the segment's superclass has the localshm attribute
set to
no
, the segment goes to Shared superclass. This is the default action.
If the faulting process and the segment belong to different subclasses
of the same superclass, and the segment's subclass has the localshm attribute
set to yes
, the segment remains in the current class (superclass
and subclass). Otherwise, the segment goes to the Shared subclass of
the superclass.
Of course, if the faulting process and the segment belong to the same class (same superclass and same subclass), the segment is not reclassified regardless of the values of the localshm attributes.