PR c/13801
* c-decl.c (struct c_binding): Add type and inner_comp fields.
(bind): Set type and inner_comp fields.
(pop_scope): Restore type of decl to the correct type from an
outer scope. Give error when popping file scope for incomplete
arrays completed incompatibly with default initialization in an
inner scope.
(diagnose_mismatched_decls): Handle externs with initializers at
block scope.
(pushdecl): Set type of external declaration at block scope based
only on the visible declarations. Save type when changing the
type of a declaration. Merge an external declaration at block
scope with a visible static declaration at file scope.
(implicitly_declare): Give recycled old declaration the new type
except for incompatible declarations of built-in functions, saving
the old type.
testsuite:
* gcc.dg/redecl-3.c, gcc.dg/redecl-4.c, gcc.dg/redecl-6.c,
gcc.dg/redecl-7.c, gcc.dg/redecl-8.c, gcc.dg/redecl-9.c,
gcc.dg/redecl-10.c, gcc.dg/debug/redecl-1.c,
gcc.dg/debug/redecl-2.c, gcc.dg/debug/redecl-3.c,
gcc.dg/debug/redecl-4.c, gcc.dg/debug/redecl-5.c: New tests.
From-SVN: r86636
2004-08-26 Daniel Berlin <dberlin@dberlin.org>
* tree-alias-common.c (gate_pta): New function.
(pass_build_pta): Use it.
(pass_del_pta): Use it.
(delete_alias_vars): Don't check flag_tree_points_to.
From-SVN: r86631
* cp-tree.h (DECL_FIELD_IS_BASE): New.
* class.c (build_base_field): Set it.
(build_simple_base_path): Use it.
(fixed_type_or_null): Don't consider base fields definitive.
From-SVN: r86630
2004-08-26 Daniel Berlin <dberlin@dberlin.org>
* Makefile.in (lambda-code.o): New.
(lambda-trans.o): Ditto.
(TREE_DATA_REF_H): Ditto.
(LAMBDA_H): Ditto.
(lambda-mat.o): Use LAMBDA_H.
(tree-data-ref.o): Ditto.
* lambda-code.c: New file. Lambda code generation algorithm.
* lambda-trans.c: Ditto. Lambda transformation matrix support.
* lambda.h: Add lambda loop structures.
Add lambda loopnest structures.
Add lambda body vector structure.
Add lambda linear expression structures.
Add prototypes for functions in new files.
* lambda-mat.c: Include tree.h
2004-08-26 Daniel Berlin <dberlin@dberlin.org>
Sebastian Pop <pop@cri.ensmp.fr>
* tree-data-ref.h: Include lambda.h
(free_dependence_relation): Declared here.
(free_dependence_relations): Ditto.
(free_data_refs): Ditto.
* tree-data-ref.c (free_dependence_relation): New function.
(free_dependence_relations): Ditto.
(free_data_refs): Ditot.
(analyze_all_data_dependences): Free datarefs and dependence_relations.
(build_classic_dist_vector): Store in the dependence_relations the
information. Each arc in the dependence_relations graph is labelled
with the distance and direction vectors.
(build_classic_dir_vector): Ditto.
(compute_rw_wr_ww_dependences): Renamed again compute_all_dependences.
Now computes again the whole dependence graph including read-read
relations.
(compute_data_dependences_for_loop): Now dependence_relations contains
all the data, and thus it doesn't need to initialize the classic_dir
and classic_dist vectors.
(analyze_all_data_dependences): Adjusted for using the new interface of
compute_data_dependences_for_loop. Remove the statistics dump.
Co-Authored-By: Sebastian Pop <pop@cri.ensmp.fr>
From-SVN: r86627
2004-08-26 Mark Wielaard <mark@klomp.org>
Fixes PR libgcj/17002:
* java/util/TimeZone.java (defaultZone): Try a couple of ways to get
a TimeZoneId string and then try to convert that to a TimeZone with
getDefaultSystemTimeZone(String).
(timezones0): Changed type from Hashtable to HashMap.
(timezones): Create HashMap, not Hashtable.
(getDefaultTimeZone): New method, rewritten from CNI version.
(readTimeZoneFile): New method.
(readtzFile): Likewise.
(skipFully): Likewise.
* java/util/natTimeZone.cc (getSystemTimeZone): Renamed to
getDefaultTimeZoneId and rewritten.
(getDefaultTimeZoneId): Rewritten in java.
From-SVN: r86623
PR target/17119.
config/m32r.c (gen_compare): Use reg_or_int16_operand when checking for a
valid constant, regardless of sign.
testsuite/gcc.c-torture/compile/pr17119.c: New test (for this failure)
From-SVN: r86619
PR target/16480
* config/rs6000/rs6000.c (rs6000_split_multireg_move): Don't abort
on "(mem (symbol_ref ..))" rtl. Look at LO_SUM base regs as well
as PLUS base regs.
From-SVN: r86598
fortran/
* expr.c (gfc_check_assign): Add comment. Add new warning.
* trans-expr.c (gfc_conv_function_call): Correctly dereference
result of pointer valued function when not in pointer assignment.
testsuite/
* gfortran.dg/assignment_1.f90: New test.
From-SVN: r86585
2004-08-25 Andrew MacLeod <amacleod@redhat.com>
* tree-ssa-operands.h (struct ssa_operand_iterator_d): New. SSA operand
iterator controlling structure.
(SSA_OP_USE, SSA_OP_DEF, SSA_OP_VUSE, SSA_OP_VMAYUSE, SSA_OP_VMAYDEF,
SSA_OP_VMUSTDEF, SSA_OP_VIRTUAL_USES, SSA_OP_VIRTUAL_DEFS,
SSA_OP_ALL_USES, SSA_OP_ALL_DEFS, SSA_OP_ALL_OPERANDS): New. Operand
iterator flags.
(FOR_EACH_SSA_TREE_OPERAND): New. Iterate over operands as trees.
(FOR_EACH_SSA_USE_OPERAND): New. Iterate over operands as uses.
(FOR_EACH_SSA_DEF_OPERAND): New. Iterate over operands as defs.
(FOR_EACH_SSA_MAYDEF_OPERAND): New. Iterate over V_MAY_DEFs.
* tree-ssa-operands.c (NULL_DEF_OPERAND_P, NULL_USE_OPERAND_P): New.
Empty operand pointers.
* tree-flow-inline.h (op_iter_done): New. Return true if finished.
(op_iter_next_use): New. Return next use_operand_p.
(op_iter_next_def): New. Return next def_operand_p.
(op_iter_next_tree): New. Return next operands as a tree.
(op_iter_init): New. Initialize an iterator structure.
(op_iter_init_use): New. Initialize structure and get the first use.
(op_iter_init_def): New. Initialize structure and get the first def.
(op_iter_init_tree): New. Initialize structure and get the first tree.
(op_iter_next_maydef): New. Return next V_MAY_DEF operands.
(op_iter_init_maydef): New. Initialize structure and get the first
V_MAY_DEF operands.
* tree-cfg.c (tree_duplicate_bb): Use new operand iterator.
* tree-dfa.c (compute_immediate_uses_for_stmt,
redirect_immediate_uses): Use new operand iterator.
(v_may_defs_disappeared_p, v_must_defs_disappeared_p): Delete.
(mark_new_vars_to_rename): Use new operand iterator. Count virtual
operands instead of using *_disappeared_p routines.
* tree-into-ssa.c (mark_def_sites, ssa_mark_def_sites, rewrite_stmt,
ssa_rewrite_stmt): Use new operand iterator.
* tree-outof-ssa.c (check_replaceable, find_replaceable_in_bb,
rewrite_trees): Use new operand iterator.
* tree-pretty-print.c (dump_vops): Use new operand iterator.
* tree-sra.c (mark_all_v_defs): Use new operand iterator.
* tree-ssa-alias.c (compute_points_to_and_addr_escape,
dump_points_to_info): Use new operand iterator.
* tree-ssa-ccp.c (cp_lattice_meet, visit_stmt, initialize,
replace_uses_in, replace_vuse_in, likely_value, set_rhs): Use new
operand iterator.
* tree-ssa-dce.c (mark_stmt_if_obviously_necessary,
propagate_necessity): Use new operand iterator.
* tree-ssa-dom.c (cprop_into_stmt, optimize_stmt): Use operand iterator.
(register_definitions_for_stmt): Use new operand iterator. Take stmt as
a parameter instead of a stmt_ann_t.
* tree-ssa-live.c (create_ssa_var_map, calculate_live_on_entry,
build_tree_conflict_graph): Use new operand iterator.
* tree-ssa-loop-im.c (determine_max_movement, single_reachable_address,
rewrite_mem_refs): Use new operand iterator.
* tree-ssa-loop-manip.c (find_uses_to_rename_stmt,
check_loop_closed_ssa_use): Use new operand iterator.
* tree-ssa.c (verify_ssa, replace_immediate_uses): Use operand iterator.
* tree-ssanames.c (release_defs): Use new operand iterator.
* tree-vectorizer.c (vect_create_data_ref): Use new operand iterator.
From-SVN: r86583
* tlink.c (initial_cwd): New variable.
(tlink_init): Initialize it.
(recompile_files): Use tlink_execute() instead of system(). Don't
duplicate verbose output of collect_execute. Restore initial_cwd.
Update comment before the function.
From-SVN: r86577
PR middle-end/16693
PR tree-optimization/16372
* decl.c (finish_enum): Make the precision of the enumerated type
the same width as the underlying integer type.
* g++.dg/opt/pr16372-1.C: New test case.
* g++.dg/opt/pr16693-1.C: New test case.
* g++.dg/opt/pr16693-2.C: New test case.
From-SVN: r86576
[gcc/ChangeLog]
2004-08-25 Ziemowit Laski <zlaski@apple.com>
* c-typeck.c (build_c_cast): In ObjC, always preserve (and silently
accept) a cast from one Objective-C pointer type to another.
[gcc/testsuite/ChangeLog]
2004-08-25 Ziemowit Laski <zlaski@apple.com>
* objc.dg/proto-lossage-4.m: New test.
From-SVN: r86574
PR c++/17155
* lex.c (build_lang_decl): Set DECL_NO_STATIC_CHAIN for all C++
functions.
PR c++/17155
* g++.dg/inherit/local2.C: New test.
From-SVN: r86571
* config/mips/mips.md (any_shift): New code macro.
(optab, insn): New code attributes.
({ashl,ashr,lshr}[sd]i3): Redefine using :GPR and any_shift.
Use the standard rather than internal patterns for the MIPS16
double-shift optimization.
(*{ashl,ashr,lshr}[sd]i3): New names for the non-mips16 shift patterns.
Redefine using :GPR and any_shift.
(*{ashl,ashr,lshr}si3_extend): Generalize ashlsi3_internal1_extend
to cover all three shifts.
(*{ashl,ashr,lshr}si3_mips16): New names for the mips16 SImode shifts.
Redefine using any_shift. Use :GPR and any_shift to combine splitters.
(*{ashl,ashr,lshr}di3_mips16): New names for the mips16 DImode shifts.
From-SVN: r86566