1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-25 23:10:47 -08:00
Commit graph

345 commits

Author SHA1 Message Date
Richard Kistruck
ff8ab008ca Mps master: poolams.c amsdescribe: fix buggy diag output intoduced
in 1998 (change 19787).

Copied from Perforce
 Change: 163155
 ServerID: perforce.ravenbrook.com
2007-08-20 17:08:59 +01:00
Richard Kistruck
c31f20a6de Mps master: from br/diagtag:
locus.c: clarify currGenSerial and new diag in ChainCondemnAuto().
poolamc.c: fix spelling of amcScanNailed_loop diag.
diag.c: (comment only) more todo list.

Copied from Perforce
 Change: 163127
 ServerID: perforce.ravenbrook.com
2007-08-14 16:27:30 +01:00
Richard Kistruck
a1ecafc1f8 Mps br/diagtag: diag.c: (comment only) add to todo list: deprecate
un-tagged diags, every diag should end with \n.
poolamc.c: fix spelling of amcScanNailed_loop diag.

Copied from Perforce
 Change: 163125
 ServerID: perforce.ravenbrook.com
2007-08-14 15:59:19 +01:00
Richard Kistruck
8bae9d7e8c Mps master: integ from br/diagtag:
DIAG_SINGLEF, _FIRSTF, _MOREF, and _END: Tagged diagnostics, sent to 
pseudo-stream "FilterStream" for buffering and filtering (diag.c, 
config.h, mpm.c, mpm.h).

mpm: WriteF now uses Stream_fputc/s, not mps_lib_fputc/s.  New 
functions WriteF_v and WriteF_firstformat_v.  New function 
StringEqual(s1, s2).

trace.c, poolamc.c: TraceStart, traceFindGrey, amcScanNailed_loop 
are now tagged diags.

Copied from Perforce
 Change: 163124
 ServerID: perforce.ravenbrook.com
2007-08-14 15:56:48 +01:00
Richard Kistruck
557026a790 Mps br/diagtag: diag_prefix_ in config.h, instead of hard-wired.
Note .filter-disable.

Copied from Perforce
 Change: 163119
 ServerID: perforce.ravenbrook.com
2007-08-14 13:31:46 +01:00
Richard Kistruck
2cbc8e1232 Mps br/diagtag: determine diag_buffer_size in config.h; space for
20000 chars (10 screenfuls) in diag varieties, 1 char in others.
Handle diag->buf overflow (in fact was already handled; now tested; 
 in the always-on safety tests, use a condition that is verbatim 
 the same as the corresponding AVER).
Diag type: DiagSig, and AVERT(Diag, diag).  Neater .rules.debug.

Copied from Perforce
 Change: 163114
 ServerID: perforce.ravenbrook.com
2007-08-13 18:07:30 +01:00
Richard Kistruck
d9d4f267df Mps br/diagtag: give helpful message if diag_end tag does not match.
(tidyup) Move RulesGlobal to head of file; write instructions.
(tidyup) Move StringEqual into mpm.c (with StringLength); add AVER.
(cosmetic) Correct case of names: module-interface names begin 
uppercase; local names begin lowercase.  Tags should be C identifiers.

Copied from Perforce
 Change: 163112
 ServerID: perforce.ravenbrook.com
2007-08-13 16:54:40 +01:00
Richard Kistruck
c6663dcbff Mps br/diagtag: matchtag now uses patternoccurs, not stringequal, so
-DIAGTEST/*/*
will filter out all diags whose tags contain "DIAGTEST".
Unit test for PatternOccurs.  (PatternOccurs used to be called 
StringMatch).  

Copied from Perforce
 Change: 163111
 ServerID: perforce.ravenbrook.com
2007-08-13 15:55:32 +01:00
Richard Kistruck
f27629ba7c Mps br/diagtag: .improve.empty-diag: if diag is empty, still allow
it to be output (if rules permit).  Rename FilterOutput as FilterStream_Output.

Copied from Perforce
 Change: 163110
 ServerID: perforce.ravenbrook.com
2007-08-13 15:05:39 +01:00
Richard Kistruck
34c5536455 Mps br/diagtag: note .improve.empty-diag. to do list.
Run diag_test() on first tag begin.

Copied from Perforce
 Change: 163105
 ServerID: perforce.ravenbrook.com
2007-08-11 16:26:51 +01:00
Richard Kistruck
05d91ccd0c Mps br/diagtag: diag.c: before first diag, output rules_diag: list
of all rules.  Aver FilterOutput non-reentrant.  Note: empty diags 
never output.

Copied from Perforce
 Change: 163104
 ServerID: perforce.ravenbrook.com
2007-08-11 12:53:50 +01:00
Richard Kistruck
95761082f4 Mps br/diagtag: (fix w3i3mv build) remove unused vars, unused static fn diagoutput, and add int->char cast in _fputc
Copied from Perforce
 Change: 163083
 ServerID: perforce.ravenbrook.com
2007-08-10 11:48:52 +01:00
Richard Kistruck
5a97a8309e Mps br/diagtag:
locus.c: slightly better ChainCondemnAuto diag.
poolamc.c: tag amcScanNailed-loop diag (as provoked by mpsicv).
(diag.c: (diag filter only) hide amcScanNailed-loop diag)

Copied from Perforce
 Change: 163082
 ServerID: perforce.ravenbrook.com
2007-08-10 10:53:32 +01:00
Richard Kistruck
3cf7d5d66a Mps br/diagtag: whether a rule matches tag and para is constant for
the whole of a given diag, so memoize it (instead of repeating the 
match for every line of the diag).
locus.c: new diag from ChainCondemnAuto.
trace.c: tidy up TraceStart diag, give traceFindGrey diag a tag.

Copied from Perforce
 Change: 163077
 ServerID: perforce.ravenbrook.com
2007-08-09 16:41:59 +01:00
Richard Kistruck
2cb3edd1c3 Mps br/diagtag: just a curious log file, see whiteset at line 356
Copied from Perforce
 Change: 163076
 ServerID: perforce.ravenbrook.com
2007-08-09 16:34:08 +01:00
Richard Kistruck
af1160663a Mps br/diagtag: matchpara lets you choose to see the whole of a
diagnostic based on something on one of its lines.  See RulesGlobalX 
for an example.  Implementation currently inefficient (scans whole 
buffer for each line).

Copied from Perforce
 Change: 163073
 ServerID: perforce.ravenbrook.com
2007-08-09 15:40:53 +01:00
Richard Kistruck
e4eafb743e Mps br/diagtag: matchline and lineoutput give line-by-line filtering.
Copied from Perforce
 Change: 163072
 ServerID: perforce.ravenbrook.com
2007-08-09 14:45:14 +01:00
Richard Kistruck
c311f178cc Mps br/diagtag: oops! back out accidental checkin of trace.c with
test code in.

Copied from Perforce
 Change: 163071
 ServerID: perforce.ravenbrook.com
2007-08-09 13:45:26 +01:00
Richard Kistruck
8342669dc9 Mps br/diagtag: diag.c: stringequal(), used to check tags, and
report helpfully if poor programmer forgot to end a tag.
FilterOutput: really filters now, but only on Tag.

Copied from Perforce
 Change: 163070
 ServerID: perforce.ravenbrook.com
2007-08-09 13:40:48 +01:00
Richard Kistruck
55b74f2590 Mps br/diagtag: writef (mpm.c) uses new stream_fputc/s(), but still use mps_lib_file*
and mps_lib_EOF.
diag.c:
  Diag is a buffer capable of holding a diagnostic.
  FilterStream can buffer and filter diagnostics.
  Rule is a selection rule for filtering diagnostics.
  FilterOutput does output (but does not apply the rules yet).
  DiagStream can be switched to either FilterStream() or mps_lib_stdout().  

Copied from Perforce
 Change: 163067
 ServerID: perforce.ravenbrook.com
2007-08-09 12:11:29 +01:00
Richard Kistruck
5cbd84f9b4 Mps br/diagtag:
diag.c: support tagging of diagnostics, and avoid having to 
  say DIAG_STREAM every time, with new macros:
    DIAG_SINGLEF, DIAG_FIRSTF, DIAG_MOREF, DIAG_END.
mpm.c: new WriteF_firstformat_v required by DIAG_MOREF.

Copied from Perforce
 Change: 163059
 ServerID: perforce.ravenbrook.com
2007-08-07 19:09:43 +01:00
Richard Kistruck
5a478d9a7d Mps br/diagtag: new writef_v takes a va_started va_list.
WriteF calls WriteF_v.

Copied from Perforce
 Change: 163057
 ServerID: perforce.ravenbrook.com
2007-08-07 17:22:12 +01:00
Richard Kistruck
65fc6da40d Mps from br/gcdiag to master: branch/2007-07-19/gcdiag/...@162965, 967, 969.
That is:
 - TraceStart diagnostic showing chains, GenDescs, and PoolGens;
 - TraceCreate calls traceCopySizes() to save a copy of each 
   GenDesc's newSize in a "newSizeAtCreate" field.

Copied from Perforce
 Change: 163046
 ServerID: perforce.ravenbrook.com
2007-08-06 17:30:02 +01:00
David Jones
671245b7e8 Mps: linux: using vmix rather than vmli
Copied from Perforce
 Change: 162974
 ServerID: perforce.ravenbrook.com
2007-07-20 19:15:15 +01:00
David Jones
3e28b6ccaa Mps: adding gendesc indexes back in. and moving some static
function

Copied from Perforce
 Change: 162969
 ServerID: perforce.ravenbrook.com
2007-07-20 18:43:07 +01:00
Richard Kistruck
64bb7f21eb Mps br/gcdiag: locus.c: (fix w3i3mv build): unused arg.
Copied from Perforce
 Change: 162968
 ServerID: perforce.ravenbrook.com
2007-07-20 18:40:14 +01:00
Richard Kistruck
f6fb026068 Mps br/gcdiag: trace.c tracestart: separate tracestartgendesc_diag
function, and use it to show &arena->topGen.

Copied from Perforce
 Change: 162967
 ServerID: perforce.ravenbrook.com
2007-07-20 18:30:06 +01:00
David Jones
d6b020e524 Mps: attempt to account for condemned in the poolgen
Copied from Perforce
 Change: 162966
 ServerID: perforce.ravenbrook.com
2007-07-20 18:18:31 +01:00
Richard Kistruck
b0219be845 Mps br/gcdiag: trace.c tracestart: diag arenadescribe, and
whiteset for this trace.

Copied from Perforce
 Change: 162965
 ServerID: perforce.ravenbrook.com
2007-07-20 17:50:16 +01:00
Richard Kistruck
90d7731a37 Mps br/gcdiag: split tracestartwhytostring into 2 parts (tostring
and ToTextBuffer), and fix DIAG in TraceStart to use ToString.  
(Previous hack of using the start-message's buffer only works if 
the client has enabled start messages).

Copied from Perforce
 Change: 162964
 ServerID: perforce.ravenbrook.com
2007-07-20 17:30:38 +01:00
David Jones
f7abe933ad Mps: minor formatting.
Copied from Perforce
 Change: 162963
 ServerID: perforce.ravenbrook.com
2007-07-20 13:50:35 +01:00
David Jones
92d3fe63bb Mps: zoneset added to diag.
Copied from Perforce
 Change: 162961
 ServerID: perforce.ravenbrook.com
2007-07-20 13:10:00 +01:00
David Jones
4cc0878bce Mps: int -> index
Copied from Perforce
 Change: 162958
 ServerID: perforce.ravenbrook.com
2007-07-20 11:51:35 +01:00
David Jones
f142d75661 Mps: tracestart diag, added poolname and gendesc index.
Copied from Perforce
 Change: 162957
 ServerID: perforce.ravenbrook.com
2007-07-20 11:21:05 +01:00
David Jones
7739f79926 Mps: why code in diagnostic, "correct" newsize diagnostics.
Copied from Perforce
 Change: 162956
 ServerID: perforce.ravenbrook.com
2007-07-20 11:09:49 +01:00
David Jones
d97d0920af Mps: poolgen diags at tracestart.
Copied from Perforce
 Change: 162955
 ServerID: perforce.ravenbrook.com
2007-07-20 10:20:44 +01:00
David Jones
2a8551b558 Mps: poolgens emitted in diags at tracestart.
Copied from Perforce
 Change: 162954
 ServerID: perforce.ravenbrook.com
2007-07-20 10:02:02 +01:00
David Jones
249ccae845 Mps: trace.c formatting changes.
Copied from Perforce
 Change: 162951
 ServerID: perforce.ravenbrook.com
2007-07-19 17:56:04 +01:00
David Jones
db1fc0c88c Mps: added link to job001687
Copied from Perforce
 Change: 162949
 ServerID: perforce.ravenbrook.com
2007-07-19 17:08:35 +01:00
Richard Kistruck
2901c70183 Mps master: diag.c's diag_with_stream_and_writef apparatus: now
always present in the source, even for builds (eg. non-diag 
varieties) in which it is not invoked.  (avoids ranlib warning on 
xcppgc).

Copied from Perforce
 Change: 162948
 ServerID: perforce.ravenbrook.com
2007-07-19 17:03:30 +01:00
Richard Kistruck
5d2c5a0cc7 Mps master: trace and poolabs: (comment only) clarify that
PoolTrivGrey knows that a white seg is an all-white seg, and 
therefore needs no greying.

Copied from Perforce
 Change: 162946
 ServerID: perforce.ravenbrook.com
2007-07-19 16:50:21 +01:00
David Jones
285586f5f0 Mps: undoing change 162940 using perforce technote 14. no
longer needed no that we use the DIAG_DECL macro.

Copied from Perforce
 Change: 162945
 ServerID: perforce.ravenbrook.com
2007-07-19 16:34:42 +01:00
Richard Kistruck
18295dfc24 Mps master: (fix w3i3mv build) wrap diag-only function declarations
(in trace.c) with DIAG_DECL() (from mpm.h).

Copied from Perforce
 Change: 162944
 ServerID: perforce.ravenbrook.com
2007-07-19 16:25:59 +01:00
David Jones
eae56ca5ed Mps: merging branch/2007-07-12/ramprel/ branch.
Copied from Perforce
 Change: 162941
 ServerID: perforce.ravenbrook.com
2007-07-19 15:52:37 +01:00
David Jones
0a1634bf36 Mps: adding -no-unused-function to avoid compiler warning.
Copied from Perforce
 Change: 162940
 ServerID: perforce.ravenbrook.com
2007-07-19 15:50:51 +01:00
Richard Kistruck
a2e36586dc Mps master: poolamc.c: diag out if amcscannailed completed, but had
to loop.  (A rare event, which might prompt a rare defect to appear).
This is diag developed for job001548, but worth leaving on by default 
(in diag varieties only, natch).

Copied from Perforce
 Change: 162939
 ServerID: perforce.ravenbrook.com
2007-07-19 15:34:51 +01:00
Richard Kistruck
35dc5cd940 Mps master: diag_with_stream_and_writef.
trace.c: traceFindGrey_diag: wrap calls in DIAG(), prevent report
overflow, reduce report array to 20 chars, and use WriteF.

Copied from Perforce
 Change: 162937
 ServerID: perforce.ravenbrook.com
2007-07-19 14:38:57 +01:00
Richard Kistruck
ae88d40843 Mps master: trace.c: (whitespace only) remove tabs, fix style of a comment.
Copied from Perforce
 Change: 162934
 ServerID: perforce.ravenbrook.com
2007-07-18 18:22:10 +01:00
Richard Kistruck
1a2668dac7 Mps master: arenavm.c: fix vmarenadescribe to cope with any number
of gens, removing hardwired limit of 3.
vmArenaExtend(): diagnostic: report when VM arena is extended (#if0)

Copied from Perforce
 Change: 162933
 ServerID: perforce.ravenbrook.com
2007-07-18 18:17:55 +01:00
Richard Kistruck
f640387076 Mps master: poolamc.c: wrap lines at 72 (or 71, oops)
Copied from Perforce
 Change: 162932
 ServerID: perforce.ravenbrook.com
2007-07-18 17:55:13 +01:00