diff options
| author | Richard Kistruck | 2007-03-22 14:02:14 +0000 |
|---|---|---|
| committer | Richard Kistruck | 2007-03-22 14:02:14 +0000 |
| commit | d46ebba46c141e9d55519d064c3661644dc85142 (patch) | |
| tree | 23fa7a63ab389ef515787ca059874f0a8b0f6377 /mps/code | |
| parent | 7ca4179235f1f358a596c621a914e495cc16f131 (diff) | |
| download | emacs-d46ebba46c141e9d55519d064c3661644dc85142.tar.gz emacs-d46ebba46c141e9d55519d064c3661644dc85142.zip | |
Mps br/unfixed-summary: good: amcsegcheck: nailboard onlyif segnailed;
AMCSegDescribe now splits Mobile vs. Stuck, clearer Map symbols, add key.
Copied from Perforce
Change: 161978
ServerID: perforce.ravenbrook.com
Diffstat (limited to 'mps/code')
| -rw-r--r-- | mps/code/poolamc.c | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/mps/code/poolamc.c b/mps/code/poolamc.c index 67cf3eff7f5..496e4876801 100644 --- a/mps/code/poolamc.c +++ b/mps/code/poolamc.c | |||
| @@ -106,6 +106,9 @@ static Bool amcSegCheck(amcSeg amcseg) | |||
| 106 | CHECKD(GCSeg, &amcseg->gcSegStruct); | 106 | CHECKD(GCSeg, &amcseg->gcSegStruct); |
| 107 | CHECKL(*amcseg->segTypeP == AMCPTypeNailboard | 107 | CHECKL(*amcseg->segTypeP == AMCPTypeNailboard |
| 108 | || *amcseg->segTypeP == AMCPTypeGen); | 108 | || *amcseg->segTypeP == AMCPTypeGen); |
| 109 | if (*amcseg->segTypeP == AMCPTypeNailboard) { | ||
| 110 | CHECKL(SegNailed(amcSeg2Seg(amcseg)) != TraceSetEMPTY); | ||
| 111 | } | ||
| 109 | CHECKL(BoolCheck(amcseg->new)); | 112 | CHECKL(BoolCheck(amcseg->new)); |
| 110 | return TRUE; | 113 | return TRUE; |
| 111 | } | 114 | } |
| @@ -172,10 +175,6 @@ static Res AMCSegDescribe(Seg seg, mps_lib_FILE *stream) | |||
| 172 | base = SegBase(seg); | 175 | base = SegBase(seg); |
| 173 | p = AddrAdd(base, pool->format->headerSize); | 176 | p = AddrAdd(base, pool->format->headerSize); |
| 174 | limit = SegLimit(seg); | 177 | limit = SegLimit(seg); |
| 175 | if (SegBuffer(seg) != NULL) | ||
| 176 | init = BufferGetInit(SegBuffer(seg)); | ||
| 177 | else | ||
| 178 | init = limit; | ||
| 179 | 178 | ||
| 180 | res = WriteF(stream, | 179 | res = WriteF(stream, |
| 181 | "AMC seg $P [$A,$A){\n", | 180 | "AMC seg $P [$A,$A){\n", |
| @@ -187,13 +186,22 @@ static Res AMCSegDescribe(Seg seg, mps_lib_FILE *stream) | |||
| 187 | res = WriteF(stream, " Boarded\n", NULL); | 186 | res = WriteF(stream, " Boarded\n", NULL); |
| 188 | /* @@@@ should have AMCNailboardDescribe() */ | 187 | /* @@@@ should have AMCNailboardDescribe() */ |
| 189 | } else { | 188 | } else { |
| 190 | res = WriteF(stream, " Mobile or Stuck\n", NULL); | 189 | if (SegNailed(seg) == TraceSetEMPTY) { |
| 190 | res = WriteF(stream, " Mobile\n", NULL); | ||
| 191 | } else { | ||
| 192 | res = WriteF(stream, " Stuck\n", NULL); | ||
| 193 | } | ||
| 191 | } | 194 | } |
| 192 | if (res != ResOK) return res; | 195 | if (res != ResOK) return res; |
| 193 | 196 | ||
| 194 | res = WriteF(stream, " Map\n", NULL); | 197 | res = WriteF(stream, " Map: *===:object bbbb:buffer\n", NULL); |
| 195 | if (res != ResOK) return res; | 198 | if (res != ResOK) return res; |
| 196 | 199 | ||
| 200 | if (SegBuffer(seg) != NULL) | ||
| 201 | init = BufferGetInit(SegBuffer(seg)); | ||
| 202 | else | ||
| 203 | init = limit; | ||
| 204 | |||
| 197 | for(i = base; i < limit; i = AddrAdd(i, row)) { | 205 | for(i = base; i < limit; i = AddrAdd(i, row)) { |
| 198 | Addr j; | 206 | Addr j; |
| 199 | char c; | 207 | char c; |
| @@ -207,7 +215,7 @@ static Res AMCSegDescribe(Seg seg, mps_lib_FILE *stream) | |||
| 207 | if (j >= limit) | 215 | if (j >= limit) |
| 208 | c = ' '; | 216 | c = ' '; |
| 209 | else if (j >= init) | 217 | else if (j >= init) |
| 210 | c = '.'; | 218 | c = 'b'; |
| 211 | else if (j == p) { | 219 | else if (j == p) { |
| 212 | c = '*'; | 220 | c = '*'; |
| 213 | p = (pool->format->skip)(p); | 221 | p = (pool->format->skip)(p); |