[BUG] Compiling a VM with 2.6 image segment changeset
Mark Guzdial
guzdial at cc.gatech.edu
Thu Sep 23 17:34:14 UTC 1999
I think that this is a bug, but I'm a newbie at VM building. Since I
figured out enough of MPW to compile the OSA plugin, I tried to follow
Andrew's directions for compiling the VM. All went well until I found that
"Metaclass" was unidentified in the below function from interp.c
int printNameOfClasscount(int classOop, int cnt) {
if (cnt <= 0) {
return print("bad class");
}
if ((sizeBitsOf(classOop)) == (((instSize(Metaclass)) + 1) * 4)) {
printNameOfClasscount(longAt(((((char *) classOop)) + 4) +
(5 << 2)), cnt - 1);
print(" class");
} else {
printStringOf(longAt(((((char *) classOop)) + 4) + (6 << 2)));
}
}
I couldn't find a #define or any other references to Metaclass in the source.
I found the Squeak source for this C function, and it was just changed in
the new 2.6 image segment code, see below:
printNameOfClass: classOop count: cnt
"Details: The count argument is used to avoid a possible infinite
recursion if classOop is a corrupted object."
cnt <= 0 ifTrue: [ ^ self print: 'bad class' ].
(self sizeBitsOf: classOop) = (Metaclass instSize +1*4) ifTrue: [
self printNameOfClass: (self fetchPointer: 5 "thisClass"
ofObject: classOop)
count: cnt - 1.
self print: ' class'.
] ifFalse: [
self printStringOf: (self fetchPointer: 6 "name" ofObject:
classOop).
].
Is there something I'm missing in order to be able to recompile the VM?
Thanks!
Mark
--------------------------
Mark Guzdial : Georgia Tech : College of Computing : Atlanta, GA 30332-0280
(404) 894-5618 : Fax (404) 894-0673 : guzdial at cc.gatech.edu
http://www.cc.gatech.edu/gvu/people/Faculty/Mark.Guzdial.html
More information about the Squeak-dev
mailing list
|