1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-19 20:30:29 -08:00
Commit graph

157 commits

Author SHA1 Message Date
David Lovemore
b4460043e6 Added more control over write barrier. in particular separated scans after a hit.
Copied from Perforce
 Change: 186988
 ServerID: perforce.ravenbrook.com
2014-08-27 11:21:18 +01:00
David Lovemore
46d723c9dc Added experimental control over write barrier eagerness.
The write barrier is only raised after three unnecessary scans.

Copied from Perforce
 Change: 186975
 ServerID: perforce.ravenbrook.com
2014-08-21 15:53:57 +01:00
David Lovemore
23174c0d80 Use write barrier in incremental mode.
This was previously completely disabled.

Copied from Perforce
 Change: 186973
 ServerID: perforce.ravenbrook.com
2014-08-21 14:03:09 +01:00
David Lovemore
8c9353fe34 Add mps_key_arena_incremental option.
Avoid read and write barrier in non-incremental mode.
Add --non-incremental option to gcbench

Copied from Perforce
 Change: 186969
 ServerID: perforce.ravenbrook.com
2014-08-20 13:03:20 +01:00
David Lovemore
858954c95e Collections now non-incremental. simple change to tracepoll to make collections do work until they are finished.
Copied from Perforce
 Change: 186964
 ServerID: perforce.ravenbrook.com
2014-08-18 12:06:03 +01:00
Gareth Rees
08f341fcc9 Catch-up merge from master sources @186540 to branch/2014-05-17/chunk-tree.
Copied from Perforce
 Change: 186546
 ServerID: perforce.ravenbrook.com
2014-06-12 17:55:16 +01:00
Gareth Rees
cb629746ea Catch-up merge from masters sources @186519 to branch/2014-04-17/describe.
Copied from Perforce
 Change: 186526
 ServerID: perforce.ravenbrook.com
2014-06-12 13:45:22 +01:00
Gareth Rees
cf75884793 Refer to rb's e-mail for potential optimization.
Copied from Perforce
 Change: 186524
 ServerID: perforce.ravenbrook.com
2014-06-12 12:18:30 +01:00
Gareth Rees
de2a30d207 Catch-up merge from master sources @186481 to branch/2014-05-17/chunk-tree.
Copied from Perforce
 Change: 186491
 ServerID: perforce.ravenbrook.com
2014-06-11 13:52:31 +01:00
Gareth Rees
144d1aea03 Catch-up merge from master sources @186213 to branch/2014-05-17/chunk-tree.
Copied from Perforce
 Change: 186214
 ServerID: perforce.ravenbrook.com
2014-05-20 19:11:50 +01:00
Gareth Rees
2f0ef9355d Clarify tracefix logic by unwinding the nested conditions.
Change the arena's chunk tree from a splay tree to an ordinary tree (so that it's not possible to accidentally splay it and leave it unbalanced).
New function TreeFindNext allows us to implement TractFirst and TractNext without having to splay the tree.
Make sure all operations on the chunk tree leave it balanced. But don't balance the tree directly in ChunkFinish() because this is only ever called in a loop where multiple chunks are being deleted from the tre. Instead use the sequence TreeToVine -- iterate and delete -- TreeBalance. The new macro TREE_DESTROY assists with this.
No need any more for ArenaIsReservedAddr, CHUNK_OF_ADDR, TRACT_OF_ADDR.
Update design documentation.

Copied from Perforce
 Change: 186212
 ServerID: perforce.ravenbrook.com
2014-05-20 18:12:37 +01:00
Gareth Rees
04a44878f3 Catch-up merge from master sources @186174 to branch/2014-04-30/poolgen.
Copied from Perforce
 Change: 186185
 ServerID: perforce.ravenbrook.com
2014-05-19 14:59:19 +01:00
Gareth Rees
4d10bb418b Catch-up merge from master sources @186077 to branch/2014-04-23/awl.
Copied from Perforce
 Change: 186110
 ServerID: perforce.ravenbrook.com
2014-05-15 10:17:41 +01:00
Gareth Rees
4c7106cd6f Check the trace argument to tracequantum.
Copied from Perforce
 Change: 186027
 ServerID: perforce.ravenbrook.com
2014-05-12 13:35:21 +01:00
Gareth Rees
8a84937edb Improve formatting of poolgendescribe and tracedescribe.
Add ArenaDescribe calls to amcss and finalcv to get coverage of PoolGenDescribe, TraceDescribe, and MRGDescribe.

Copied from Perforce
 Change: 186010
 ServerID: perforce.ravenbrook.com
2014-05-11 21:13:55 +01:00
Gareth Rees
30f37732a9 Catch-up merge from master sources @185999 to branch/2014-04-17/describe.
Copied from Perforce
 Change: 186003
 ServerID: perforce.ravenbrook.com
2014-05-11 18:33:02 +01:00
Gareth Rees
c77c91056d Consistent order stream, depth.
Copied from Perforce
 Change: 186001
 ServerID: perforce.ravenbrook.com
2014-05-11 18:30:23 +01:00
Gareth Rees
2493f121dc Correct indentation of describe output by passing depth parameter to describe functions and to writef.
Call Describe functions from test cases so that we get coverage.

Copied from Perforce
 Change: 186000
 ServerID: perforce.ravenbrook.com
2014-05-11 18:20:38 +01:00
Gareth Rees
d05197dccb Avoid the need for newsizeatcreate by emitting events for the pool generations in tracecreate instead of tracestart.
Get rid of proflow member of GenDescStruct (it was unused).
Use STATISTIC to avoid updating segs, freeSize, oldSize, and oldDeferredSize in non-checking varieties.
Add design for pool generation accounting.

Copied from Perforce
 Change: 185930
 ServerID: perforce.ravenbrook.com
2014-05-01 19:00:08 +01:00
Gareth Rees
4fa0ae0db9 Output all the pool generation accounting information.
Copied from Perforce
 Change: 185911
 ServerID: perforce.ravenbrook.com
2014-04-30 17:39:37 +01:00
Gareth Rees
36d731c149 Use double-entry book-keeping and bank reconciliation to ensure the soundness and completeness of the pool generation size accounting.
Copied from Perforce
 Change: 185888
 ServerID: perforce.ravenbrook.com
2014-04-30 12:14:54 +01:00
Gareth Rees
0eb9ac546f Pool generations now refer directly to their generation (not via a chain and a generation number).
Allocation into a generation now via PoolGenAlloc (not ChainAlloc).
The "top generation" logic is encapsulated in the function ChainGen.

Copied from Perforce
 Change: 185877
 ServerID: perforce.ravenbrook.com
2014-04-30 11:18:44 +01:00
David Lovemore
70c0cb9a94 Rename bool(v) to boolof(v) to fix clash with the windows header file windows.h
Copied from Perforce
 Change: 185841
 ServerID: perforce.ravenbrook.com
2014-04-28 13:14:04 +01:00
Gareth Rees
b888d047ba Explain traceaddwhite failure logic as requested by nb in <https://info.ravenbrook.com/mail/2014/04/24/12-10-09/0/>.
Copied from Perforce
 Change: 185800
 ServerID: perforce.ravenbrook.com
2014-04-25 17:41:56 +01:00
Gareth Rees
b674ece749 Tracecondemnzones could leave the white set inconsistent if traceaddwhite failed. add an assertion to cover this case (corresponding to the similar assertion in tracecondemnall).
Copied from Perforce
 Change: 185765
 ServerID: perforce.ravenbrook.com
2014-04-23 20:22:19 +01:00
Gareth Rees
6ffd4c7df5 Fix bugs in condemn logic:
1. TraceStartCollectAll now condemns all segments in pools with AttrGC (not just pools attached to generation zero of some chain, as before).
2. ChainDeferral now looks at all generations in the chain, so that the chain is condemned if any generation's new size is greater than its capacity (not just generation zero, as before).
3. ChainCondemnAuto now condemns all generations up to and including the highest generation whose new size is greater than its capacity (rather than, as before, up to and excluding the lowest generation whose new size is lower than its capacity).
Update finaltest.c so that it has a mode in which it allocates in generation 1 of a chain and with the arena released so that the above fixes are tested. Remove the MPS_KEY_GEN workarounds from awlut and awluthe as these are no longer needed.

Copied from Perforce
 Change: 185741
 ServerID: perforce.ravenbrook.com
2014-04-22 17:53:47 +01:00
Gareth Rees
e65a085be9 New function tracedescribe.
Copied from Perforce
 Change: 185631
 ServerID: perforce.ravenbrook.com
2014-04-17 14:22:19 +01:00
Gareth Rees
93a79ac8a6 Add -wconversion to the options for gcc. ensure that the mps builds.
Copied from Perforce
 Change: 185463
 ServerID: perforce.ravenbrook.com
2014-04-11 14:25:15 +01:00
Gareth Rees
9c8713f51b Fix problems found by coverity. see <https://info.ravenbrook.com/mail/2014/04/10/23-23-42/0/> for full analysis.
Copied from Perforce
 Change: 185445
 ServerID: perforce.ravenbrook.com
2014-04-11 00:26:48 +01:00
Gareth Rees
d3d2795fce Improve control over checking:
1. Where Type is a pointer type with a signature, replace CHECKL(TypeCheck(val)) with CHECKD(Type, val).
2. Where Type is a pointer type with no signature, replace CHECKL(TypeCheck(val)) with CHECKD_NOSIG(Type, val).
3. Where Type is a pointer type with a signature, but the structure is not visible at point of checking, replace CHECKL(TypeCheck(val)) with CHECKD_NOSIG(Type, val). Reference <design/check/#.hidden-type>
4. Make BTCheck extern and use it where possible.
5. Replace AVER(TypeCheck(val)) with AVERT(Type, val).

Copied from Perforce
 Change: 185263
 ServerID: perforce.ravenbrook.com
2014-04-06 22:51:05 +01:00
Gareth Rees
9bb6b2f8be Tidy-up of attributes and pool classes:
* Bring design up to date.
* New function PoolHasAttr encapsulates attribute checking.
* Abstract classes are abstract and mustn't be checked.
* The dummy pool class in fotest needs a size.
* Abstract pool classes null out methods that they can't provide a generic implementation for, to force subclasses to provide one.
* New function PoolTrivFramePopPending provides a generic implementation of that method.
* Rename PoolNoFreeWalk to PoolTrivFreeWalk since it has NOOP rather than NOTREACHED.
* Check that AttrMOVINGGC implies AttrGC.
* Remove unimplemented attributes (BUF_RESERVE, BUF_ALLOC, INCR_RB, INCR_WB, PM)
* AMC now inherits from AMCZ instead of the other way round. This is simpler: AMC adds features to AMCZ rather than AMCZ taking features away (and not quite getting it right).
* Similarly, LO inherits from AbstractSegBufPoolClass + PoolClassMixInCollect so that it doesn't have to clear AttrSCAN and the scan methods.
* Fix bug in MFSCheck -- mustn't check unroundedUnitSize >= UNIT_MIN since small unit sizes are rounded up to UNIT_MIN.
* Don't see AttrFREE in MRG (since no free method is supplied).
* Check AttrSCAN systematically (in PoolScan and SegCheck) rather than opportunistically in TraceStart and TraceQuantum.

Copied from Perforce
 Change: 185231
 ServerID: perforce.ravenbrook.com
2014-04-04 17:05:08 +01:00
Gareth Rees
b2ec897e6b Support the clang address sanitizer.
Copied from Perforce
 Change: 185096
 ServerID: perforce.ravenbrook.com
2014-03-30 18:51:53 +01:00
Gareth Rees
f025b00534 Turn on -wunreachable-code for gcc and clang.
Remove unreachable code:
* No need to have different debug options or structured allocation classes for different platforms.
* Don't use STATISTIC_BEGIN, use STATISTIC_STAT.
* #ifdef away the unused code in zmess.c for testing ControlAlloc failure.
* Remove unused code from the example Scheme interpreter.

Copied from Perforce
 Change: 185089
 ServerID: perforce.ravenbrook.com
2014-03-30 14:26:02 +01:00
Richard Brooksby
d8cb7e9a01 Catch-up merge from master, mainly to pick up chain-zones merge.
Copied from Perforce
 Change: 184343
 ServerID: perforce.ravenbrook.com
2014-02-14 15:23:36 +00:00
Richard Brooksby
e6ff3a648f Merging branch //info.ravenbrook.com/project/mps/branch/2014-01-29/mps-chain-zones/... into master.
Copied from Perforce
 Change: 184342
 ServerID: perforce.ravenbrook.com
2014-02-14 15:15:07 +00:00
Richard Brooksby
8679bb210f Catch-up merge from master, mainly to pick up gcbench.
Copied from Perforce
 Change: 184335
 ServerID: perforce.ravenbrook.com
2014-02-12 17:39:31 +00:00
Richard Brooksby
f1d5750639 Adding a cache of free pages per zone to the arena, so that we recycle single pages fast, especially after each reclaim.
Copied from Perforce
 Change: 184324
 ServerID: perforce.ravenbrook.com
2014-02-11 15:23:32 +00:00
Richard Brooksby
8a3dc7c98a Fixing gcc warnings found in https://travis-ci.org/ravenbrook/mps-temporary/jobs/17977403
Copied from Perforce
 Change: 184271
 ServerID: perforce.ravenbrook.com
2014-01-31 15:49:14 +00:00
Richard Brooksby
f719851f50 Since the dynamic generation is shared between chains (for some reason) using its unified zone set, rather than keeping a special zone set per chain, which would’ve used up more zones.
Using arena->topGen->mortality for the dynamic generation’s mortality, rather than a global variable.

Copied from Perforce
 Change: 184216
 ServerID: perforce.ravenbrook.com
2014-01-29 13:49:42 +00:00
Richard Brooksby
56d48bbd1d iterating over segments using the pool and segment rings, rather than scanning the tract table, which may be full of irrelevant tracts, especially when non-gc pools are large. see <https://info.ravenbrook.com/mail/2014/01/25/12-16-09/0/>.
Copied from Perforce
 Change: 184120
 ServerID: perforce.ravenbrook.com
2014-01-25 15:33:10 +00:00
Gareth Rees
ea9df0b2b7 Merge custom cet mainline into the master sources. this includes fixes for job003519 (clock values in text telemetry logs on windows have top 32 bits zero), job003536 (cet office can't replicate 100k snowmen in reasonable time), job003651 (stack overflows are not reliably handled).
Copied from Perforce
 Change: 183926
 ServerID: perforce.ravenbrook.com
2014-01-10 14:16:08 +00:00
Gareth Rees
1c4ff669ac Remove diag facility.
Copied from Perforce
 Change: 182553
 ServerID: perforce.ravenbrook.com
2013-06-05 18:35:40 +01:00
Richard Brooksby
3b37d681c2 Linking tags to mmprevol requests (e.g. request.epcode.12345) to their location on info.ravenbrook.com.
Copied from Perforce
 Change: 182526
 ServerID: perforce.ravenbrook.com
2013-06-05 00:57:04 +01:00
Richard Brooksby
5c6785b815 Catch-up merge from custom/cet/main to master.
Includes installable assertion handler, events in circular memory buffers, LARGEADDRESSAWARE, etc.

Copied from Perforce
 Change: 182176
 ServerID: perforce.ravenbrook.com
2013-05-24 19:42:46 +01:00
Richard Brooksby
c4d6a2de1f Merging spelling corrections contributed by bruce mitchener.
See <1c80ccb634>.

Copied from Perforce
 Change: 180956
 ServerID: perforce.ravenbrook.com
2013-02-18 15:46:39 +00:00
Richard Brooksby
85f3d6bbb4 Short-circuit the cases where we set the greyness or summary of a segment to the same as it was before in all cases, rather than just in a few restricted cases in amc.
This was the result of noticing a large number of SetSetGrey events that set the segment to the same greyness when scanning ambiguous references.

Copied from Perforce
 Change: 179567
 ServerID: perforce.ravenbrook.com
2012-09-19 20:04:41 +01:00
David Lovemore
1ece8c4ccb Remove whiteminalign handling code which was used to calculate a mask for scanning in tracescanareatagged. for now we use sizeof(word)-1, which will work for dylan and configura.
Copied from Perforce
 Change: 179393
 ServerID: perforce.ravenbrook.com
2012-09-10 15:17:38 +01:00
Richard Brooksby
5a604a2f51 Fixing bugs introduced by type puns passed through scanning methods, discovered by offsetting mps_ss_s from the beginning of scanstatestruct.
Adding a pseudo-target "find-puns" which, on FreeBSD mostly, prints useful warnings about strict aliasing rule violations.
Fixing more strict aliasing rule violations found by the above.

Copied from Perforce
 Change: 179358
 ServerID: perforce.ravenbrook.com
2012-09-07 23:48:14 +01:00
Richard Brooksby
d6b37e23c5 Correcting use of parent in trace.c. oops.
Copied from Perforce
 Change: 179348
 ServerID: perforce.ravenbrook.com
2012-09-07 21:25:00 +01:00
Richard Brooksby
e8d345149f Adding references to critical path design.
Fixing cast from external scan state structure to a PARENT, now that we're not punning the pointer any more.

Copied from Perforce
 Change: 179347
 ServerID: perforce.ravenbrook.com
2012-09-07 20:49:05 +01:00