Paul Brook [Tue, 2 Nov 2004 00:27:13 +0000 (00:27 +0000)]
intrinsic.c (check_intrinsic_standard): Include error locus.
* intrinsic.c (check_intrinsic_standard): Include error locus.
Remove VLA.
(gfc_intrinsic_func_interface, gfc_intrinsic_sub_interface): Pass
locus to check_intrinsic_standard.
Andrew MacLeod [Tue, 2 Nov 2004 00:23:04 +0000 (00:23 +0000)]
re PR tree-optimization/16447 (out of ssa generates bloated code)
2004-11-01 Andrew MacLeod <amacleod@redhat.com>
PR tree-optimization/16447
* tree-cfg.c (bsi_commit_one_edge_insert): Rename from
bsi_commit_edge_inserts_1, and make funtion external. Return new block.
(bsi_commit_edge_inserts): Use renamed bsi_commit_one_edge_insert.
* tree-optimize.c (pass_cleanup_cfg_post_optimizing): Enable listing.
* tree-flow.h (bsi_commit_one_edge_insert): Extern decl.
* tree-outof-ssa.c (rewrite_trees): Don't commit edges here.
(same_stmt_list_p): New. Return TRUE if edge is to be forwarded.
(identical_copies_p): New. Return true is two copies are the same.
(identical_stmt_lists_p): New. Return true if stmt lists are the same.
(analyze_edges_for_bb): New. Determine how best to insert edge stmts
for a basic block.
(perform_edge_inserts): New. Determine what to do with all stmts that
have been inserted on edges.
(remove_ssa_form): Analyze and commit edges from here.
Andrew Pinski [Mon, 1 Nov 2004 22:24:52 +0000 (22:24 +0000)]
re PR tree-optimization/18232 (../../gcc/gcc/tree-ssa-operands.c:1624: warning: 'bi$ptr2' is used uninitialized in this function)
2004-11-01 Andrew Pinski <pinskia@physics.uc.edu>
PR bootstrap/18232
* bitmap.h (bmp_iter_end_p): Take a const pointer instead of a struct.
(EXECUTE_IF_SET_IN_BITMAP): Update call to bmp_iter_end_p.
(EXECUTE_IF_AND_COMPL_IN_BITMAP): Likewise.
(EXECUTE_IF_AND_IN_BITMAP): Likewise.
Mike Stump [Mon, 1 Nov 2004 19:01:15 +0000 (19:01 +0000)]
inclhack.def (stdio_va_list): Break out clients from here...
* inclhack.def (stdio_va_list): Break out clients from here...
(stdio_va_list_clients): ...to here. Also, don't fix if stdarg.h is
included or ifdef va_start.
Andreas Krebbel [Mon, 1 Nov 2004 18:50:20 +0000 (18:50 +0000)]
s390.c (regclass_map): Put reg 33 (cc) to CC_REGS group.
2004-11-01 Andreas Krebbel <krebbel1@de.ibm.com>
* config/s390/s390.c (regclass_map): Put reg 33 (cc) to CC_REGS group.
(s390_secondary_input_reload_class)
(s390_secondary_output_reload_class): Use GENERAL_REGS to reload a cc
register.
(s390_expand_cmpmem): Enable cmpmem implementation.
* config/s390/s390.h (reg_class, REG_CLASS_NAMES, REG_CLASS_CONTENTS):
Added three new classes: CC_REGS, ADDR_CC_REGS, GENERAL_CC_REGS.
(REG_CLASS_FROM_LETTER): New constraint 'c' added.
* config/s390/s390.md ("movcc"): New insn pattern.
* doc/md.texi: Document 'c' constraint for s390.
* lambda-code.c (lambda_lattice_compute_base): Fix reversed
assert test.
(gcc_tree_to_linear_expression): Add extra to existing constant.
(depth_of_nest): Factor out function used in various places.
(gcc_loop_to_lambda_loop): Clean up code a little bit. No
functional changes.
(find_induction_var_from_exit_cond): Stop guessing, and just
get the right answer :).
(gcc_loopnest_to_lambda_loopnest): Remove useless pre-allocation.
Print out message about result of attempt to create perfect nest.
(lbv_to_gcc_expression): Add type argument, use it to do math
and induction variable creation.
(lle_to_gcc_expression): Ditto.
(lambda_loopnest_to_gcc_loopnest): Create new iv with same type as
oldiv. Pass type argument to lle_to_gcc_expression and
lbv_to_gcc_expression.
Reset number of iterations after transformation.
(perfect_nestify): Remove useless pre-allocation, and cleanup
a small amount.
* tree-data-ref.c (build_classic_dist_vector): Return false for
dependences completely outside of the loop nest we asked about.
(build_classic_dir_vector): Ditto.
(compute_data_dependences_for_loop): Only add dependence relations
inside the loop we asked about.
* tree-loop-linear.c (linear_transform_loops): Use DDR_SIZE_VECT.
Compute immediate uses.
* tree-optimize.c: Move linear_transform_loops to before ivcanon.
Paolo Carlini [Mon, 1 Nov 2004 11:31:44 +0000 (11:31 +0000)]
locale_facets.tcc (num_get<>::_M_extract_float): Evaluate *__beg the exact strict minimum number of times...
2004-11-01 Paolo Carlini <pcarlini@suse.de>
* include/bits/locale_facets.tcc (num_get<>::_M_extract_float):
Evaluate *__beg the exact strict minimum number of times; likewise
for __beg != __end; in the main parsing loop, call ++__beg in two
places only. The former is also a correctness issue, because,
according to the standard (22.2.2.1.2, Stage 2), 'in' shall be
dereferenced only one time for each increment.
* cfgloop.h (struct loop): Remove unused "nodes" field.
* timevar.def (TV_TREE_LOOP_BOUNDS): New.
* tree-data-ref.c (find_data_references_in_loop): Use get_loop_body
instead of calling flow_bb_inside_loop_p for every basic block
in the function.
* tree-ssa-loop.c (pass_record_bounds): Use TV_TREE_LOOP_BOUNDS.
Ziemowit Laski [Sun, 31 Oct 2004 06:17:55 +0000 (06:17 +0000)]
c-common.h (objc_lookup_ivar): Add second parameter to prototype.
[gcc/ChangeLog]
2004-10-30 Ziemowit Laski <zlaski@apple.com>
* c-common.h (objc_lookup_ivar): Add second parameter to
prototype.
* c-typeck.c (build_external_ref): After looking up symbol,
pass it to objc_lookup_ivar() to decide whether it or the
ivar should be used, rather than deciding the issue locally.
* stub-objc.c (objc_lookup_ivar): Add an OTHER parameter,
which is simply returned in the non-ObjC case.
[gcc/objc/ChangeLog]
2004-10-30 Ziemowit Laski <zlaski@apple.com>
* objc-act.c (objc_lookup_ivar): The new OTHER parameter
contains the result of the ID lookup by the C or C++
front-end; in class methods, use OTHER if it exists;
in instance methods, use OTHER only if it is locally
declared.
[gcc/testsuite/ChangeLog]
2004-10-30 Ziemowit Laski <zlaski@apple.com>
Janne Blomqvist [Sun, 31 Oct 2004 01:24:29 +0000 (03:24 +0200)]
re PR fortran/17590 (Standard conformance should take intrinsics into account.)
2004-10-31 Janne Blomqvist <jblomqvi@cc.hut.fi>
PR fortran/17590
* gfortran.h: Change GFC_STD_* flags to more appropriate
ones. (struct gfc_intrinsic_isym): Add field for standard. (struct
gfc_option_t): Add field for warning about use of nonstandard
intrinsics.
* intrinsic.c (add_sym): Add parameter for standard version, check
this against current standard.
(add_sym_0): Pass standard parameter to add_sym.
(add_sym_1, add_sym_0s, add_sym_1s, add_sym_1m, add_sym_2): Ditto.
(add_sym_2s, add_sym_3, add_sym_3ml, add_sym_3red, add_sym_3s): Ditto.
(add_sym_4, add_sym_4s, add_sym_5, add_sym_5s): Ditto.
(make_generic): Add parameter for standard, check this
against currently selected standard.
(add_functions, add_subroutines): Add parameter to tell which
standard an intrinsic belongs to.
(check_intrinsic_standard): New function.
(gfc_intrinsic_func_interface): Add call to check_intrinsic_standard.
(gfc_intrinsic_sub_interface): Ditto.
* lang.opt: Add Wnonstd-intrinsics option.
* options.c (gfc_init_options): Change to use new GFC_STD_* flags,
init new warning.
(set_Wall): Add warning about nonstd intrinsics.
(gfc_handle_option): Change to use new GFC_STD_* flags,
handle new warning.
* invoke.texi: Update manual to include -Wnonstd-intrinsics.
Kaz Kojima [Sat, 30 Oct 2004 23:29:46 +0000 (23:29 +0000)]
sh.c (calc_live_regs): Declare reg as unsigned and modify the for loop expressions for it.
* config/sh/sh.c (calc_live_regs): Declare reg as unsigned and
modify the for loop expressions for it. Remove unnecessary casts.
(sh_expand_prologue): Declare reg as unsigned.
(sh_gimplify_va_arg_expr): Initinalize lab_over.
(sh_handle_sp_switch_attribute): Add const qualifier appropriately.
Roger Sayle [Sat, 30 Oct 2004 19:20:43 +0000 (19:20 +0000)]
re PR middle-end/18096 (internal compiler error: in final_scan_insn, at final.c:2429)
PR middle-end/18096
* config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Check that
the stack adjustment, "size", is valid for Pmode. If the stack
frame is too large, generate a trap insn and issue a warning.
Joseph Myers [Sat, 30 Oct 2004 08:50:31 +0000 (09:50 +0100)]
re PR c/16666 (dremf type conflict)
PR c/16666
* c-decl.c (start_function): Don't check for DECL_BUILT_IN when
determining whether to copy parameter types from a previous
prototype declaration.
Geoffrey Keating [Sat, 30 Oct 2004 01:03:12 +0000 (01:03 +0000)]
configure.host (darwin*): Set os_include_dir to a separate directory for Darwin.
* configure.host (darwin*): Set os_include_dir to a separate directory
for Darwin.
* acinclude.m4 (GLIBCXX_ENABLE_CLOCALE): Add a new C locale kind,
'darwin'.
* config/locale/darwin/ctype_members.cc: New.
* config/os/bsd/darwin/ctype_base.h: New.
* config/os/bsd/darwin/ctype_inline.h: New.
* config/os/bsd/darwin/ctype_noninline.h: New.
* config/os/bsd/darwin/os_defines.h: New.
Roger Sayle [Sat, 30 Oct 2004 00:56:59 +0000 (00:56 +0000)]
re PR rtl-optimization/17581 (Long long arithmetic fails inside a switch/case statement when compiled with -O2)
PR rtl-optimization/17581
* cselib.c (cselib_process_insn): The last instruction of a libcall
block, with the REG_RETVAL note, should be considered in the libcall.
* gcse.c (do_local_cprop): Allow constants to be propagated outside
of libcall blocks.
(adjust_libcall_notes): Use simplify_replace_rtx instead of
replace_rtx to avoid creating invalid RTL in REG_RETVAL notes.
Jeff Law [Sat, 30 Oct 2004 00:06:22 +0000 (18:06 -0600)]
tree-ssa-dom.c (struct edge_info): New structure holding edge equivalences and edge redirection information.
* tree-ssa-dom.c (struct edge_info): New structure holding
edge equivalences and edge redirection information.
(get_eq_expr_value, record_dominating_conditions): Kill.
(propagate_to_outgoing_edges): Renamed from cprop_into_phis.
Call record_edge_info.
(allocate_edge_info, free_edge_info): New.
(tree_ssa_dominator_optimize): Use propagate_to_outgoing_edges
rather than cprop_into_phis. Free all edge infos before threading
jumps.
(thread_across_edge): Allocate new edge info structures as needed
and store the redirection target into the edge info structure
instead of the edge's AUX field.
(dom_opt_initialize_block): Mark unused argument with ATTRIBUTE_UNUSED.
(record_equivalence_from_incoming_edge): Lose unnecessary argument.
Revamp code which finds and records equivalences associated with
edges to use saved data in the edge_info structure.
(record_equivalencs_from_phis): Similarly.
(dom_opt_finalize_block): Revamp code which finds and records
equivalences associated with edges to use saved data in the
edge_info structure.
(build_and_record_new_cond): New function.
(record_conditions): Use build_and_record_new_cond to record
dominating conditions.
(record_edge_info): New function.
(record_range): Tighten test for conditions which create
useful range records.
Nathan Sidwell [Fri, 29 Oct 2004 08:35:49 +0000 (08:35 +0000)]
typeck.c (composite_pointer_type): Remove comment about DR 195.
cp:
* typeck.c (composite_pointer_type): Remove comment about DR 195.
(build_reinterpret_cast_1): Revert DR195 patch. Only emit a
warning when being pedantic.
(build_reinterpet_cast, build_c_cast): Adjust.
testsuite:
* g++.dg/conversion/dr195.C: Adjust expected errors for DR195 not
being implemented.
* g++.dg/conversion/dr195-1.C: New.
* g++.old-deja/g++.brendan/operators4.C: Don't be pedantic.
* g++.old-deja/g++.mike/p10148.C: Likewise.
Daniel Berlin [Fri, 29 Oct 2004 02:13:03 +0000 (02:13 +0000)]
tree-into-ssa.c (rewrite_virtual_phi_arguments): New function.
2004-10-28 Daniel Berlin <dberlin@dberlin.org>
* tree-into-ssa.c (rewrite_virtual_phi_arguments): New function.
(rewrite_blocks): Modify argument, and use it to decide which
function to call.
(rewrite_def_def_chains): Call rewrite_blocks with true here.
(rewrite_into_ssa): and call it with false here.
Andrew Pinski [Thu, 28 Oct 2004 23:38:47 +0000 (23:38 +0000)]
visibility-[1-9a].c: Change to use scan-hidden instead of scan-assembler.
2004-10-28 Andrew Pinski <pinskia@physics.uc.edu>
* gcc.dg/visibility-[1-9a].c: Change to use scan-hidden instead of
scan-assembler.
* lib/scanasm.exp (hidden-scan-for): New proc.
(scan-hidden): Use hidden-scan-for instead of constructing the scan
string.
(scan-not-hidden): Likewise.
* lib/target-supports.exp (check_visibility_available): mach-o is
support too.
Added pedantic_min_int to gfc_integer_info Added ARITH_ASYMMETRIC to arith...
Added pedantic_min_int to gfc_integer_info
Added ARITH_ASYMMETRIC to arith
Added support for an "asymmetric integer" warning when compiling with pedantic
Set minimum integer values to reflect realities of two's complement signed integers
Frank Ch. Eigler [Thu, 28 Oct 2004 21:24:33 +0000 (21:24 +0000)]
tree-mudflap.c (mudflap_init): Mark cache-lookup decls to prevent their later unnecessary registration.
2004-10-28 Frank Ch. Eigler <fche@redhat.com>
* tree-mudflap.c (mudflap_init): Mark cache-lookup decls to
prevent their later unnecessary registration.
(mf_build_check_statement_for): Remove "addr" argument, and
related "__mf_value" generated code. Update callers.
(mf_decl_eligible_p): New function, factored from mx_register_decls.
(mx_register_decls): Call it.
(mf_xform_derefs_1): Rewrite COMPONENT_REF and ARRAY_REF cases
to restore support for complex nested expressions.
(mudflap_enqueue_decl): Simplify. Move registration call emission
out ...
(mudflap_finish_file): ... to here.
(mudflap_enqueue_constant): Remove dump code.