1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-30 02:02:38 -07:00

Mps: now uses correct test for remembering / restoring

SegSummary.

Copied from Perforce
 Change: 64983
 ServerID: perforce.ravenbrook.com
This commit is contained in:
David Jones 2003-11-19 14:15:49 +00:00
parent 2181c4c807
commit dd74152e77
3 changed files with 13 additions and 1 deletions

View file

@ -6,6 +6,15 @@
*
* DESIGN
*
* Just a copy of finaltest.c with the following modifcations:
* maxtreeDEPTH is 2 rather than 12. This makes the test run and fail
* much more quickly.
*
* After trees have been created and finalized, call
* mps_arena_unsafe_expose_remember_protection / restore. If the bug
* is present then this sequence will fail.
*
*
* DEPENDENCIES
*
* This test uses the dylan object format, but the reliance on this

View file

@ -610,6 +610,8 @@ extern void SegClassMixInNoSplitMerge(SegClass class);
#define SEG_SUPERCLASS(className) \
((SegClass)SUPERCLASS(className))
#define ClassOfSeg(seg) ((seg)->class)
extern Size SegSize(Seg seg);
extern Addr (SegBase)(Seg seg);
extern Addr (SegLimit)(Seg seg);

View file

@ -1761,7 +1761,7 @@ void ArenaExposeRemember(Globals globals, int remember)
do {
base = SegBase(seg);
if((SegPool(seg)->class->attr & AttrSCAN) != 0) {
if(IsSubclassPoly(ClassOfSeg(seg), GCSegClassGet())) {
if(remember) {
RefSet summary;
@ -1805,6 +1805,7 @@ void ArenaRestoreProtection(Globals globals)
}
b = SegOfAddr(&seg, arena, block->the[i].base);
if(b && SegBase(seg) == block->the[i].base) {
AVER(IsSubclassPoly(ClassOfSeg(seg), GCSegClassGet()));
SegSetSummary(seg, block->the[i].summary);
} else {
/* Either seg has gone or moved, both of which are