1 2005-04-19 Kazu Hirata <kazu@cs.umass.edu>
3 * except.c: Fix a comment typo.
5 2005-04-19 Julian Brown <julian@codesourcery.com>
7 * decl.c (finish_method): Revert patch from 2005-04-13 for breaking
8 indirect dispatch with PIC.
10 2005-04-18 Andrew Haley <aph@redhat.com>
12 * java-except.h (struct eh_range.handler): Remove unused field.
13 (handle_nested_ranges): Remove function declaration.
14 (sanity_check_exception_range): Add function declaration.
15 * verify.c (verify_jvm_instructions): Remove call to
17 * verify-glue.c (verify_jvm_instructions_new): Call
18 sanity_check_exception_range.
19 * except.c (link_handler, eh_range_freelist, link_handler,
20 handle_nested_ranges): Remove.
21 (add_handler): Rewrite.
22 (sanity_check_exception_range): New function.
23 (print_ranges): New function.
25 2005-04-13 Julian Brown <julian@codesourcery.com>
27 * decl.c (finish_method): Give methods once-only linkage.
29 2005-04-11 Richard Sandiford <rsandifo@redhat.com>
31 * lang.opt: Refer to the GCC internals documentation instead of c.opt.
33 2005-04-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
35 * java-tree.h: Don't use PARAMS().
37 2005-04-07 Per Bothner <per@bothner.com>
39 * class.c (push_class): By default, suppress debug output.
40 (finish_class): Enable debug output for classes we're emitting.
42 2005-04-07 Andrew Haley <aph@redhat.com>
44 * gcj.texi: Correct gcj-dbtool instructions.
46 2005-04-04 Kazu Hirata <kazu@cs.umass.edu>
48 * gcj.texi: Fix a typo.
49 * lang.c: Fix a comment typo.
51 2005-04-01 Thomas Fitzsimmons <fitzsim@redhat.com>
53 * gcj.texi (Invoking gij): Add descriptions of new -X options.
54 Mention recognized-and-ignored compatibility options.
55 (Memory allocation): Add descriptions of JvMalloc, JvRealloc and
57 (About CNI): Add Memory allocation section.
59 2005-04-01 Tom Tromey <tromey@redhat.com>
61 * decl.c (java_init_decl_processing): Fix types of
62 _Jv_MonitorEnter, _Jv_MonitorExit, _Jv_AllocObject,
63 _Jv_AllocObjectNoFinalizer, _Jv_Throw, _Jv_NewPrimArray,
64 _Jv_JNI_PopSystemFrame, _Jv_divI, _Jv_remI, _Jv_divJ, _Jv_remJ.
66 2005-03-31 Jan Hubicka <jh@suse.cz>
68 * Make-lang.in (class.o, decl.o): Depend on cgraph.h.
69 * class.c: Include cgraph.h
70 (make_local_functoin_alias): Mark aslias as needed.
71 * resource.c: Include cgraph.h
72 (compile_resource_data): Go via cgraph interface.
74 2005-03-30 Ian Lance Taylor <ian@airs.com>
76 * parse.y (maybe_yank_clinit): Don't crash if bbody is NULL.
78 2005-03-30 Tom Tromey <tromey@redhat.com>
80 * jcf-dump.c (HANDLE_INNERCLASSES_ATTRIBUTE): Handle cases where
81 inner_class_info_index==0 or outer_class_info_index==0.
83 2005-03-29 Tom Tromey <tromey@redhat.com>
85 * gcj.texi (libgcj Runtime Properties): Document
86 gnu.gcj.runtime.endorsed.dirs.
88 2005-03-24 Anthony Green <green@redhat.com>
90 * gcj.texi (Invoking gcj-dbtool): Document new LIBDIR option to
93 2005-03-23 Tom Tromey <tromey@redhat.com>
95 * decl.c (GCJ_CURRENT_BC_ABI_VERSION): New define.
96 (parse_version): Use it.
98 2005-03-23 Joseph S. Myers <joseph@codesourcery.com>
100 * lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Remove.
102 2005-03-18 Andrew Haley <aph@redhat.com>
105 * decl.c (update_aliases): Don't update variables that are about
107 (maybe_poplevels): Add comment.
109 2005-03-17 Bryce McKinlay <mckinlay@redhat.com>
112 * jcf-parse.c (duplicate_class_warning): New function.
113 (java_parse_file): Call duplicate_class_warning if
114 CLASS_FROM_CURRENTLY_COMPILED_P is already set.
115 (parse_zip_file_entries): Likewise. Also set
116 CLASS_FROM_CURRENTLY_COMPILED_P.
118 2005-03-16 Andrew Haley <aph@redhat.com>
120 * expr.c (expand_java_arrayload): Don't generate a
121 NullPointerException based on the type of the node.
122 (build_java_array_length_access): Likewise.
124 2005-03-15 Zack Weinberg <zack@codesourcery.com>
126 * Make-lang.in (TEXI_JAVA_FILES): Add gcc-vers.texi.
128 2005-03-11 Tom Tromey <tromey@redhat.com>
130 * gcj.texi (Invoking gcj-dbtool): Document 'gcj-dbtool -p'.
131 (libgcj Runtime Properties): Document the default .db.
133 2005-03-10 Ranjit Mathew <rmathew@hotmail.com>
136 * parse.y (checks_throws_clauses): Check exceptions list even when
137 the base class does not come from a source file being compiled.
138 (java_complete_lhs): Remove unused variable 'wfl'.
140 2005-03-09 Ranjit Mathew <rmathew@hotmail.com>
143 * decl.c (finish_method): Emit _Jv_InitClass for private static
144 methods inside inner classes as well.
146 2005-03-08 Julian Brown <julian@codesourcery.com>
147 * Revert patch from 2005-03-08 for causing bootstrap failure on
150 2005-03-08 Julian Brown <julian@codesourcery.com>
152 * decl.c (finish_method): Give methods once-only linkage.
154 2005-03-07 Ranjit Mathew <rmathew@hotmail.com>
156 * lang.c (flag_new_verifier): Enable by default, regardless of ABI.
158 2005-03-07 Bryce McKinlay <mckinlay@redhat.com>
160 * verify-glue.c (vfy_is_assignable_from): Perform static check using
161 can_widen_reference_to if the C++ ABI is in use.
162 (vfy_get_interface_count, vfy_get_interface): Remove unused functions.
163 * verify-impl.c (debug_print, make_utf8_const, init_type, copy_type,
164 type_isresolved, init_state, set_pc, state_get_pc,
165 _Jv_BytecodeVerifier): Clean up unused and disabled functions.
166 (verify_fail): Report the current PC from the verifier context.
167 (free_state): Remove #if 0 block to enable this function.
168 (free_verifier_context): Call free_state on state_list iterator
169 values before freeing them.
170 * expr.c (pop_type_0): Pop correct type for error message when stack
171 contains a multi-word type.
173 2005-03-07 Ranjit Mathew <rmathew@hotmail.com>
175 * expr.c (build_java_array_length_access): Remove !flag_new_verifier
176 for known NULL array length access.
178 2005-03-07 Tom Tromey <tromey@redhat.com>
180 * gcj.texi (Invoking gcj-dbtool): Document '-f'.
182 2005-03-06 Kazu Hirata <kazu@cs.umass.edu>
184 * jcf-dump.c, jcf-io.c, jcf-reader.c, lang.c, parse.h,
185 typeck.c: Update copyright.
187 2005-03-06 Ranjit Mathew <rmathew@hotmail.com>
190 * xref.c, xref.h: Remove file.
191 * Make-lang.in (java/xref.o): Remove.
192 * java-tree.h (flag_emit_xref, do_not_fold): Remove declaration.
193 * lang.c (flag_emit_xref): Remove definition.
194 * parse.h (DECL_END_SOURCE_LINE, DECL_INHERITED_SOURCE_LINE): Remove.
195 * typeck.c (convert): Remove use of do_not_fold.
196 * parse.y (do_not_fold): Remove definition.
197 (parser grammar): Remove xref code.
198 (maybe_create_class_interface_decl, create_class): Likewise.
199 (register_fields, method_header, finish_method_declaration): Likewise.
200 (declare_local_variables, source_end_java_method): Likewise.
201 (java_complete_expand_classes): Do not set do_not_fold.
202 (java_complete_expand_method): Remove xref code.
203 (java_expand_classes, resolve_field_access, patch_invoke): Likewise.
204 (java_complete_tree, java_complete_lhs, patch_assignment): Likewise.
205 (patch_binop, build_string_concatenation, patch_array_ref): Likewise.
206 (patch_synchronized_statement, patch_throw_statement): Likewise.
207 (maybe_build_class_init_for_field): Likewise.
209 2005-03-05 Kazu Hirata <kazu@cs.umass.edu>
211 * expr.c (build_expr_wfl, expr_add_location): Use TYPE_P
212 instead of IS_NON_TYPE_CODE_CLASS.
214 2005-03-04 Andrew Haley <aph@redhat.com>
217 * class.c (set_method_index): Don't set method_index if it is
219 (layout_class_method): Don't complain about "non-static method foo
220 overrides static method" in the case of indirect dispatch.
222 2005-03-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
224 * jcf-io.c (caching_stat): Use __extension__ to avoid pedantic
226 * Make-lang.in: Don't elide warnings in jcf-io.c.
228 2005-03-01 Per Bothner <per@bothner.com>
231 * check-init.c (wfl): Remove static.
232 (final_assign_error, check_init): Replace calls to parse_error_context
234 (check_init): Save, set, and restore input_location for each exp.
236 2005-03-01 Per Bothner <per@bothner.com>
238 * jcf-reader.c (get_attribute): Handle SourceDebugExtension (JSR 45)
239 if HANDLE_SOURCEDEBUGEXTENSION_ATTRIBUTE is defined.
240 * jcf-dump.c (HANDLE_SOURCEDEBUGEXTENSION_ATTRIBUTE): Print contents.
242 2005-03-01 Per Bothner <per@bothner.com>
244 * java-tree.h (IDENTIFIER_HANDLECLASS_VALUE): Remove ancient macro.
246 2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com>
249 * gcj.texi (Invocation): Add descriptions of JvVMInitArgs and
252 2005-02-22 Tom Tromey <tromey@redhat.com>
255 * verify-impl.c (EITHER): New define.
256 (types_compatible): Handle it.
257 (check_field_constant): Use it.
259 2005-02-18 Tom Tromey <tromey@redhat.com>
262 * verify-impl.c (types_equal): Fixed test.
265 * verify-glue.c (vfy_class_has_field): New function.
266 * verify.h (vfy_class_has_field): Declare.
267 * verify-impl.c (check_field_constant): Added 'putfield'
269 (verify_instructions_0): Updated.
270 (types_equal): New function.
272 2005-02-14 Tom Tromey <tromey@redhat.com>
275 * jcf-write.c (generate_bytecode_insns) <CALL_EXPR>: Note the
276 stack effect of multianewarray.
278 2005-02-14 Andrew Haley <aph@redhat.com>
281 * expr.c (expand_byte_code): Call promote_arguments().
282 (promote_arguments): New function.
283 * decl.c (check_local_unnamed_variable): Remove special case for
285 (find_local_variable): Promote all boolean types to int
286 when searching for local variable decls.
288 2005-02-12 Kazu Hirata <kazu@cs.umass.edu>
290 * builtins.c, java-except.h, jcf-parse.c, jv-scan.c, lex.c,
291 parse-scan.y: Update copyright.
293 2005-02-11 Per Bothner <per@bothner.com>
296 * parse-scan.y (input_location): Remove variable.
297 (main_input_filename): New - replaces input_filename, which isn't
298 settable if USE_MAPPED_LOCATION.
299 * lex.c (java_init_lex): Wrap some more places in #ifndef JC1-LITE,
300 so we don't reference input_location or wfl_operator in that case.
301 * jv-scan.c (expand_location): Remove - no longer used.
302 (main): Set main_input_filename rather than input_filename.
304 2005-02-09 Richard Henderson <rth@redhat.com>
306 * builtins.c (initialize_builtins): Call build_common_builtin_nodes.
307 * decl.c (java_init_decl_processing): Initialize const_ptr_type_node.
309 2005-02-08 Marcin Dalecki <martin@dalecki.de>
311 * expr.c (add_type_assertion): Use the proper enumeration type,
312 since this is what htab_find_slot() is expecting.
314 2005-02-06 Joseph S. Myers <joseph@codesourcery.com>
316 * gcj.texi: Update copyright dates.
318 2005-02-02 Tom Tromey <tromey@redhat.com>
320 * gcj.texi (libgcj Runtime Properties): Default library_control
323 2005-02-02 Ranjit Mathew <rmathew@hotmail.com>
326 * parse-scan.y (formal_parameter): Use $2 (type) instead of $$
327 (modifiers) when square brackets are present in a declaration for
329 * jv-scan.c (main): Set input_filename and input_line.
331 2005-02-01 Tom Tromey <tromey@redhat.com>
334 * gjavah.c (get_field_name): Don't override name for JNI header.
336 2005-02-01 Roger Sayle <roger@eyesopen.com>
338 * jcf-write.c (generate_bytecode_insns): Implement RSHIFT_EXPR
339 of unsigned types using iushr and lushr JVM bytecodes.
341 2005-02-01 Ranjit Mathew <rmathew@hotmail.com>
344 * gjavah.c (jni_print_float): Do not emit floating-point
345 initialiser for a static final field.
346 (jni_print_double): Likewise.
348 2005-02-01 Mark Mitchell <mark@codesourcery.com>
351 2005-01-31 Mark Mitchell <mark@codesourcery.com>
352 * gjavah.c (print_field_info): Mark static data members of
353 floating-point type with "__extension__".
355 2005-01-31 Mark Mitchell <mark@codesourcery.com>
357 * gjavah.c (print_field_info): Mark static data members of
358 floating-point type with "__extension__".
360 2005-02-01 Ranjit Mathew <rmathew@hotmail.com>
363 * parse.y (build_string_concatenation): Remove redundant if.
364 (patch_conditional_expr): Attempt to patch_string() the condition
365 of a ?: as well, in addition to its other operands.
367 2005-01-25 Tom Tromey <tromey@redhat.com>
369 * Make-lang.in (java/java-tree-inline.o): Removed.
371 2005-01-25 Ranjit Mathew <rmathew@hotmail.com>
374 * parse.y (patch_binop): Allow comparisons against NULL only
375 if the other operand is of a reference type.
377 2005-01-24 Tom Tromey <tromey@redhat.com>
379 * java-tree.h (gcj_abi_version): Declare.
380 * class.c (make_class_data): Push gcj_abi_version into "next"
381 field. Renamed field.
382 * decl.c (gcj_abi_version): New global.
383 (parse_version): New function.
384 (java_init_decl_processing): Call it. Renamed 'next' field.
386 (GCJ_BINARYCOMPAT_ADDITION): New define.
388 2005-01-24 Roger Sayle <roger@eyesopen.com>
391 * jcf-write.c (generate_bytecode_insns): Conversions between
392 integer types of the same precision shouldn't generate widening
393 or narrowing conversion bytecodes.
395 2005-01-22 Kazu Hirata <kazu@cs.umass.edu>
397 * java-except.h, java-tree.h: Remove unused prototypes.
399 2005-01-20 Andrew Pinski <pinskia@gcc.gnu.org>
402 * jcf-write.c (perform_relocations): Don't call memcpy if source
403 and destination are the same.
405 2005-01-17 Tom Tromey <tromey@redhat.com>
407 * verify-impl.c (get_short): Sign extend.
410 2005-01-12 Ranjit Mathew <rmathew@hotmail.com>
412 * expr.c (build_jni_stub): Replace mistaken use of TYPE_SIZE_UNIT
415 2005-01-10 Ranjit Mathew <rmathew@hotmail.com>
417 * verify.c: Revert to the version before the BC-ABI merge.
419 2005-01-10 Ranjit Mathew <rmathew@hotmail.com>
422 * check-init.c (check_init): Take care of references that do not
423 have an explicit final variable declaration (e.g. array length
424 access) for pre/post in/de-crement operators.
426 2005-01-08 Mark Wielaard <mark@klomp.org>
428 * parse.y (process_imports): Allocate (and free) original_name only
429 when not already defined.
430 * jcf-parse.c (read_class): Free results of find_class() and
432 (java_parse_file): Keep pointer to head of file_list and free when
433 done. Free result of lrealpath().
435 2005-01-05 Tom Tromey <tromey@redhat.com>
437 * gcj.texi (Standard Properties): java.ext.dirs is now used.
439 2004-12-20 Andrew Haley <aph@redhat.com>
441 * typeck.c: Use fold_convert for ints and booleans.
443 2004-12-17 Andrew Haley <aph@redhat.com>
446 * typeck.c (convert): Use a CONVERT_EXPR when converting to
447 BOOLEAN_TYPE or CHAR_TYPE.
448 (convert_to_boolean, convert_to_char) : Remove.
449 * convert.h (convert_to_boolean, convert_to_char) : Remove.
450 * expr.c (expand_load_internal): Do type conversion if type is not
453 2004-12-13 Danny Smith <dannysmith@users.sourceforge.net>
456 * class.c (emit_register_classes): Use TARGET_USE_JCR_SECTION.
459 2004-12-07 Andrew Haley <aph@redhat.com>
462 * jcf-parse.c (load_class): Remove sanity test for missing inner
465 2004-12-06 Tom Tromey <tromey@redhat.com>
467 * Make-lang.in (JAVA_MANFILES): Added gcj-dbtool.
468 (java.uninstall): Likewise.
469 (java.maintainer-clean): Likewise.
470 (.INTERMEDIATE): Likewise.
471 (java.install-man): Likewise.
472 (gcj-dbtool.pod): New target.
473 * gcj.texi (Code Generation): Document -findirect-dispatch.
474 (libgcj Runtime Properties): Document
475 gnu.gcj.precompiled.db.path.
476 (Top): Link to "Invoking gcj-dbtool".
478 2004-12-06 Tom Tromey <tromey@redhat.com>
481 * java-tree.h (extract_field_decl): Declare.
482 * parse.y (extract_field_decl): Renamed from
483 strip_out_static_field_access_decl. No longer static.
484 * check-init.c (get_variable_decl): Unwrap COMPOUND_EXPRs.
486 2004-12-03 Tom Tromey <tromey@redhat.com>
488 * lang.c (flag_new_verifier): Define.
489 (java_post_options): Set flag_new_verifier if indirect dispatch
491 * lang.opt (fnew-verifier): Removed.
493 2004-12-03 Tom Tromey <tromey@redhat.com>
496 * Make-lang.in (java.install-common): Only install transformed
497 gcjh if gcj-cross exists.
499 2004-12-03 Andrew Haley <aph@redhat.com>
502 * except.c (link_handler): Patch 'outer' field of siblings of the
503 range we're demoting.
505 2004-12-03 Andrew Haley <aph@redhat.com>
508 * class.c (layout_class_method): Don't fail to override a method
509 simply because it has DECL_ARTIFICIAL set.
511 2004-12-02 Tom Tromey <tromey@redhat.com>
514 * parse.y (craft_constructor): Special case null_pointer_node.
516 2004-12-02 Tom Tromey <tromey@redhat.com>
519 * java-gimplify.c (java_gimplify_expr): Don't call
520 SET_EXPR_LOCATION unless wrapped tree is an expression.
522 2004-11-27 Per Bothner <per@bothner.com>
524 * jcf-parse.c (set_source_filename): Improvement to Andrew's fix:
525 Fix fencepost error in 'i', which got executed one too many times.
526 Also, fold memcpy into explicit loop, as originally intended.
527 Also, free temporary 'buf' which otherwise leaks.
529 2004-11-27 Per Bothner <per@bothner.com>
531 * expr.c (build_expr_wfl): Only declare last_file and last_filenode
532 local static variables if not USE_MAPPED_LOCATION.
534 2004-11-27 Kazu Hirata <kazu@cs.umass.edu>
536 * class.c, decl.c, expr.c: Fix comment typos.
538 2004-11-26 Andrew Pinski <pinskia@physics.uc.edu>
541 * decl.c (end_java_method): Call
542 attach_init_test_initialization_flags on all the init_decls.
543 * parse.y (attach_init_test_initialization_flags): Move to ...
544 * expr.c (attach_init_test_initialization_flags): here and
545 support BIND_EXPR also.
546 * java-tree.h (attach_init_test_initialization_flags): Prototype.
547 * jcf-parse.c (parse_class_file): Don't disable class init
550 2004-11-25 Joseph S. Myers <joseph@codesourcery.com>
552 * gjavah.c, jcf-dump.c, jv-scan.c, jvspec.c: Avoid ` as left quote
555 2004-11-24 Richard Henderson <rth@redhat.com>
557 * verify-glue.c (vfy_init_name, vfy_clinit_name, vfy_object_type,
558 vfy_string_type, vfy_throwable_type): Use ANSI declaration form.
560 2004-11-24 Tom Tromey <tromey@redhat.com>
562 * verify.c (defer_merging): Don't use C++-style comment.
563 * verify.h (java_opcode): Added java_opcode_end.
564 * class.c (build_class_ref): Remove C++ comment and old FIXME.
566 * verify-impl.c (vfy_push_type): Removed bogus "return".
567 (initialize_stack): Use vfy_alloc and vfy_free.
568 (verify_instructions_0): Likewise.
570 * Merged gcj-abi-2-dev-branch to trunk.
572 2004-11-24 Andrew Haley <aph@redhat.com>
574 * jcf-parse.c (parse_class_file): Set file_start_location.
576 2004-11-10 Tom Tromey <tromey@redhat.com>
578 * class.c (make_field_value): Don't call build_static_field_ref.
579 (build_static_field_ref): Don't emit direct references when using
582 * gcj.texi (Invoking gij): Document -verbose. Put -verbose and
583 -verbose:class into man page synopsis.
585 2004-11-09 Tom Tromey <tromey@redhat.com>
587 * expr.c (build_java_arraystore_check): Still generate check if
588 element type is itself an array.
590 2004-11-08 Tom Tromey <tromey@redhat.com>
592 * java-tree.h (soft_check_assignment_node): Removed.
593 (enum java_tree_index): Removed JTI_SOFT_CHECK_ASSIGNMENT_NODE.
594 * decl.c (java_init_decl_processing): Don't initialize
595 soft_check_assignment_node.
597 2004-11-05 Tom Tromey <tromey@redhat.com>
599 * class.c (layout_class_methods): Don't add Miranda methods when
600 using indirect dispatch.
602 2004-11-05 Bryce McKinlay <mckinlay@redhat.com>
604 * class.c (make_class_data): Call emit_assertion_table to set the
605 'assertion_table' field.
606 (build_signature_for_libgcj): Move here from expr.c.
607 (add_assertion_table_entry): New function. Callback for assertion
609 (emit_assertion_table): New. Take class argument, and generate
610 assertion table DECL based on the TYPE_ASSERTIONS hashtable.
611 * decl.c (init_decl_processing): Define assertion_entry_type record.
612 Push 'assertion_table' class field instead of 'verify'.
613 * expr.c (type_assertion_eq): Compare 'assertion_code' field.
614 (type_assertion_hash): Include 'assertion_code' in hash.
615 (add_type_assertion): Rewritten. Take class and assertion_code
616 arguments. Add assertions to the TYPE_ASSERTIONS hashtable.
617 (can_widen_reference_to): Use new add_type_assertion() arguments.
618 * java-tree.h (java_tree_index): Add JTI_ASSERTION_ENTRY_TYPE,
619 JTI_ASSERTION_TABLE_TYPE. Remove JTI_VERIFY_IDENTIFIER_NODE.
620 (verify_identifier_node): Removed.
621 (assertion_entry_type, assertion_table_type): New.
622 (ASSERTION_TYPES_COMPATIBLE, ASSERTION_IS_INSTANTIABLE): New. Type
623 assertion code definitions.
624 (struct type_assertion): Add assertion_code. Rename 'source_type' and
625 'target_type' to 'op1' and 'op2'.
626 (add_type_assertion): Declare.
627 (lang_printable_name_wls): Remove unused definition.
628 * verify-glue.c: (vfy_is_assignable_from): New. Call add_type_assertion
629 to emit runtime assertion.
630 (vfy_note_stack_type): Clean up non-C90 declarations.
631 (vfy_note_local_type): Likewise.
632 * verify.h (vfy_is_assignable_from): Declare.
633 * verify-impl.c (is_assignable_from_slow): Remove unused function.
634 (ref_compatible): Rename arguments. Call vfy_is_assignable_from()
635 instead of is_assignable_from_slow().
636 (types_compatible): Reinstate ref_compatible() call.
638 2004-11-04 Tom Tromey <tromey@redhat.com>
640 * class.c (build_static_field_ref): Reverted previous patch.
642 * class.c (build_static_field_ref): Don't emit direct references
643 when using indirect dispatch.
645 2004-11-03 Tom Tromey <tromey@redhat.com>
647 * expr.c (expand_java_arrayload): Set lhs_type_node.
648 (expand_java_arraystore): Set rhs_type_node.
650 2004-11-02 Tom Tromey <tromey@redhat.com>
652 * jcf-parse.c (compute_class_name): Use filename length from zip
653 directory, not strlen.
655 * expr.c (expand_invoke): Mark new interface methods as abstract.
657 2004-11-01 Tom Tromey <tromey@redhat.com>
659 * verify-impl.c (push_jump): Removed check for uninitialized
661 (push_exception_jump): Likewise.
662 (handle_ret_insn): Likewise.
663 (handle_jsr_insn): Likewise.
664 (state_check_no_uninitialized_objects): Removed.
666 * decl.c (check_local_unnamed_variable): Recognize
667 promoted-to-int parameters when using the new verifier.
668 * expr.c (expand_java_arraystore): Explicitly request array type
669 when using new verifier.
670 (expand_java_arrayload): Likewise.
671 (invoke_build_dtable): Don't pass object_type_node as
672 expression argument to build_java_indirect_ref.
673 (build_java_check_indexed_type): Do nothing.
674 (build_java_arraystore_check): Handle case where array doesn't
676 (build_java_array_length_access): Likewise.
677 (expand_invoke): Handle case where interface overrides a method
679 (pop_type_0): Always succeed for reference types.
680 (process_jvm_instruction): Don't pop a value in a dead
682 (pop_arguments): Convert arguments to correct types.
684 2004-10-29 Andrew Haley <aph@redhat.com>
686 * jcf-parse.c (give_name_to_class): Remove line that was
689 2004-10-29 Andrew Haley <aph@redhat.com>
691 * jcf-parse.c (set_source_filename): Add code to build new sfname.
693 2004-10-20 Andrew Haley <aph@redhat.com>
695 * decl.c (end_java_method): Don't expand if flag_syntax_only.
697 2004-10-26 Tom Tromey <tromey@redhat.com>
699 * verify.h (vfy_notify_verified): Removed.
700 * verify-glue.c (vfy_notify_verified): Removed.
702 2004-10-26 Tom Tromey <tromey@redhat.com>
704 * verify-impl.c (debug_print_state): Declare `i' before code.
705 (merge_types): Modify `t' when it is null_type.
707 2004-10-26 Tom Tromey <tromey@redhat.com>
709 * verify-impl.c (type_print): Renamed from print. Now static and
711 (debug_print_state): Use type_print.
713 2004-10-25 Tom Tromey <tromey@redhat.com>
715 * expr.c (build_invokeinterface): Compute correct offset for
716 index into interface methods.
718 2004-10-20 Tom Tromey <tromey@redhat.com>
720 * java-tree.h (verify_jvm_instructions_new): Declare.
722 * jvspec.c (jvgenmain_spec): Remove -fnew-verifier from cc1
725 * verify-impl.c (verify_instructions): Correctly handle wide
727 * verify-glue.c (vfy_get_class_name): Use DECL_NAME.
728 (vfy_get_component_type): Strip pointer types.
729 (vfy_find_class): Use get_type_from_signature. Strip pointer
731 Include java-except.h.
733 2004-10-20 Bryce McKinlay <mckinlay@redhat.com>
735 * verify-impl.c (type_array_elementpop_raw, vfy_pop_type_t,
736 vfy_push_type_t, set_variable, add_new_state, merge_into,
737 handle_jsr_insn, branch_prepass, check_class_constant,
738 check_wide_constant, get_one_type, compute_static_types,
739 verify_instructions_0): Clean up C99 declarations after statements.
741 2004-10-20 Tom Tromey <tromey@redhat.com>
743 * verify-impl.c (merge_refs): Compare reference against iterator,
746 * verify-glue.c (vfy_tag): Mask off resolved flag.
748 2004-10-19 Tom Tromey <tromey@redhat.com>
750 * verify-impl.c (verify_instructions): Call vfy_note_local_type.
751 (init_state_with_stack): Initialize `this_type' in state.
752 (verify_method): Use debug_print.
753 * verify-glue.c (vfy_is_primitive): Removed debugging print.
754 (vfy_note_stack_depth): Reverted last patch.
755 (vfy_note_stack_type): Note pointer to Object, not Object.
756 (vfy_note_local_type): Likewise.
758 * verify.h (vfy_note_instruction_seen): Declare.
759 * verify-glue.c (verify_jvm_instructions_new): Set
760 BCODE_EXCEPTION_TARGET on target instruction.
761 (vfy_note_instruction_seen): New function.
762 * verify-impl.c (FLAG_INSN_SEEN): New define.
763 (verify_instructions_0): Set flag on instruction. Save state for
765 (verify_instructions): Call vfy_note_instruction_seen.
767 * verify-glue.c (vfy_note_stack_depth): Fix off-by-one error.
768 (verify_jvm_instructions_new): Call method_init_exceptions,
769 add_handler, and handle_nested_ranges.
770 * verify-impl.c (verify_method): Return 1 on success.
771 (verify_instructions_0): Save the state at PC=0.
773 * verify-impl.c (init_type_from_class): Set is_resolved and
774 ref_next on new ref_intersection.
775 (init_type_from_string): Likewise.
777 2004-10-15 Bryce McKinlay <mckinlay@redhat.com>
779 * expr.c (expand_bytecode): Use verify_jvm_instructions_new
780 if flag_new_verifier is set.
781 * java-tree.h (flag_new_verifier): Declare.
782 * lang.opt (fnew-verifier): New option.
783 * verify-impl.c: Work around namespace pollution by undef'ing
785 (struct verifier_context): Make 'bytecode' const.
786 (verify_fail_pc): Pass -1 PC argument to vfy_fail.
787 (types_compatible): For the BC-ABI, always consider reference types
789 (check_class_constant): Use vfr->current_class.
790 (check_constant): Likewise.
791 (check_wide_constant): Likewise.
792 (check_field_constant): Check for 'L' at start of type name.
793 (get_one_type): Return pointer instead of type. Set type result in
794 caller via passed type pointer.
795 (compute_argument_types): Update to use new get_one_type arguments.
796 (compute_return_type): Likewise.
797 (make_verifier_context): New. Allocate and initialize 'vfr'.
798 (free_verifier_context): New. Free 'vfr' and its contents.
799 (verify_method): Remove ATTRIBUTE_UNUSED. Call make_verifier_context
800 and free_verifier_context.
802 2004-10-15 Tom Tromey <tromey@redhat.com>
804 * verify-glue.c (vfy_note_local_type): Mark argument as unused.
805 * verify.h (vfy_fail): Fixed formatting.
807 * verify-impl.c (vfr): Fixed comment formatting.
808 (collapse_type): New function.
809 (verify_instructions): Notify compiler about type map.
810 * verify.h (vfy_note_stack_depth): Updated.
811 (vfy_note_stack_type): Likewise.
812 (vfy_note_local_type): Likewise.
813 (vfy_unsuitable_type, vfy_return_address_type, vfy_null_type):
815 * verify-glue.c (vfy_note_stack_depth): Correctly size type
816 state. Added `method' argument.
817 (vfy_note_stack_type): Renamed from vfy_note_type. Added `method'
819 (vfy_note_local_type): New function.
820 (vfy_unsuitable_type): Likewise.
821 (vfy_return_address_type): Likewise.
822 (vfy_null_type): Likewise.
824 * verify.h (VFY_IN_GCC): Removed.
825 (VFY_WANT_TYPEMAP): Removed.
826 * verify-impl.c (verify_instructions_0): Removed useless "\".
827 (struct state) <next>: Uncomment.
829 2004-10-13 Bryce McKinlay <mckinlay@redhat.com>
831 * verify-impl.c: Formatting fixes. Reformat C++-style comments to
834 2004-10-06 Bryce McKinlay <mckinlay@redhat.com>
836 * Make-lang.in (verify.o): Re-enabled this target.
837 * verify-glue.c (vfy_get_interface_count): Add ATTRIBUTE_UNUSED.
838 (vfy_get_interface): Likewise.
839 (verify_jvm_instructions_new): Renamed from verify_jvm_instructions.
840 * verify.h (verify_jvm_instructions_new): Declare.
841 * verify-impl.c (free_state): Temporarily comment out unused
844 2004-10-06 Tom Tromey <tromey@redhat.com>
846 * java-tree.h (JV_STATE_READ): New enum value.
848 2004-10-06 Bryce McKinlay <mckinlay@redhat.com>
850 * verify.h: New file.
852 2004-10-05 Bryce McKinlay <mckinlay@redhat.com>
854 * verify-impl.c, verify-glue.c, verify.h: New files.
855 * Make-lang.in: Add rules for verify-impl.o and verify-glue.o.
857 2004-09-24 Andrew Haley <aph@redhat.com>
859 * decl.c (check_local_unnamed_variable): Always use the PARM_DECL
860 for a slot if it's of pointer type.
862 2004-09-14 Tom Tromey <tromey@redhat.com>
864 * class.c (make_class_data): Correctly initialize "state" field.
865 Initialize "engine" field.
866 * decl.c (java_init_decl_processing): Add "engine" field.
868 2004-09-10 Andrew Haley <aph@redhat.com>
871 * expr.c (build_invokeinterface): Use fast method for interface
873 * java-tree.h (enum java_tree_index): Add JTI_ITABLE_TYPE,
875 (struct lang_type): Add itable_methods, itable_decl, itable_syms_decl.
876 (emit_symbol_table): Add new arg, element_size.
877 * decl.c (java_init_decl_processing): Initialize Class.itable.
878 * class.c (GEN_TABLE): New macro.
879 (gen_indirect_dispatch_tables): Use it. Add itable.
880 (make_class_data): Add new arg for emit_symbol_table().
882 (add_miranda_methods): Make sure search_class has been parsed.
883 (emit_symbol_table): Add new arg, element_size.
885 2004-09-06 Andrew Haley <aph@redhat.com>
887 * verify.c (merge_types): Return Object for all merges of
889 * expr.c (add_type_assertion): Don't generate assertions when
890 source type is array of Object.
892 2004-09-03 Andrew Haley <aph@redhat.com>
894 * class.c (finish_class): Nullify TYPE_VERIFY_METHOD.
896 * lang.c (java_post_options): Force flag_verify_invocations if
897 we're not using indirect dispatch.
899 * expr.c (pop_type_0): Move test for interfaces before call to
900 can_widen_reference_to().
901 (build_signature_for_libgcj): Remove generation of canonical array
903 (add_type_assertion): Canonicalize both arrays.
904 Don't assert that type X can be assigned to Object.
905 Don't assert that type X an be assigned to type X.
906 Don't assert that Object can be assigned to type X.
907 (can_widen_reference_to): Warn whenever we generate an assertion.
908 (process_jvm_instruction): Use throwable_type_node for the type of
911 2004-09-01 Andrew Haley <aph@redhat.com>
913 * decl.c (java_init_decl_processing): Change
914 verify_identifier_node to "__verify".
915 * expr.c (add_type_assertion): Use verify_identifier_node for name.
916 * java-tree.h (verify_identifier_node): Change to "__verify".
918 * expr.c (build_signature_for_libgcj): New function.
919 (add_type_assertion): Use it to construct signatures for
920 source_type and target_type.
922 2004-08-27 Andrew Haley <aph@redhat.com>
924 * java-tree.h (enum java_tree_index): Add JTI_VERIFY_IDENTIFIER_NODE.
925 (verify_identifier_node): New.
926 (TYPE_VERIFY_METHOD): New.
927 (struct type_assertion): New type.
928 * expr.c (type_assertion_eq): New function.
929 (type_assertion_hash): New function.
930 (add_type_assertion): New function.
931 (can_widen_reference_to): Call add_type_assertion().
932 * decl.c (java_init_decl_processing): Add verify_identifier_node.
933 * class.c (make_class_data): Initialize TYPE_VERIFY_METHOD (type).
934 (finish_class): Output TYPE_VERIFY_METHOD (type).
936 * decl.c (end_java_method): Nullify unused fields.
938 2004-08-17 Andrew Haley <aph@redhat.com>
940 * verify.c (defer_merging): Quieten.
941 * jcf-parse.c (load_class): Only try to open a class file if it's
942 java.lang.Object or if it's part of the current compilation.
943 Check that the class we just tried to load is the class we just
945 (java_parse_file): Set flag_verify_invocations off if we're
946 compiling from .class.
947 (parse_zip_file_entries): Abort if we try to read a dummy class.
948 * expr.c (can_widen_reference_to): Quieten.
949 (build_invokevirtual): Abort if we try to invokevirtual an
951 (expand_invoke): Don't build a non-interface call to an interface.
952 (build_instanceof): Don't do premature optimization if
953 flag_verify_invocations is not set.
954 * class.c (set_super_info): Disable code that inherits TYPE_DUMMY
956 (build_static_field_ref): Add correct type conversion for
958 (add_miranda_methods): Disable generation of Miranda methods for
960 (layout_class_method): Don't complain about non-static method
961 overrides static method with dummy classes.
963 2004-08-13 Tom Tromey <tromey@redhat.com>
965 * class.c (build_static_field_ref): Re-enable atable lookups for
968 * parse.y (strip_out_static_field_access_decl): Indentation fix.
970 2004-08-11 Tom Tromey <tromey@redhat.com>
972 * gcj.texi (libgcj Runtime Properties): Document new properties.
974 2004-08-06 Andrew Haley <aph@redhat.com>
976 * jcf-parse.c (load_class): Check that we really have loaded the
977 class we're looking for.
979 2004-07-19 Andrew Haley <aph@redhat.com>
981 * verify.c (verify_jvm_instructions): Comment change only.
983 * typeck.c (build_java_array_type): Add size field to array name.
985 * java-tree.h (LOCAL_SLOT_P): New.
986 (update_aliases): Add PC argument.
987 (pushdecl_function_level): New function.
989 * java-gimplify.c (java_gimplify_expr): Handle VAR_DECL,
990 MODIFY_EXPR, and SAVE_EXPR.
991 (java_gimplify_modify_expr): New function.
993 * expr.c (push_type_0): Call find_stack_slot() to create temporary.
994 (expand_iinc): Pass PC to update_aliases().
995 (STORE_INTERNAL): Likewise.
996 (process_jvm_instruction): Likewise.
998 * decl.c (base_decl_map): New variable.
999 (uniq): New variable.
1000 (update_aliases): Rewrite with more thorough checking.
1001 (debug_variable_p): New function.
1002 (push_jvm_slot): Don't initialize local variable. Don't pushdecl.
1003 (check_local_named_variable): Delete whole function.
1004 (initialize_local_variable): New function.
1005 (check_local_unnamed_variable): Add checks and comments.
1006 (find_local_variable): Rewrite.
1007 (java_replace_reference): New function.
1008 (function_binding_level): New variable.
1009 (pushdecl_function_level): New function.
1010 (maybe_pushlevels): Set DECL_LOCAL_END_PC.
1011 (maybe_pushlevels): Call pushdecl() on each of the new decls.
1012 (start_java_method): Reset uniq. Create base_decl_map. Set
1013 function_binding_level.
1014 (end_java_method): Null unused fields to save memory.
1016 2004-06-29 Andrew Haley <aph@redhat.com>
1018 * except.c (expand_start_java_handler): Push a new binding level.
1019 Don't build a TRY_CATCH_EXPR now, we'll do it later. Call
1020 register_exception_range() to register where we'll do it.
1021 (expand_end_java_handler): Remove old bogus code. Replace with
1022 new logic that simply builds TRY_CATCH_EXPRs and inserts them at
1023 the top of the expression we're curently building.
1024 (maybe_end_try): Delete.
1025 * decl.c (binding_level.exception_range): New field.
1026 (clear_binding_level): Add field exception_range. Reformat.
1027 (poplevel): Call expand_end_java_handler().
1028 (poplevel): Call java_add_stmt only if functionbody is false.
1029 (maybe_poplevels): Don't call maybe_end_try() from here.
1030 (end_java_method): Clear no longer used trees in function decl.
1031 (register_exception_range): New function.
1032 * java-tree.h (register_exception_range, struct eh_range): Declare.
1034 2004-06-22 Andrew Haley <aph@redhat.com>
1036 * class.c (gen_indirect_dispatch_tables): Set the DECL_OWNER of
1038 * check-init.c (get_variable_decl): Teach check-init about
1039 FIELD_DECLs addressed via the otable.
1040 * jcf-parse.c (load_class): Check CLASS_LOADED_P, not
1043 2004-05-28 Andrew Haley <aph@redhat.com>
1045 * jcf-parse.c (load_class): Don't try to read a class that we've
1048 * expr.c (build_invokeinterface): Use the old-fashioned way of
1049 doing indirect dispatch: look up interfaces by name.
1050 * java-tree.h (enum java_tree_index): Add
1051 JTI_SOFT_LOOKUPINTERFACEMETHODBYNAME_NODE
1052 * decl.c (java_init_decl_processing): Add
1053 soft_lookupinterfacemethodbyname_node.
1055 * gjavah.c (print_method_info): Final methods have vtable entries,
1056 so gjavah needs to output them.
1057 * class.c (layout_class_method): Generate vtable entries for final
1059 * parse.y (invocation_mode): Use INVOKE_VIRTUAL for indirect
1060 dispatch, even if a method is final.
1062 2004-05-25 Andrew Haley <aph@redhat.com>
1064 * class.c (build_symbol_entry): Convert the names of constructors
1065 to init_identifier_node when generating an entry for the indirect
1068 * expr.c (build_known_method_ref): Generate indirect calls for
1069 all methods marked DECL_EXTERNAL or TREE_PUBLIC.
1071 2004-05-24 Andrew Haley <aph@redhat.com>
1073 * expr.c (build_known_method_ref): Make sure ARRAY_REF access to
1074 atable element is of the right type.
1076 * class.c (build_static_field_ref): Cast pointer to correct type
1079 2004-04-20 Bryce McKinlay <mckinlay@redhat.com>
1081 * Merged with HEAD as of 20040514. Diff against
1082 gcj-abi-2-merge-20040514.
1084 2004-04-16 Andrew Haley <aph@redhat.com>
1086 * verify.c (check_pending_block): Disable subroutine checks.
1087 (defer_merging): New function.
1088 (merge_types): If types are dummy, use defer_merging to combine them.
1089 (verify_jvm_instructions): If invocation is invokeinterface and
1090 target is dummy, assume target really is an interface.
1092 * parse.y (patch_invoke): Break out call to java_create_object.
1094 * lang.c (flag_verify_invocations): New.
1096 * jcf-parse.c (load_class): If we've already failed to load a
1097 class, don't try again.
1098 (load_class): If we can't find a .class file, don't fail, but emit
1100 (parse_class_file): Don't act on dummy methods.
1102 * java-tree.h (flag_verify_invocations): New.
1104 (lang_type.dummy_class): New field.
1105 (java_create_object): New function.
1106 (METHOD_DUMMY): New.
1108 * expr.c (build_field_ref): Widen field offset.
1109 (pop_type_0): If the type in stack_type_map is a TREE_LIST, check
1110 that each of its elements is compatible with the one we're
1112 (pop_type_0): Issue a warning to say that we need to generate a
1114 (java_create_object): New function.
1115 (build_field_ref): Only generate hard refs if we're not using
1117 (expand_java_field_op): If we're using !verify_invocations and we
1118 see a missing field, generate a decl for it.
1120 (expand_invoke): If a class doesn't have the method we seek and
1121 we're using !flag_verify_invocations, generate a decl for the
1124 (build_known_method_ref): Always use indirect dispatch via the
1125 atable for static methods.
1127 (expand_java_NEW): Break out object creation into new function,
1130 (can_widen_reference_to): Issue a warning to say that we need to
1131 generate a runtime check.
1133 * class.c (set_super_info): Inherit TYPE_DUMMY from sureclass.
1134 (make_method_value): Also use index for interfaces.
1135 (make_class_data): Skip dummy field for inherited data.
1136 Don't build method array for dummy methods.
1137 Set size_in_byte to -1 when using inirect dispatch
1138 Don't build a hard class ref if we don't have a hard ref to our
1139 superclass, or if we're using inirect dispatch.
1140 Null out dispatch tables.
1142 (layout_class_method): Don't complain about non-static method
1143 overrides static method is method is artificial.
1145 (build_static_field_ref): Disable atable references to static
1146 fields for the time being.
1148 (layout_class_methods): Check for CLASS_INTERFACE as
1149 well as CLASS_ABSTRACT.
1151 2004-11-24 Steven Bosscher <stevenb@suse.de>
1153 * class.c (make_class_data): Don't check flag_inline_functions.
1154 * lang.c (flag_really_inline): Remove unused flag.
1155 (java_handle_option): Don't set it here. Remove special handling
1156 of flag_inline_functions for Java.
1157 (java_init): Don't set flag_inline_trees here. Already done...
1158 (java_post_options): ...here. Don't clear flag_inline_functions.
1160 2004-11-24 Steven Bosscher <stevenb@suse.de>
1162 * java-gimplify.c (java_gimplify_labeled_block_expr): New function.
1163 (java_gimplify_exit_block_expr): New function.
1164 (java_gimplify_expr): Use them to gimplify EXIT_BLOCK_EXPR and
1166 * java-tree.def (LABELED_BLOCK_EXPR): Moved from tree.def.
1167 (EXIT_BLOCK_EXPR): Likewise.
1168 * java-tree.h (LABELED_BLOCK_LABEL): Moved from tree.h.
1169 (LABELED_BLOCK_BODY): Likewise.
1170 (EXIT_BLOCK_LABELED_BLOCK): Likewise.
1171 * jcf-write.c (generate_bytecode_insns): Don't handle the unused
1172 EXIT_BLOCK_RETURN operand. Use EXIT_BLOCK_LABELED_BLOCK instead of
1174 * lang.c (java_tree_inlining_walk_subtrees): Handle EXIT_BLOCK_EXPR.
1175 (java_dump_tree): Use LABELED_BLOCK_LABEL, LABELED_BLOCK_BODY, and
1176 EXIT_BLOCK_LABELED_BLOCK instead of TREE_OPERAND. Don't handle the
1177 second operand of EXIT_BLOCK_EXPR.
1178 * parse.y (find_expr_with_wfl): Use LABELED_BLOCK_BODY instead of
1180 (build_bc_statement): Use build1 to build EXIT_BLOCK_EXPR nodes.
1182 2004-11-23 Ben Elliston <bje@au.ibm.com>
1184 * xref.h (xref_flag_value): Remove.
1185 (xref_set_data, xref_get_data): Likewise.
1186 (xref_set_current_fp): Likewise.
1187 (XREF_NONE): Likewise.
1188 (XREF_GET_DATA): Likewise.
1189 * xref.c (xref_flag_value): Remove.
1190 (xref_set_data, xref_get_data): Likewise.
1191 (xref_set_current_fp): Likewise.
1193 2004-11-23 Ben Elliston <bje@au.ibm.com>
1195 * gjavah.c (output_directory): Make static.
1196 (temp_directory): Likewise.
1198 2004-11-15 Tom Tromey <tromey@redhat.com>
1200 * decl.c (instn_ptr_type_node): Removed.
1201 (lineNumbers_ptr_type_node): Removed.
1202 (jint_type): Removed.
1203 (jint_ptr_type): Removed.
1205 2004-11-09 Andrew Pinski <pinskia@physics.uc.edu>
1208 * check-init.c (check_init): Ignore DECL_EXPR.
1209 * expr.c (always_initialize_class_p): Reenable.
1210 (build_class_init): Use a variable to store the decl. Also use
1211 boolean_false_node instead of integer_zero_node.
1212 * parse.y (attach_init_test_initialization_flags): Add a decl_expr
1215 2004-11-08 Tom Tromey <tromey@redhat.com>
1218 * gjavah.c (HANDLE_END_FIELD): Call print_field_info when
1219 generating a JNI header.
1220 (print_field_info): Handle JNI headers.
1221 (jni_print_float): Likewise.
1222 (jni_print_double): Likewise.
1224 2004-11-08 Andrew Pinski <pinskia@physics.uc.edu>
1226 * decl.c (end_java_method): Remove duplicated code.
1228 2004-11-06 Zack Weinberg <zack@codesourcery.com>
1229 Gerald Pfeifer <gerald@pfeifer.com>
1231 * lex.h (HAVE_ICONV): Undefine if we do not have HAVE_ICONV_H
1234 2004-11-02 Bryce McKinlay <mckinlay@redhat.com>
1237 * class.c: Reinstate 2004-08-18 patch.
1238 (make_local_function_alias): Don't create an alias for extern (native)
1241 2004-10-22 Eric Botcazou <ebotcazou@libertysurf.fr>
1244 * class.c (make_local_function_alias): Revert 2004-08-18 change.
1245 (make_method_value): Likewise.
1247 2004-10-21 Andrew Haley <aph@redhat.com>
1250 * jcf-parse.c (set_source_filename): Add code to build new sfname.
1252 2004-10-20 Andrew Haley <aph@redhat.com>
1254 * decl.c (end_java_method): Don't expand if flag_syntax_only.
1255 Remove duplicated code block.
1257 2004-10-18 Steven Bosscher <stevenb@suse.de>
1259 * Make-lang.in (java/parse.o-warn, java/parse-scan.o-warn):
1260 New rules to work around old Bison warnings.
1262 2004-10-17 Steven Bosscher <stevenb@suse.de>
1264 * class.c (ident_subst): Always alloca buffer.
1265 * java-opcodes.h (LAST_AND_UNUSED_JAVA_OPCODE): Add this dummy
1266 opcode after including javaop.def.
1267 * jcf-dump.c (CHECK_PC_IN_RANGE): Return 0 from the arm of the
1268 conditional expression that exits, to avoid warnings.
1269 * verify.c (CHECK_PC_IN_RANGE): Mark the __GNUC__ definition as
1270 a user of an extension.
1271 * win32-host.c: Move check down to have non-empty file when
1272 WIN32 is not defined.
1274 * Make-lang.in (java-warn): Add STRICT_WARN.
1275 (java/jcf-io.o-warn): Don't have Werror for this file.
1276 * jcf-io.c (caching_stat): Add FIXME for non-POSIX scandir use.
1278 2004-10-16 Hans-Peter Nilsson <hp@bitrange.com>
1280 * expr.c (expr_add_location): Move declaration to before all
1282 * parse.y (java_expand_classes): Ditto.
1283 * lex.c (java_peek_unicode): Ditto.
1285 2004-10-16 Ranjit Mathew <rmathew@hotmail.com>
1287 * check-init.c: Use %<, %> and %q for quoting in diagnostics,
1288 if possible, else convert `foo' to 'foo'.
1289 * class.c: Likewise.
1292 * jcf-io.c: Likewise.
1293 * jcf-parse.c: Likewise.
1296 * parse.h: Likewise.
1298 2004-10-16 Ranjit Mathew <rmathew@hotmail.com>
1300 * parse.y (parse_warning_context): Remove ATTRIBUTE_PRINTF_2 and
1301 rename parameter 'msg' to 'msgid' in function declaration.
1302 (issue_warning_error_from_context): Likewise.
1303 (yyerror): Rename parameter 'msg' to 'msgid'.
1304 (all over): Use new quoting style for diagnostics.
1306 2004-10-15 Kazu Hirata <kazu@cs.umass.edu>
1308 * boehm.c, builtins.c, java-except.h, jcf-io.c, jcf-path.c,
1309 jcf.h, lang-specs.h, lex.c, lex.h, resource.c, win32-host.c:
1312 2004-10-14 Matt Austern <austern@apple.com>
1314 * lang.c (java_tree_inlining_walk_subtrees): Last arg is struct
1317 2004-10-13 Tom Tromey <tromey@redhat.com>
1320 * lang.opt (--extdirs): Document.
1321 * jvspec.c (lang_specific_driver): Recognize -encoding and
1324 2004-10-06 Ulrich Weigand <uweigand@de.ibm.com>
1326 * parse.y (issue_warning_error_from_context): Use va_list *
1327 instead of va_list parameter.
1328 (parse_error_context): Update call.
1329 (parse_warning_context): Likewise.
1331 2004-10-05 Zack Weinberg <zack@codesourcery.com>
1333 * parse.y, parse-scan.y: Add list of diagnostic messages to
1334 insulate translation template from version of yacc/bison used
1335 to compile the grammar.
1337 2004-10-05 Ranjit Mathew <rmathew@hotmail.com>
1339 Prepare for %q, %< and %> in diagnostic message strings.
1340 * java-tree.h (parse_error_context): remove ATTRIBUTE_PRINTF_2.
1341 Name second parameter 'msgid'.
1342 * parse.y: Additionally include pretty-print.h and diagnostic.h.
1343 (issue_warning_error_from_context): Use pretty-printer functions
1344 instead of vsprintf for constructing formatted messages. Rename
1345 parameter 'msg' to 'msgid'.
1346 (parse_error_context): Rename parameter 'msg' to 'msgid'.
1347 (parse_warning_context): Likewise.
1349 2004-10-05 Andrew Haley <aph@redhat.com>
1352 * jcf-parse.c (parse_zip_file_entries): If a class has a
1353 superclass and a TYPE_SIZE of zero, lay it out.
1355 2004-09-30 Andrew Haley <aph@redhat.com>
1358 * jcf-parse.c (compute_class_name): Rewrite.
1360 2004-10-01 Jan Hubicka <jh@suse.cz>
1362 * java.c (java_expand_body): Update call of tree_rest_of_compilation.
1364 2004-10-01 Kazu Hirata <kazu@cs.umass.edu>
1366 * lex.c: Fix a comment typo.
1368 2004-10-01 Kazu Hirata <kazu@cs.umass.edu>
1370 * java-tree.h: Fix a comment typo.
1372 2004-09-30 Per Bothner <per@bothner.com>
1374 Simplify lexer. Implement --enable-mapped-location support.
1375 * jcf-parse.c (parse_class_file): Use linemap_line_start.
1376 (parse_source_file_1): Pass filename as extra parameter, so we can call
1377 linemap_add and set input_location here, rather than in both callers.
1378 (read_class): Pass copied filename to parse_source_file_1.
1379 Don't initialize wfl_operator - only needed for source compilation.
1380 (read_class, jcf_parse): Call linemap_add with LC_LEAVE.
1381 * lex.h: Remove a bunch of debugging macros.
1382 * lex.h (struct_java_line, struct java_error): Remove types.
1383 (JAVA_COLUMN_DELTA): Remove - use java_lexer.next_colums instead.
1384 (struct java_lc_s): Remove prev_col field.
1385 (struct java_lexer): New fields next_unicode, next_columns, and
1386 avail_unicode. New position field, and maybe token_start field.
1387 Don't need hit_eof field - use next_unicode == -1 instead.
1388 (JAVA_INTEGERAL_RANGE_ERROR): Rename to JAVA_RANGE_ERROR.
1389 (JAVA_RANGE_ERROR, JAVA_FLOAT_ANGE_ERROR): Update accordingly.
1390 * parse.h: Various changes for USE_MAPPED_LOCATION.
1391 (EXPR_WFL_EMIT_LINE_NOTE): XXX
1392 (BUILD_EXPR_WFL, EXPR_WFL_ADD_COL): Remove no-longer-used macros.
1393 (struct parser_ctxt): New file_start_location field.
1394 Remove p_line, c_line fields since we no longer save lines.
1395 Remove elc, lineno, and current_jcf fields - no longer used.
1396 * parse.y: Updates for USE_MAPPED_LOCATION and new lexer.
1397 Don't use EXPR_WFL_ADD_COL since that isn't trivial with
1398 source_location and is probably not needed anymore anyway.
1399 Use new expr_add_Location function.
1400 (SET_EXPR_LOCATION_FROM_TOKEN): New convenience macro.
1401 (java_pop_parser_context): Minor cleanup.
1402 (java_parser_context_save_global, java_parser_context_restore_global,
1403 java_pop_parser_context): Save/restore input_location as a unit.
1404 (issue_warning_error_from_context): If USE_MAPPED_LOCATION take
1405 a source_location instead of a wfl context node.
1406 (check_class_interface_creation): input_filename is not addressable.
1407 (create_artificial_method): Calling java_parser_context_save_global
1408 and java_parser_context_restore_global is overkill. Instead,
1409 temporarily set input_location from class decl.
1410 (java_layout_seen_class_methods): Set input_location from method decl.
1411 (fix_constructors): Make more robust if no EXPR_WITH_FILE_LOCATION.
1412 (finish_loop_body): Likewise.
1413 * lex.c: Updates for USE_MAPPED_LOCATION. Use build_unknwon_wfl.
1414 (java_sprint_unicode): Take a character, not index in line.
1415 (java_sneak_uncode): Replaced by java_peek_unicode.
1416 (java_unget_unicode): No longer used.
1417 (java_allocate_new_line. java_store_unicode): Removed, since we
1418 no longer remember "lines".
1419 (java_new_lexer): Update for new data structures.
1420 (java_read_char): Move unget_value checking to java_read_unicode.
1421 (java_get_unicode, java_peek_unicode, java_next_unicode): New more
1422 efficient functions that are used directly when lexing.
1423 (java_read_unicode_collapsing_terminators): No longer needed.
1424 (java_parse_end_comment, java_parse_escape_sequence, do_java_lex):
1425 Re-organize to use java_peek_unicode to avoid java_unget_unicode.
1426 (java_parse_escape_sequence): Rewrite to be simpler / more efficient.
1427 (do_java_lex): Lots of movings around to avoid java_unget_unicode,
1428 combine switch branches, and test for common token kinds earlier.
1429 (java_lex_error): Rewrite.
1430 * jv-scan.c (expand_location): New function, copied from tree.c.
1431 (main): Set ctxp->filename instead of setting input_filename directly.
1433 2004-09-30 Per Bothner <per@bothner.com>
1435 More cleanup for --enable-mapped-location.
1436 * class.c (push_class): If USE_MAPPED_LOCATION don't set
1437 input_location here. Instead do it in give_name_to_class.
1438 (build_class_ref): Set DECL_ARTIFICIAL, for the sake of dwarf2out.
1439 * expr.c (expand_byte_code): Call linemap_line_start.
1440 * expr.c (build_expr_wfl): If USE_MAPPED_LOCATION, change final
1441 parameters to a source_location. Don't need EXPR_WFL_FILENAME_NODE.
1442 (expr_add_location): New function, if USE_MAPPED_LOCATION.
1443 * class.c (maybe_layout_super_class): Adjust build_expr_wfl call
1444 to USE_MAPPED_LOCATION case.
1446 * java-tree.h (JAVA_FILE_P, ZIP_FILE_P): Remove unused macros.
1447 * jcf-parse.c (java_parse_file): Don't set input_filename.
1448 Use IS_A_COMMAND_LINE_FILENAME_P to check for duplicate filenames.
1449 Create a list of TRANSLATION_UNIT_DECL.
1450 (current_file_list): Is now a TRANSLATION_UNIT_DECL chain. The
1451 reason is so we can set a DECL_SOURCE_LOCATION for each file.
1452 (java_parse_file): Don't set unused ZIP_FILE_P, JAVA_FILE_P..
1453 Create line-map LC_ENTER/LC_LEAVE entries for archive itself.
1454 (file_start_location): New static.
1455 (set_source_filename): Avoid extra access to input_filename macro.
1456 Concatenate new name with class's package prefix.
1457 (set_source_filename, give_name_to_class): Update.
1458 (give_name_to_class): Set class's "line 0" input_location here.
1459 (parse_class_file): Set input_location as a unit.
1461 * jcf-parse.c (load_class): Sanity test if missing inner class file.
1463 2004-09-29 Per Bothner <per@bothner.com>
1465 * java-tree.h: Redefine some macros and add some declaration
1466 to handle the USE_MAPPED_LOCATION case.
1467 * parse.h (EXPR_WFL_QUALIFICATION): Use operand 1, not 2.
1468 * java-tree.h (EXPR_WFL_FILENAME_NODE): Use operand 2, not 1.
1469 * java-tree.def (EXPR_WITH_FILE_LOCATION): Only need two operands in
1470 USE_MAPPED_LOCATION case, since EXPR_WFL_FILENAME_NODE is gone.
1472 * check-init.c (check_init): Handle USE_MAPPED_LOCATION case.
1473 * decl.c (finish_method, java_add_stmt): Likewise.
1474 * java-gimplify.c (java-gimplify.c): Likewise.
1475 * jcf-write.c (generate_bytecode_insns): Likewise.
1476 * lang.c (java_post_options): Likewise - call linemap_add.
1478 2004-09-29 Andrew Haley <aph@redhat.com>
1481 * parse.y (patch_binop): Don't mess with the TREE_SIDE_EFFECTS of the
1482 result of TRUNC_MOD_EXPR.
1483 (patch_unaryop): Likewise for CONVERT_EXPR, which may throw.
1484 * decl.c (java_init_decl_processing): Mark
1485 soft_lookupinterfacemethod_node and soft_instanceof_node pure.
1487 2004-09-28 Tom Tromey <tromey@redhat.com>
1490 * class.c (add_miranda_methods): Load superinterface if not
1493 2004-09-28 Andrew Haley <aph@redhat.com>
1496 * jcf-parse.c (load_class): Don't try to read a class that we've
1499 2004-09-28 Andrew Haley <aph@redhat.com>
1501 * jcf-parse.c (load_class): Back out previous broken patch.
1503 2004-09-28 Andrew Haley <aph@redhat.com>
1506 * jcf-parse.c (load_class): Don't try to read a class that we've
1508 Check that we really did read the right class.
1510 2004-09-25 Tom Tromey <tromey@redhat.com>
1513 * parse.y (create_artificial_method): Use add_method_1.
1515 2004-09-25 Kazu Hirata <kazu@cs.umass.edu>
1517 * expr.c, jcf-dump.c, parse-scan.y, parse.y: Fix
1519 * gcj.texi: Fix typos.
1521 2004-09-24 Tom Tromey <tromey@redhat.com>
1524 * parse.y (class_instance_creation_expression): Set `$$' to NULL
1525 in error parts of rule.
1526 (unary_expression): Don't call error_if_numeric_overflow when $1
1529 2004-09-24 Tom Tromey <tromey@redhat.com>
1532 * parse.y (resolve_qualified_expression_name): Set
1533 CAN_COMPLETE_NORMALLY on first call when chaining static calls.
1534 * expr.c (force_evaluation_order): Check for empty argument list
1535 after stripping COMPOUND_EXPR.
1537 2004-09-23 Andrew Haley <aph@redhat.com>
1540 * parse.y (java_complete_lhs): Call patch_string() on Operand 1 of
1543 2004-09-23 Tom Tromey <tromey@redhat.com>
1546 * java-gimplify.c (java_gimplify_expr) <SAVE_EXPR>: Ignore case
1547 where operand is null.
1549 2004-09-23 Tom Tromey <tromey@redhat.com>
1552 * parse.y (not_accessible_p): Allow access to protected members
1553 even when class is not static.
1555 2004-09-22 Kelley Cook <kcook@gcc.gnu.org>
1557 * Make-lang.in: Revert the gcc-none.o change.
1559 2004-09-22 Nathan Sidwell <nathan@codesourcery.com>
1561 * parse.y (patch_anonymous_class): VEC_space returns true if there
1564 2004-09-21 Matt Austern <austern@apple.com>
1567 * gjavah.c (free_method_name_list): Fix function definition so
1568 it's a proper C prototype.
1570 2004-09-21 Tom Tromey <tromey@redhat.com>
1573 * gjavah.c (free_method_name_list): New method.
1576 2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
1577 Zack Weinberg <zack@codesourcery.com>
1579 * java-tree.def: Use tree_code_class enumeration constants
1580 instead of code letters.
1581 * java-gimplify.c, jcf-write.c, lang.c, parse.y: Update for
1582 new tree-class enumeration constants.
1584 2004-09-13 Tom Tromey <tromey@redhat.com>
1587 * class.c (layout_class_method): Put synthetic methods into the
1590 2004-09-11 Andrew Pinski <apinski@apple.com>
1592 * Make-lang.in (java/ggc-none.c): Change dependency
1593 for ggc.h into $(GGC_H).
1595 2004-09-11 Mohan Embar <gnustuff@thisiscool.com>
1597 * Make-lang.in (java/win32-host.o): Add dependency on
1599 * win32-host.c: Add includes for coretypes.h, jcf.h
1601 2004-09-11 Mohan Embar <gnustuff@thisiscool.com>
1603 * Make-lang.in (GCJH_OBJS): Change dependency from
1604 ggc-none.o to java/ggc-none.o
1605 (JCFDUMP_OBJS): Likewise.
1606 (java/ggc-none.o): New target.
1608 2004-08-25 Nathan Sidwell <nathan@codesourcery.com>
1610 * boehm.c (get_boehm_type_descriptor): Adjust build_int_cst calls.
1611 * class.c (build_utf8_ref, build_static_field_ref,
1612 make_field_value, make_method_value, get_dispatch_table,
1613 make_class_data, emit_symbol_table, emit_catch_table): Likewise.
1614 * constants.c (get_tag_node, build_ref_from_constant_pool,
1615 build_constants_constructor): Likewise.
1616 * decl.c (java_init_decl_processing): Likewise.
1617 * expr.c (build_java_array_length_access, build_newarray,
1618 expand_java_multianewarray, expand_java_pushc, expand_iinc,
1619 build_java_binop, build_field_ref, expand_java_add_case,
1620 expand_java_call, build_known_method_ref, build_invokevirtual,
1621 build_invokeinterface, build_jni_stub): Likewise.
1622 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
1623 * jcf-parse.c (get_constant): Likewise.
1624 * lex.c (do_java_lex): Likewise.
1625 * parse.y (patch_binop, patch_unaryop, patch_cast,
1626 build_newarray_node, patch_newarray): Likewise.
1627 * resource.c (compile_resource_data): Likewise.
1628 * typeck.c (build_prim_array_type): Likewise.
1630 2004-08-24 Nathan Sidwell <nathan@codesourcery.com>
1632 * decl.c (java_init_decl_processing): Adjust
1633 initialize_sizetypes call.
1635 2004-08-23 Nathan Sidwell <nathan@codesourcery.com>
1637 * jv-scan.c (fancy_abort): Add.
1639 2004-08-20 Nathan Sidwell <nathan@codesourcery.com>
1641 * expr.c (build_java_arrayaccess): Use convert to change
1644 2004-08-19 Bryce McKinlay <mckinlay@redhat.com>
1646 * class.c (make_local_function_alias): Allocate extra space for 'L'
1647 in name buffer. Reported by Thomas Neumann.
1649 2004-08-19 Nathan Sidwell <nathan@codesourcery.com>
1651 * parse.h (JAVA_RADIX10_FLAG): Rename to ...
1652 (JAVA_NOT_RADIX10_FLAG): ... here. Invert meaning.
1653 * lex.c (do_java_lex): Adjust.
1654 (error_if_numeric_overflow): Likewise.
1656 2004-08-18 Andrew Pinski <apinski@apple.com>
1658 * class.c (make_local_function_alias): Only make a new decl if we
1659 support alias attribute on all decls.
1661 2004-08-18 Bryce McKinlay <mckinlay@redhat.com>
1663 * class.c (make_local_function_alias): New function. Create local
1664 alias for public method DECL.
1665 (make_method_value): Use make_local_function_alias.
1666 * parse.y (craft_constructor): Don't special-case anonymous classes.
1667 Always set ctor_name to init_identifier_node.
1668 (lookup_method_invoke): Call layout_class_method when creating
1669 anonymous class constructor.
1671 2004-08-18 Richard Henderson <rth@redhat.com>
1673 * java-gimplify.c (java_gimplify_expr): Move '2' handling into
1674 default case. Treat '<' similarly. Update for
1675 is_gimple_formal_tmp_var name change.
1677 2004-08-17 Andrew Haley <aph@redhat.com>
1679 * lang.c (lang_printable_name): Obey verbose flag.
1680 * parse.y (constructor_circularity_msg): Set VERBOSE arg for
1681 lang_printable_name().
1682 (verify_constructor_circularity, get_printable_method_name,
1683 check_abstract_method_definitions, java_check_regular_methods,
1684 java_check_abstract_methods, check_inner_class_access,
1685 fix_constructors, patch_method_invocation, patch_return):
1687 * expr.c (pop_type_0): Likewise.
1689 * java-tree.h (lang_printable_name_wls): Delete.
1691 2004-08-16 Tom Tromey <tromey@redhat.com>
1694 * parse.y (primary): Changed for initialized and uninitialized
1696 (array_access): Handle array_creation_initialized.
1697 (array_creation_expression): Split into
1698 array_creation_initialized and array_creation_uninitialized.
1700 2004-08-16 Andrew Haley <aph@redhat.com>
1702 * jcf-write.c (find_constant_index): Canonicalize NaNs when
1703 generating bytecode.
1705 2004-08-16 Elliot Lee <sopwith@redhat.com>
1708 * jcf-parse.c (java_parse_file): Handle filenames with embedded
1709 spaces, and quoted filelists.
1711 2004-08-15 Nathan Sidwell <nathan@codesourcery.com>
1713 * boehm.c (get_boehm_type_descriptor): Use build_int_cst.
1714 * class.c (build_utf8_ref, build_static_field_ref,
1715 make_field_value, make_method_value, get_dispatch_table,
1716 make_class_data, emit_symbol_table, emit_catch_table): Likewise.
1717 * constants.c (get_tag_node, build_ref_from_constant_pool,
1718 build_constants_constructor): Likewise.
1719 * decl.c (java_init_decl_processing): Likewise.
1720 * expr.c (build_java_array_length_access, build_newarray,
1721 expand_java_multianewarray, expand_java_pushc, expand_iinc,
1722 build_java_binop, build_field_ref, expand_java_add_case,
1723 expand_java_call, build_known_method_ref, build_invokevirtual,
1724 build_invokeinterface, build_jni_stub): Likewise.
1725 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
1726 * jcf-parse.c (get_constant): Likewise.
1727 * lex.c (do_java_lex): Likewise.
1728 * parse.y (patch_binop, patch_unaryop, patch_cast,
1729 build_null_of_type, patch_newarray): Likewise.
1730 * resource.c (compile_resource_data): Likewise.
1731 * typeck.c (build_prim_array_type): Likewise.
1733 2004-08-10 Bryce McKinlay <mckinlay@redhat.com>
1735 * java-gimplify.c (java_gimplify_new_array_init): Use create_tmp_var.
1736 Don't create BLOCK here or call java_gimplify_block.
1738 2004-08-09 H.J. Lu <hongjiu.lu@intel.com>
1740 * java-tree.h (flag_deprecated): Removed.
1741 * lang.opt (Wdeprecated): Use existing Var(warn_deprecated).
1742 * parse.y (check_deprecation): Check warn_deprecated instead of
1745 2004-08-06 Kelley Cook <kcook@gcc.gnu.org>
1747 * lang.c (flag_emit_class_files, flag_filelist_file, flag_redundant,
1748 flag_use_divide_subroutine, flag_use_boehm_gc, flag_store_check,
1749 flag_hash_synchronization, flag_assert, flag_jni, flag_newer,
1750 flag_check_references, flag_extraneous_semicolon, flag_deprecated,
1751 flag_force_classes_archive_check, flag_optimize_sci,
1752 flag_indirect_dispatch): Remove explicit declarations.
1753 * lang.opt: Add implicit declare/define/assign. Remove obsolete
1756 2004-08-05 Michael Chastain <mec.gnu@mindspring.com>
1759 * Make-lang.in (java.install-man): Install from either build
1760 tree or source tree, whichever has the file first.
1762 2004-08-05 Nathan Sidwell <nathan@codesourcery.com>
1764 * jcf-parse.c (get_constant): Adjust force_fit_type call.
1765 * lex.h (SET_LVAL_NODE_TYPE): Remove.
1766 * lex.c (java_perform_atof): Use SET_LVAL_NODE directly.
1767 (do_java_lex): Likewise. Adjust force_fit_type call.
1769 2004-08-04 Roger Sayle <roger@eyesopen.com>
1770 Andrew Haley <aph@redhat.com>
1772 * typeck.c (convert_ieee_real_to_integer): Call fold on the range
1773 checking trees as they're being built.
1774 (convert): Call convert_ieee_real_to_integer if we're
1775 converting a constant, even if we're writing a class file.
1777 2004-08-02 Bryce McKinlay <mckinlay@redhat.com>
1780 * parse.y (fold_constant_for_init): Call resolve_field_access with
1781 correct current_class context.
1783 2004-08-01 Roger Sayle <roger@eyesopen.com>
1785 * decl.c (update_aliases, initialize_local_variable): Replace calls
1786 to build with calls to buildN.
1787 * java-gimplify.c (java_gimplify_modify_expr): Likewise.
1788 * java-tree.h (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT): Likewise.
1789 * parse.h (BUILD_THROW): Likewise.
1790 * parse.y (switch_expression, synchronized_statement,
1791 catch_clause_parameter, array_creation_expression,
1792 conditional_expression, make_qualified_name,
1793 resolve_qualified_expression_name, patch_method_invocation,
1794 patch_invoke, build_method_invocation, build_new_invocation,
1795 build_assignment, patch_assignment, build_binop, patch_binop,
1796 build_string_concatenation, build_incdec, patch_unaryop,
1797 patch_cast, build_array_ref, build_newarray_node, patch_newarray,
1798 patch_return, build_if_else_statement, build_labeled_block,
1799 build_new_loop, build_loop_body, build_bc_statement,
1800 build_assertion, encapsulate_with_try_catch, build_try_statement,
1801 build_try_finally_statement, patch_synchronized_statement,
1802 emit_test_initialization): Likewise, replace build with buildN.
1804 2004-07-28 Eric Christopher <echristo@redhat.com>
1806 * lang.c (LANG_HOOKS_UNSAFE_FOR_REEVAL): Delete.
1807 (java_unsafe_for_reeval): Ditto.
1809 2004-07-26 <hp@bitrange.com>
1811 * parse.y (build_super_invocation): Adjust declaration order to
1812 avoid declaration after statement.
1814 2004-07-25 Bernardo Innocenti <bernie@develer.com>
1816 * decl.c: Rename all identifiers named `class' to `cl'.
1818 2004-07-25 Richard Henderson <rth@redhat.com>
1820 * decl.c (build_result_decl): Set DECL_ARTIFICIAL and DECL_IGNORED_P.
1822 2004-07-23 Mike Stump <mrs@apple.com>
1824 * boehm.c (set_bit): Improve type safety wrt unsignedness.
1825 * gjavah.c (throwable_p, decode_signature_piece,
1826 print_full_cxx_name, print_include, add_namelet, add_class_decl,
1827 process_file): Likewise.
1828 * jcf-dump.c (main): Likewise.
1829 * jcf-io.c (read_zip_member): Likewise.
1830 * jcf-parse.c (HANDLE_CONSTANT_Utf8, get_constant,
1831 give_name_to_class, get_class_constant): Likewise.
1832 * jcf-write.c (find_constant_wide, push_long_const,
1833 generate_classfile): Likewise.
1834 * lex.c (java_new_lexer, java_read_char, cxx_keyword_p): Likewise.
1835 * parse.y (read_import_dir): Likewise.
1836 * typeck.c (parse_signature_type): Likewise.
1837 * verify.c (verify_jvm_instructions): Likewise.
1838 * zextract.c (find_zip_file_start, read_zip_archive): Likewise.
1840 2004-07-23 Thomas Fitzsimmons <fitzsim@redhat.com>
1842 * Make-lang.in: Replace rmic and rmiregistry references with
1843 grmic and grmiregistry.
1844 * gcj.texi: Likewise.
1846 2004-07-20 Andrew Haley <aph@redhat.com>
1849 * verify.c (verify_jvm_instructions): Comment change only.
1851 * typeck.c (build_java_array_type): Add size field to array name.
1853 * java-tree.h (LOCAL_SLOT_P): New.
1854 (update_aliases): Add PC argument.
1855 (pushdecl_function_level): New function.
1857 * java-gimplify.c (java_gimplify_expr): Handle VAR_DECL,
1858 MODIFY_EXPR, and SAVE_EXPR.
1859 (java_gimplify_modify_expr): New function.
1861 * expr.c (push_type_0): Call find_stack_slot() to create temporary.
1862 (expand_iinc): Pass PC to update_aliases().
1863 (STORE_INTERNAL): Likewise.
1864 (process_jvm_instruction): Likewise.
1866 * decl.c (base_decl_map): New variable.
1867 (uniq): New variable.
1868 (update_aliases): Rewrite with more thorough checking.
1869 (debug_variable_p): New function.
1870 (push_jvm_slot): Don't initialize local variable. Don't pushdecl.
1871 (check_local_named_variable): Delete whole function.
1872 (initialize_local_variable): New function.
1873 (check_local_unnamed_variable): Add checks and comments.
1874 (find_local_variable): Rewrite.
1875 (java_replace_reference): New function.
1876 (function_binding_level): New variable.
1877 (pushdecl_function_level): New function.
1878 (maybe_pushlevels): Set DECL_LOCAL_END_PC.
1879 (maybe_pushlevels): Call pushdecl() on each of the new decls.
1880 (start_java_method): Reset uniq. Create base_decl_map. Set
1881 function_binding_level.
1882 (end_java_method): Null unused fields to save memory.
1884 2004-07-20 Nathan Sidwell <nathan@codesourcery.com>
1886 * class.c (add_interface_do): Remove.
1887 (set_super_info, interface_of_p, maybe_add_interface,
1888 add_interface, make_class_data, layout_class,
1889 add_miranda_methods): Adjust BINFO accessors and addition.
1890 * expr.c (can_widen_reference_to, lookup_field): Adjust BINFO
1892 * jcf-write.c (generate_classfile): Likewise.
1893 * parse.y (patch_anonymous_class, check_inner_circular_reference,
1894 check_circular_reference, java_complete_class,
1895 check_abstract_method_definitions,
1896 java_check_abstract_method_definitions,
1897 check_interface_throws_clauses, java_check_abstract_methods,
1898 lookup_java_interface_method2,
1899 find_applicable_accessible_methods_list): Adjust BINFO accessors
1901 * typeck.c (find_method_in_interfaces): Adjust BINFO accessors.
1903 2004-07-18 Roger Sayle <roger@eyesopen.com>
1905 * builtins.c (max_builtin, min_builtin,
1906 java_build_function_call_expr): Replace calls to build with buildN.
1907 * class.c (build_class_ref, build_static_field_ref,
1908 get_dispatch_table, make_class_data, layout_class_method): Likewise.
1909 * constants.c (build_ref_from_constant_pool): Likewise.
1910 * decl.c (update_aliases, push_jvm_slot, poplevel, finish_method,
1911 add_stmt_to_compound): Likewise.
1912 * except.c (build_exception_object_ref, expand_end_java_handler):
1914 * java-gimplify.c (java_gimplify_case_expr,
1915 java_gimplify_default_expr, java_gimplify_block,
1916 java_gimplify_new_array_init, java_gimplify_try_expr): Likewise.
1917 * jcf-write.c (generate_bytecode_insns): Likewise.
1918 * typeck.c (convert_ieee_real_to_integer): Likewise.
1920 2004-07-17 Joseph S. Myers <jsm@polyomino.org.uk>
1922 * java-tree.h (builtin_function): Declare.
1924 2004-07-16 Steven Bosscher <stevenb@suse.de>
1926 * parse.y (java_complete_expand_methods, java_expand_classes): Don't
1927 abuse restore_line_number_status.
1929 2004-07-15 Frank Ch. Eigler <fche@redhat.com>
1932 * jcf-parse.c (java_emit_static_constructor): Specify default
1935 2004-07-13 Per Bothner <per@bothner.com>
1937 * java-tree.h (all_class_filename): Remove useless macro.
1938 (enum java_tree_index): Remove JTI_ALL_CLASS_FILENAME constant.
1939 (BUILD_FILENAME_IDENTIFIER_NODE): Remove useless macro.
1940 * parse.y (java_parser_context_restore_global): Replace
1941 BUILD_FILENAME_IDENTIFIER_NODE by plain get_identifier.
1942 * jcf-parse.c (read_class, java_parse_file): Likewise.
1944 2004-07-12 Bryce McKinlay <mckinlay@redhat.com>
1947 gjavah.c (print_field_info): Emit constant only if field is static.
1949 2004-07-11 Roger Sayle <roger@eyesopen.com>
1951 * expr.c (java_truthvalue_conversion, flush_quick_stack,
1952 java_stack_swap, java_stack_dup, build_java_athrow, build_java_jsr,
1953 build_java_ret, build_java_throw_out_of_bounds_exception,
1954 build_java_array_length_access, java_check_reference,
1955 build_java_arrayaccess, build_java_arraystore_check, build_newarray,
1956 build_anewarray, expand_java_multianewarray, expand_java_arraystore,
1957 expand_java_arrayload, build_java_monitor, expand_java_return,
1958 expand_load_internal, expand_java_NEW, build_get_class,
1959 build_instanceof, expand_java_CHECKCAST, expand_iinc,
1960 build_java_soft_divmod, build_java_binop, build_field_ref,
1961 expand_compare, expand_java_goto, expand_java_switch,
1962 expand_java_add_case, build_class_init, build_known_method_ref,
1963 invoke_build_dtable, build_invokevirtual, build_invokeinterface,
1964 expand_invoke, build_jni_stub, expand_java_field_op,
1965 java_expand_expr, expand_byte_code, STORE_INTERNAL,
1966 force_evaluation_order, emit_init_test_initialization): Convert
1967 calls to "build" into calls to the prefered "buildN" functions.
1969 2004-07-11 Joseph S. Myers <jsm@polyomino.org.uk>
1971 * java-tree.h (set_block): Remove.
1972 * lang.c (java_clear_binding_stack): New.
1973 (LANG_HOOKS_CLEAR_BINDING_STACK): Define.
1974 * decl.c (struct binding_level): Remove this_block.
1975 (clear_binding_level): Likewise.
1976 (poplevel): Don't handle this_block.
1977 (set_block): Remove.
1979 2004-07-10 Bryce McKinlay <mckinlay@redhat.com>
1981 * class.c (common_enclosing_context_p): Remove statement with no
1984 2004-07-09 Bryce McKinlay <mckinlay@redhat.com>
1987 * parse.y (create_anonymous_class): Remove 'location' argument. Use
1988 the WFL from TYPE_NAME to get line number for the decl. Fix comment.
1989 (craft_constructor): Inherit access flags for implicit constructor
1990 from the enclosing class.
1991 (create_class): Fix comment typo.
1992 (resolve_qualified_expression_name): Pass type of qualifier to
1993 not_accessible_p, not the type in which target field was found.
1994 (not_accessible_p): Handle inner classes. Expand protected
1995 qualifier-subtype check to enclosing instances, but don't apply this
1996 check to static members. Allow protected access to inner classes
1997 of a subtype. Allow private access within common enclosing context.
1998 (build_super_invocation): Get WFL line number info from current
2000 (build_incomplete_class_ref): Update for new create_anonymous_class
2002 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Use
2003 common_enclosing_instance_p.
2004 * class.c (common_enclosing_context_p): New. Determine if types
2005 share a common enclosing context, even across static contexts.
2006 (common_enclosing_instance_p): Renamed from
2007 common_enclosing_context_p. Determines if types share a common
2008 non-static enclosing instance.
2009 * java-tree.h (common_enclosing_instance_p): Declare.
2010 * jcf-write.c (get_method_access_flags): New. Surpress private flag
2011 for inner class constructors.
2012 (generate_classfile): Use get_method_access_flags.
2014 2004-07-09 Bryce McKinlay <mckinlay@redhat.com>
2016 * class.c (interface_of_p): Check for null TYPE_BINFO.
2018 2004-07-09 Nathan Sidwell <nathan@codesourcery.com>
2020 * class.c (make_class): Do not create binfo here.
2021 (set_super_info): Create it here.
2022 * java-tree.h (CLASS_HAS_SUPER): Cope with lack of a binfo.
2024 2004-07-08 Richard Henderson <rth@redhat.com>
2026 * expr.c (case_identity, get_primitive_array_vtable,
2027 java_expand_expr, emit_init_test_initialization): Remove.
2028 * java-tree.h (java_expand_expr): Remove.
2029 * lang.c (LANG_HOOKS_EXPAND_EXPR): Remove.
2031 2004-07-07 Per Bothner <per@bothner.com>
2033 * class.c (build_static_field_ref): Add a NOP_EXPR; otherwise we
2034 get internal error due to mismatched types.
2036 * gcj.texi (Invoking gij): Document new -verbose:class flag.
2038 * gcj.texi (Linking): New node. Document -lgij usage.
2040 2004-07-07 Nathan Sidwell <nathan@codesourcery.com>
2042 * java-tree.h (CLASSTYPE_SPUER): Adjust BINFO macros.
2043 (TYPE_NVIRTUALS, TYPE_VTABLE): Likewise.
2044 * java/class.c (set_super_info, class_depth, interface_of_p,
2045 maybe_add_interface, add_interface, make_class_data,
2046 layout_class, add_miranda_methods): Adjust BINFO macros.
2047 * expr.c (can_widen_reference_to, lookup_field): Likewise.
2048 * jcf-write.c (generate_classfile): Likewise.
2049 * parse.y (patch_anonymous_class,
2050 check_inner_circular_reference, check_circular_reference,
2051 java_complete_class, check_abstract_method_definitions,
2052 java_check_abstract_method_definitions,
2053 check_interface_throws_clauses, java_check_abstract_methods,
2054 lookup_java_interface_method2,
2055 find_applicable_accessible_methods_list): Likewise.
2056 * typeck.c (find_method_in_interface): Likewise.
2057 * verify.c (merge_types): Likewise.
2059 2004-07-06 Nathan Sidwell <nathan@codesourcery.com>
2061 * java-tree.h (CLASS_HAS_SUPER_FLAG): Use BINFO_FLAG_1.
2062 * class.c (add_interface_do): Use BINFO_VIRTUAL_P.
2064 2004-07-05 Nathan Sidwell <nathan@codesourcery.com>
2066 * class.c (make_class): Use make_tree_binfo.
2067 (set_super_info, add_interface_do): Likewise.
2068 * java-tree.h (CLASS_HAS_SUPER_FLAG): Expect a BINFO.
2070 2004-07-04 Ranjit Mathew <rmathew@hotmail.com>
2072 * verify.c: Correct array element access formatting thinko.
2074 2004-07-04 Ranjit Mathew <rmathew@hotmail.com>
2076 * verify.c: Insert a short blurb at the start referring to the JVMS.
2077 (merge_type_state): Remove redundant nested if statement.
2078 (verify_jvm_instructions): Ensure current_subr is initialised to
2080 Minor formatting fixes all over the place.
2082 2004-07-02 Richard Henderson <rth@redhat.com>
2084 * jcf-write.c (generate_bytecode_insns <case SAVE_EXPR>): Rewrite.
2086 2004-07-01 Richard Henderson <rth@redhat.com>
2088 * class.c (registerClass_libfunc): Remove.
2089 (init_class_processing): Don't set it.
2090 (emit_register_classes): Take list_p parameter. Fill it in
2091 with _Jv_RegisterClass calls.
2092 * decl.c (java_init_decl_processing): Don't call
2093 init_resource_processing.
2094 * jcf-parse.c (java_emit_static_constructor): New.
2095 (java_parse_file): Call it.
2096 * resource.c (registerResource_libfunc): Remove.
2097 (init_resource_processing): Remove.
2098 (write_resource_constructor): Take list_p parameter. Fill it in
2099 with _Jv_RegisterResource calls.
2100 * java-tree.h: Update prototypes.
2102 2004-06-29 Bryce McKinlay <mckinlay@redhat.com>
2105 * class.c (layout_class_method): Do not override package-private
2106 method if its in a different package.
2107 (split_qualified_name): Move here from parse.y. Rename from
2108 breakdown_qualified. Add comment.
2109 (in_same_package): Move here from parse.y. Add comment.
2110 * java-tree.h (break_down_qualified, in_same_package): Declare.
2111 (in_same_package): Likewise.
2112 * parse.y (breakdown_qualified, in_same_package): Moved to class.c.
2115 2004-06-29 Andrew Haley <aph@redhat.com>
2117 * except.c (expand_start_java_handler): Push a new binding level.
2118 Don't build a TRY_CATCH_EXPR now, we'll do it later. Call
2119 register_exception_range() to register where we'll do it.
2120 (expand_end_java_handler): Remove old bogus code. Replace with
2121 new logic that simply builds TRY_CATCH_EXPRs and inserts them at
2122 the top of the expression we're curently building.
2123 (maybe_end_try): Delete.
2124 * decl.c (binding_level.exception_range): New field.
2125 (clear_binding_level): Add field exception_range. Reformat.
2126 (poplevel): Call expand_end_java_handler().
2127 (poplevel): Call java_add_stmt only if functionbody is false.
2128 (maybe_poplevels): Don't call maybe_end_try() from here.
2129 (end_java_method): Clear no longer used trees in function decl.
2130 (register_exception_range): New function.
2131 * java-tree.h (register_exception_range, struct eh_range): Declare.
2133 2004-06-28 Bryce McKinlay <mckinlay@redhat.com>
2135 * jcf-write.c (get_classfile_modifiers): Formatting fixes.
2137 2004-06-27 Ranjit Mathew <rmathew@hotmail.com>
2140 * expr.c (class_has_finalize_method): Fix method name indentation.
2141 (expand_java_call): Remove K&R style parameter declaration.
2142 (expand_invoke): Fix statement indentation.
2143 (expand_java_field_op): Likewise.
2144 * parse-scan.y: Fix typo.
2145 (reset_report): Fix method name indentation.
2146 * parse.y (unresolved_type_p, build_expr_block): Remove extra blank
2148 * verify.c (verify_jvm_instructions): Document parameters, insert
2150 * lang.c (lang_init_source): Fix method name indentation.
2151 * class.c (common_enclosing_context_p): Likewise.
2152 (emit_symbol_table): Fix parameter list indentation.
2153 * decl.c (add_stmt_to_compound, java_add_stmt): Remove K&R style
2154 parameter declaration.
2155 * constants.c: Fix copyright notice indentation.
2156 * typeck.c (find_method_in_superclasses): Fix parameter list
2158 (find_method_in_interfaces): Likewise.
2159 * zextract.c (makelong): Fix method name indentation.
2161 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
2164 * parse.y (create_interface): Set correct access modifiers for
2166 * jcf-write.c (get_classfile_modifiers): New function.
2167 (generate_classfile): Use get_classfile_modifiers, not
2170 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
2172 * parse.y (register_incomplete_type): Set JDEP_ENCLOSING for "super"
2173 dependency to current parser context, not NULL_TREE, for top-level
2175 (jdep_resolve_class): Enable member access check for all inner
2178 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
2180 * parse.y (qualify_and_find): Pass type decl, not identifier, to
2183 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
2186 * expr.c (expand_java_field_op): Ensure that target class for static
2187 field access has been loaded.
2189 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
2190 Ranjit Mathew <rmathew@hotmail.com>
2192 PR java/1207, java/16178
2193 * jcf-parse.c (load_class): Return immediately if passed a type decl
2194 where CLASS_FROM_SOURCE_P is set. Remove FIXME.
2195 * parse.y (do_resolve_class): Remove checks for CLASS_FROM_SOURCE_P
2196 before calling load_class.
2197 (qualify_and_find): Likewise.
2198 (find_in_imports_on_demand): Likewise.
2199 (find_applicable_accessible_methods_list): Likewise.
2201 2004-06-24 Bryce McKinlay <mckinlay@redhat.com>
2203 * parse.y (java_layout_seen_class_methods): Don't call load_class
2204 on class defined by source parser.
2206 2004-06-23 Bryce McKinlay <mckinlay@redhat.com>
2208 * parse.y (set_nested_class_simple_name_value): Removed.
2209 (java_complete_expand_class): Remove calls to
2210 set_nested_class_simple_name_value.
2212 2004-06-22 Andrew Haley <aph@redhat.com>
2213 Ranjit Mathew <rmathew@hotmail.com>
2215 Fixes PR java/16113.
2216 * decl.c (force_poplevels): Remove call to expand_end_bindings.
2218 2004-06-22 Ranjit Mathew <rmathew@hotmail.com>
2220 * parse.y (create_class): Correct diagnostic message about
2221 java.lang.Object extending anything else.
2223 2004-06-21 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
2225 * class.c (build_class_ref): Add new operand for COMPONENT_REF.
2226 (build_static_field_ref): Likewise and add new operands for ARRAY_REF.
2227 * constants.c (build_ref_from_constant_pool): Likewise.
2228 * expr.c (build_java_array_length_access): Likewise.
2229 (build_get_class, build_field_ref, build_known_method_ref): Likewise.
2230 (invoke_build_dtable, build_invokevirtual): Likewise.
2231 (build_invokeinterface, java_expand_expr): Likewise.
2232 (emit_init_test_initialization): Likewise.
2233 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
2234 * parse.y (make_qualifed_name, build_array_ref): Likewise.
2236 2004-06-21 Andrew Haley <aph@redhat.com>
2238 * java-gimplify.c (java_gimplify_block): set TREE_USED on the new
2241 2004-06-21 Joseph S. Myers <jsm@polyomino.org.uk>
2243 * jcf.h (struct JCF): Change java_source, right_zip and finished
2245 * lex.h (struct java_lexer): Change hit_eof, read_anything,
2246 byte_swap and use_fallback to unsigned int.
2247 * parse.h (struct _jdep): Change flag0 to unsigned int.
2249 2004-06-17 Ranjit Mathew <rmathew@hotmail.com>
2252 * parse.y (java_layout_seen_class_methods): Ensure class is loaded
2253 before trying to lay out its methods.
2254 * jcf-parse.c (read_class): Track parsed files using canonical paths
2255 obtained via lrealpath from libiberty.
2256 (java_parse_file): Likewise.
2257 (parse_source_file_1): Rename formal parameter to reflect its
2258 modified purpose. Minor formatting fix.
2260 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
2262 * class.c (emit_register_classes): Make the function uninlinable,
2263 do not set current_function_cannot_inline.
2264 * resource.c (write_resource_constructor): Do not reset
2265 flag_inline_functions around rest_of_compilation.
2267 2004-06-08 Andrew Pinski <pinskia@physics.uc.edu>
2270 * expr.c (java_truthvalue_conversion): Handle
2271 UNEQ_EXPR, UNLE_EXPR, UNGE_EXPR, UNLT_EXPR, UNGT_EXPR,
2272 ORDERED_EXPR, and UNORDERED_EXPR as comparison operators,
2273 i.e. return the expression.
2275 2004-06-03 Mark G. Adams <mark.g.adams@sympatico.ca>
2277 * gjavah.c: Include version.h
2279 2004-05-31 Bryce McKinlay <mckinlay@redhat.com>
2281 * jcf-write.c (generate_bytecode_conditional): Correct handling
2282 of unordered conditionals. Add comment.
2284 2004-05-29 Ranjit Mathew <rmathew@hotmail.com>
2285 Per Bothner <per@bothner.com>
2287 * java-tree.h (DECL_LOCAL_FINAL_IUD): New macro to test if a
2288 local variable was initialised upon declaration.
2289 * parse.y (declare_local_variables): Set DECL_LOCAL_FINAL_IUD if
2290 variable was final and initialised upon declaration.
2291 * check-init.c (check_final_reassigned): Give error only if a blank
2292 final is not definitely unassigned or if an initialised final is
2294 (check_bool_init): Respect JLS2 16.1.7 requirements for boolean
2295 assignment expressions. Remove case MODIFY_EXPR, label do_default.
2296 (check_init): Perform initialised-variable-removing-optimisation
2297 only on non-final local variables.
2299 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
2301 * jcf-write.c (generate_bytecode_conditional): Handle binops
2302 UNLT_EXPR, UNLE_EXPR, UNGT_EXPR, UNGE_EXPR, UNEQ_EXPR,
2304 (generate_bytecode_insns): Likewise.
2306 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
2308 * check-init.c (check_init): Handle binops UNLT_EXPR, UNLE_EXPR,
2309 UNGT_EXPR, UNGE_EXPR, UNEQ_EXPR, and LTGT_EXPR.
2311 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
2313 * gcj.texi (Object allocation): Remove _Jv_AllocBytes.
2314 (Mixing with C++): Document JvAllocBytes and RawDataManaged.
2316 2004-05-26 Bryce McKinlay <mckinlay@redhat.com>
2318 * decl.c (struct binding_level): Add GTY marker. Compile
2319 binding_depth unconditionally.
2320 (current_binding_level, free_binding_level, global_binding_level):
2322 (clear_binding_level): Unconditionally set binding_depth.
2323 (make_binding_level): Use ggc_alloc_cleared, not xmalloc.
2325 2004-05-26 Bryce McKinlay <mckinlay@redhat.com>
2327 * lex.c (java_new_lexer): Set 'encoding'.
2328 (java_read_char): Improve error message for unrecognized characters.
2329 * lex.h (struct java_lexer): New field 'encoding'.
2331 2004-05-23 Paolo Bonzini <bonzini@gnu.org>
2333 * Make-lang.in: Link in $(LIBCPP) instead of mkdeps.o.
2335 2004-05-21 Mark Wielaard <mark@klomp.org>
2337 * gjavah.c (print_stub_or_jni): Mark functions only JNIEXPORT, not
2340 2004-05-19 Paolo Bonzini <bonzini@gnu.org>
2342 * typeck.c: Remove non-printable character 160.
2344 2004-05-17 Ranjit Mathew <rmathew@hotmail.com>
2346 * check-init.c: Correct minor typos.
2348 2004-05-13 Diego Novillo <dnovillo@redhat.com>
2350 * Make-lang.in, expr.c, java-gimplify.c: Rename
2351 tree-simple.[ch] to tree-gimple.[ch].
2353 2004-05-14 Ranjit Mathew <rmathew@hotmail.com>
2355 * java-gimplify.c (java_gimplify_expr): Correct minor typos.
2357 2004-05-13 Diego Novillo <dnovillo@redhat.com>
2359 Merge from tree-ssa-20020619-branch. See
2360 ChangeLog.tree-ssa for details.
2362 * Make-lang.in, builtins.c, check-init.c, class.c,
2363 constants.c, decl.c, except.c, expr.c, java-except.h,
2364 java-tree.def, java-tree.h, jcf-parse.c, jcf-write.c,
2365 lang.c, lang.opt, parse.y, resource.c: Merged.
2366 * java-gimplify.c: New file.
2368 2004-05-10 Andrew Haley <aph@redhat.com>
2370 * parse.y (create_class): Set TYPE_VFIELD.
2371 * decl.c (java_init_decl_processing): Likewise.
2373 * expr.c (build_invokevirtual): Remove DECL_VINDEX offset adjustment.
2374 * class.c (make_method_value): Replace DECL_VINDEX with call to
2376 (get_dispatch_vector): Likewise.
2377 (layout_class_method): Likewise.
2378 Replace set of DECL_VINDEX with call to set_method_index().
2379 (set_method_index): New function.
2380 (get_method_index): New function.
2381 * java-tree.h (set_method_index): New function decl.
2382 (get_method_index): New function decl.
2384 2004-05-10 Andrew Pinski <pinskia@physics.uc.edu>
2386 * parse.y (check_pkg_class_access): Add new argument
2387 and use it when cl is NULL to call lookup_cl on it.
2388 (parser_check_super_interface): Do not call lookup_cl.
2389 Pass this_decl to check_pkg_class_access and NULL
2390 instead of lookup_cl.
2391 (parser_check_super): Update for change in
2392 check_pkg_class_access.
2393 (do_resolve_class): Likewise.
2394 (process_imports): Likewise.
2395 (find_in_imports_on_demand): Likewise.
2396 (resolve_qualified_expression_name): Likewise.
2398 2004-05-06 Ranjit Mathew <rmathew@hotmail.com>
2400 Fixes PR java/9685, PR java/15073
2401 * parse.y (accessibility_string): New method.
2402 (not_accessible_field_error): Use accessibility_string()
2403 instead of java_accstring_lookup().
2404 (resolve_qualified_expression_name): Check with
2405 check_pkg_class_access() before allowing access using
2408 Use check_pkg_class_access() instead of not_accessible_p()
2409 for unqualified types.
2410 (not_accessible_p): Use DECL_CONTEXT (member) instead of
2411 REFERENCE for package-private access checking.
2412 (patch_method_invocation): Use accessibility_string() instead
2413 of java_accstring_lookup().
2415 2004-04-30 Ranjit Mathew <rmathew@hotmail.com>
2418 * gjavah.c (struct method_name): Add member is_native.
2419 (overloaded_jni_method_exists_p): Match candidate method only if
2421 (print_method_info): Initialise is_native flag from the method's
2424 2004-04-30 Roger Sayle <roger@eyesopen.com>
2426 * builtins.c (java_builtins): Add acos, asin, ceil and floor.
2427 (initialize_builtins): Likewise, define acos, asin, ceil and floor.
2429 2004-04-22 Roger Sayle <roger@eyesopen.com>
2431 * resource.c (write_resource_constructor): Guard call to possibly
2432 NULL targetm.asm_out.constructor with targetm.have_ctors_dtors.
2434 2004-04-19 Bryce McKinlay <mckinlay@redhat.com>
2436 * class.c (make_class_data): Add new field aux_info.
2437 * decl.c (java_init_decl_processing): Push type and decl for
2440 2004-04-15 Bryce McKinlay <mckinlay@redhat.com>
2442 * expr.c (expand_java_NEW): Don't use size argument for
2443 _Jv_AllocObject calls.
2444 * parse.y (patch_invoke): Likewise.
2446 2004-04-12 Bryce McKinlay <mckinlay@redhat.com>
2448 * expr.c (build_invokeinterface): Remove unused variables to
2451 2004-04-12 Bryce McKinlay <mckinlay@redhat.com>
2453 * class.c (get_interface_method_index): New function. Return dispatch
2454 index for interface method.
2455 (make_method_value): For interface methods, set index field to
2456 iface dispatch index, not DECL_VINDEX.
2457 * expr.c (build_invokeinterface): Use get_interface_method_index.
2459 2004-03-31 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
2461 * jcf-write.c (generate_bytecode_insns): Use TYPE_UNSIGNED.
2463 2004-03-31 Andrew Haley <aph@redhat.com>
2466 * jcf-io.c (opendir_in_zip): Tidy up error handling.
2468 2004-03-30 Zack Weinberg <zack@codesourcery.com>
2470 * builtins.c, expr.c, jcf.h, parse.h: Use new shorter
2471 form of GTY markers.
2473 2004-03-25 Marcus Meissner <meissner@suse.de>
2476 * jcf-path.c (jcf_path_extdirs_arg): Add missing closedir.
2478 2004-03-23 Tom Tromey <tromey@redhat.com>
2481 * jcf-write.c (make_class_file_name): Don't report if mkdir
2484 2004-03-23 Tom Tromey <tromey@redhat.com>
2486 * gcj.texi (Extensions): Document GCJ_PROPERTIES.
2488 2004-03-20 Kazu Hirata <kazu@cs.umass.edu>
2490 * class.c, gjavah.c, lang.c: Fix comment typos.
2491 * gcj.texi: Fix typos.
2493 2004-03-19 Per Bothner <per@bothner.com>
2495 * gcj.texi (Code Generation): Document new flags and assert defaults.
2497 * class.c (assume_compiled_node_struct): Rename type to
2498 class_flag_node_struct, as it is now also used for enable_assertions.
2499 Rename assume_compiled_node typedef. Rename excludep field to value.
2500 (find_assume_compiled_node): Rename function to find_class_flag_node.
2501 Minor optimization - avoid needless strlen.
2502 (add_assume_compiled): Some tweaking and optimization.
2503 Rename and generalize to add_class_flag takem an extra parameter.
2504 (add_assume_compled): New just calls add_class_flag.
2505 (add_enable_assert, enable_assertions): New functions.
2506 (enable_assert_tree): New static.
2507 * java-tree.h (add_enable_assert, enable_assertions): New declarations.
2508 * lang.opt (fenable-assertions, fenable-assertions=,
2509 fdisable-assertions, fdisable-assertions=): New options.
2510 * lang.c (java_handle_option): Handle new options.
2511 * parse.y (build_incomplete_class_ref): Handle class$ in an inner
2512 class in an interface - create helper class nested in outer interface.
2513 (build_assertion): Short-circuit if enable_assertions is false.
2515 2004-03-18 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
2517 * java-tree.h: Changes throughout to add checking to macros
2518 and numerous whitespace changes.
2519 (VAR_OR_FIELD_CHECK): New macro.
2520 * jcf-write.c (get_access_flags): Use FIELD_PUBLIC, METHOD_PUBLIC,
2521 FIELD_FINAL, and METHOD_FINAL instead of CLASS_PUBLIC and CLASS_FINAL.
2523 2004-03-16 Per Bothner <per@bothner.com>
2525 * jcf-jump.c (options): New --print-constants option.
2526 * gcj.texi (Invoking jcf-dump): Document --print-constants.
2528 * jcf-dump.c (flag_print_constant_pool): Default to off.
2529 (print_constant_terse_with_index): New helper function.
2530 (various places): Check flag_print_constant_pool where missing.
2531 (main): If verbose set flag_print_constant_pool.
2532 (HANDLE_INNERCLASSES_ATTRIBUTE): Null inner class name is anonymous.
2534 2004-03-15 Andrew Haley <aph@redhat.com>
2537 * parse.y (java_complete_lhs): Check that final variable has an
2540 2004-03-12 Andrew Haley <aph@redhat.com>
2543 * typeck.c (convert): Clear TREE_OVERFLOW after an integer
2546 2004-02-29 Roger Sayle <roger@eyesopen.com>
2548 * jcf-parse.c (java_parse_file): Handle the case that input_filename
2551 2004-02-27 Per Bothner <per@bothner.com>
2553 * parse.y (build_assertion): Re-do 02-25 change following Jeff Sturm
2554 suggestion: Use build_incomplete_class_ref.
2555 This fixes PR java/13508, java/11714.
2557 2004-02-27 Kazu Hirata <kazu@cs.umass.edu>
2559 * java/parse.h: Update copyright.
2561 2004-02-26 Andrew Haley <aph@redhat.com>
2564 * parse.y (check_interface_throws_clauses): Check for
2565 !METHOD_INVISIBLE (iface_method).
2566 * class.c (layout_class_methods): Check for CLASS_INTERFACE as
2567 well as CLASS_ABSTRACT.
2569 2004-02-25 Per Bothner <per@bothner.com>
2571 * parse.y (build_assertion): If we're in an inner class, create the
2572 class$ helper routine in the outer class.
2574 2004-02-19 Richard Henderson <rth@redhat.com>
2576 * parse.y (switch_label): Use make_node for DEFAULT_EXPR.
2578 2004-02-16 Geoffrey Keating <geoffk@apple.com>
2580 * Make-lang.in (java.install-man): Add extra dependencies.
2582 2004-02-13 Geoffrey Keating <geoffk@apple.com>
2584 * Make-lang.in: Install man pages under the same names
2585 (possibly transformed) as the program they document.
2587 2004-02-10 Joseph S. Myers <jsm@polyomino.org.uk>
2589 * gjavah.c: Include "intl.h".
2590 (error): New function.
2591 (main): Call gcc_init_libintl.
2592 (get_field_name, throwable_p, print_c_decl, print_full_cxx_name,
2593 print_stub_or_jni, process_file, main): Use error rather than
2595 (print_method_info, usage, help, version, main): Mark strings for
2596 translation with _. Avoid splitting up sentences. Send
2597 information messages to stdout.
2598 * jcf-dump.c: Include "intl.h".
2599 (main): Call gcc_init_libintl.
2600 (process_class, usage, help, version, main, CHECK_PC_IN_RANGE):
2601 Mark error, usage and version messages for translation with _.
2602 Avoid splitting up sentences.
2603 * jv-scan.c: Include "intl.h".
2604 (fatal_error, warning): Change parameter s to msgid. Translate
2606 (main): Call gcc_init_libintl.
2607 (usage, help, version): Mark error, usage and version messages for
2608 translation with _. Avoid splitting up sentences.
2609 * jvgenmain.c: Include "intl.h".
2610 (main): Call gcc_init_libintl.
2611 (usage, main): Mark error messages for translation with _.
2612 * Make-lang.in (GCJH_OBJS, JVSCAN_OBJS, JCFDUMP_OBJS,
2613 JVGENMAIN_OBJS): Add intl.o.
2614 (java/jcf-dump.o, java/gjavah.o, java/jv-scan.o,
2615 java/jvgenmain.o): Update dependencies.
2617 2004-02-08 Per Bothner <per@bothner.com>
2619 * parse.y (resolve_qualified_expression_name): In case of inaccessible
2620 class don't use not_accessible_field_error, which can get confused.
2622 2004-02-05 Kelley Cook <kcook@gcc.gnu.org>
2624 Make-lang.in (po-generated): Delete.
2626 2004-02-05 Kazu Hirata <kazu@cs.umass.edu>
2628 * Make-lang.in (java/decl.o, java/expr.o, java/parse.o):
2630 * decl.c: Include target.h.
2631 (start_java_method): Replace PROMOTE_PROTOTYPES with
2632 targetm.calls.promote_prototypes.
2633 * expr.c: Include target.h.
2634 (pop_arguments): Replace PROMOTE_PROTOTYPES with
2635 targetm.calls.promote_prototypes.
2636 * parse.y: Include target.h.
2637 (start_complete_expand_method): Replace PROMOTE_PROTOTYPES
2638 with targetm.calls.promote_prototypes.
2640 2004-02-04 Kazu Hirata <kazu@cs.umass.edu>
2642 * typeck.c: Update copyright.
2644 2004-02-02 Tom Tromey <tromey@redhat.com>
2646 * decl.c (java_init_decl_processing): Remove duplicate
2649 2004-01-30 Kelley Cook <kcook@gcc.gnu.org>
2651 * Make-lang.in (doc/gcj.dvi): Use $(abs_docdir).
2653 2004-01-28 Andrew Pinski <pinskia@physics.uc.edu>
2655 * expr.c (build_field_ref): Move variable
2658 2004-01-28 Andrew Haley <aph@redhat.com>
2660 * expr.c (build_field_ref): Widen field offset.
2662 2004-01-27 Andrew Haley <aph@redhat.com>
2665 * parse.y (check_interface_throws_clauses): Make sure class_decl
2668 2004-01-22 Jeff Sturm <jsturm@one-point.com>
2671 * parse.y (patch_assignment): Don't modify lhs_type for
2672 reference assignments.
2674 2004-01-20 Kelley Cook <kcook@gcc.gnu.org>
2676 * Make-lang.in: Replace $(docdir) with doc.
2677 (java.info, java.srcinfo, java.man, java.srcman): New rules.
2678 (java.install-man): Revamp rule.
2680 2004-01-20 Kelley Cook <kcook@gcc.gnu.org>
2682 * Make-lang.in (JAVA_INSTALL_NAME, JAVA_TARGET_INSTALL_NAME,
2683 GCJH_TARGET_INSTALL_NAME): Define via a immediate $(shell)
2684 instead of deferred backquote.
2686 2004-01-16 Andrew Pinski <pinskia@physics.uc.edu>
2688 * typeck.c (find_method_in_interfaces): Move variable
2691 2004-01-16 Andrew Haley <aph@redhat.com>
2694 * typeck.c (shallow_find_method): New.
2695 (find_method_in_superclasses): New.
2696 (find_method_in_interfaces): New.
2697 (lookup_do): Rewrite.
2698 * java-tree.h (SEARCH_ONLY_INTERFACE): Delete.
2700 * jcf-parse.c (read_class): Save and restore output_class.
2701 * decl.c (java_expand_body): Set output_class from fndecl.
2703 2004-01-15 Michael Chastain <mec.gnu@mindspring.com>
2705 * class.c (gen_indirect_dispatch_tables): Fix string length
2708 2004-01-15 Kelley Cook <kcook@gcc.gnu.org>
2710 * Make-lang.in (parse.c, parse-scan.c): Always build in doc directory.
2711 (java.srcextra): Copy above back to source directory if requested.
2712 (po-generated): Delete reference to $(parsedir).
2713 (java/parse.o, java/parse-scan.o): Delete reference to $(parsedir).
2716 2004-01-14 Jan Hubicka <jh@suse.cz>
2718 * lang.c (java_estimate_num_insns_1): Fix bug in MODIFY_EXPR cost
2721 2004-01-09 Mark Mitchell <mark@codesourcery.com>
2723 * java-tree.h (java_expand_expr): Change prototype.
2724 * expr.c (java_expand_expr): Add alt_rtl parameter.
2726 2004-01-09 Andrew Haley <aph@redhat.com>
2729 * parse.y (java_fix_constructors): Set output_class.
2730 (java_reorder_fields): Likewise.
2731 (java_layout_classes): Likewise.
2732 (java_expand_classes): Generate indirect dispatch tables.
2733 (java_expand_classes): Set output_class.
2734 (java_finish_classes): Likewise.
2735 * lang.c (java_init): Turn on always_initialize_class_p if we're
2736 using indirect dis[atch.
2737 (java_decl_ok_for_sibcall): Use output_class, not current_class.
2738 (java_get_callee_fndecl): Use class local atable.
2740 (always_initialize_class_p): Decl moved to java-tree.h.
2741 (HANDLE_CLASS_INFO): Set output_class.
2742 (read_class): Likewise.
2743 (parse_class_file): Call gen_indirect_dispatch_tables.
2744 (parse_zip_file_entries): Set output_class.
2745 (java_parse_file): Set output_class. Don't emit symbol tables.
2746 * java-tree.h (output_class): New.
2747 Remove global declarations for otable, atable, and ctable.
2748 (always_initialize_class_p): moved here from decl.c.
2750 (TYPE_ATABLE_METHODS, TYPE_ATABLE_SYMS_DECL, TYPE_ATABLE_DECL,
2751 TYPE_OTABLE_METHODS, TYPE_OTABLE_SYMS_DECL, TYPE_OTABLE_DECL,
2752 TYPE_CTABLE_DECL, TYPE_CATCH_CLASSES): New.
2753 (struct lang_type): Add otable_methods, otable_decl,
2754 otable_syms_decl, atable_methods, atable_decl, atable_syms_decl,
2755 ctable_decl, catch_classes, type_to_runtime_map.
2756 * expr.c (build_field_ref): Make otable, atable, and ctable class
2757 local rather than global.
2758 (build_known_method_ref): Likewise.
2759 (build_invokeinterface): Likewise.
2760 (java_expand_expr): Pass runtime type (rather than actual type) to
2762 * except.c (prepare_eh_table_type): Create TYPE_TO_RUNTIME_MAP for
2763 this class. Look up each class in that map to delete duplicates.
2764 (expand_end_java_handler): Pass runtime type (rather than actual
2765 type) to expand_start_catch.
2766 * decl.c: (always_initialize_class_p): Decl moved to java-tree.h.
2768 (java_init_decl_processing): Rearrange things. Remove global
2769 declarations of otable, atable, and ctable.
2770 (java_init_decl_processing): Make lang_eh_runtime_type do_nothing.
2771 (java_expand_body): Set output_class.
2772 * constants.c (build_constant_data_ref): Use output_class, not
2774 (alloc_name_constant): Likewise.
2775 * class.c (gen_indirect_dispatch_tables): New.
2776 (build_class_ref): Generate hard reference to superclass, even if
2777 using indirect dispatch.
2778 (build_static_field_ref): Use class local atable.
2779 (make_class_data): Generate hard reference to superclass, even if
2780 using indirect dispatch.
2781 Generate symbolic references to interfaces when using indirect
2783 (make_class_data): Emit otable, atable, and ctable.
2784 Make otable, atable, and ctable class local rather than global.
2785 (emit_catch_table): Make otable, atable, and ctable class local
2788 2003-12-25 Andrew Pinski <pinskia@physics.uc.edu>
2790 * parse.y (catch_clause_parameter): Fix typo.
2793 * parse.y: (catch_clause_parameter): Return early if $3, aka
2794 formal_parameter, is null.
2796 2003-12-20 Kazu Hirata <kazu@cs.umass.edu>
2798 * class.c: Remove uses of "register" specifier in
2799 declarations of arguments and local variables.
2802 * gjavah.c: Likewise.
2803 * jcf-dump.c: Likewise.
2804 * jcf-io.c: Likewise.
2805 * jcf-parse.c: Likewise.
2806 * jcf-write.c: Likewise.
2807 * keyword.h: Likewise.
2808 * parse.y: Likewise.
2809 * typeck.c: Likewise.
2810 * verify.c: Likewise.
2812 2003-12-06 Kelley Cook <kcook@gcc.gnu.org>
2814 * Make-lang.in (GCJ_CROSS_NAME): Delete.
2815 (java.install_common, java.install-man): Adjust for above.
2816 (java.uninstall): Likewise.
2818 2003-12-03 Michael Koch <konqueror@gmx.de>
2820 * class.c (make_class_data):
2821 Push field value to 'hack_signers' instead of 'signers'.
2822 * decl.c (java_init_decl_processing):
2823 Push field 'hack_signers' instead of 'signers'.
2825 2003-12-03 Zack Weinberg <zack@codesourcery.com>
2827 * lex.h: Check both HAVE_ICONV and HAVE_ICONV_H before
2830 2003-12-03 Ralph Loader <rcl@ihug.co.nz>
2833 * parse.y (qualify_ambiguous_name): Remove lots of broken
2834 field access processing - there's no need to do that here,
2835 because we have resolve_field_access. Remove
2836 RESOLVE_EXPRESSION_NAME_P as it isn't used anywhere else.
2837 * java-tree.h: Remove RESOLVE_EXPRESSION_NAME_P as it isn't
2840 2003-12-01 Jeff Sturm <jsturm@one-point.com>
2843 * parse.y (java_complete_lhs): Save location prior to patching
2846 2003-11-25 Mohan Embar <gnustuff@thisiscool.com>
2849 * resource.c (write_resource_constructor): Append
2850 "_resource" to constructor identifier name.
2852 2003-11-25 Jeff Sturm <jsturm@one-point.com>
2855 * constants.c (cpool_for_class): New function.
2856 (outgoing_cpool): Remove global variable.
2857 (alloc_name_constant): Use cpool_for_class.
2858 (build_constants_constructor): Likewise.
2859 * decl.c (java_expand_body): Set current_class.
2860 * java-tree.h (outgoing_cpool) Remove declaration.
2861 (init_outgoing_cpool): Likewise.
2862 * jcf-parse.c (init_outgoing_cpool): Remove function.
2863 (parse_class_file): Don't call init_outgoing_cpool.
2864 * parse.y (java_complete_expand_methods): Don't call
2865 init_outgoing_cpool. Don't save outgoing_cpool.
2866 (java_expand_classes): Don't restore outgoing_cpool.
2867 (java_finish_classes): Likewise.
2869 2003-11-24 Mohan Embar <gnustuff@thisiscool.com>
2871 * Make-lang.in: (java.install-common) Add
2872 symlink for $(target_noncanonical)-gcjh for
2875 2003-11-20 Joseph S. Myers <jsm@polyomino.org.uk>
2877 * Make-lang.in (java.extraclean): Delete.
2879 2003-11-20 Joseph S. Myers <jsm@polyomino.org.uk>
2881 * Make-lang.in (check-java): Add.
2883 2003-11-19 Jeff Sturm <jsturm@one-point.com>
2886 * except.c (prepare_eh_table_type): Allocate variable-sized
2887 buffer `buf' with alloca.
2889 2003-11-17 Jeff Sturm <jsturm@one-point.com>
2893 decl.c (java_init_decl_processing): Don't initialize
2894 class_not_found_type_node, no_class_def_found_type_node.
2896 java-tree.h (JTI_CLASS_NOT_FOUND_TYPE_NODE,
2897 JTI_NO_CLASS_DEF_FOUND_TYPE_NODE): Remove from java_tree_index.
2898 (class_not_found_type_node, no_class_def_found_type_node):
2901 parse.y (build_dot_class_method_invocation): Add this_class
2902 argument. Qualify method invocations to a different class.
2903 (create_new_parser_context): Initialize saved_data_ctx to 0.
2904 (java_parser_context_save_global): Initialize saved_data_ctx to 1.
2905 (build_dot_class_method): Don't load classes. Register
2907 (build_incomplete_class_ref): Special cases for interfaces
2908 and inner classes. Move build_dot_class_method call to here...
2909 (patch_incomplete_class_ref): ...from here. Pass current_class
2910 to build_dot_class_method_invocation.
2911 (build_assertion): Pass class_type to
2912 build_dot_class_method_invocation.
2913 (encapsulate_with_try_catch): Handle EXPR_WITH_FILE_LOCATION node.
2915 2003-11-17 Jeff Sturm <jsturm@one-point.com>
2918 * java-tree.h (BLOCK_EMPTY_P): Define.
2919 * parse.y (java_complete_lhs): Check for empty blocks
2920 in TRY_FINALLY_EXPR case.
2922 2003-11-17 Andrew Haley <aph@redhat.com>
2924 * java-tree.h (LOCAL_VAR_OUT_OF_SCOPE_P): New.
2925 (struct lang_decl_var:freed): New variable.
2926 * decl.c (poplevel): Mark local vars that have gone out of scope.
2927 (push_jvm_slot): Don't use the RTL of a var that has gone out of
2930 2003-11-16 Jason Merrill <jason@redhat.com>
2932 * Make-lang.in (java.tags): Create TAGS.sub files in each directory
2933 and TAGS files that include them for each front end.
2935 2003-11-15 Tom Tromey <tromey@redhat.com>
2937 * gjavah.c (print_stub_or_jni): Pass `env' to FatalError.
2939 2003-11-12 Jason Merrill <jason@redhat.com>
2941 PR optimization/12547
2942 * lang.c (java_tree_inlining_walk_subtrees): Just walk
2943 BLOCK_EXPR_BODY directly.
2945 2003-11-12 Andrew Haley <aph@redhat.com>
2948 * parse.y (fold_constant_for_init): Check that we really do have a
2952 * lang.c (merge_init_test_initialization): Clear DECL_INITIAL for
2953 init_test_decls being inlined.
2956 * parse.y (do_resolve_class): Check return value from
2957 breakdown_qualified().
2959 2003-11-11 Tom Tromey <tromey@redhat.com>
2962 * parse.y (merge_string_cste): Handle case where we have a
2963 pointer that happens to be zero, not null_pointer_node.
2965 2003-11-10 Tom Tromey <tromey@redhat.com>
2967 * jcf-parse.c (classify_zip_file): Correctly compare
2968 filename_length against length of manifest file's name.
2970 2003-11-08 Tom Tromey <tromey@redhat.com>
2973 * jcf-parse.c (classify_zip_file): Only skip MANIFEST.MF file.
2975 2003-11-06 Andrew Haley <aph@redhat.com>
2977 * expr.c (java_stack_swap): Make sure destination stack slots are
2978 of the correct type.
2980 2003-11-03 Kelley Cook <kcook@gcc.gnu.org>
2982 * Make-lang.in (dvi): Move targets to $(docobjdir).
2983 (gcj.dvi): Simplify rule and adjust target.
2984 (gcj.info): Simplify rule.
2985 (gcj.pod): New intermediate rule.
2986 (gcjh.pod): Likewise.
2987 (jv-scan.pod): Likewise.
2988 (jcf-dump.pod): Likewise.
2989 (gij.pod): Likewise.
2990 (jv-convert.pod): Likewise.
2991 (rmic.pod): Likewise.
2992 (rmiregistry.pod): Likewise.
2995 (jv-scan.1): Delete.
2996 (jcf-dump.1): Delete.
2998 (jv-convert.1): Delete.
3000 (rmiregistry.1): Delete.
3002 2003-11-02 Jeff Sturm <jsturm@one-point.com>
3004 Fixes PR java/12866.
3005 * parse.y (resolve_qualified_expression_name): Move test
3006 for outer field access methods from here...
3007 (check_thrown_exceptions) ...to here.
3009 2003-11-01 Kelley Cook <kcook@gcc.gnu.org>
3011 * .cvsignore: Delete.
3013 2003-10-28 Frank Ch. Eigler <fche@redhat.com>
3015 * verify.c (verify_jvm_instructions): Don't warn about legal
3016 eh binding regions generated for example by jdk 1.4.1.
3018 2003-10-24 David S. Miller <davem@redhat.com>
3020 * jcf-parse.c (jcf_parse): Fix args to fatal_error().
3022 2003-10-22 Andrew Haley <aph@redhat.com>
3024 * lang.c (LANG_HOOKS_GET_CALLEE_FNDECL): New.
3025 (java_get_callee_fndecl): New.
3027 * jcf-parse.c (java_parse_file): Call emit_catch_table().
3029 * java-tree.h (ctable_decl): New.
3030 (catch_classes): New.
3031 (java_tree_index): Add JTI_CTABLE_DECL, JTI_CATCH_CLASSES.
3033 * decl.c (java_init_decl_processing): Add catch_class_type.
3035 Add catch_classes field.
3037 * class.c (build_indirect_class_ref): Break out from
3039 (make_field_value): Check flag_indirect_dispatch.
3040 (make_class_data): Ditto.
3041 Tidy uses of PUSH_FIELD_VALUE.
3042 Add field catch_classes.
3043 (make_catch_class_record): New.
3045 * java-tree.h (PUSH_FIELD_VALUE): Tidy.
3047 2003-10-22 Kazu Hirata <kazu@cs.umass.edu>
3049 * jcf-write.c: Follow spelling conventions.
3050 * parse.y: Likewise.
3052 2003-10-22 Kazu Hirata <kazu@cs.umass.edu>
3054 * ChangeLog: Fix typos.
3055 * expr.c: Fix comment typos.
3056 * jcf-write.c: Likewise.
3059 * mangle.c: Likewise.
3060 * parse-scan.y: Likewise.
3061 * parse.y: Likewise.
3063 2003-10-22 Tom Tromey <tromey@redhat.com>
3065 * expr.c (expand_byte_code): Only warn about dead bytecode when
3066 extra_warnings is set.
3068 2003-10-22 Bryce McKinlay <bryce@mckinlay.net.nz>
3070 Fix for PR java/12586.
3071 * mangle.c (find_compression_record_match): Don't iterate through
3072 package namespace elements unless they all match compression_table
3075 2003-10-20 Kelley Cook <kcook@gcc.gnu.org>
3077 * Make-lang.in (info): Honor $(parsedir) and $(docobjdir).
3078 (generate-manpages): Likewise.
3079 (java.maintainer-clean): Likewise.
3080 (gcj.info): Likewise.
3083 (jv-scan.1): Likewise.
3084 (jcf-dump.1): Likewise.
3086 (jv-convert.1): Likewise.
3088 (rmiregistry.1): Likewise.
3089 (java.install-man): Likewise.
3090 (parse-scan.o): Move and define complete compile line.
3091 (parse.o): Likewise.
3092 (jcf-tree-inline.o): Move.
3094 2003-10-20 Mark Mitchell <mark@codesourcery.com>
3096 * Make-lang.in (info): Update dependencies.
3097 (java.install-info): Remove.
3098 ($(srcdir)/java/gcj.info): Replace with ...
3099 ($(docobjdir)/gcj.info): ... this.
3101 2003-10-14 Nathanael Nerode <neroden@gcc.gnu.org>
3103 * Make-lang.in: Replace uses of $(target_alias) with
3104 $(target_noncanonical).
3106 2003-10-09 Tom Tromey <tromey@redhat.com>
3108 * decl.c (java_init_decl_processing): Declare signers field.
3109 * class.c (make_class_data): Set signers field.
3111 2003-10-09 Jason Merrill <jason@redhat.com>
3113 * parse.y (patch_assignment): Use make_node to create a BLOCK.
3114 * parse.h (BUILD_PTR_FROM_NAME): Use make_node to create a
3117 2003-10-06 Mark Mitchell <mark@codesourcery.com>
3119 * Make-lang.in (java.info): Replace with ...
3121 (java.dvi): Replace with ...
3123 (java.generated-manpages): Replace with ...
3125 2003-10-03 Kelley Cook <kelleycook@wideopenwest.com>
3127 * builtins.c, jcf.h, jvspec.c: Remove PARAMS macros.
3129 2003-10-01 Andrew Haley <aph@redhat.com>
3131 * jcf-parse.c (java_parse_file): Write otable and atable.
3132 * java-tree.h (atable_methods): New.
3134 (atable_syms_decl): New.
3135 (enum java_tree_index): Add JTI_ATABLE_METHODS, JTI_ATABLE_DECL,
3136 JTI_ATABLE_SYMS_DECL. Rename JTI_METHOD_SYMBOL* to JTI_SYMBOL*.
3137 (symbol_*type): Rename method_symbol* to symbol*type.
3138 (emit_offset_symbol_table): Delete.
3139 (emit_symbol_table): New.
3140 (get_symbol_table_index): New.
3142 * expr.c (build_field_ref): Handle flag_indirect_dispatch.
3143 (build_known_method_ref): Likewise.
3144 (get_symbol_table_index): Rename from get_offset_table_index.
3145 Parameterize to allow re-use by differing types of symbol table.
3146 (build_invokevirtual): Pass table to get_offset_table_index.
3147 * decl.c (java_init_decl_processing): Push types and decls for
3148 atable and atable_syyms.
3149 * class.c (build_static_field_ref): Handle flag_indirect_dispatch.
3150 (make_class_data): Add new fields atable and atable_syms.
3151 (emit_symbol_table): Rename from emit_offset_symbol_table.
3152 Parameterize to allow re-use by different types of symbol table.
3153 (build_symbol_entry): Renamed from build_method_symbols_entry.
3155 2003-09-30 Roger Sayle <roger@eyesopen.com>
3157 * jcf-write.c (generate_bytecode_insns): Implement evaluate-once
3158 semantics for SAVE_EXPR, by caching the result in a temporary.
3160 2003-09-28 Richard Henderson <rth@redhat.com>
3162 * check-init.c (check_init): Save and restore input_location
3163 instead of file and line separately.
3164 * decl.c (java_expand_body): Likewise.
3165 * jcf-write.c (generate_bytecode_insns): Likewise.
3166 * parse.y (safe_layout_class): Likewise.
3167 * jcf-parse.c (read_class, parse_class_file): Likewise.
3168 (java_parse_file): Use %H for warning locator.
3170 2003-09-28 Roger Sayle <roger@eyesopen.com>
3172 * expr.c (java_check_reference): Use the semantics of COND_EXPRs
3173 with void-type branches instead of using a COMPOUND_EXPR.
3175 2003-09-28 Jeff Sturm <jsturm@one-point.com>
3177 * decl.c (java_optimize_inline, dump_function): Remove.
3178 * java-tree.h (java_optimize_inline): Remove declaration.
3179 * jcf-parse.c (java_parse_file): Assume flag_unit_at_a_time is set.
3180 * parse.y (source_end_java_method, java_expand_classes):
3181 Likewise. Remove dead code.
3183 2003-09-27 Roger Sayle <roger@eyesopen.com>
3185 * lang.c (java_init_options): Set flag_evaluation_order.
3186 * expr.c (force_evaluation_order): Don't attempt to force
3187 evaluation order of binary operations using save_expr.
3188 * parse.y (java_complete_lhs): No longer need to call
3189 force_evaluation_order when constructing binary operators.
3191 2003-09-27 Alexandre Petit-Bianco <apbianco@redhat.com>
3192 Bryce McKinlay <bryce@mckinlay.net.nz>
3195 * parse.y (not_accessible_field_error): New function.
3196 (resolve_expression_name): Check field access permissions.
3197 (resolve_qualified_expression_name): Use
3198 not_accessible_field_error.
3199 (resolve_qualified_expression_name): Likewise.
3201 2003-09-24 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
3203 * class.c (build_utf8_ref): Test for HAVE_GAS_SHF_MERGE value.
3205 2003-09-23 Roger Sayle <roger@eyesopen.com>
3207 * jcf-write.c (generate_bytecode_insns): Optimize binary operations
3208 with equal operands without side-effects.
3210 2003-09-22 Jeff Sturm <jsturm@one-point.com>
3212 * decl.c (java_init_decl_processing): Don't emit otable decls
3213 if flag_indirect_dispatch is not set.
3215 2003-09-21 Richard Henderson <rth@redhat.com>
3217 * class.c, decl.c, jcf-parse.c, jcf-write.c, parse.y,
3220 2003-09-21 Richard Henderson <rth@redhat.com>
3222 * class.c, decl.c, jcf-parse.c, jcf-write.c, parse.y,
3223 resource.c: Update for DECL_SOURCE_LOCATION rename and change to const.
3225 2003-09-20 Richard Henderson <rth@redhat.com>
3227 * check-init.c, class.c, decl.c, expr.c: Use %J in diagnostics.
3229 2003-09-18 Roger Sayle <roger@eyesopen.com>
3231 * expr.c (java_truthvalue_conversion): Remove FFS_EXPR case.
3232 * check-init.c (check_init): Likewise.
3234 2003-09-18 Roger Sayle <roger@eyesopen.com>
3236 * jcf-write.c (generate_bytecode_insns): Add support for fconst_2.
3238 2003-09-16 Andrew Haley <aph@redhat.com>
3240 * jcf-write.c (generate_bytecode_insns): Add MIN_EXPR and MAX_EXPR.
3242 2003-09-17 Ranjit Mathew <rmathew@hotmail.com>
3245 * mangle.c (find_compression_record_match): Skip
3246 over a "6JArray" (the array template mangled string)
3248 (mangle_array_type): Correct minor typo.
3249 (atms): Move definition to the beginning.
3251 2003-09-16 Bryce McKinlay <bryce@mckinlay.net.nz>
3253 * class.c (add_miranda_methods): Ensure super-interfaces are laid
3254 out. Fix for PR java/12254.
3256 2003-09-11 Richard Henderson <rth@redhat.com>
3258 * parse.y (source_end_java_method): Update for new
3259 cgraph_finalize_function argument.
3261 2003-09-09 Richard Henderson <rth@redhat.com>
3263 * parse.y (source_end_java_method): Update call to
3264 cgraph_finalize_function.
3266 2003-09-03 Jeff Sturm <jsturm@one-point.com>
3268 * decl.c (java_expand_body): New function.
3269 * expr.c (build_class_init): Set DECL_IGNORED_P.
3270 * java-tree.h (start_complete_expand_method,
3271 java_expand_body): Declare.
3272 * jcf-parse.c (cgraph.h): Include.
3273 (java_parse_file): Handle flag_unit_at_a_time.
3274 * lang.c (LANG_HOOKS_TREE_INLINING_START_INLINING,
3275 LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Define.
3276 (java_estimate_num_insns): Use walk_tree_without_duplicates.
3277 (java_start_inlining): New function.
3278 * parse.h (java_finish_classes): Declare.
3279 * parse.y: Include cgraph.h.
3280 (block): Don't special-case empty block production.
3281 (craft_constructor): Set DECL_INLINE.
3282 (source_end_java_method): Handle flag_unit_at_a_time.
3283 Replace inline code with call to java_expand_body.
3284 (start_complete_expand_method): Remove static modifier.
3285 (java_expand_method_bodies): Patch function tree for
3286 class initialization and/or synchronization as needed.
3287 Don't begin RTL expansion yet.
3288 (java_expand_classes): Check flag_unit_at_a_time before
3289 calling finish_class.
3290 (java_finish_classes): New function.
3291 (java_complete_lhs): Ensure COMPOUND_EXPR has non-NULL type.
3292 (patch_assignment): Set DECL_CONTEXT on temporary variable.
3293 (emit_test_initialization): Set DECL_IGNORED_P.
3295 2003-09-03 Roger Sayle <roger@eyesopen.com>
3297 * builtins.c (enum builtin_type): Delete unused enumeration.
3298 * Make-lang.in (java/builtins.o): Remove built-types.def dependency.
3300 2003-08-28 Tom Tromey <tromey@redhat.com>
3302 * gcj.texi (Extensions): Document gcjlib URLs.
3304 2003-08-20 Tom Tromey <tromey@redhat.com>
3306 * gcj.texi (Extensions): Added xref.
3307 (libgcj Runtime Properties): Document
3308 gnu.gcj.runtime.VMClassLoader.library_control.
3310 2003-08-20 Andrew Haley <aph@redhat.com>
3312 * except.c (prepare_eh_table_type): Use new encoding for exception
3313 handlers when using -fno-assume-compiled.
3315 2003-08-13 Tom Tromey <tromey@redhat.com>
3317 * gcj.texi (Invoking gij): Document -X and -?.
3319 2003-08-13 Mohan Embar <gnustuff@thisiscool.com>
3321 * Make-lang.in: Added missing win32-host.o to JAVA_OBJS,
3322 GCJH_OBJS, JCFDUMP_OBJS
3323 * win32-host.c: Removed the unnecessary and broken dependency
3326 2003-08-11 Tom Tromey <tromey@redhat.com>
3328 * parse.y (java_check_regular_methods): Typo fixes. Call
3329 check_interface_throws_clauses. Use
3330 check_concrete_throws_clauses.
3331 (check_interface_throws_clauses): New function.
3332 (check_concrete_throws_clauses): New function.
3333 (hack_is_accessible_p): New function.
3334 (find_most_specific_methods_list): Added FIXME.
3335 * typeck.c (lookup_do): Use `flags' argument to decide what to
3337 (lookup_argument_method_generic): New function.
3338 (lookup_argument_method2): Removed.
3339 * jcf.h (ACC_INVISIBLE): New define.
3340 * jcf-write.c (generate_classfile): Skip invisible methods.
3341 * class.c (add_miranda_methods): New function.
3342 (layout_class_methods): Use it.
3343 (get_access_flags_from_decl): Use ACC_INVISIBLE.
3344 * java-tree.h (METHOD_INVISIBLE): New define.
3345 (lang_decl_func) [invisible]: New field.
3346 (lookup_argument_method_generic): Declare.
3347 (SEARCH_INTERFACE): New define.
3348 (SEARCH_SUPER): Likewise.
3349 (SEARCH_ONLY_INTERFACE): Likewise.
3350 (SEARCH_VISIBLE): Likewise.
3351 (lookup_argument_method2): Removed declaration.
3353 2003-08-05 Tom Tromey <tromey@redhat.com>
3355 Fix for PR java/11600:
3356 * parse.y (java_complete_lhs): See whether we're calling a method
3358 (check_thrown_exceptions): Added `is_array_call' argument;
3359 fixed `clone' checking; updated all callers.
3361 2003-08-05 Steven Bosscher <steven@gcc.gnu.org>
3363 * java-tree.h (DECL_ESTIMATED_INSNS): Remove (moved to tree.h).
3365 2003-08-03 Tom Tromey <tromey@redhat.com>
3367 * java-tree.h (METHOD_TRANSIENT): Removed.
3368 * decl.c (pushdecl): Removed some dead code.
3369 * class.c (get_access_flags_from_decl): Can't have transient
3371 (add_method_1): Can't have a transient method.
3373 2003-07-28 Andreas Jaeger <aj@suse.de>
3375 * jvspec.c: Convert to ISO C90 prototypes.
3377 2003-07-25 Nathan Sidwell <nathan@codesourcery.com>
3379 * decl.c (force_poplevels): Fix warning call.
3381 2003-07-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
3383 * expr.c (expand_java_field_op): Don't use xxx_with_decl
3384 (expand_java_field_op): Likewise.
3385 * class.c (layout_class_method): Likewise
3386 (emit_register_classes): Likewise.
3387 * decl.c (pushdecl): Likewise.
3388 (poplevel): Likewise.
3389 (force_poplevels): Likewise.
3390 (give_name_to_locals): Likewise.
3391 * check-init.c (check_for_initialization): Likewise.
3393 2003-07-24 Jason Merrill <jason@redhat.com>
3395 * java-tree.h: Move boolean_type_node et al to the back end.
3397 2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
3399 * class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary
3402 2003-07-19 Neil Booth <neil@daikokuya.co.uk>
3404 * lang.opt: Don't show -MD_ and -MDD_.
3406 2003-07-18 Neil Booth <neil@daikokuya.co.uk>
3408 * lang-options.h: Remove.
3409 * lang.opt: Add help text.
3411 2003-07-15 Kazu Hirata <kazu@cs.umass.edu>
3413 * expr.c: Remove the last argument to expand_assignment().
3415 2003-07-09 Jan Hubicka <jh@suse.cz>
3417 * java-tree.h (DECL_NUM_STMTS): Rename to...
3418 (DECL_ESTIMATED_INSNS): ... this.
3419 * lang.c (java_estimate_num_insns, java_estimate_num_insns_1):
3420 New static functions.
3421 (LANG_HOOKS_TREE_INLINING_ESTIMATE_NUM_INSNS): Define.
3422 * parser.y (add_stmt_to_compound): Do not account statements.
3424 2003-07-08 Mark Wielaard <mark@klomp.org>
3426 * gcj.texi: CNI now expands to Compiled Native Interface.
3428 2003-07-08 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
3430 * Make-lang.in (java/gcj.dvi): Use PWD_COMMAND.
3432 2003-07-07 Nathan Sidwell <nathan@codesourcery.com>
3434 * expr.c (expand_byte_code): Adjist emit_line_note call.
3436 2003-07-06 Neil Booth <neil@daikokuya.co.uk>
3438 * lang.c (java_handle_option): Don't handle filenames.
3440 2003-07-02 Zack Weinberg <zack@codesourcery.com>
3442 * jcf-path.c: Don't default-define PATH_SEPARATOR nor
3445 * jcf-write.c: Don't default-define DIR_SEPARATOR.
3446 * jcf.h: Delete COMPARE_FILENAMES d