This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Patch: FYI: Merge BC branch to trunk


This patch merges the BC branch to the trunk.  After this patch, I
think the BC branch is dead; I'll submit another patch to update the
web pages.  I've made a tag on the branch at the merge point.

The resulting compiler passes the libgcj test suite.
Tested on x86 FC2.

Most of the new code in the compiler is controlled by the
-findirect-dispatch and -fnew-verifier options.  These don't seem to
have been documented on the branch, but I have a list of minor
documentation updates I'll be making soon, so I will fix these as
well.

The runtime side involves many changes, most notably a complete
reworking of our runtime linking.  It now handles all the [oai]table
stuff mentioned in the GCC Summit paper, and it also is just cleaner
in general.

I'm attaching the patch compressed as it is quite large.
I'm appending the ChangeLog entries as well.  It wasn't clear to me
how to handle these for a merge, so I just put all the entries from
the branch at the top of the existing ChangeLog.

This patch changes Class; you will need to do a clean rebuild of
libgcj.

Tom


Index: gcc/java/ChangeLog
from  Tom Tromey  <tromey@redhat.com>

	* class.c (make_field_value): Don't call build_static_field_ref.
	(build_static_field_ref): Don't emit direct references when using
	indirect dispatch.

	* gcj.texi (Invoking gij): Document -verbose.  Put -verbose and
	-verbose:class into man page synopsis.

2004-11-09  Tom Tromey  <tromey@redhat.com>

	* expr.c (build_java_arraystore_check): Still generate check if
	element type is itself an array.

2004-11-08  Tom Tromey  <tromey@redhat.com>

	* java-tree.h (soft_check_assignment_node): Removed.
	(enum java_tree_index): Removed JTI_SOFT_CHECK_ASSIGNMENT_NODE.
	* decl.c (java_init_decl_processing): Don't initialize
	soft_check_assignment_node.

2004-11-05  Tom Tromey  <tromey@redhat.com>

	* class.c (layout_class_methods): Don't add Miranda methods when
	using indirect dispatch.

2004-11-05  Bryce McKinlay  <mckinlay@redhat.com>

	* class.c (make_class_data): Call emit_assertion_table to set the
	'assertion_table' field.
	(build_signature_for_libgcj): Move here from expr.c.
	(add_assertion_table_entry): New function. Callback for assertion
	hashtable traversal.
	(emit_assertion_table): New. Take class argument, and generate 
	assertion table DECL based on the TYPE_ASSERTIONS hashtable.
	* decl.c (init_decl_processing): Define assertion_entry_type record.
	Push 'assertion_table' class field instead of 'verify'.
	* expr.c (type_assertion_eq): Compare 'assertion_code' field.
	(type_assertion_hash): Include 'assertion_code' in hash.
	(add_type_assertion): Rewritten. Take class and assertion_code
	arguments. Add assertions to the TYPE_ASSERTIONS hashtable.
	(can_widen_reference_to): Use new add_type_assertion() arguments.
	* java-tree.h (java_tree_index): Add JTI_ASSERTION_ENTRY_TYPE, 
	JTI_ASSERTION_TABLE_TYPE. Remove JTI_VERIFY_IDENTIFIER_NODE.
	(verify_identifier_node): Removed.
	(assertion_entry_type, assertion_table_type): New.
	(ASSERTION_TYPES_COMPATIBLE, ASSERTION_IS_INSTANTIABLE): New. Type
	assertion code definitions.
	(struct type_assertion): Add assertion_code. Rename 'source_type' and
	'target_type' to 'op1' and 'op2'.
	(add_type_assertion): Declare.
	(lang_printable_name_wls): Remove unused definition.
	* verify-glue.c: (vfy_is_assignable_from): New. Call add_type_assertion
	to emit runtime assertion.
	(vfy_note_stack_type): Clean up non-C90 declarations.
	(vfy_note_local_type): Likewise.
	* verify.h (vfy_is_assignable_from): Declare.
	* verify-impl.c (is_assignable_from_slow): Remove unused function.
	(ref_compatible): Rename arguments. Call vfy_is_assignable_from() 
	instead of is_assignable_from_slow().
	(types_compatible): Reinstate ref_compatible() call.

2004-11-04  Tom Tromey  <tromey@redhat.com>

	* class.c (build_static_field_ref): Reverted previous patch.

	* class.c (build_static_field_ref): Don't emit direct references
	when using indirect dispatch.

2004-11-03  Tom Tromey  <tromey@redhat.com>

	* expr.c (expand_java_arrayload): Set lhs_type_node.
	(expand_java_arraystore): Set rhs_type_node.

2004-11-02  Tom Tromey  <tromey@redhat.com>

	* jcf-parse.c (compute_class_name): Use filename length from zip
	directory, not strlen.

	* expr.c (expand_invoke): Mark new interface methods as abstract.

2004-11-01  Tom Tromey  <tromey@redhat.com>

	* verify-impl.c (push_jump): Removed check for uninitialized
	objects.
	(push_exception_jump): Likewise.
	(handle_ret_insn): Likewise.
	(handle_jsr_insn): Likewise.
	(state_check_no_uninitialized_objects): Removed.

	* decl.c (check_local_unnamed_variable): Recognize
	promoted-to-int parameters when using the new verifier.
	* expr.c (expand_java_arraystore): Explicitly request array type
	when using new verifier.
	(expand_java_arrayload): Likewise.
	(invoke_build_dtable): Don't pass object_type_node as
	expression argument to build_java_indirect_ref.
	(build_java_check_indexed_type): Do nothing.
	(build_java_arraystore_check): Handle case where array doesn't
	have array type.
	(build_java_array_length_access): Likewise.
	(expand_invoke): Handle case where interface overrides a method
	from Object.
	(pop_type_0): Always succeed for reference types.
	(process_jvm_instruction): Don't pop a value in a dead
	exception handler.
	(pop_arguments): Convert arguments to correct types.

2004-10-29  Andrew Haley  <aph@redhat.com>

	* jcf-parse.c (give_name_to_class): Remove line that was
	incorrectly merged.

2004-10-29  Andrew Haley  <aph@redhat.com>

	* jcf-parse.c (set_source_filename): Add code to build new sfname.

2004-10-20  Andrew Haley  <aph@redhat.com>

	* decl.c (end_java_method): Don't expand if flag_syntax_only.

2004-10-26  Tom Tromey  <tromey@redhat.com>

	* verify.h (vfy_notify_verified): Removed.
	* verify-glue.c (vfy_notify_verified): Removed.

2004-10-26  Tom Tromey  <tromey@redhat.com>

	* verify-impl.c (debug_print_state): Declare `i' before code.
	(merge_types): Modify `t' when it is null_type.

2004-10-26  Tom Tromey  <tromey@redhat.com>

	* verify-impl.c (type_print): Renamed from print.  Now static and
	takes an argument.
	(debug_print_state): Use type_print.

2004-10-25  Tom Tromey  <tromey@redhat.com>

	* expr.c (build_invokeinterface): Compute correct offset for
	index into interface methods.

2004-10-20  Tom Tromey  <tromey@redhat.com>

	* java-tree.h (verify_jvm_instructions_new): Declare.

	* jvspec.c (jvgenmain_spec): Remove -fnew-verifier from cc1
	command line.

	* verify-impl.c (verify_instructions): Correctly handle wide
	types on the stack.
	* verify-glue.c (vfy_get_class_name): Use DECL_NAME.
	(vfy_get_component_type): Strip pointer types.
	(vfy_find_class): Use get_type_from_signature.  Strip pointer
	types.
	Include java-except.h.

2004-10-20  Bryce McKinlay  <mckinlay@redhat.com>

	* verify-impl.c (type_array_elementpop_raw, vfy_pop_type_t, 
	vfy_push_type_t, set_variable, add_new_state, merge_into,
	handle_jsr_insn, branch_prepass, check_class_constant,
	check_wide_constant, get_one_type, compute_static_types, 
	verify_instructions_0): Clean up C99 declarations after statements.

2004-10-20  Tom Tromey  <tromey@redhat.com>

	* verify-impl.c (merge_refs): Compare reference against iterator,
	not ref2.

	* verify-glue.c (vfy_tag): Mask off resolved flag.

2004-10-19  Tom Tromey  <tromey@redhat.com>

	* verify-impl.c (verify_instructions): Call vfy_note_local_type.
	(init_state_with_stack): Initialize `this_type' in state.
	(verify_method): Use debug_print.
	* verify-glue.c (vfy_is_primitive): Removed debugging print.
	(vfy_note_stack_depth): Reverted last patch.
	(vfy_note_stack_type): Note pointer to Object, not Object.
	(vfy_note_local_type): Likewise.

	* verify.h (vfy_note_instruction_seen): Declare.
	* verify-glue.c (verify_jvm_instructions_new): Set
	BCODE_EXCEPTION_TARGET on target instruction.
	(vfy_note_instruction_seen): New function.
	* verify-impl.c (FLAG_INSN_SEEN): New define.
	(verify_instructions_0): Set flag on instruction.  Save state for
	PC=0 later.
	(verify_instructions): Call vfy_note_instruction_seen.

	* verify-glue.c (vfy_note_stack_depth): Fix off-by-one error.
	(verify_jvm_instructions_new): Call method_init_exceptions,
	add_handler, and handle_nested_ranges.
	* verify-impl.c (verify_method): Return 1 on success.
	(verify_instructions_0): Save the state at PC=0.

	* verify-impl.c (init_type_from_class): Set is_resolved and
	ref_next on new ref_intersection.
	(init_type_from_string): Likewise.

2004-10-15  Bryce McKinlay  <mckinlay@redhat.com>

	* expr.c (expand_bytecode): Use verify_jvm_instructions_new
	if flag_new_verifier is set.
	* java-tree.h (flag_new_verifier): Declare.
	* lang.opt (fnew-verifier): New option.
	* verify-impl.c: Work around namespace pollution by undef'ing 
	'current_class'.
	(struct verifier_context): Make 'bytecode' const.
	(verify_fail_pc): Pass -1 PC argument to vfy_fail.
	(types_compatible): For the BC-ABI, always consider reference types
	compatible.
	(check_class_constant): Use vfr->current_class.
	(check_constant): Likewise.
	(check_wide_constant): Likewise.
	(check_field_constant): Check for 'L' at start of type name.
	(get_one_type): Return pointer instead of type. Set type result in
	caller via passed type pointer.
	(compute_argument_types): Update to use new get_one_type arguments.
	(compute_return_type): Likewise.
	(make_verifier_context): New. Allocate and initialize 'vfr'.
	(free_verifier_context): New. Free 'vfr' and its contents.
	(verify_method): Remove ATTRIBUTE_UNUSED. Call make_verifier_context
	and free_verifier_context.

2004-10-15  Tom Tromey  <tromey@redhat.com>

	* verify-glue.c (vfy_note_local_type): Mark argument as unused.
	* verify.h (vfy_fail): Fixed formatting.

	* verify-impl.c (vfr): Fixed comment formatting.
	(collapse_type): New function.
	(verify_instructions): Notify compiler about type map.
	* verify.h (vfy_note_stack_depth): Updated.
	(vfy_note_stack_type): Likewise.
	(vfy_note_local_type): Likewise.
	(vfy_unsuitable_type, vfy_return_address_type, vfy_null_type):
	Declare.
	* verify-glue.c (vfy_note_stack_depth): Correctly size type
	state.  Added `method' argument.
	(vfy_note_stack_type): Renamed from vfy_note_type.  Added `method'
	argument.
	(vfy_note_local_type): New function.
	(vfy_unsuitable_type): Likewise.
	(vfy_return_address_type): Likewise.
	(vfy_null_type): Likewise.

	* verify.h (VFY_IN_GCC): Removed.
	(VFY_WANT_TYPEMAP): Removed.
	* verify-impl.c (verify_instructions_0): Removed useless "\".
	(struct state) <next>: Uncomment.

2004-10-13  Bryce McKinlay  <mckinlay@redhat.com>

	* verify-impl.c: Formatting fixes. Reformat C++-style comments to 
	C-style.

2004-10-06  Bryce McKinlay  <mckinlay@redhat.com>

	* Make-lang.in (verify.o): Re-enabled this target.
	* verify-glue.c (vfy_get_interface_count): Add ATTRIBUTE_UNUSED.
	(vfy_get_interface): Likewise.
	(verify_jvm_instructions_new): Renamed from verify_jvm_instructions.
	* verify.h (verify_jvm_instructions_new): Declare.
	* verify-impl.c (free_state): Temporarily comment out unused
	function.

2004-10-06  Tom Tromey  <tromey@redhat.com>

	* java-tree.h (JV_STATE_READ): New enum value.

2004-10-06  Bryce McKinlay  <mckinlay@redhat.com>

	* verify.h: New file.

2004-10-05  Bryce McKinlay  <mckinlay@redhat.com>

	* verify-impl.c, verify-glue.c, verify.h: New files.
	* Make-lang.in: Add rules for verify-impl.o and verify-glue.o.

2004-09-24  Andrew Haley  <aph@redhat.com>

	* decl.c (check_local_unnamed_variable): Always use the PARM_DECL
	for a slot if it's of pointer type.

2004-09-14  Tom Tromey  <tromey@redhat.com>

	* class.c (make_class_data): Correctly initialize "state" field.
	Initialize "engine" field.
	* decl.c (java_init_decl_processing): Add "engine" field.

2004-09-10  Andrew Haley  <aph@redhat.com>

	PR java/12760
	* expr.c (build_invokeinterface): Use fast method for interface
	dispatch.
	* java-tree.h (enum java_tree_index): Add JTI_ITABLE_TYPE,
	JTI_ITABLE_PTR_TYPE.
	(struct lang_type): Add  itable_methods, itable_decl, itable_syms_decl.
	(emit_symbol_table): Add new arg, element_size.
	* decl.c (java_init_decl_processing): Initialize Class.itable.
	* class.c (GEN_TABLE): New macro.
	(gen_indirect_dispatch_tables): Use it.  Add itable.
	(make_class_data): Add new arg for emit_symbol_table().
	Emit itable.
	(add_miranda_methods): Make sure search_class has been parsed.
	(emit_symbol_table): Add new arg, element_size.

2004-09-06  Andrew Haley  <aph@redhat.com>

	* verify.c (merge_types): Return Object for all merges of
	interfaces.
	* expr.c (add_type_assertion): Don't generate assertions when
	source type is array of Object.

2004-09-03  Andrew Haley  <aph@redhat.com>

	* class.c (finish_class): Nullify TYPE_VERIFY_METHOD.

	* lang.c (java_post_options): Force flag_verify_invocations if
	we're not using indirect dispatch.

	* expr.c (pop_type_0): Move test for interfaces before call to
	can_widen_reference_to().
	(build_signature_for_libgcj): Remove generation of canonical array
	type.
	(add_type_assertion): Canonicalize both arrays.
	Don't assert that type X can be assigned to Object.
	Don't assert that type X an be assigned to type X.
	Don't assert that Object can be assigned to type X.
	(can_widen_reference_to): Warn whenever we generate an assertion.
	(process_jvm_instruction): Use throwable_type_node for the type of
	an exception class.

2004-09-01  Andrew Haley  <aph@redhat.com>

	* decl.c (java_init_decl_processing): Change
	verify_identifier_node to "__verify".
	* expr.c (add_type_assertion): Use verify_identifier_node for name.
	* java-tree.h (verify_identifier_node): Change to "__verify".

	* expr.c (build_signature_for_libgcj): New function.
	(add_type_assertion): Use it to construct signatures for
	source_type and target_type.

2004-08-27  Andrew Haley  <aph@redhat.com>

	* java-tree.h (enum java_tree_index): Add JTI_VERIFY_IDENTIFIER_NODE.
	(verify_identifier_node): New.
	(TYPE_VERIFY_METHOD): New.
	(struct type_assertion): New type.
	* expr.c (type_assertion_eq): New function.
	(type_assertion_hash): New function.
	(add_type_assertion): New function.
	(can_widen_reference_to): Call add_type_assertion().
	* decl.c (java_init_decl_processing): Add verify_identifier_node.
	* class.c (make_class_data): Initialize TYPE_VERIFY_METHOD (type).
	(finish_class): Output TYPE_VERIFY_METHOD (type).

	* decl.c (end_java_method): Nullify unused fields.

2004-08-17  Andrew Haley  <aph@redhat.com>

	* verify.c (defer_merging): Quieten.
	* jcf-parse.c (load_class): Only try to open a class file if it's
	java.lang.Object or if it's part of the current compilation.
	Check that the class we just tried to load is the class we just
	loaded.  Quieten.
	(java_parse_file): Set flag_verify_invocations off if we're
	compiling from .class.
	(parse_zip_file_entries): Abort if we try to read a dummy class.
	* expr.c (can_widen_reference_to): Quieten.
	(build_invokevirtual): Abort if we try to invokevirtual an
	interface.
	(expand_invoke): Don't build a non-interface call to an interface.
	(build_instanceof): Don't do premature optimization if
	flag_verify_invocations is not set.
	* class.c (set_super_info): Disable code that inherits TYPE_DUMMY
	from superclass.
	(build_static_field_ref): Add correct type conversion for
	field_address.
	(add_miranda_methods): Disable generation of Miranda methods for
	dummy classes.
	(layout_class_method): Don't complain about non-static method
	overrides static method with dummy classes.

2004-08-13  Tom Tromey  <tromey@redhat.com>

	* class.c (build_static_field_ref): Re-enable atable lookups for
	static fields.

	* parse.y (strip_out_static_field_access_decl): Indentation fix.

2004-08-11  Tom Tromey  <tromey@redhat.com>

	* gcj.texi (libgcj Runtime Properties): Document new properties.

2004-08-06  Andrew Haley  <aph@redhat.com>

	* jcf-parse.c (load_class): Check that we really have loaded the
	class we're looking for.

2004-07-19  Andrew Haley  <aph@redhat.com>

	* verify.c (verify_jvm_instructions): Comment change only.

	* typeck.c (build_java_array_type): Add size field to array name.

	* java-tree.h (LOCAL_SLOT_P): New.
	(update_aliases): Add PC argument.
	(pushdecl_function_level): New function.

	* java-gimplify.c (java_gimplify_expr): Handle VAR_DECL,
	MODIFY_EXPR, and SAVE_EXPR.
	(java_gimplify_modify_expr): New function.

	* expr.c (push_type_0): Call find_stack_slot() to create temporary.
	(expand_iinc): Pass PC to update_aliases().
	(STORE_INTERNAL): Likewise.
	(process_jvm_instruction): Likewise.

	* decl.c (base_decl_map): New variable.
	(uniq): New variable.
	(update_aliases): Rewrite with more thorough checking.
	(debug_variable_p): New function.
	(push_jvm_slot): Don't initialize local variable.  Don't pushdecl.
	(check_local_named_variable): Delete whole function.
	(initialize_local_variable): New function.
	(check_local_unnamed_variable): Add checks and comments.
	(find_local_variable): Rewrite.
	(java_replace_reference): New function.
	(function_binding_level): New variable.
	(pushdecl_function_level): New function.
	(maybe_pushlevels): Set DECL_LOCAL_END_PC.
	(maybe_pushlevels): Call pushdecl() on each of the new decls.
	(start_java_method): Reset uniq.  Create base_decl_map.  Set
	function_binding_level.
	(end_java_method): Null unused fields to save memory.

2004-06-29  Andrew Haley  <aph@redhat.com>

	* except.c (expand_start_java_handler): Push a new binding level.
	Don't build a TRY_CATCH_EXPR now, we'll do it later.  Call
	register_exception_range() to register where we'll do it.
	(expand_end_java_handler): Remove old bogus code.  Replace with
	new logic that simply builds TRY_CATCH_EXPRs and inserts them at
	the top of the expression we're curently building.
	(maybe_end_try): Delete.
	* decl.c (binding_level.exception_range): New field.
	(clear_binding_level): Add field exception_range.  Reformat.
	(poplevel): Call expand_end_java_handler().
	(poplevel): Call java_add_stmt only if functionbody is false.
	(maybe_poplevels): Don't call maybe_end_try() from here.
	(end_java_method): Clear no longer used trees in function decl.
	(register_exception_range): New function.
	* java-tree.h (register_exception_range, struct eh_range): Declare.

2004-06-22  Andrew Haley  <aph@redhat.com>

	* class.c (gen_indirect_dispatch_tables): Set the DECL_OWNER of
	the otable.
	* check-init.c (get_variable_decl): Teach check-init about
	FIELD_DECLs addressed via the otable.
	* jcf-parse.c (load_class): Check CLASS_LOADED_P, not
	CLASS_PARSED_P.

2004-05-28  Andrew Haley  <aph@redhat.com>

	* jcf-parse.c (load_class): Don't try to read a class that we've
	already read.

	* expr.c (build_invokeinterface): Use the old-fashioned way of
	doing indirect dispatch: look up interfaces by name.
	* java-tree.h (enum java_tree_index): Add
	JTI_SOFT_LOOKUPINTERFACEMETHODBYNAME_NODE
	* decl.c (java_init_decl_processing): Add
	soft_lookupinterfacemethodbyname_node.

	* gjavah.c (print_method_info): Final methods have vtable entries,
	so gjavah needs to output them. 
	* class.c (layout_class_method): Generate vtable entries for final
	methods.
	* parse.y (invocation_mode): Use INVOKE_VIRTUAL for indirect
	dispatch, even if a method is final.

2004-05-25  Andrew Haley  <aph@redhat.com>

	* class.c (build_symbol_entry): Convert the names of constructors
	to init_identifier_node when generating an entry for the indirect
	dispatch table.

	* expr.c (build_known_method_ref): Generate indirect calls for
	all methods marked DECL_EXTERNAL or TREE_PUBLIC.

2004-05-24  Andrew Haley  <aph@redhat.com>

	* expr.c (build_known_method_ref): Make sure ARRAY_REF access to
	atable element is of the right type.

	* class.c (build_static_field_ref): Cast pointer to correct type
	for field.

2004-04-20  Bryce McKinlay  <mckinlay@redhat.com>

	* Merged with HEAD as of 20040514. Diff against
	gcj-abi-2-merge-20040514.

2004-04-16  Andrew Haley  <aph@redhat.com>

	* verify.c (check_pending_block): Disable subroutine checks.
	(defer_merging): New function.
	(merge_types): If types are dummy, use defer_merging to combine them.
	(verify_jvm_instructions): If invocation is invokeinterface and
	target is dummy, assume target really is an interface.

	* parse.y (patch_invoke): Break out call to java_create_object.

	* lang.c (flag_verify_invocations): New.

	* jcf-parse.c (load_class): If we've already failed to load a
	class, don't try again.
	(load_class): If we can't find a .class file, don't fail, but emit
	a warning.
	(parse_class_file): Don't act on dummy methods.

	* java-tree.h (flag_verify_invocations): New.
	(TYPE_DUMMY): New.
	(lang_type.dummy_class): New field.
	(java_create_object): New function.
	(METHOD_DUMMY): New.

	* expr.c (build_field_ref): Widen field offset.
	(pop_type_0): If the type in stack_type_map is a TREE_LIST, check
	that each of its elements is compatible with the one we're
	popping.
	(pop_type_0): Issue a warning to say that we need to generate a
	runtime check.
	(java_create_object): New function.
	(build_field_ref): Only generate hard refs if we're not using
	indirect dispatch.
	(expand_java_field_op): If we're using !verify_invocations and we
	see a missing field, generate a decl for it.

	(expand_invoke): If a class doesn't have the method we seek and
	we're using !flag_verify_invocations, generate a decl for the
	method now.

	(build_known_method_ref): Always use indirect dispatch via the
	atable for static methods.

	(expand_java_NEW): Break out object creation into new function,	
	java_create_object.

	(can_widen_reference_to): Issue a warning to say that we need to
	generate a runtime check.

	* class.c (set_super_info): Inherit TYPE_DUMMY from sureclass.
	(make_method_value): Also use index for interfaces.
	(make_class_data): Skip dummy field for inherited data.
	Don't build method array for dummy methods.
	Set size_in_byte to -1 when using inirect dispatch
	Don't build a hard class ref if we don't have a hard ref to our
	superclass, or if we're using inirect dispatch.
	Null out dispatch tables.

	(layout_class_method): Don't complain about non-static method
	overrides static method is method is artificial.

	(build_static_field_ref): Disable atable references to static
	fields for the time being.

	(layout_class_methods): Check for CLASS_INTERFACE as
	well as CLASS_ABSTRACT.


Index: libjava/ChangeLog
from  Tom Tromey  <tromey@redhat.com>

	* include/java-interp.h (_Jv_DefineClass): Updated.
	* java/lang/natVMClassLoader.cc (defineClass): Pass protection
	domain to class reader.
	* defineclass.cc (parse): Use print_class_loaded.
	Include ProtectionDomain.h.
	(_Jv_DefineClass): Added ProtectionDomain argument.
	(_Jv_ClassReader): Likewise.
	* include/jvm.h (_Jv_Linker::print_class_loaded): Declare.
	* link.cc: Include CodeSource.h.
	(print_class_loaded): New function.
	(wait_for_state): Use it.

2004-11-16  Andrew Haley  <aph@redhat.com>

	* gnu/gcj/util/Debug.java (print): Add RawDataManaged.

2004-11-16  Andrew Haley  <aph@redhat.com>

	* configure.ac (LIBGCJ_LD_SYMBOLIC): AC_SUBST this definition.
	* configure.host: Define libgcj_ld_symbolic for Linux hosts.
	* Makefile.am (lib_*_la_LDFLAGS): Add LIBGCJ_LD_SYMBOLIC.
	* configure: Regenerate.
	* Makefile.in: Regenerate.	

2004-11-15  Andrew Haley  <aph@redhat.com>

	* boehm.cc (_Jv_GCRegisterDisappearingLink): Check that *objp is a
	gc-allocated object.

2004-11-15  Andrew Haley  <aph@redhat.com>

	* java/net/URLClassLoader.java
	(URLLoader.getClassPath): New method.
	(JarURLLoader.JarURLLoader): Read mainfest to parse "Class-Path"
	attribute and add URLs for each entry.
	(JarURLLoader.classPath): New field.
	(JarURLLoader.getClassPath): New method.
	(addURLImpl): Scan through the list of extraUrls in the new
	loader, adding them to our urlinfos.
	(definePackage, findURLResource, findResources): Use
	urlinfos.size(), not urls.size().

2004-11-11  Tom Tromey  <tromey@redhat.com>

	* gnu/gcj/runtime/natSharedLibLoader.cc (ensureSupersLinked): New
	method.
	* gnu/gcj/runtime/SharedLibHelper.java (findClass): Ensure supers
	linked.
	(ensureSupersLinked): Declare.
	* java/lang/natVMClassLoader.cc (loadClass): Ensure supers
	linked.

2004-11-10  Tom Tromey  <tromey@redhat.com>

	* gij.cc (main): Treat -verbose the same as -verbose:class.
	(help): Document -verbose and -verbose:class.

	* link.cc (verbose_class_flag): Declare.
	(wait_for_state): Print message when handling precompiled class.
	* java/lang/natClass.cc (verbose_class_flag): Moved to link.cc.

2004-11-09  Tom Tromey  <tromey@redhat.com>

	* testsuite/libjava.lang/assign2.out: New file.
	* testsuite/libjava.lang/assign2.java: New file.

	* java/lang/natRuntime.cc (insertSystemProperties): Set
	java.version to 1.4.2 and java.specification.version to 1.4.  Set
	java.runtime.version.

2004-11-08  Tom Tromey  <tromey@redhat.com>

	* java/lang/natClass.cc (_Jv_IsAssignableFromSlow): Ensure
	supers installed.
	* link.cc (verify_type_assertions): Don't link supers.

	* include/jvm.h (_Jv_Linker::search_method_in_class): Declare.
	* include/java-interp.h (class _Jv_InterpClass)
	<_Jv_PrepareMissingMethods>: No longer `friend'.
	* java/lang/Class.h (_Jv_SearchMethodInClass): No longer
	`friend'.
	(_Jv_PrepareMissingMethods, _Jv_PrepareCompiledClass,
	_Jv_GetInterfaces, _Jv_GenerateITable, _Jv_FindIIndex,
	_Jv_AppendPartialITable, _Jv_LinkSymbolTable,
	_Jv_LayoutInterfaceMethods, _Jv_SetVTableEntries, _Jv_MakeVTable,
	_Jv_linkExceptionClassTable, _Jv_WaitForState): Likewise.
	* link.cc (search_method_in_class): Renamed from
	_Jv_SearchMethodInClass.
	(resolve_pool_entry): Updated.

	* include/jvm.h (_Jv_CheckAssignment): Removed.
	* java/lang/natClass.cc (_Jv_CheckAssignment): Removed.

2004-11-05  Tom Tromey  <tromey@redhat.com>

	* link.cc (verify_type_assertions): Ensure classes have supers
	linked.  Strip off array types first.

2004-11-05  Bryce McKinlay  <mckinlay@redhat.com>

	* link.cc: Include VerifyError.h. 
	(_Jv_Linker::verify_type_assertions): New. Read and evaluate entries
	in the type assertion table.
	* include/execution.h (_Jv_CompiledEngine::do_verify): Use
	verify_type_assertions.
	* include/jvm.h (_Jv_Linker::verify_type_assertions): declare.
	* java/lang/Class.h (JV_ASSERT_END_OF_TABLE, 
	JV_ASSERT_TYPES_COMPATIBLE, JV_ASSERT_IS_INSTANTIABLE): Declare
	assertion code values.
	(struct _Jv_TypeAssertion): Declare.
	(assertion_table): New class field.
	(verify): Remove class field.

2004-11-05  Andrew Haley  <aph@redhat.com>

	* Makefile.am: Move jv_dbtool.java to
	gnu/gcj/tools/gcj_dbtool/Main.java.
	* Makefile.in: Rebuild.
	* java/lang/VMCompiler.java: Rename property
	"gnu.gcj.precompiled.db" to "gnu.gcj.precompiled.db.path".
	* gnu/gcj/tools/gcj_dbtool/Main.java: moved here from
	jv_dbtool.java.

2004-11-05  Andrew Haley  <aph@redhat.com>

	* jv_dbtool.java (main): Allow the user to specify the size of the
	database.  Display the capacity and the size.
	(usage): Show the new option.

2004-11-04  Tom Tromey  <tromey@redhat.com>

	* include/jvm.h (_Jv_Linker::set_vtable_entries): Updated.
	* link.cc (make_vtable): Use correct index when searching for
	missing method's name.  Don't use `flags'.
	(set_vtable_entries): Removed `flags' argument.  Don't recurse
	into superclasses.
	(link_symbol_table): Ensure target class method table is
	complete.  Ensure target fields are laid out before entering
	loop.

	* java/lang/natClass.cc (_Jv_getInterfaceMethod): Indentation
	fix.

	* interpret.cc (do_verify): Don't verify abstract methods.

2004-11-01  Tom Tromey  <tromey@redhat.com>

	* link.cc (wait_for_state): Call verify_class.

	* verify.cc (state::check_no_uninitialized_objects): Removed.
	(push_jump): Updated.
	(push_exception_jump): Likewise.
	(handle_ret_insn): Likewise.
	(handle_jsr_insn): Likewise.

2004-10-28  Andrew Haley  <aph@redhat.com>

	* gnu/gcj/runtime/PersistentByteMap.java: New file.
	* jv_dbtool.java: New file.
	* Makefile.am (bin_PROGRAMS): Add jv-dbtool
	(jv_dbtool_SOURCES, jv_dbtool_LDFLAGS, jv_dbtool_LINK)
	(jv_dbtool_LDADD, jv_dbtool_DEPENDENCIES): New.
	* Makefile.in: Regenerate,
	* java/lang/VMCompiler.java: Import NoSuchAlgorithmException,
	Enumeration, StringTokenizer, Vector, PersistentByteMap.
	(precompiledMapFiles): New variable.
	(VMCompiler static intializer): Read "gnu.gcj.precompiled.db" to
	initialize precompiledMapFiles.
	(compileClass): Look at the database of precompiled class files
	before firing up gcj.

	* gnu/gcj/runtime/VMClassLoader.java (findClass): Fix comment.

2004-10-27  Andrew Haley  <aph@redhat.com>

	* java/lang/VMCompiler.java (compileClass): try looking for
	precompiledMapFiles.
	* gnu/gcj/runtime/PersistentByteMap.java: New file.

2004-10-27  Tom Tromey  <tromey@redhat.com>

	* link.cc (ensure_class_linked): Only resolve classes for
	compiled classes.
	(add_miranda_methods): Ensure interface supers are installed.
	(resolve_pool_entry): Better error message.

2004-10-25  Tom Tromey  <tromey@redhat.com>

	* boehm.cc (_Jv_MarkObj): Test aux_info before dereferencing it.

	* java/util/ResourceBundle.java (tryBundle): Use
	Class.isAssignableFrom rather than catching ClassCastException.

	* java/util/zip/InflaterInputStream.java (fill): Don't throw an
	exception if we hit EOF of `in'.
	(read): Handle case where inflating returns -1.

	* gnu/java/text/WordBreakIterator.java (WordBreakIterator): Don't
	initialize `iter'.
	* gnu/java/text/SentenceBreakIterator.java
	(SentenceBreakIterator): Don't initialize `iter'.
	* gnu/java/text/LineBreakIterator.java (LineBreakIterator): Don't
	initialize `iter'.
	* gnu/java/text/CharacterBreakIterator.java
	(CharacterBreakIterator): Don't initialize `iter'.
	* gnu/java/text/BaseBreakIterator.java (BaseBreakIterator): New
	constructor.
	* java/text/BreakIterator.java: Updated documentation.

2004-10-20  Tom Tromey  <tromey@redhat.com>

	* java/util/ResourceBundle.java (tryBundle): Also ignore
	ClassCastException.

2004-10-18  Tom Tromey  <tromey@redhat.com>

	* interpret.cc (do_post_miranda_hook): New method.
	* include/execution.h (_Jv_ExecutionEngine::post_miranda_hook):
	New field.
	(_Jv_CompiledEngine::do_post_miranda_hook): New method.
	(_Jv_CompiledEngine): Initialize new field.
	(_Jv_InterpreterEngine::do_post_miranda_hook): Declare.
	(_Jv_InterpreterEngine): Initialize new field.
	* link.cc (resolve_pool_entry): Put Miranda methods in target
	class.
	(ensure_method_table_complete): Call post_miranda_hook.
	* java/lang/natVMClassLoader.cc (defineClass): Don't set class'
	aux_info.
	* defineclass.cc (read_one_method_attribute): Use _Jv_AllocBytes.
	(parse): Set class' aux_info here.

	* boehm.cc (_Jv_MarkObj): Mark `throws'.

	* boehm.cc: Re-merged with trunk.

2004-10-18  Andrew Haley  <aph@redhat.com>

	PR java/18036:
	* gnu/gcj/runtime/natStackTrace.cc (fillInStackTrace): Reorganize
	and correct logic used to find interpreter.

2004-10-13  Andrew Haley  <aph@redhat.com>

	* interpret.cc (_Jv_InterpMethod::run): Initialize
	_Jv_StartOfInterpreter.
	(_Jv_StartOfInterpreter, _Jv_EndOfInterpreter): Functions removed.
	(_Jv_StartOfInterpreter, _Jv_EndOfInterpreter): New variables.
	* gnu/gcj/runtime/natStackTrace.cc (fillInStackTrace): Use
	_Unwind_FindEnclosingFunction to discover whether PC is within the
	interpreter.

2004-10-13  Tom Tromey  <tromey@redhat.com>

	* link.cc (find_iindex): Copy correct number of slots to new
	ioffsets.

2004-10-12  Tom Tromey  <tromey@redhat.com>

	* testsuite/libjava.loader/loader.exp (gcj_object_file_name): New
	proc.
	(gcj_loader_test_one): Use it.
	(gcj_loader_run): Likewise.

	* prims.cc: Don't include FirstThread.h.

2004-10-06  Tom Tromey  <tromey@redhat.com>

	* link.cc (ensure_method_table_complete): Ensure superclass
	Miranda methods installed.

	* include/java-interp.h (class _Jv_JNIMethod): Added
	JV_MARKOBJ_DECL as a friend.
	* interpret.cc (ncode): Allocate jni_arg_types field with GC.
	* boehm.cc (_Jv_MarkObj): Skip abstract methods when marking
	interpreter method structures.  Mark jni_arg_types of JNI
	methods.

	* defineclass.cc (parse): Use JV_STATE_READ.
	* java/lang/Class.h (JV_STATE_READ): New enum value.

2004-10-05  Tom Tromey  <tromey@redhat.com>

	* link.cc (resolve_pool_entry): Add signature info to missing
	method's information.

	* gnu/gcj/util/Debug.java (Debug(int,boolean)): New constructor.
	* gnu/gcj/util/natDebug.cc (_Jv_StaticDeepDebug): New function.

2004-10-04  Tom Tromey  <tromey@redhat.com>

	* boehm.cc (_Jv_MarkObj): Correctly indicate base pointer when
	marking IDT.

2004-09-29  Tom Tromey  <tromey@redhat.com>

	* Makefile.am (libgcj_la_SOURCES): Mention link.cc, not
	resolve.cc.
	* include/jvm.h (class _Jv_Linker): Renamed from _Jv_Resolver.
	* jni.cc: Use _Jv_Linker.
	* interpret.cc: Use _Jv_Linker.
	* java/lang/reflect/natField.cc (getType): Use _Jv_Linker.
	* java/lang/natClassLoader.cc: Use _Jv_Linker.
	* java/lang/natVMClassLoader.cc (resolveClass): Use _Jv_Linker.
	* java/lang/Class.h: Use _Jv_Linker.
	* java/lang/natClass.cc (initializeClass): Use _Jv_Linker.
	* resolve.cc: Renamed ...
	* link.cc: ... here.  Use _Jv_Linker.
	* defineclass.cc (checkExtends): Use _Jv_Linker.

2004-09-17  Tom Tromey  <tromey@redhat.com>

	* defineclass.cc (handleCodeAttribute): Don't reference
	`deferred'.
	(handleMethodsEnd): Likewise.
	* include/java-interp.h (_Jv_MethodBase::deferred): Removed
	field.
	(_Jv_Defer_Resolution): Don't declare or define.
	* interpret.cc (do_create_ncode): Don't resolve deferred method
	pointers.
	* java/lang/Class.h (_Jv_Defer_Resolution): Don't declare.
	* resolve.cc (link_symbol_table): No need to defer resolution.

2004-09-14  Tom Tromey  <tromey@redhat.com>

	* boehm.cc (MAYBE_MARK): Remove unused `Exit' argument.
	(_Jv_MarkObj): Updated.
	(_Jv_MarkArray): Likewise.

	* include/jvm.h (StringClass): Removed.
	* jni.cc (_Jv_JNI_ThrowNew): Don't use StringClass.
	* interpret.cc (_Jv_InitField): Don't use StringClass.
	* java/lang/natString.cc (_Jv_StringFindSlot): Don't use
	StringClass.
	(rehash): Likewise
	(intern): Likewise.
	(_Jv_FinalizeString): Likewise.
	(_Jv_NewStringUtf8Const): Likewise.
	(equals): Likewise.
	* prims.cc (JvConvertArgv): Don't use StringClass.

	* gcj/field.h (struct _Jv_Field): Don't mention COMPACT_FIELDS.
	* resolve.cc (ensure_fields_laid_out): Don't mention
	COMPACT_FIELDS.
	* defineclass.cc (handleField): Don't mention COMPACT_FIELDS.
	* boehm.cc (_Jv_MarkObj): Don't mention COMPACT_FIELDS.

	* java/lang/reflect/natField.cc (getType): Use resolve_field.
	* java/lang/natVMClassLoader.cc (resolveClass): New native
	implementation.
	(linkClass0): Removed.
	(markClassErrorState0): Likewise.
	* java/lang/natClassLoader.cc: Include execution.h.  Moved class
	preparation code to resolve.cc.
	(_Jv_RegisterClassHookDefault): Set class's execution engine if
	not already set.
	(_Jv_FindClass): Use wait_for_state.
	(_Jv_NewArrayClass): Likewise.  Simplified permissions setting.
	* java/lang/natClass.cc (_Jv_IsInstanceOf): Include execution.h.
	Moved interface table and class preparation code to resolve.cc.
	(finalize): Rewrote.
	(initializeClass): Simplified locking and class preparation.
	* java/lang/VMClassLoader.java (linkClass0): Removed.
	(markClassErrorState0): Likewise.
	(resolveClass): Now native.
	(transformException): New method.
	* java/lang/Class.h (getSuperclass): Don't try to resolve super
	reference.
	(getInterface): Likewise.
	(size): Likewise.
	(set_state): New method.
	(Class): Updated friend declarations.
	(verify): Field now private.
	(engine): New field.
	* include/jvm.h (class _Jv_Resolver): New class declaration.
	(_Jv_ResolveField): Removed declaration.
	(_Jv_CheckAccessNoInit): Likewise.
	(_Jv_isBinaryCompatible): Removed.
	* include/java-interp.h (class _Jv_MethodBase): Updated friend
	declarations.
	(class _Jv_InterpMethod): Likewise.
	(class _Jv_InterpClass): Likewise.
	(class _Jv_JNIMethod): Likewise.
	* include/execution.h: New file.
	* gnu/gcj/runtime/natSharedLibLoader.cc: Include execution.h.
	(_Jv_sharedlib_register_hook): Set `engine' on loaded class.
	Register class after setting fields.
	* resolve.cc: Include execution.h, VerifyError.h.  Moved
	interpreter-specific code to interpret.cc.
	(uaddr): New location.
	(struct aligner): Likewise.
	(ALIGNOF): Likewise.
	(INITIAL_IOFFSETS_LEN): Interface dispatch code moved here.
	(INITIAL_IFACES_LEN): Likewise.
	(null_idt): Likewise.
	(_Jv_GetMethodString): Likewise.
	(_Jv_ThrowNoSuchMethodError): Likewise.
	(_Jv_abstractMethodError): Likewise.
	(_Jv_Resolver::get_alignment_from_class): Renamed.
	(_Jv_Resolver::resolve_field): Likewise.
	(_Jv_Resolver::resolve_pool_entry): Likewise.
	(_Jv_Resolver::resolve_class_ref): Likewise.
	(_Jv_Resolver::prepare_constant_time_tables): Likewise.
	(_Jv_Resolver::indexof): Likewise.
	(_Jv_Resolver::get_interfaces): Likewise.
	(_Jv_Resolver::generate_itable): Likewise.
	(_Jv_Resolver::append_partial_itable): Likewise.
	(_Jv_Resolver::find_iindex): Likewise.
	(_Jv_Resolver::link_symbol_table): Likewise.
	(_Jv_Resolver::link_exception_table): Likewise.
	(_Jv_Resolver::layout_interface_methods): Likewise.
	(_Jv_Resolver::layout_vtable_methods): Likewise.
	(_Jv_Resolver::set_vtable_entries): Likewise.
	(_Jv_Resolver::make_vtable): Likewise.
	(_Jv_Resolver::ensure_fields_laid_out): Likewise.
	(_Jv_Resolver::ensure_class_linked): Likewise.
	(_Jv_Resolver::ensure_supers_installed): Likewise.
	(_Jv_Resolver::add_miranda_methods): Likewise.
	(_Jv_Resolver::ensure_method_table_complete): Likewise.
	(_Jv_Resolver::verify_class): Likewise.
	(_Jv_Resolver::wait_for_state): Likewise.
	* prims.cc (_Jv_soleCompiledEngine): New global.
	(_Jv_CheckAccess): Use _Jv_IsAssignableFromSlow.
	(_Jv_CheckAccessNoInit): Removed.
	* jni.cc (_Jv_JNI_GetAnyFieldID): Use resolve_field.
	* interpret.cc: Include platform.h, ClassFormatError.h,
	Modifier.h, execution.h.
	(_Jv_soleInterpreterEngine): New global.
	(compile): Use resolve_pool_entry.
	(run): Likewise.
	(_Jv_InitField): New location.
	(skip_one_type): Likewise.
	(get_ffi_type_from_signature): Likewise.
	(_Jv_count_arguments): Likewise.
	(init_cif): Likewise.
	(ncode_closure): Likewise.
	(ffi_closure_fun): Likewise.
	(ncode): Likewise.
	(throw_class_format_error): Likewise.
	(throw_class_format_error): Likewise.
	(_Jv_InterpreterEngine::do_verify): New method.
	(_Jv_InterpreterEngine::do_create_ncode): Likewise.
	(_Jv_InterpreterEngine::do_allocate_static_fields): Likewise.
	(_Jv_InterpreterEngine::do_resolve_method): Likewise.
	* defineclass.cc: Include execution.h.
	(_Jv_ClassReader): Initialize size_in_bytes, vtable_method_count,
	engine.
	(checkExtends): Ensure superclass has supers installed.
	(_Jv_ClassNameSamePackage): Clarify usage constraints.
	* boehm.cc (GC_enable, GC_disable): Declare at top of file.
	(_Jv_MarkObj): Unconditionally mark vtable.  Mark interface
	dispatch tables.

2004-09-13  Tom Tromey  <tromey@redhat.com>

	* mauve-libgcj: List some classes we don't have.

2004-09-10  Andrew Haley  <aph@redhat.com>

	* java/lang/Class.h (_Jv_getInterfaceMethod(): new friend.
	* java/lang/natClass.cc (initializeClass): Check itable.
	(_Jv_getInterfaceMethod): New.
	(_Jv_LinkSymbolTable): Rewrite code that handles inerface calls.
	Check that an interface method isn't called with invokevirtual.

	* java/lang/natClass.cc (_Jv_LayoutVTableMethods): Make sure
	super_meth is virtual.

2004-09-01  Tom Tromey  <tromey@redhat.com>

	* java/lang/Class.h (_Jv_CheckAccessNoInit): Declare as friend.
	* java/lang/natClass.cc (_Jv_LayoutVTableMethods): Use
	_Jv_CheckAccessNoInit.
	* include/jvm.h (_Jv_CheckAccessNoInit): Declare.
	* prims.cc (_Jv_CheckAccessNoInit): New method.

	* java/lang/reflect/natMethod.cc (invoke): Check access against
	declaring class, not object's class.
	* java/lang/natClass.cc (_Jv_LookupDeclaredMethod): Added another
	argument.
	(_Jv_LayoutVTableMethods): Perform checks of accessibility of
	overridden method.
	* java/lang/Class.h (_Jv_LookupDeclaredMethod): Added another
	argument.

2004-08-30  Andrew Haley  <aph@redhat.com>

	* java/lang/natClass.cc (_Jv_CheckAssignment): Catch
	ClassNotFoundException.
	Throw NoClassDefFoundError.

	* java/lang/natClassLoader.cc (_Jv_FindClassInCache): Remove call
	to klass->verify() from here ...
	(_Jv_PrepareCompiledClass): ...and put it here.

2004-08-27  Andrew Haley  <aph@redhat.com>

	* java/lang/natClassLoader.cc (_Jv_FindClassInCache): Call
	klass->verify().
	* java/lang/natClass.cc (_Jv_LinkSymbolTable): Add debugging.
	(_Jv_LinkSymbolTable): Call Jv_LayoutClass on target class.

2004-08-27  Tom Tromey  <tromey@redhat.com>

	* java/lang/Class.h (_Jv_IsAssignableFromSlow): Declare as
	friend.
	* java/lang/natClass.cc (_Jv_CheckAssignment): New function.
	(_Jv_IsAssignableFromSlow): New function.
	Include VerifyError.h.
	* include/jvm.h (_Jv_CheckAssignment): Declare.

2004-08-18  Andrew Haley  <aph@redhat.com>

	* java/lang/VMCompiler.java (loadSharedLibrary): Add className
	argument.  Pass it to findClass instead of fileName.
	(compileClass): Pass class name to loadSharedLibrary.

2004-06-22  Andrew Haley  <aph@redhat.com>

	* testsuite/libjava.compile/compile.exp: Force indirect dispatch.

2004-06-15  Andrew Haley  <aph@redhat.com>

	* java/lang/natSystem.cc (getenv0): Don't assume environment
	variable is Latin 1 coded.

2004-06-07  Andrew Haley  <aph@redhat.com>

	* java/lang/System.java: (getenv0): New method.
	(getenv): Add security check.  Do the right thing.
	* java/lang/natSystem.cc (getenv0): New method.

2004-04-19    Andrew Haley  <aph@redhat.com>

	* gnu/gcj/runtime/NameFinder.java: Call waitFor() on the processes
	we destroy.

	* gnu/java/net/natPlainSocketImplPosix.cc (read): The value byte
	is returned as an int in the range 0 to 255.

2004-08-13  Tom Tromey  <tromey@redhat.com>

	* java/lang/natClass.cc (_Jv_LinkSymbolTable): Prepare the target
	class if it is interpreted.

2004-08-12  Tom Tromey  <tromey@redhat.com>

	* java/lang/natClassLoader.cc (_Jv_WaitForState): Updated.
	* java/lang/Class.h (_Jv_ResolveClassRef): Updated declaration.
	(Class::getSuperclass): Updated.
	(Class::getInterfaces): Likewise.
	(Class::size): Updated.
	(_Jv_LayoutClass): Updated declaration.
	* java/lang/natClass.cc (_Jv_ResolveClassRef): Changed interface.
	Synchronize on class.
	(_Jv_LayoutClass): Changed interface.
	(initializeClass): Updated.
	(_Jv_LinkSymbolTable): Likewise.

	* java/lang/Class.h (Class::_Jv_isBinaryCompatible): Declare as
	friend.
	* java/lang/natClassLoader.cc (_Jv_WaitForState): Use
	_Jv_isBinaryCompatible.
	* java/lang/natClass.cc (initializeClass): Use
	_Jv_isBinaryCompatible.
	(_Jv_LinkSymbolTable): Likewise.
	* include/jvm.h (_Jv_isBinaryCompatible): New function.

2004-08-11  Tom Tromey  <tromey@redhat.com>

	* gcj/javaprims.h: Regenerated.
	* java/lang/natClassLoader.cc (getClassLoader0): Removed.
	(_registerClass): Likewise.
	* Makefile.in: Rebuilt.
	* Makefile.am (core_java_source_files): Added VMCompiler.
	* java/lang/Compiler.java: Rewrote in terms of VMCompiler.
	* java/lang/VMCompiler.java: New file.
	* gnu/gcj/runtime/SharedLibHelper.java (findClass): Removed
	`verbose' code.
	(copyFile): Don't use fully-qualified name.
	(h): Removed.
	* java/lang/natVMClassLoader.cc: Include VMCompiler.h.
	(defineClass): Use VMCompiler.
	* java/lang/ClassLoader.java (defineClass): Removed jit
	compilation code and `verbose' code.
	(getClassLoader0): Removed.
	(_registerClass): Likewise.
	(SharedLibHelpers): Removed.

2004-08-10  Tom Tromey  <tromey@redhat.com>

	* java/net/URLClassLoader.java (URLLoader(URLClassLoader, URL,
	URL)): New constructor.
	(SoURLLoader): Likewise.
	(JarURLLoader): Create SoURLLoader with override URL.

2004-08-10  Mark Wielaard  <mark@klomp.org>

	* Makefile.in: Rebuilt.
	* Makefile.am (interpret.lo): New rule.

2004-08-05  Andrew Haley  <aph@redhat.com>

	* java/net/URLClassLoader.java (JarURLLoader.JarURLLoader): Look
	aside for "GCJLIBS" in directory where jarfiles are loaded.	
	(JarURLLoader.getClass): New method.
	(JarURLLoader.toString):  New method.
	(FileResource.toString):  New method.
	* java/lang/natClassLoader.cc (_Jv_RegisterClassHookDefault):
	Remove "Duplicate class registration: " bug.
	(_registerClass): New method.
	* java/lang/natClass.cc (_Jv_LinkSymbolTable): Check method index.
	(_Jv_LinkSymbolTable): Call _Jv_LayoutClass().
	Add debugging.
	(_Jv_LayoutClass): Use getSuperclass() rather than directly
	accessing the field.
	* java/lang/ClassLoader.java (SharedLibHelpers): New variable.
	(defineClass): Call gcj to JIT-compile a class.
	(_registerClass): New method.
	* gnu/gcj/runtime/SharedLibHelper.java (findHelper): A shared
	library name can refer to more than one loaded library, so use a
	Set of SharedLibHelpers.
	If a shared library is already loaded, take a copy.
	(copyFile): New function.

	* testsuite/libjava.compile/compile.exp: Force
	-findirect-dispatch.

	* java/security/BasicPermission.java: Remove bogus checks.

	* java/lang/System.java (getenv0): New method.
	* java/lang/natSystem.cc (getenv0): New method.

2004-05-24  Andrew Haley  <aph@redhat.com>

	* java/lang/natClass.cc (_Jv_LayoutClass): Remove warning message.

2004-04-20  Bryce McKinlay  <mckinlay@redhat.com>

	* Merged with HEAD as of 20040514. Diff against
	gcj-abi-2-merge-20040514.

2004-04-16  Andrew Haley  <aph@redhat.com>

	* java/lang/natClassLoader.cc (_Jv_WaitForState): Call
	_Jv_LayoutClass.
	(_Jv_PrepareCompiledClass): Cast address to uaddr for comparison.
	(_Jv_PrepareCompiledClass): If we throw an exception during
	preparation, restore state.
	(ClassLoader::getClassLoader0): New method.

	* java/lang/natClass.cc (get_alignment_from_class): Moved here
	from resolve.cc.
	(ALIGNOF): Use offsetof, not __alignof__.
	(_Jv_ResolveClassRef): Resolve a reference to a class in a
	constant pool.
	(getInterfaces): Emit debug output if interface hasn't been
	resolved.
	(initializeClass): Call _Jv_LayoutClass.
	(_Jv_LinkSymbolTable): Add debugging output.
	(_Jv_LinkSymbolTable): NoClassDefFoundError if target_class isn't
	found.
	(_Jv_LinkSymbolTable): Call _Jv_PrepareClass.
	(_Jv_LinkSymbolTable): Pass the real class loader to
	_Jv_FindClass.
	(_Jv_linkExceptionClassTable): Don't throw if we fail to find an
	exception class.
	(_Jv_LinkSymbolTable): Assert if we find a static field reference
	to an interpreted class.
	(_Jv_LayoutVTableMethods): Use klass->getSuperclass to get the
	superclass.
	(_Jv_LayoutClass): Moved here; it was part of _Jv_PrepareClass in
	resolve.cc.

	* java/lang/VMSecurityManager.java: Check for the system class
	loader as well as loader != null.

	* java/lang/SecurityManager.java (checkPermission): Remove
	security check.
	(checkRead): Likewise.
	(checkConnect): Likewise.

	* java/lang/ClassLoader.java (loadClass): Include all class
	loaders in stack trace string.
	Look for class in "gcjlib.so" in the same directory.
	(getSystemClassLoader) Use getClassLoader0.
	(getClassLoader0): New native method.

	* java/lang/Class.h (getSuperclass): New method.
	(getInterface): New method.
	(size): Lay out class if needed.
	(firstMethodIndex): New method.
	(Jv_ResolveClassRef): New declaration.
	(_Jv_LinkSymbolTable): New declaration.

	* java/io/ObjectOutputStream.java: Add DEBUG statements
	everywhere.
	(dumpElementln): New method.
	(depth): New field.
	* java/io/ObjectInputStream.java (MyIOException): new, for
	debugging.
	Everywhere: use MyIOException rather than IOException.
	Indent debugging output to make nesting visible.
	(currentClassLoader): Make native
	(callersClassLoader): New field.
	(depth): New field.
	* java/io/natObjectInputStream.cc (getCallersClassLoader): New
	method.

	(readObject): ENDBLOCKDATA is generated if the class has a write
	method, not if it has a read method.

	* include/jvm.h (_Jv_CallAnyMethodA): Add new arg, iface.

	* gnu/javax/rmi/CORBA/DelegateFactory.java: Use the
	getContextClassLoader form the current thread after our own class
	loader.

	* gnu/gcj/runtime/SharedLibHelper.java (findClass): Class loader
	debugging.
	(toString): New method.

	* verify.cc (class _Jv_BytecodeVerifier): Don't directly access
	interfaces array.

	* resolve.cc (_Jv_PrepareMissingMethods): If interface looks like
	a constant pool entry, resolve it now.
	(_Jv_PrepareClass): Break out part of this function to Jv_LayoutClass
	in natClass.cc.
	Move get_alignment_from_class to natClass.cc.

	* prims.cc (_Jv_AllocObjectNoFinalizer): Use size field from class.
	(_Jv_AllocObjectNoInitNoFinalizer): Likewise.

	* defineclass.cc (checkExtends): Don't access superclass field
	directly.

	* Makefile.in: regenerate.

	* gnu/gcj/util/natDebug.cc: New
	* gnu/gcj/util/Debug.java: New.

	* Makefile.am (java/io/ObjectInputStream.lo): Use
	-fno-optimize-sibling-calls.

	* java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Use
	_Jv_LookupInterfaceMethodIdx to calculate the address of a method
	in an interface.
	* include/jvm.h (_Jv_CallAnyMethodA): Add new arg: iface.

Attachment: BC-merge.patch.gz
Description: the patch


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]