mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-03-23 15:22:20 -07:00
Add source for some of the monitor requirements.
Add missing design cross-references. Fix typo: "even" for "event". Copied from Perforce Change: 195075
This commit is contained in:
parent
d2d2895c03
commit
5ec88060f4
5 changed files with 38 additions and 30 deletions
|
|
@ -51,16 +51,16 @@ typedef mps_arg_s *Arg;
|
|||
typedef mps_arg_s *ArgList;
|
||||
typedef mps_key_t Key;
|
||||
|
||||
typedef Word RefSet; /* design.mps.refset */
|
||||
typedef Word ZoneSet; /* design.mps.refset */
|
||||
typedef unsigned Rank;
|
||||
typedef unsigned RankSet;
|
||||
typedef unsigned RootMode;
|
||||
typedef Size Epoch; /* design.mps.ld */
|
||||
typedef unsigned TraceId; /* <design/trace/> */
|
||||
typedef unsigned TraceSet; /* <design/trace/> */
|
||||
typedef unsigned TraceState; /* <design/trace/> */
|
||||
typedef unsigned TraceStartWhy;
|
||||
typedef Word RefSet; /* <design/collection/#refsets> */
|
||||
typedef Word ZoneSet; /* <design/collection/#refsets> */
|
||||
typedef unsigned Rank; /* <design/type/#rank> */
|
||||
typedef unsigned RankSet; /* <design/type/#rankset> */
|
||||
typedef unsigned RootMode; /* <design/type/#rootmode> */
|
||||
typedef Size Epoch; /* <design/type/#epoch> */
|
||||
typedef unsigned TraceId; /* <design/type/#traceid> */
|
||||
typedef unsigned TraceSet; /* <design/type/#traceset> */
|
||||
typedef unsigned TraceState; /* <design/type/#tracestate> */
|
||||
typedef unsigned TraceStartWhy; /* <design/type/#tracestartwhy> */
|
||||
typedef unsigned AccessSet; /* <design/type/#access-set> */
|
||||
typedef unsigned Attr; /* <design/type/#attr> */
|
||||
typedef unsigned RootVar; /* <design/type/#rootvar> */
|
||||
|
|
|
|||
|
|
@ -59,10 +59,11 @@ Notes
|
|||
-----
|
||||
|
||||
_`.note.refset`: Some of this document simply assumes that RefSets
|
||||
(see the horribly incomplete design.mps.refset) have been chosen as
|
||||
the solution for design.mps.arena.req.fun.set_. It's a lot simpler
|
||||
that way. Both to write and understand.
|
||||
(see design.mps.collections.refsets_) have been chosen as the solution for
|
||||
design.mps.arena.req.fun.set_. It's a lot simpler that way. Both to
|
||||
write and understand.
|
||||
|
||||
.. _design.mps.collections.refsets: collections#refsets
|
||||
.. _design.mps.arena.req.fun.set: arena#req-fun-set
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ _`.req.state.stopped`: that has finished running.
|
|||
|
||||
It should be possible to see:
|
||||
|
||||
_`.req.memory.total`: the total memory in use by the client program;
|
||||
_`.req.memory.total`: the total memory in use by the client program [GR_2004-12-02]_;
|
||||
|
||||
_`.req.memory.pool`: the memory in use by each pool;
|
||||
|
||||
|
|
@ -42,7 +42,7 @@ _`.req.trace`: when traces take place;
|
|||
|
||||
_`.req.trace.generation`: which generations get collected by each trace;
|
||||
|
||||
_`.req.time-fraction`: the fraction of time spent in collections;
|
||||
_`.req.time-fraction`: the fraction of runtime spent in collections;
|
||||
|
||||
_`.req.barriers`: the rate of barrier hits, to indicate how the barriers
|
||||
are working.
|
||||
|
|
@ -141,6 +141,11 @@ References
|
|||
Ravenbrook Limited; 2018-06-27;
|
||||
<https://info.ravenbrook.com/mail/2018/06/27/10-51-04/0/>.
|
||||
|
||||
.. [GR_2004-12-02]
|
||||
"RE: MPS, working set, and address space"; Göran Rydqvist;
|
||||
Configura Sverige AB; 2004-12-02;
|
||||
<http://info.ravenbrook.com/mail/2004/12/02/07-53-32/0/>.
|
||||
|
||||
|
||||
Document History
|
||||
----------------
|
||||
|
|
|
|||
|
|
@ -391,7 +391,9 @@ intended.
|
|||
``typedef Word RefSet``
|
||||
|
||||
_`.refset`: ``RefSet`` is a conservative approximation to a set of
|
||||
references. See design.mps.refset.
|
||||
references. See design.mps.collection.refsets_.
|
||||
|
||||
.. _design.mps.collection.refsets: collection#refsets
|
||||
|
||||
|
||||
``typedef int Res``
|
||||
|
|
@ -655,7 +657,7 @@ which we know very little about.
|
|||
``typedef Word ZoneSet``
|
||||
|
||||
_`.zoneset`: ``ZoneSet`` is a conservative approximation to a set of
|
||||
zones. See design.mps.refset.
|
||||
zones. See design.mps.collection.refsets_.
|
||||
|
||||
|
||||
Abstract types
|
||||
|
|
|
|||
|
|
@ -180,7 +180,7 @@ SI_PREFIX = list('yzafpnµm kMGTPEZY')
|
|||
SI_PREFIX[8] = ''
|
||||
|
||||
def with_SI_prefix(y, precision=5, unit=''):
|
||||
"""Turn the number y into a string using SI prefixes followed by unit."""
|
||||
"Turn the number y into a string using SI prefixes followed by unit."
|
||||
if y < 0:
|
||||
return '-' + with_SI_prefix(-y, precision, unit)
|
||||
y = decimal.Context(prec=precision).create_decimal(y)
|
||||
|
|
@ -1463,7 +1463,7 @@ class ApplicationWindow(QtWidgets.QMainWindow):
|
|||
self._log(message)
|
||||
|
||||
def _on_key_press(self, event):
|
||||
"""Handle a keyboard event."""
|
||||
"Handle a keyboard event."
|
||||
with ErrorReporter(self._log_lines):
|
||||
if event.key in self._shortcuts:
|
||||
self._shortcuts[event.key][0](event)
|
||||
|
|
@ -1471,11 +1471,11 @@ class ApplicationWindow(QtWidgets.QMainWindow):
|
|||
self._log(f"Unknown key {event.key!r}")
|
||||
|
||||
def _mpl_key(self, event):
|
||||
"""Hand a key-press even on to the toolbar."""
|
||||
"Pass a key-press event to the toolbar."
|
||||
key_press_handler(event, self._canvas, self._toolbar)
|
||||
|
||||
def _help(self, event):
|
||||
"""Report keyboard help to the log pane."""
|
||||
"Report keyboard help to the log pane."
|
||||
# Collate shortcut keys by their documentation string.
|
||||
doc_keys = defaultdict(list)
|
||||
for _, key, doc in self._shortcuts.values():
|
||||
|
|
@ -1487,15 +1487,15 @@ class ApplicationWindow(QtWidgets.QMainWindow):
|
|||
self._log(f"\t{'/'.join(doc_keys[doc])}\t{doc}")
|
||||
|
||||
def _pause(self, event):
|
||||
"""Toggle pausing of axis limit updates."""
|
||||
"Toggle pausing of axis limit updates."
|
||||
self._toolbar.pause()
|
||||
|
||||
def _close(self, event):
|
||||
"""Close the monitor application."""
|
||||
"Close the monitor application."
|
||||
self.close()
|
||||
|
||||
def _toggle_log_linear(self, event):
|
||||
"""Toggle the bytes axis between log and linear scales."""
|
||||
"Toggle the bytes axis between log and linear scales."
|
||||
yscale = 'linear' if self._log_scale else 'log'
|
||||
self._axes_dict[BYTES_AXIS].set_yscale(yscale)
|
||||
self._axes_dict[BYTES_AXIS].yaxis.set_major_formatter(
|
||||
|
|
@ -1504,33 +1504,33 @@ class ApplicationWindow(QtWidgets.QMainWindow):
|
|||
self._log(f'Switched bytes axis to {yscale} scale.')
|
||||
|
||||
def _next_point(self, event):
|
||||
"""Select the next point on the selected line."""
|
||||
"Select the next point on the selected line."
|
||||
if self._close_points is None:
|
||||
return
|
||||
line, index = self._close_points[self._selected]
|
||||
self._select(line, index + 1)
|
||||
|
||||
def _previous_point(self, event):
|
||||
"""Select the previous point on the selected line."""
|
||||
"Select the previous point on the selected line."
|
||||
if self._close_points is None:
|
||||
return
|
||||
line, index = self._close_points[self._selected]
|
||||
self._select(line, index - 1)
|
||||
|
||||
def _up_line(self, event):
|
||||
"""Select the point on the line above the currently selected point."""
|
||||
"Select the point on the line above the currently selected point."
|
||||
if self._selected is None:
|
||||
return
|
||||
self._annotate(self._selected + 1)
|
||||
|
||||
def _down_line(self, event):
|
||||
"""Select the point on the line below the currently selected point."""
|
||||
"Select the point on the line below the currently selected point."
|
||||
if self._selected is None:
|
||||
return
|
||||
self._annotate(self._selected - 1)
|
||||
|
||||
def _select(self, line, index):
|
||||
"""Select the point with index `index` on `line`, if it exists."""
|
||||
"Select the point with index `index` on `line`, if it exists."
|
||||
if index < 0 or index >= len(line):
|
||||
return
|
||||
t, y = line[index]
|
||||
|
|
@ -1693,7 +1693,7 @@ class ApplicationWindow(QtWidgets.QMainWindow):
|
|||
self._zoom_to(newlo, newhi)
|
||||
|
||||
def _zoom_to(self, lo, hi):
|
||||
"""Redraw with new limits on the time axis."""
|
||||
"Redraw with new limits on the time axis."
|
||||
ax = self._axes_dict[BYTES_AXIS]
|
||||
if self._toolbar.empty():
|
||||
self._toolbar.push_current()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue