Thread: [Sablevm-developer] _svmt_interned_string_struct unused
Brought to you by:
egagnon
From: David <db...@cs...> - 2004-03-28 01:01:08
|
Etienne, One of the bug reports concern the type _svmt_interned_string_struct that is unused. The String.intern() is implemented in Java. Is there any future or unimplemented use for _svmt_interned_string_struct: ------- struct _svmt_interned_string_struct { _svmt_interned_string *next; const char *value; /* this string will not be automatically feed and m= ust remain unchanged throughout the bootstrapping process. */ jstring string; /* reference to interned string */ }; --------- David --- David B=E9langer Graduate Student School of Computer Science McGill University Office: MC226 Web page: http://www.cs.mcgill.ca/~dbelan2/ Public key: http://www.cs.mcgill.ca/~dbelan2/public_key.txt |
From: Etienne G. <gag...@uq...> - 2004-03-28 18:12:14
|
Hi David, David B=E9langer wrote: > One of the bug reports concern the type _svmt_interned_string_struct > that is unused. The String.intern() is implemented in Java. >=20 > Is there any future or unimplemented use for > _svmt_interned_string_struct: Not that I know of. Early versions of SableVM needed it, until I simplif= ied the bootstrap process (thus the static initialization restrictions). You can safely remove this code. Etienne --=20 Etienne M. Gagnon, Ph.D. http://www.info.uqam.ca/~egagnon/ SableVM: http://www.sablevm.org/ SableCC: http://www.sablecc.org/ |
From: Grzegorz B. P. <ga...@de...> - 2004-03-28 20:37:42
|
W li=B6cie z nie, 28-03-2004, godz. 12:21, Etienne Gagnon pisze:=20 > Hi David, >=20 > David B=E9langer wrote: > > One of the bug reports concern the type _svmt_interned_string_struct > > that is unused. The String.intern() is implemented in Java. > >=20 > > Is there any future or unimplemented use for > > _svmt_interned_string_struct: >=20 > Not that I know of. Early versions of SableVM needed it, until I simpl= ified > the bootstrap process (thus the static initialization restrictions). ...speaking of which: I tried to remove comments for things like: //private static final long serialVersionUID =3D 3206093459760846163L; from ex. java.io.Serializable and apparently, when the code is compiled with the latest jikes SableVM bombs out in initialization.c when finds <clinit> method that contains initialization of this field. Q: Assuming for the moment that I don't care what is inside of <clinit> what method should I call here, from within svmf_special_initialization (_svmt_JNIEnv *env, _svmt_class_info *class) to execute this method ? Q: Do we have any flag that says that we're in bootstrap stage (I haven't found any), or should I add one (in env, I guess)? Q: Wouldn't prepare_code.c be good place to restrict what bytecodes can be prepared for execution at bootstrap stage? GBP --=20 Grzegorz B. Prokopski <ga...@de...> Debian GNU/Linux http://www.debian.org SableVM - LGPLed JVM http://www.sablevm.org Why SableVM ?!? http://devel.sablevm.org/wiki/WhySableVM |
From: Etienne G. <gag...@uq...> - 2004-03-29 03:00:26
|
Grzegorz B. Prokopski wrote: > from ex. java.io.Serializable and apparently, when the code is compiled > with the latest jikes SableVM bombs out in initialization.c when finds > <clinit> method that contains initialization of this field. I think I found the motivation for this change... (unless somebody has a better explanation; maybe someone should ask on jikes ML): This field being a constant, any reference to its value would be hardcoded in compiled code (instead of using GETSTATIC) as mandated by the specification, yet most probably, if another class refers to this constant, it is because it wants to check the "current" value against some value encoded in a serialized file... > Q: Assuming for the moment that I don't care what is inside of <clinit> > what method should I call here, from within > svmf_special_initialization (_svmt_JNIEnv *env, _svmt_class_info > *class) to execute this method ? If you really didn't care, you would call the usual _svmf_initialization(). > Q: Do we have any flag that says that we're in bootstrap stage > (I haven't found any), or should I add one (in env, I guess)? Not sure about this way to go about it. We should discuss this in person (emails would be too long). > Q: Wouldn't prepare_code.c be good place to restrict what bytecodes > can be prepared for execution at bootstrap stage? Yes, it would. Etienne -- Etienne M. Gagnon, Ph.D. http://www.info.uqam.ca/~egagnon/ SableVM: http://www.sablevm.org/ SableCC: http://www.sablecc.org/ |