1. 21 Dec, 2001 1 commit
  2. 16 Dec, 2001 1 commit
    • For PR java/5088: · 68940f3f
      	* java/lang/natClassLoader.cc (_Jv_InitNewClassFields): New
      	function.
      	(_Jv_NewClass): Use it.
      	(defineClass0): Use it.
      	* prims.cc (_Jv_InitPrimClass): Adjust vtable here.
      	(_Jv_InitPrimClass): Use _Jv_InitNewClassFields.
      	(_Jv_NewArray): Don't abort; just throw exception.
      	Include InternalError.h.
      	* java/lang/Class.h (Class::Class): Declare, don't define.
      	(Class): Declare _Jv_InitNewClassFields as a friend.
      	(union _Jv_Self): Removed.
      
      From-SVN: r48081
      Tom Tromey committed
  3. 15 Dec, 2001 1 commit
    • java-tree.h (otable_methods, [...]): New field/global tree definitions. · 861ef928
      gcc/java:
      
      	* java-tree.h (otable_methods, otable_decl, otable_syms_decl,
      	otable_type, otable_ptr_type, method_symbol_type,
      	method_symbols_array_type, method_symbols_array_ptr_type): New
      	field/global tree definitions.
      	(flag_indirect_dispatch): New flag.
      	* decl.c (java_init_decl_processing): Initialize new otable and
      	otable_syms type nodes and decls. Add new field "index" to
      	method_type_node.
      	* class.c (build_method_symbols_entry): New function.
      	(make_method_value): Set "index" to to method's vtable index for
      	virtual methods when indirect-dispatch is not used.
      	(make_class_data): For indirect-dispatch, dont emit the dtable_decl,
      	and set vtable_method_count to -1. Set otable and otable_syms field
      	if indirect-dispatch is used and there was something to put in them.
      	(build_method_symbols_entry): New function.
      	(emit_offset_symbol_table): New function.
      	* expr.c (get_offset_table_index): New function.
      	(build_invokevirtual): Build array reference to otable at the index
      	returned by get_offset_table_index, and use the result as the vtable
      	offset.
      	(build_invokeinterface): Similar.
      	* jcf-parse.c (yyparse): If indirect-dispatch, call
      	emit_offset_symbol_table at the end of compilation, after all classes
      	have been generated.
      	* jvspec.c: Don't pass findirect-dispatch to jvgenmain.
      	* lang.c (flag_indirect_dispatch): Define.
      	(lang_f_options): Add indirect-dispatch flag.
      
      libjava:
      
      	* include/jvm.h (_Jv_VTable::idx_to_offset): New method.
      	* java/lang/natClassLoader.cc (_Jv_PrepareCompiledClass): Call
      	_Jv_MakeVTable and _Jv_LinkOffsetTable if needed.
      	* java/lang/Class.h (_Jv_Method): Add "index" field.
      	(_Jv_MethodSymbol): New struct type.
      	(_Jv_LinkOffsetTable, _Jv_LayoutVTableMethods, _Jv_SetVTableEntries,
      	_Jv_MakeVTable): Friends.
      	(otable, otable_syms): New Class fields.
      	* java/lang/natClass.cc (_Jv_LinkOffsetTable): New function.
      	(isVirtualMethod): New static function.
      	(_Jv_LayoutVTableMethods): New function.
      	(_Jv_SetVTableEntries): New function.
      	(_Jv_MakeVTable): New function.
      
      From-SVN: r48038
      Bryce McKinlay committed
  4. 05 Nov, 2001 1 commit
    • Class.h (Class): Made _Jv_BytecodeVerifier a friend. · a12fe13d
      	* java/lang/Class.h (Class): Made _Jv_BytecodeVerifier a friend.
      	* Makefile.in: Rebuilt.
      	* Makefile.am (libgcj_la_SOURCES): Added verify.cc.
      	* verify.cc: New file.
      	* include/java-interp.h (_Jv_count_arguments): Declare.
      	(_Jv_VerifyMethod): Likewise.
      	(class _Jv_InterpMethod): Made _Jv_BytecodeVerifier a friend.
      	(class _Jv_InterpException): Likewise.
      	* resolve.cc (_Jv_count_arguments): Renamed from count_arguments.
      	No longer static.  Updated callers.
      	* defineclass.cc (int_bits_to_float): Removed.
      	(long_bits_to_double): Likewise.
      	(prepare_pool_entry): Updated.
      	(handleCodeAttribute): Verify method (commented out for now).
      
      From-SVN: r46796
      Tom Tromey committed
  5. 31 Oct, 2001 1 commit
    • HACKING, [...]: Fix spelling errors. · 18e1f2bd
      	* HACKING, gnu/gcj/xlib/Pixmap.java, gnu/gcj/xlib/XException.java,
      	gnu/java/rmi/rmic/RMIC.java, java/awt/Window.java,
      	java/awt/AWTEvent.java, java/io/ByteArrayOutputStream.java,
      	java/io/CharConversionException.java,
      	java/io/PipedInputStream.java, java/io/PipedReader.java,
      	java/io/PrintWriter.java, java/io/WriteAbortedException.java,
      	java/io/natFileWin32.cc, java/lang/Class.h,
      	java/lang/natClassLoader.cc, java/lang/natObject.cc,
      	java/lang/Package.java, java/net/BindException.java,
      	java/net/ConnectException.java, java/net/ProtocolException.java,
      	java/net/SocketException.java,
      	java/net/UnknownServiceException.java,
      	java/security/cert/X509Certificate.java,
      	java/security/interfaces/DSAKey.java,
      	java/security/SecureRandom.java, java/security/SignedObject.java,
      	java/sql/DatabaseMetaData.java,
      	java/text/DecimalFormatSymbols.java,
      	java/util/jar/Attributes.java, java/util/jar/JarEntry.java,
      	java/util/jar/JarInputStream.java,
      	java/util/jar/JarOutputStream.java, java/util/Calendar.java,
      	java/util/Collections.java, java/util/GregorianCalendar.java,
      	java/util/HashMap.java, java/util/List.java,
      	java/util/Properties.java, java/util/Timer.java,
      	java/util/Vector.java, java/util/WeakHashMap.java,
      	javax/naming/NamingException.java,
      	testsuite/libjava.lang/Thread_Wait.java,
      	org/xml/sax/helpers/DefaultHandler.java,
      	org/xml/sax/HandlerBase.java, org/xml/sax/SAXParseException.java,
      	ChangeLog, acinclude.m4, aclocal.m4, posix-threads.cc: Fix
      	spelling errors.
      	* configure: Regenerate.
      
      From-SVN: r46665
      Joseph Myers committed
  6. 16 Oct, 2001 1 commit
  7. 01 Sep, 2001 1 commit
    • javaprims.h (_Jv_RegisterClassHook): New extern declaration. · dee45a7f
      	* gcj/javaprims.h (_Jv_RegisterClassHook):  New extern declaration.
      	(_Jv_RegisterClassHookDefault):  Likewise.
      	* java/lang/Class.h (_Jv_RegisterClassHookDefault):  Declare as friend.
      	* java/lang/natClassLoader.cc (_Jv_RegisterClassHook):  New variable.
      	(_Jv_RegisterClassHookDefault):  New.function.
      	(_Jv_RegisterClasses):  Call _Jv_RegisterClassHook.
      
      From-SVN: r45344
      Per Bothner committed
  8. 24 Aug, 2001 1 commit
    • Field.java (toString): Use Method.appendClassName. · 224b7b7b
      	* java/lang/reflect/Field.java (toString): Use
      	Method.appendClassName.
      	* java/lang/reflect/Constructor.java (toString): Use
      	Method.appendClassName.
      	* java/lang/reflect/Method.java: Reindented.
      	(appendClassName): New method.
      	(toString): Use it.
      	* defineclass.cc (handleMethod ): Initialize `throws' field of
      	method.
      	(read_one_method_attribute): Handle Exceptions attribute.
      	* java/lang/reflect/natMethod.cc (ClassClass): Removed.
      	(ObjectClass): Removed.
      	(getType): Compute `exception_types'.
      	* java/lang/Class.h (struct _Jv_Method): Added `throws' field.
      
      From-SVN: r45153
      Tom Tromey committed
  9. 05 Jul, 2001 1 commit
  10. 24 May, 2001 1 commit
    • [multiple changes] · 3610e0d5
      2001-05-23  Tom Tromey  <tromey@redhat.com>
      
      	* posix-threads.cc (_Jv_self_cache): Renamed from self_cache.
      	* gcj/Makefile.in: Rebuilt.
      	* gcj/Makefile.am (gcj_HEADERS): Added libgcj-config.h.
      	* gcj/javaprims.h: Include gcj/libgcj-config.h.
      	* gcj/libgcj-config.h.in: New file.
      	* libgcj.spec.in (*jc1): Added @HASH_SYNC_SPEC@.
      	* configure: Rebuilt.
      	* configure.in: Enable hash synchronization by default on some
      	platforms.
      	(HASH_SYNC_SPEC): New subst.
      	(AC_CONFIG_HEADER): Added gcj/libgcj-config.h.
      	Correctly use `test -z' instead of `test -n' in a couple places.
      	(JV_HASH_SYNCHRONIZATION): Use AC_DEFINE; don't add to
      	LIBGCJ_CXXFLAGS.
      	* configure.host (enable_java_net_default): Initialize.
      	(enable_hash_synchronization_default): New variable.
      
      2001-05-23  Hans Boehm <Hans_Boehm@hp.com>
      
      	* boehm.cc (_Jv_MarkObj): Don't mark sync_info when hash
      	synchronization in use.
      	(_Jv_MarkArray): Likewise.
      	(_Jv_AllocBytes): Don't check return result.
      	(handle_out_of_memory): New function.
      	(_Jv_InitGC): Set GC_oom_fn.
      	(trace_one_vtable): New global.
      	(_Jv_AllocTraceOne): New function.
      	* configure.in: Added --enable-hash-synchronization.
      	* defineclass.cc, prims.cc, resolve.cc, java/lang/natString.cc,
      	java/net/natInetAddress.cc: Remove _Jv_AllocBytesChecked.
      	* nogc.cc (_Jv_AllocObj): Throw out-of-memory.
      	(_Jv_AllocArray): Likewise.
      	(_Jv_AllocBytes): Likewise.
      	(_Jv_AllocPtrFreeObject): New function.
      	(_Jv_AllocTraceOne): Likewise.
      	* posix-threads.cc (_Jv_ThreadRegister): Handle slow
      	pthread_self().
      	(self_cache): New global.
      	(_Jv_ThreadSelf_out_of_line): New function.
      	* prims.cc (_Jv_AllocBytesChecked): Removed.
      	(_Jv_ThrowNoMemory): New function.
      	(_Jv_AllocObject): Don't check for null return from allocator.
      	(_Jv_NewObjectArray): Likewise.
      	(_Jv_AllocPtrFreeObject): New function.
      	(_Jv_NewPrimArray): Allocate pointer-free object if possible.
      	* include/javaprims.h (_Jv_AllocPtrFreeObject): Declare.
      	(_Jv_MonitorEnter, _Jv_MonitorExit): Don't return value.
      	* include/boehm-gc.h (_Jv_AllocObj): Define.
      	(_Jv_AllocPtrFreeObj): Define.
      	* include/jvm.h (_Jv_AllocPtrFreeObj): Declare.
      	(_Jv_ThrowNoMemory): Declare.
      	(_Jv_AllocTraceOne): Declare.
      	(_Jv_AllocBytesChecked): Removed.
      	* include/posix-threads.h (_Jv_MutexInit, _Jv_MutexLock,
      	_Jv_MutexUnlock): Handle LOCK_DEBUG.
      	(_Jv_ThreadSelf): Handle case where system pthread_self() is
      	slow.
      	* java/lang/Class.h (Class): Declare _Jv_AllocPtrFreeObj as
      	friend.
      	* java/lang/Object.h (sync_info): Conditional upon presence of
      	hash synchronization.
      	* java/lang/natObject.cc: Much new code to handle thin locks and
      	hash synchronization.
      	* java/lang/natString.cc (_Jv_AllocString): Allocate pointer-free
      	object if possible.
      
      From-SVN: r42519
      Tom Tromey committed
  11. 06 May, 2001 1 commit
  12. 25 Apr, 2001 1 commit
    • decl.c (init_decl_processing): Add new class "protectionDomain" field. · 28f7d9d0
      gcc/java:
      
      2001-04-25  Bryce McKinlay  <bryce@waitaki.otago.ac.nz>
      
      	* decl.c (init_decl_processing): Add new class "protectionDomain"
      	field.
      	* class.c (make_class_data): Set initial value for "protectionDomain".
      
      libjava:
      
      2001-04-25  Bryce McKinlay  <bryce@albatross.co.nz>
      
      	java.security merge and ClassLoader compliance fixes.
      
      	* java/lang/Class.h (Class): Include ProtectionDomain.h.
      	New protectionDomain field.
      	(forName): Add initialize parameter. Fixes declaration to comply with
      	JDK spec.
      	* java/lang/natClass.cc (forName): Correct declaration of the three-arg
      	variant. Honour	"initialize" flag.
      	(getProtectionDomain0): New method.
      	* java/lang/Class.java: Fix forName() declaration.
      	(getPackage): New method based on Classpath implementation.
      	(getProtectionDomain0): New native method decl.
      	(getProtectionDomain): New method.
      	* java/lang/ClassLoader.java (getParent): Now final.
      	(definedPackages): New field.
      	(getPackage): New.
      	(defineClass): New variant with protectionDomain argument.
      	(definePackage): New.
      	(getPackages): New.
      	(findSystemClass): Now final.
      	(getSystemResourceAsStream): Remove redundant "final" modifier.
      	(getSystemResource): Remove redundant "final" modifier.
      	(getResources): Now final.
      	(protectionDomainPermission): New static field.
      	(unknownProtectionDomain): Ditto.
      	(defaultProtectionDomain): Ditto.
      	(getSystemClassLoader): Now non-native.
      	* java/util/ResourceBundle.java (tryGetSomeBundle): Use the correct
      	arguments for Class.forName().
      	* java/lang/Package.java: New file.
      	* gnu/gcj/runtime/VMClassLoader.java (getVMClassLoader): Removed.
      	(instance): Static initialize singleton.
      	(findClass): Override this, not findSystemClass.
      	* java/lang/natClassLoader.cc (defineClass0): Set class's
      	protectionDomain field as specified.
      	(getSystemClassLoader): Removed.
      	(findClass): Renamed from findSystemClass. Call the interpreter via
      	URLClassLoader.findClass if loading class via dlopen fails.
      
      	* java/security/*.java: java.security import/merge with Classpath.
      	* java/security/acl/*.java: Likewise.
      	* java/security/interfaces/*.java: Likewise.
      	* java/security/spec/*.java: Likewise.
      	* java/net/NetPermission.java: Likewise.
      	* java/net/SocketPermission.java: Likewise.
      	* gnu/java/security/provider/DefaultPolicy.java: Likewise.
      
      	* Makefile.am: Add new classes.
      	* Makefile.in: Rebuilt.
      	* gcj/javaprims.h: CNI namespace rebuild.
      
      From-SVN: r41543
      Bryce McKinlay committed
  13. 17 Jan, 2001 2 commits
  14. 15 Jan, 2001 1 commit
    • All files with updated copyright. · 2feccc20
      2001-01-07  Alexandre Petit-Bianco  <apbianco@cygnus.com>
      
      	All files with updated copyright.
      	* prims.cc (class _Jv_PrimClass): Removed.
      	(init_prim_class): New function.
      	(DECLARE_PRIM_TYPE): Rewritten. `java::lang::Class' replaces
      	`_Jv_PrimClass' in primitive type declarations. Assign to the
      	value returned by `init_prim_class.'
      	* gcj/array.h: `java::lang::Class' replaces `_Jv_PrimClass' in
      	primitive type declarations.
      	(JvPrimClass): Cast to `jclass' removed.
      	* java/lang/Class.h (Class): New constructor.
      	(Class): New copy constructor.
      	(initializePrim): New prototype.
      	(_Jv_PrimClass): Field removed.
      	* java/lang/Object.h (struct _JvObjectPrefix): New virtuals
      	nacd_1 and nacd_2 (for compatibility with the new C++ ABI.)
      	(class java::lang::Object): `finalize' moved up front.
      	* java/lang/natClass.cc
      	(isAssignableFrom): Turned outline.
      	(isInstance): Likewise.
      	(isInterface): Likewise, fixed indentation.
      	(initializePrim): New function.
      
      (New C++ ABI compatibility patch:
       http://sources.redhat.com/ml/java-patches/2001-q1/msg00065.html)
      
      From-SVN: r39032
      Alexandre Petit-Bianco committed
  15. 08 Jan, 2001 1 commit
    • In gcc/java: · 5bb11b2e
      	* class.c (make_class_data): Push initial value for "arrayclass".
      	* decl.c (init_decl_processing): Add new class field "arrayclass".
      
      In libjava:
      	* java/lang/Class.h (_Jv_InitClass): Use __builtin_expect.
      	(_Jv_NewArrayClass): Renamed from _Jv_FindArrayClass.
      	(_Jv_GetArrayClass): New inline function.
      	(arrayclass): New field.
      	* prims.cc (_Jv_NewObjectArray): Use _Jv_GetArrayClass. Don't use
      	_Jv_GetArrayElementFromElementType.
      	(_Jv_NewPrimArray): Ditto.
      	(_Jv_PrimClass constructor): Initialize "depth", "ancestors", and
      	"idt" for completeness. Initialze "arrayclass" using _Jv_NewArrayClass.
      	Set Modifier::ABSTRACT.
      	* java/lang/natClassLoader.cc (_Jv_NewClass): Initialize "arrayclass".
      	(_Jv_NewArrayClass): Renamed from _Jv_FindArrayClass. Now void.
      	Now synchronized. Array classes are now referenced from
      	elementClass->arrayclass. Don't use _Jv_FindClassInCache.
      	Set array classes' accessibility flags correctly. Optimize so that
      	all array classes share the same IDT.
      	* java/lang/reflect/natArray.cc (newInstance): Use _Jv_GetArrayClass.
      	* java/lang/reflect/natMethod.cc (_Jv_GetTypesFromSignature): Ditto.
      	* java/lang/natClass.cc (_getFields): Increment offset. Prevent fields
      	in superclasses from overwriting classes own fields.
      	(_Jv_IsAssignableFrom): Check for NULL source idt instead of calling
      	Modifier::isAbstract().
      	(null_idt): New static field.
      	(_Jv_PrepareConstantTimeTables): Optimize case where class implements
      	no interfaces.
      	(_Jv_IndexOf): Made inline.
      	* boehm.cc (_Jv_MarkObj): Mark "arrayclass" field.
      
      From-SVN: r38808
      Bryce McKinlay committed
  16. 26 Nov, 2000 1 commit
    • prims.cc (_Jv_NewObjectArray): Undo placement change. · 31280fb7
      2000-11-25  Anthony Green  <green@redhat.com>
      
      	* prims.cc (_Jv_NewObjectArray): Undo placement change.
      	(_Jv_NewPrimArray): Likewise.
      	* gcj/array.h (__JArray): Undo const change.  Removed constructor.
      	(class JArray): Removed constructor.
      
      	* java/lang/Thread.java (context_class_loader): New private data.
      	(getContextClassLoader): New method.
      	(setContextClassLoader): New method.
      	(Thread): Initialize context_class_loader.
      
      	* java/net/URLClassLoader.java: Import java.util.Enumeration.
      	(getResource): Rename to findResource.
      	(findResource): New method.  Used to be getResource.
      	(getResourceAsStream): Deleted.
      	(jarFileize): Extracted logic from URLClassLoader constructor into
      	this new private method.
      	(addURL): New protected method.
      	(URLClassLoader): Call jarFileize.  Use addElement instead of
      	insertElementAt.
      	(findResources): New method.
      
      	* java/lang/ClassLoader.java: Import java.util.Enumeration.
      	(getResource): Implement correct logic.
      	(findResource): New method.
      	(getResources): New method.
      	(findClass): Create a ClassNotFoundException with the name of the
      	class rather than nothing at all.
      	(defineClass) Only throw ClassFormatError.
      
      	* java/lang/Class.java (forName): New method.
      	* java/lang/Class.h (forName): New method.
      	* java/lang/natClass.cc (forName): New method.
      
      From-SVN: r37751
      Anthony Green committed
  17. 06 Oct, 2000 1 commit
    • natField.cc (BooleanClass): Don't define. · 1d336a09
      	* java/lang/reflect/natField.cc (BooleanClass): Don't define.
      	* java/lang/reflect/natArray.cc (BooleanClass): Don't define.
      	* java/lang/Class.h (Object): Added `class$' field.
      	* java/lang/Object.h (Object): Added `class$' field.
      	* defineclass.cc (ClassClass): Use `class$' form.
      	(ClassObject): Likewise.
      	* resolve.cc (ClassObject): Use `class$' form.
      	(ObjectClass): Likewise.
      	* interpret.cc (ClassError): Removed.
      	* java/net/natPlainDatagramSocketImpl.cc (BooleanClass): Use
      	`class$' form.
      	(IntegerClass): Likewise.
      	* java/net/natPlainSocketImpl.cc (BooleanClass): Use `class$'
      	form.
      	* java/lang/natClassLoader.cc (CloneableClass): Use `class$' form.
      	(ObjectClass, ClassClass, VMClassLoaderClass, ClassLoaderClass,
      	SerializableClass): Likewise.
      	Include Serializable.h, Cloneable.h.
      	* java/lang/natSystem.cc (SystemClass): Removed.
      	(init_properties): Use `class$' form.
      	* java/lang/natObject.cc (CloneableClass): Removed.
      	(clone): Use `class$' form.
      	* java/lang/natClass.cc (CloneableClass): Use `class$' form.
      	(ObjectClass, ErrorClass, ClassClass, MethodClass, FieldClass,
      	ConstructorClass): Likewise.
      	* java/lang/reflect/natMethod.cc (ObjectClass): Use `class$' form.
      	(ClassClass, VoidClass, ByteClass, ShortClass, CharacterClass,
      	IntegerClass, LongClass, FloatClass, DoubleClass): Likewise.
      	* java/io/natObjectInputStream.cc (ObjectClass): Use `class$'
      	form.
      	(ClassClass): Likewise.
      	* include/jvm.h (StringClass): Use `class$' form.
      	* prims.cc (ObjectClass): Removed.
      	(_Jv_RunMain): Use `class$' form.
      	(_Jv_AllocObject): Likewise.
      	* jni.cc (ClassClass): Use `class$' form.
      	(ThrowableClass): Likewise.
      	(ObjectClass): Likewise.
      	(MethodClass): Likewise.
      	(ThreadGroupClass): Likewise.
      	(NativeThreadClass): Likewise.
      	* boehm.cc (ObjectClass): Removed.
      	(ClassClass): Removed.
      	(_Jv_MarkObj): Use `class$' form.
      	* gcj/field.h (JvFieldIsRef): Use `class$' form.
      	Include RawData.h.
      
      From-SVN: r36740
      Tom Tromey committed
  18. 30 Sep, 2000 1 commit
    • Implement bitmap descriptor based marking for Boehm GC. · bf3b8e42
      2000-09-30  Hans Boehm  <boehm@acm.org>
      	    Bryce McKinlay  <bryce@albatross.co.nz>
      
      	Implement bitmap descriptor based marking for Boehm GC.
      
      	* configure.in: Define JC1GCSPEC. Set it if boehm-gc is used.
      	* configure: Rebuilt.
      	* libgcj.spec.in: Pass JC1GCSPEC to jc1.
      	* include/jvm.h (struct _Jv_VTable): New field `gc_descr'. New inline
      	method get_finalizer().
      	(struct _Jv_ArrayVTable): Ditto. Declare method array with
      	NUM_OBJECT_METHODS elements instead of NUM_OBJECT_METHODS + 1.
      	(_Jv_AllocObj): Add new jclass parameter.
      	(_Jv_AllocArray): Ditto.
      	(_Jv_BuildGCDescr): New prototype.
      	* prims.cc (_Jv_AllocObject): Rename parameter `c' to `klass'. Pass
      	`klass' to _Jv_AllocObj. Don't set the new object's vtable. Use
      	get_finalizer() instead of direct finalizer vtable offset.
      	(_Jv_NewObjectArray): Rename parameter `clas' to `klass'. Pass
      	`klass' to _Jv_AllocArray. Don't set the new array's vtable.
      	(_Jv_NewPrimArray): Call _Jv_FindArrayClass before _Jv_AllocObj.
      	Pass `klass' to _Jv_AllocObj. Don't set the new array's vtable.
      	* resolve.cc (METHOD_NOT_THERE, METHOD_INACCESSIBLE): New #defines.
      	(_Jv_ResolvePoolEntry): Use METHOD_NOT_THERE and METHOD_INACCESSIBLE.
      	(_Jv_DetermineVTableIndex): Ditto.
      	(_Jv_PrepareClass): Ditto. Remove offset-by-one adjustments from vtable
      	calculations to account for new gc_descr field.
      	* boehm.cc: #include gc_gcj.h.
      	(obj_kind_x, obj_free_list): `#if 0'-ed away.
      	(_Jv_MarkObj): Check that vtable doesn't point to a cleared object.
      	New commentary from HB. Mark the classes vtable.
      	(_Jv_MarkArray): Check that vtable doesn't point to a cleared object.
      	(GC_DEFAULT_DESCR): New #define.
      	(_Jv_BuildGCDescr): New function. Use GC_DEFAULT_DESCR, for now.
      	(_Jv_AllocObj): New parameter `klass'. Use GC_GCJ_MALLOC ().
      	(_Jv_AllocArray): New parameter `klass'. Allocate with GC_MALLOC and
      	scan conservativly if size is less than min_heap_addr. Set vtable
      	pointer of new object before returning.
      	(_Jv_AllocBytes): Use GC_MALLOC_ATOMIC, not GC_GENERIC_MALLOC.
      	(_Jv_InitGC): Call GC_init_gcj_malloc(). Don't set up marking and
      	allocation for obj_kind_x.
      	* nogc.cc (_Jv_BuildGCDescr): New function. Return 0.
      	(_Jv_AllocObj): Set vtable on returned object.
      	(_Jv_AllocArray): Ditto.
      	* java/lang/Class.h (_Jv_NewObjectArray): No longer a friend.
      	(_Jv_NewPrimArray): Ditto.
      	(_Jv_AllocObj): Declare as a friend.
      	(_Jv_AllocArray): Ditto.
      	* java/lang/natClassLoader.cc (_Jv_FindArrayClass): Copy gc_descr
      	from &ObjectClass into new array class. Remove offset-by-one
      	adjustments from `method' size calculations to account for gc_descr
      	field.
      
      Co-Authored-By: Bryce McKinlay <bryce@albatross.co.nz>
      
      From-SVN: r36679
      Hans Boehm committed
  19. 15 Jun, 2000 1 commit
    • 2000-06-15 Bryce McKinlay <bryce@albatross.co.nz> · 1bf89727
      	Fix for PR java.lang/258:
      	* prims.cc (_Jv_PrimClass): Set state of primitive class to
      	JV_STATE_DONE, to prevent accidental initialization.
      	* java/lang/natClass.cc (_Jv_IsAssignableFrom): Call
      	_Jv_InterfaceAssignableFrom if target is an interface and source is
      	an interface or an abstract class. Remove redundant initializeClass
      	calls. Remove duplicate if_idt test.
      	(_Jv_InterfaceAssignableFrom): New function.
      	* java/lang/Class.h (_Jv_InterfaceAssignableFrom): Prototype.
      
      From-SVN: r34563
      Bryce McKinlay committed
  20. 31 May, 2000 1 commit
    • prims.cc (DECLARE_PRIM_TYPE): Define a vtable as well. · c74e2214
      	* prims.cc (DECLARE_PRIM_TYPE): Define a vtable as well.
      	(_Jv_PrimClass): Set `methods' by calling _Jv_FindArrayClass.
      	* include/jvm.h (struct _Jv_ArrayVTable): Declare.
      	(NUM_OBJECT_METHODS): New define.
      	* java/lang/natClassLoader.cc (_Jv_FindArrayClass): Added
      	`array_vtable' parameter.  Added assertion.
      	* java/lang/Class.h (_Jv_FindArrayClass): Added `array_vtable'
      	parameter.
      
      From-SVN: r34312
      Tom Tromey committed
  21. 20 May, 2000 1 commit
  22. 19 May, 2000 1 commit
  23. 05 May, 2000 1 commit
    • natClass.cc (isInstance): Use __builtin_expect. · 9d4c2148
      2000-05-05  Bryce McKinlay  <bryce@albatross.co.nz>
      
      	* java/lang/natClass.cc (isInstance): Use __builtin_expect.
      	(_Jv_IsAssignableFrom): Ditto.
      	(_Jv_IsInstanceOf): Ditto.
      	(_Jv_CheckCast): Ditto.
      	(_Jv_CheckArrayStore): Ditto.
      	* java/lang/Class.h (_Jv_InitClass): Ditto.
      	* java/lang/natObject.cc (_Jv_MonitorEnter): __builtin_expect `false',
      	not `0'.
      	(notify): Ditto.
      	(notifyAll): Ditto.
      	(wait): Ditto.
      	(_Jv_MonitorExit): Ditto.
      	* boehm.cc (_Jv_MarkObj): Ditto.
      	(_Jv_MarkObj): Ditto.
      	(_Jv_MarkArray): Ditto.
      	* prims.cc (_Jv_AllocObject): Ditto.
      	(_Jv_NewObjectArray): Ditto.
      	(_Jv_NewPrimArray): Ditto.
      	(_Jv_Malloc): Ditto.
      	(_Jv_Realloc): Ditto.
      	(_Jv_MallocUnchecked): Ditto.
      	(_Jv_divI): Ditto.
      	(_Jv_remI): Ditto.
      	(_Jv_divJ): Ditto.
      	(_Jv_remJ): Ditto.
      
      From-SVN: r33698
      Bryce McKinlay committed
  24. 20 Apr, 2000 1 commit
  25. 07 Mar, 2000 2 commits
    • All files: Updated copyright information. · 2ba5f774
      	* All files: Updated copyright information.
      	* COPYING: New file.
      	* COPYING.LIB: Removed.
      	* LIBGCJ_LICENSE: We now use GPL + special exception.
      
      From-SVN: r32387
      Tom Tromey committed
    • resolve.cc (_Jv_SearchMethodInClass): New function. · ddf0fc6c
      2000-03-07  Bryce McKinlay  <bryce@albatross.co.nz>
      
              * resolve.cc (_Jv_SearchMethodInClass): New function.
              (_Jv_ResolvePoolEntry): Search superinterfaces for interface
              methods.
              * java/lang/Class.h (_Jv_SearchMethodInClass): New prototype.
      
      2000-03-07  Bryce McKinlay  <bryce@albatross.co.nz>
      
              * java/lang/Class.h (union _Jv_IDispatchTable): New declaration.
              (struct _Jv_ifaces): New declaration.
              JV_CLASS: New macro definition.
              (getComponentType): Relocate below isArray() for inlining.
              (getModifiers): Declare `inline'.
              (getSuperclass): Ditto.
              (isArray): Ditto.
              (isPrimitive): Ditto.
              (_Jv_IsAssignableFrom): New prototype.
              (_Jv_LookupInterfaceMethodIdx): New prototype. Predeclare with "C"
              linkage.
              (_Jv_InitClass): Move from natClass.cc. Declare `inline'.
              Check for JV_STATE_DONE before invoking initializeClass().
              (_Jv_PrepareConstantTimeTables): New prototype.
              (_Jv_GetInterfaces): Ditto.
              (_Jv_GenerateITable): Ditto.
              (_Jv_GetMethodString): Ditto.
              (_Jv_AppendPartialITable): Ditto.
              (_Jv_FindIIndex): Ditto.
              depth, ancestors, idt: New class fields.
      
              * java/lang/natClass.cc (isAssignableFrom): Move functionality to
              inline function `_Jv_IsAssignableFrom'. Use that function.
              (isInstance): Declare `inline'.
              (initializeClass): Get lock on class before checking `state'. Unlock
              before calling resolveClass0. Call _Jv_PrepareConstantTimeTables
      	with the lock held.
              (_Jv_LookupInterfaceMethod): Use _Jv_GetMessageString.
              (_Jv_IsAssignableFrom): New inline function. Test assignability
      	using class->depth and ancestor table.
              (_Jv_IsInstanceOf): Use _Jv_IsAssignableFrom.
              (_Jv_CheckCast): Move from prims.cc. Use JV_CLASS and
              _Jv_IsAssignableFrom.
              (_Jv_CheckArrayStore): Ditto.
              (_Jv_LookupInterfaceMethodIdx): New function.
              INITIAL_IOFFSETS_LEN, INITIAL_IFACES_LEN: New #defines.
              (_Jv_PrepareConstantTimeTables): New function.
              (_Jv_IndexOf): Ditto.
              (_Jv_GetInterfaces): Ditto.
              (_Jv_GenerateITable): Ditto.
              (_Jv_GetMethodString): Ditto.
              (_Jv_AppendPartialITable): Ditto.
              iindex_mutex, iindex_mutex_initialized: New static fields.
              (_Jv_FindIIndex): New function.
      
              * java/lang/natClassLoader.cc (_Jv_NewClass): Set new jclass fields.
      
              * prims.cc (_Jv_CheckCast): Moved to natClass.cc.
              (_Jv_CheckArrayStore): Ditto.
              (JvNewCharArray, JvNewBooleanArray, JvNewByteArray, JvNewShortArray,
              JvNewIntArray, JvNewLongArray, JvNewFloatArray, JvNewDoubleArray):
              Moved to gcj/array.h.
              (_Jv_Realloc): New function.
      
              * gcj/cni.h: Move _Jv_PrimClass definitions to gcj/array.h.
      
              * gcj/array.h: _Jv_PrimClass definitions moved from gcj/cni.h.
              (JvNewCharArray, JvNewBooleanArray, JvNewByteArray,
              JvNewShortArray, JvNewIntArray, JvNewLongArray, JvNewFloatArray,
              JvNewDoubleArray): Implementations moved from prims.cc and
              declared `inline'.
      
              * gcj/javaprims.h (_Jv_Realloc): Prototype.
      
              * include/jvm.h (_Jv_LookupInterfaceMethodIdx): Prototype.
      
      From-SVN: r32382
      Bryce McKinlay committed
  26. 02 Mar, 2000 1 commit
    • java-interp.h: Don't include MethodInvocation.h. · b099f07d
      	* include/java-interp.h: Don't include MethodInvocation.h.
      	(class _Jv_InterpMethod): Don't make MethodInvocation a friend.
      	* Makefile.in: Rebuilt.
      	* Makefile.am (gnu/gcj/runtime/MethodInvocation.h): Removed.
      	(ordinary_java_source_files): Don't mention
      	MethodInvocation.java.
      	* gnu/gcj/runtime/MethodInvocation.java: Removed.
      	* interpret.cc (MethodInvocation::continue1): Removed.
      	(run): Handle exceptions here.
      	* java/lang/ClassLoader.java (defineClass1, defineClass2):
      	Removed.
      	* java/lang/natClassLoader.cc (defineClass0): Catch exceptions
      	here.
      	(defineClass2): Removed.
      
      	* java/lang/reflect/Method.java (hack_trampoline, hack_call):
      	Removed.
      	* java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Catch
      	exceptions here.
      	(hack_call): Removed.
      
      	* java/lang/Class.h (Class): Removed hackRunInitializers,
      	hackTrampoline.
      	* java/lang/natClass.cc (hackRunInitializers): Removed.
      	(initializeClass): Catch exceptions here.
      	Include ExceptionInInitializerError.h.
      	* java/lang/Class.java (hackTrampoline, hackRunInitializers):
      	Removed.
      
      	* java/lang/Object.h (Object): Don't mention hack12_6.
      	* java/lang/natObject.cc (_Jv_FinalizeObject): Catch exceptions
      	here.
      	* java/lang/Object.java (hack12_6): Removed.
      
      	* java/lang/natThread.cc (run_): Renamed.  Catch exceptions here.
      	(start): Use run_, not run__.
      	* java/lang/Thread.java (run_): Renamed from run__; old run_
      	removed.
      
      	* jni.cc (_Jv_JNI_FindClass): Handle exceptions.
      	(_Jv_JNI_EnsureLocalCapacity): Likewise.
      	(_Jv_JNI_DefineClass): Likewise.
      	(_Jv_JNI_ThrowNew): Likewise.
      	(_Jv_JNI_AllocObject): Likewise.
      	(_Jv_JNI_GetAnyMethodID): Likewise.
      	(_Jv_JNI_CallAnyMethodV): Likewise.
      	(_Jv_JNI_CallAnyMethodA): Likewise.
      	(_Jv_JNI_CallAnyVoidMethodV): Likewise.
      	(_Jv_JNI_CallAnyVoidMethodA): Likewise.
      	(_Jv_JNI_GetAnyFieldID): Likewise.
      	(_Jv_JNI_NewString): Likewise.
      	(_Jv_JNI_NewStringUTF): Likewise.
      	(_Jv_JNI_GetStringUTFChars): Likewise.
      	(_Jv_JNI_NewObjectArray): Likewise.
      	(_Jv_JNI_NewPrimitiveArray): Likewise.
      	(_Jv_JNI_GetPrimitiveArrayRegion): Likewise.
      	(_Jv_JNI_GetStringRegion): Likewise.
      	(_Jv_JNI_GetStringUTFRegion): Likewise.
      	(_Jv_JNI_SetPrimitiveArrayRegion): Likewise.
      	(_Jv_JNI_MonitorEnter): Likewise.
      	(_Jv_JNI_MonitorExit): Likewise.
      	(_Jv_JNI_ToReflectedField): Likewise.
      	(_Jv_JNI_ToReflectedMethod): Likewise.
      	(_Jv_JNI_RegisterNatives): Likewise.
      	(_Jv_JNI_AttachCurrentThread): Likewise.
      	(_Jv_JNI_DestroyJavaVM): Likewise.
      
      From-SVN: r32294
      Tom Tromey committed
  27. 26 Jan, 2000 2 commits
    • method.h (JvNumMethods): Moved from Class.h. · 355dff4c
      	* gcj/method.h (JvNumMethods): Moved from Class.h.
      	(JvGetFirstMethod): Likewise.
      	* java/lang/Class.h (Object): Updated decl of
      	_Jv_JNI_ToReflectedField.
      	(Object): Added _Jv_JNI_ToReflectedMethod as a friend.
      	* Makefile.in: Rebuilt.
      	* Makefile.am (java/lang/reflect/Field.h): Added `jboolean'
      	argument of _Jv_JNI_ToReflectedField.
      	(java/lang/reflect/Constructor.h): Added _Jv_JNI_ToReflectedMethod
      	as a friend.
      	(java/lang/reflect/Method.h): Likewise.
      	* include/jni.h (class _Jv_JNIEnv): Added `klass' member.  Use
      	__GCJ_JNI_IMPL__.
      	(jweak): New typedef.
      	(struct JNINativeInterface): Correctly declare remaining entries.
      	* jni.cc: Include Class.h, ClassLoader.h.
      	(_Jv_JNI_FindClass): New function.
      	(_Jv_JNI_DefineClass): New function.
      	(_Jv_JNI_conversion_call): New function.
      	(_Jv_JNI_FindClass): Use current class loader to find class.
      	(_Jv_JNI_ExceptionCheck): New function.
      	(_Jv_JNI_FromReflectedField): Now static.
      	(MethodClass): New define.
      	(_Jv_JNI_FromReflectedMethod): New function.
      	(_Jv_JNI_ToReflectedMethod): Likewise.
      	Include Method.h.
      	(_Jv_JNI_IsAssignableFrom): Renamed.
      	(_Jv_JNI_GetStringRegion): New function.
      	Include StringIndexOutOfBoundsException.h.
      	(_Jv_JNI_GetStringUTFRegion): New function.
      	(_Jv_JNIFunctions): Updated for new functions.
      	(_Jv_JNI_GetPrimitiveArrayCritical): New function
      	(_Jv_JNI_ReleasePrimitiveArrayCritical): Likewise.
      	(_Jv_JNI_GetStringCritical): New function.
      	(_Jv_JNI_ReleaseStringCritical): Likewise.
      	(get_throwable): Removed.
      	(GCJ_JV_JNIENV_FRIEND): Removed.
      	(__GCJ_JNI_IMPL__): Define.
      	Include method.h.
      
      From-SVN: r31638
      Tom Tromey committed
    • field.h (struct _Jv_Field): Use "jshort" as type for nameIndex. · 0507a9b1
      	* gcj/field.h (struct _Jv_Field): Use "jshort" as type for
      	nameIndex.  Use "jint" as type for boffset.
      	* java/lang/Class.h (struct _Jv_Method): Made accflags a
      	_Jv_ushort.
      	(Class): Likewise.  Also changed type of method_count,
      	vtable_method_count, size_in_bytes, field_count,
      	static_field_count, interface_count.
      	* gcj/array.h (__JArray): Made `length' a const jsize, not an
      	int.
      
      From-SVN: r31621
      Tom Tromey committed
  28. 21 Jan, 2000 1 commit
    • natConstructor.cc (newInstance): Use _Jv_CallAnyMethodA. · 8a922095
      	* java/lang/reflect/natConstructor.cc (newInstance): Use
      	_Jv_CallAnyMethodA.
      	* include/jvm.h: Declare _Jv_CallAnyMethodA.
      	* java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Renamed
      	from _Jv_CallNonvirtualMethodA.  Changed interface; overloaded.
      	Include <jni.h>.
      	(COPY): Removed.
      	(invoke): Use _Jv_CallAnyMethodA.
      	(VAL): Redefined.
      	* java/lang/Class.h (Class): Declare JvGetFirstStaticField,
      	JvNumStaticFields, JvNumMethods, and JvGetFirstMethod as friend
      	functions.
      	(struct _Jv_Method): Added getNextMethod method.
      	(JvNumMethods): New function.
      	(JvGetFirstMethod): Likewise.
      	* gcj/field.h (JvGetFirstStaticField): New function.
      	(JvNumStaticFields): Likewise.
      	(getNextField): Renamed from getNextInstanceField.
      	(struct _Jv_Field): New method getClass.
      	* jni.cc: Wrote many new functions.
      	* include/jni.h (JNI_TRUE): Define.
      	(JNI_FALSE): Likewise.
      	(jobject, jclass, jstring, jarray, jthrowable, jobjectArray,
      	jbyteArray, jshortArray, jintArray, jlongArray, jbooleanArray,
      	jcharArray, jfloatArray, jdoubleArray): New typedefs.
      	(jfieldID, jmethodID): Likewise.
      	(JNI_COMMIT, JNI_ABORT): New defines.
      	(JNINativeMethod): New struct.
      	(struct JNINativeInterface): Correctly declared more entries.
      	(class _Jv_JNIEnv): Added `ex' member.
      	(JNI_VERSION_1_1): New define.
      	(JNI_VERSION_1_2): Likewise.
      
      	* boehm.cc (_Jv_MarkObj): Use getNextField, not
      	getNextInstanceField.
      
      From-SVN: r31553
      Tom Tromey committed
  29. 19 Jan, 2000 1 commit
  30. 05 Jan, 2000 3 commits
    • Class.h (_getMethods): Correctly declare as private, not public. · 1258cada
      	* java/lang/Class.h (_getMethods): Correctly declare as private,
      	not public.
      
      From-SVN: r31246
      Tom Tromey committed
    • Class.h (_getMethods): Declare. · 6f2b93eb
      	* java/lang/Class.h (_getMethods): Declare.
      	* java/lang/Class.java (_getMethods): Declare.
      	* java/lang/natClass.cc (getDeclaringClass): Always return NULL.
      	(getDeclaredClasses): Always return empty array.
      	(_getMethods): New method.
      	(getMethods): Wrote.
      	(getDeclaredMethod): Return `rmethod'.
      	(finit_name): New global.
      	(getDeclaredMethods): Check for finit_name.
      	(_getMethods): Likewise.
      	(getMethod): Only return public methods.
      
      From-SVN: r31245
      Tom Tromey committed
    • Class.h (getSignature): Updated. · 95c6cc0a
      	* java/lang/Class.h (getSignature): Updated.
      	* java/lang/Class.java (getSignature): Updated.
      	* java/lang/natClass.cc (getSignature): Added `is_constructor'
      	argument.
      	(getConstructor): Ensure constructor is public.
      	(_getConstructors): Check for public-ness of constructor when
      	`declared' is false, not when it is true.
      
      From-SVN: r31241
      Tom Tromey committed
  31. 04 Jan, 2000 1 commit
    • [multiple changes] · 0f918fea
      2000-01-04  Tom Tromey  <tromey@cygnus.com>
      
      	* java/lang/reflect/natConstructor.cc (newInstance): Pass
      	declaring class as return_type argument to
      	_Jv_CallNonvirtualMethodA.
      	* java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA): In
      	constructor case, create object and use it as `this' argument.
      	* java/lang/Class.h (_getConstructors): Declare.
      	(_getFields): Declare.
      	* java/lang/Class.java (getConstructors): Wrote.
      	(_getConstructors): New native method.
      	(getDeclaredConstructors): Wrote.
      	(_getFields): Declare new native method.
      	* java/lang/natClass.cc (_Jv_LookupInterfaceMethod): Removed
      	incorrect comment.
      	(getMethod): Work correctly when class is primitive.
      	(getDeclaredMethods): Likewise.  Compute offset using `method',
      	not `mptr'.
      	(getDeclaredMethod): Likewise.
      	(getConstructor): Wrote.
      	(ConstructorClass): New define.
      	(getDeclaredConstructor): Wrote.
      	(_getConstructors): New method.
      	(_getFields): New method.
      	(getFields): Wrote.
      
      	* Makefile.in: Rebuilt.
      	* Makefile.am (AM_CXXFLAGS): Added -D_GNU_SOURCE.
      
      	* prims.cc: Remove `#pragma implementation'.
      	* gcj/array.h: Remove `#pragma interface'.
      
      	* prims.cc (_Jv_equaln): New function.
      	* java/lang/Class.java (getSignature): Declare.
      	* resolve.cc (_Jv_LookupDeclaredMethod): Moved to natClass.cc.
      	* java/lang/natClass.cc (_Jv_LookupDeclaredMethod): Moved from
      	resolve.cc.
      	(getSignature): New method.
      	(getDeclaredMethod): Wrote.
      	(getMethod): Wrote.
      	Include StringBuffer.h.
      	* java/lang/Class.h (Class): Added _Jv_FromReflectedConstructor
      	as a friend.  Unconditionally declare _Jv_LookupDeclaredMethod as
      	a friend.
      	(getSignature): Declare.
      	* include/jvm.h (_Jv_GetTypesFromSignature): Declare.
      	(_Jv_equaln): Declare.
      	(_Jv_CallNonvirtualMethodA): Declare.
      	* Makefile.in: Rebuilt.
      	* Makefile.am (nat_source_files): Added natConstructor.cc.
      	(java/lang/reflect/Constructor.h): New target.
      	* java/lang/reflect/natConstructor.cc: New file.
      	* java/lang/reflect/Constructor.java (newInstance): Now native.
      	(declaringClass): Renamed from decl_class.
      	(offset): Renamed from index.
      	(getType): New native method.
      	(getModifiers): Now native.
      	(getParameterTypes): Call getType if required.
      	(hashCode): Include hash code from declaring class.
      	(modifiers): Removed.
      	(toString): Call getType if required.
      	* gcj/method.h (_Jv_FromReflectedConstructor): New function.
      	* java/lang/reflect/natMethod.cc (hack_call): New method.
      	Removed `#if 0' around FFI code.
      	Include <gnu/gcj/RawData.h>.
      	(invoke): Use _Jv_CallNonvirtualMethodA.  Throw
      	IllegalArgumentException when argument object and class disagree.
      	(_Jv_GetTypesFromSignature): New function.
      	(getType): Use it.
      	(ObjectClass): New define.
      	(_Jv_CallNonvirtualMethodA): New function.
      	* java/lang/reflect/Method.java (hack_trampoline): New method.
      	(hack_call): New native method.
      
      1999-12-21  Per Bothner  <per@bothner.com>
      
      	* java/lang/natClass.cc (getDeclaredMethods): Correctly compute
      	offset in new Method.
      
      From-SVN: r31199
      Tom Tromey committed
  32. 10 Sep, 1999 1 commit
    • configure: Rebuilt. · 27e934d8
      	* configure: Rebuilt.
      	* configure.in: Build include/Makefile.
      	* Makefile.in: Rebuilt.
      	* Makefile.am (SUBDIRS): Added gcj and include.
      	(install-data-local): New target.
      	(extra_headers): New macro.
      	* include/Makefile.in: New file.
      	* include/Makefile.am: New file.
      
      	* interpret.cc: Don't include gcj/field.h or gcj/cni.h.
      	* java/lang/reflect/natField.cc: Don't include gcj/field.h or
      	gcj/cni.h.
      	* boehm.cc: Don't include java-threads.h or gcj/field.h.
      	* resolve.cc: Include config.h.
      	* defineclass.cc: Include config.h.
      	* include/java-interp.h: Don't include config.h.
      	* include/jvm.h: Include java-threads.h, Object.h, java-gc.h,
      	cni.h.
      
      	* gcj/javaprims.h: Regenerated namespace decls.
      	* classes.pl (scan): Don't put `;' after closing brace.
      
      	* Makefile.in: Rebuilt.
      	* Makefile.am (INCLUDES): Added -I for top_srcdir.
      	* configure.in: Create gcj/Makefile.
      	* gcj/Makefile.in: New file.
      	* gcj/Makefile.am: New file.
      	* java/lang/Object.h: Don't include any other headers.
      	* gcj/array.h: Renamed from include/java-array.h.
      	* gcj/field.h: Renamed from include/java-field.h.
      	* gcj/method.h: Renamed from include/java-method.h.
      	* gcj/cni.h, gcj/javaprims.h: Moved from include/.
      	Updated all files to reflect new include structure.
      
      From-SVN: r29278
      Tom Tromey committed
  33. 01 Sep, 1999 2 commits
  34. 18 Aug, 1999 1 commit
    • natClassLoader.cc (_Jv_PrepareCompiledClass): Renamed from _Jv_InternClassStrings. · eb4534a6
      	* java/lang/natClassLoader.cc (_Jv_PrepareCompiledClass): Renamed
      	from _Jv_InternClassStrings.
      
      	* prims.cc (_Jv_RunMain): New function.
      	(JvRunMain): Remove gij-support.
      
      	* gij.cc (main): Use _Jv_RunMain.
      
      	* java/util/zip/ZipFile.java: Call readDirectory in constructor.
      
      	* interpret.cc (PUSHA, PUSHI, PUSHF, PUSHL, PUSHD): Don't store
      	argument in temp variable.
      	(continue1): For all op_x2y insns, use temp variable for
      	intermediate value.  Also remove some comments.
      
      	* java/lang/natClass.cc (newInstance): Call _Jv_InitClass.
      	(forName): Don't call _Jv_InitClass.
      
      	* java/lang/Class.java (getResource,getResourceAsStream): Implement.
      
      	* java/util/zip/ZipEntry.java (ZipEntry(ZipEntry)): New construcor.
      
      	* java/util/jar/JarInputStream.java: New file.
      
      	* java/util/jar/JarEntry.java: New file.
      
      	* java/util/jar/JarFile.java: New file.
      
      	* java/net/URLClassLoader.java: New file.
      
      	* java/net/JarURLConnection.java: New file.
      
      	* gnu/gcj/protocol/jar/Handler.java: New file.
      
      	* gnu/gcj/protocol/jar/Connection.java: New file.
      
      	* java/security/SecureClassLoader.java: New file.
      
      	* java/lang/ClassLoader.java (parent): New variable.
      	(ClassLoader (ClassLoader)): new constructor.
      	(findClass): New method.
      	(loadClass): Add default 1.2 implementation.
      	(getSystemResourceAsBytes, getResourceAsBytes): Removed.
      	(readfully): Removed.
      
      	* gnu/gcj/runtime/VMClassLoader.java: Moved from java/lang.
      	(findSystemClass): New method.
      	(VMClassLoader): Constructor rewritten.
      	(init): New method.
      	All other methods removed.
      
      	* java/lang/natClassLoader.cc: Change use of java::lang::VMClassLoader
      	to gnu::gcj::runtime::VMClassLoader.
      	(_Jv_InternClassStrings): Use _Jv_ResolvePoolEntry.  Also handle
      	class entries.
      	(VMClassLoader::findSystemClass): renamed from findBootClass.
      
      	* Makefile.am: Add new files.
      	(FirstThread.h, ThreadGroup.h): Add _Jv_Main friend.
      
      	* Makefile.in: Rebuilt.
      
      From-SVN: r28748
      Kresten Krab Thorup committed