Commit Graph

74789 Commits

Author SHA1 Message Date
Daniel Berlin
832a0c1d09 re PR tree-optimization/26626 (ICE in in add_virtual_operand)
2006-05-02  Daniel Berlin  <dberlin@dberlin.org>

	Fix PR tree-optimization/26626
	* tree-ssa-structalias.c (compute_points_to_sets): For now, solve
	always.
	* tree-ssa-operands.c (access_can_touch_variable): Allow
	typecasting through union pointers.

From-SVN: r113493
2006-05-03 03:19:22 +00:00
Mark Mitchell
cc3281454e re PR c++/27102 (ICE with invalid class name in function template)
PR c++/27102
	* decl.c (grokdeclarator): Robustify checks for defining members
	of incomplete types.
	PR c++/27102
	* g++.dg/template/crash49.C: New test.

From-SVN: r113492
2006-05-03 00:19:40 +00:00
GCC Administrator
db40f6d4a1 Daily bump.
From-SVN: r113490
2006-05-03 00:18:06 +00:00
Steve Ellcey
b931db5f4d re PR testsuite/27032 (gcc.c-torture/compile/pr23237.c fails)
PR testsuite/27032
	* gcc.c-torture/compile/pr23237.c: Move dg-do line.

From-SVN: r113484
2006-05-02 22:16:13 +00:00
Jakub Jelinek
8ca5b2a2d4 re PR c++/26943 ([gomp] firstprivate + lastprivate uses inefficient barrier)
PR c++/26943
	* omp-low.c (maybe_lookup_decl_in_outer_ctx): New function.
	(build_outer_var_ref): Use maybe_lookup_decl_in_outer_ctx
	to find if var will be a global variable even in the nested context.
	(omp_copy_decl): Only check for global variable at the end, it might
	be overridden in outer contexts.
	(scan_sharing_clauses): For global variables don't create a field.
	(lower_rec_input_clauses): Do nothing for global shared variables.
	Emit a barrier at the end of ILIST if there were any decls in both
	firstprivate and lastprivate clauses.
	(lower_send_clauses): Do nothing for global variables except for
	COPYIN.

	* testsuite/libgomp.c/pr26943-1.c: New test.
	* testsuite/libgomp.c/pr26943-2.c: New test.
	* testsuite/libgomp.c/pr26943-3.c: New test.
	* testsuite/libgomp.c/pr26943-4.c: New test.
	* testsuite/libgomp.c++/pr27337.C: Remove barrier.
	* testsuite/libgomp.c++/pr26943.C: New test.

From-SVN: r113483
2006-05-02 22:03:38 +02:00
Zdenek Dvorak
a3428e0701 tree.c (unsigned_type_for, [...]): Make sure a type of the correct signedness is returned.
* tree.c (unsigned_type_for, signed_type_for): Make sure a type
	of the correct signedness is returned.

From-SVN: r113482
2006-05-02 19:59:21 +00:00
Jeff Law
26ef43017a re PR tree-optimization/27364 (VRP miscompiles some unsigned math)
PR tree-optimization/27364
	* tree-vrp.c (vrp_int_const_binop): Fix detection of overflow from
	multiply expressions.

	* gcc.c-torture/execute/pr27364.c: New test.

From-SVN: r113481
2006-05-02 13:54:20 -06:00
Bryce McKinlay
e6cbdf26b4 libjava.exp (test_libjava): Test bytecode->native -findirect-dispatch compilation.
2006-05-02  Bryce McKinlay  <mckinlay@redhat.com>

        * testsuite/lib/libjava.exp (test_libjava): Test bytecode->native
        -findirect-dispatch compilation.

From-SVN: r113477
2006-05-02 18:41:40 +01:00
Mark Mitchell
7137605e8f re PR c++/27309 (ICE on invalid constructor definition)
PR c++/27309
	* class.c (add_method): Call grok_special_member_properties.
	* decl.c (grokdeclarator): Don't call it here.
	(copy_fn_p): A TEMPLATE_DECL is never a copy constructor or
	assignment operator.  Set TYPE_HAS_CONSTURCTOR if DECL is a
	constructor.
	(start_method): Don't call grok_special_member_properties.
	* method.c (implicitly_declare_fn): Likewise.
	* pt.c (instantiate_class_template): Likewise.
	* decl2.c (grokfield): Likewise.
	PR c++/27309
	* g++.dg/parser/ctor5.C: New test.

From-SVN: r113473
2006-05-02 15:59:50 +00:00
Tom Tromey
263bb8fb86 * tree-flow-inline.h (op_iter_init_phiuse): Fixed typo.
From-SVN: r113472
2006-05-02 15:54:00 +00:00
Kazu Hirata
3abde0f150 re PR target/27387 (Thumb thunk is not PIC)
gcc/
	PR target/27387
	* arm.c (arm_output_mi_thunk): Use pc-relative addressing when
	-mthumb -fPIC are used.

testsuite/
	PR target/27387
	* gcc.target/arm/arm.exp: New.
	* gcc.target/arm/pr27387.C: Likewise.

From-SVN: r113468
2006-05-02 15:06:35 +00:00
Kazu Hirata
54b9e93953 re PR target/27387 (Thumb thunk is not PIC)
gcc/
	PR target/27387
	* arm.c (arm_output_mi_thunk): Use pc-relative addressing when
	-mthumb -fPIC are used.

testsuite/
	PR target/27387
	* gcc.target/arm/arm.exp: New.
	* gcc.target/arm/pr27387.C: Likewise.

From-SVN: r113467
2006-05-02 15:04:52 +00:00
Paul Thomas
613e2ac8d3 re PR fortran/27269 (Segfault with EQUIVALENCEs in modules together with ONLY clauses)
2006-05-02 Paul Thomas <pault@gcc.gnu.org>

        PR fortran/27269
        * module.c: Add static flag in_load_equiv.
        (mio_expr_ref): Return if no symtree and in_load_equiv.
        (load_equiv): If any of the equivalence members have no symtree, free
        the equivalence and the associated expressions.

        PR fortran/27324
        * trans-common.c (gfc_trans_common): Invert the order of calls to
        finish equivalences and gfc_commit_symbols.

        PR fortran/27269
        PR fortran/27324
        * gfortran.dg/module_equivalence_2.f90: New test.

From-SVN: r113465
2006-05-02 14:13:17 +00:00
Daniel Jacobowitz
597fb86c90 Correct changelog date in last commit.
From-SVN: r113463
2006-05-02 14:00:22 +00:00
Daniel Jacobowitz
84309a323e * texi2pod.pl: Handle -I.
From-SVN: r113462
2006-05-02 13:50:58 +00:00
Zdenek Dvorak
7aa20a86fe Fix mistake in my previous commit (n_of_executions_at_least should be
named n_of_executions_at_most).

From-SVN: r113461
2006-05-02 13:16:37 +00:00
Stanislaw Skowronek
d541888b0f re PR target/25871 (TRAMPOLINE_TEMPLATE uses 32bit moves on 64bit code)
2006-05-02  Joshua Kinard  <kumba@gentoo.org>

	PR target/25871
	* gcc/config/mips/mips.h (TRAMPOLINE_TEMPLATE): Avoid 32-bit moves
	with 64-bit pointers.

From-SVN: r113460
2006-05-02 12:57:52 +00:00
Paul Brook
7a7017bc20 arm.c (add_minipool_forward_ref): Check if insn and pool overlap.
2006-05-02  Paul Brook  <paul@codesourcery.com>

	* config/arm/arm.c (add_minipool_forward_ref): Check if insn
	and pool overlap.
	(create_fix_barrier): Check that a suitable barrier location is
	found.
	(arm_reorg): Include ftmp->address in allowable range of addresses.

From-SVN: r113459
2006-05-02 12:49:48 +00:00
David Billinghurst
3beef5cbb2 re PR ada/27366 (ada build fails as cygwin does not have clearenv)
2006-05-02  David Billinghurst <David.Billinghurst@riotinto.com>
 
         PR ada/27366
         * ada/env.c (__gnat_clearenv): Use unsetenv() to clear
	 environment on Cygwin.

From-SVN: r113457
2006-05-02 11:38:35 +00:00
Jakub Jelinek
077b0dfbfe re PR middle-end/27337 (OpenMP ICE in expand_expr_real_1 at expr.c:6814)
PR middle-end/27337
	* gimplify.c (gimplify_scan_omp_clauses): Handle INDIRECT_REF
	around RESULT_DECL for result passed by reference.
	(gimplify_expr): Call omp_notice_variable when RESULT_DECL is seen.
	* omp-low.c (use_pointer_for_field): Don't look at
	DECL_HAS_VALUE_EXPR_P for RESULT_DECLs.
	(scan_omp_1): Call remap_decl on RESULT_DECLs.
	(lower_rec_input_clauses): Don't allocate VLA memory for the second
	time or var for passing by reference for
	OMP_CLAUSE_LASTPRIVATE_FIRSTPRIVATE clauses.  Allow creation of
	TREE_ADDRESSABLE variables when passing by reference.

	* omp-low.c (dump_omp_region): Fix output formatting.
cp/
	* cp-gimplify.c (cxx_omp_privatize_by_reference): New function.
	* cp-tree.h (cxx_omp_privatize_by_reference): New prototype.
	* cp-objcp-common.h (LANG_HOOKS_OMP_PRIVATIZE_BY_REFERENCE): Define.
testsuite/
	* g++.dg/gomp/pr27337-1.C: New test.
	* g++.dg/gomp/pr27337-2.C: New test.
libgomp/
	* testsuite/libgomp.c++/pr27337.C: New test.

From-SVN: r113456
2006-05-02 12:44:55 +02:00
Jakub Jelinek
2aee3e57ae re PR middle-end/27328 (ICE with -fopenmp and goto)
PR middle-end/27328
	* omp-low.c (remove_exit_barrier): Handle NULL exit_bb.
	(expand_omp_parallel): Likewise.
	* tree-cfg.c (move_sese_region_to_fn): Likewise.

	* gcc.dg/gomp/pr27328.c: New test.

From-SVN: r113455
2006-05-02 12:41:44 +02:00
Jakub Jelinek
4a31b7ee3c re PR middle-end/27325 (ICE with enabled exceptions and -fopenmp)
PR middle-end/27325
	* omp-low.c (lower_omp_sections): Call maybe_catch_exception
	on statement list containing also constructors and destructors.
	(lower_omp_single, lower_omp_for, lower_omp_parallel): Likewise.

	* g++.dg/gomp/pr27325.C: New test.

From-SVN: r113454
2006-05-02 12:40:21 +02:00
Jakub Jelinek
d5d86fde90 re PR middle-end/27310 (ICE in duplicate_eh_regions)
PR middle-end/27310
	* except.c (duplicate_eh_regions): Fix clearing of
	cfun->eh->region_array entries.

	* g++.dg/gomp/pr27310.C: New test.

From-SVN: r113453
2006-05-02 12:38:12 +02:00
Ben Elliston
7d0e5ebe7b Trivial formatting fixes accumulated over the last few months.
From-SVN: r113452
2006-05-02 15:53:01 +10:00
DJ Delorie
3d8f47a092 Fix typo.
From-SVN: r113448
2006-05-01 20:59:56 -04:00
DJ Delorie
c15b113ba2 configure.ac (gcc_cv_nm): Don't use an in-tree nm if build!=host.
* configure.ac (gcc_cv_nm): Don't use an in-tree nm if
build!=host.
(gcc_cv_objdump): Likewise.
* configure: Regenerated.

From-SVN: r113447
2006-05-01 20:55:43 -04:00
GCC Administrator
7ba437d672 Daily bump.
From-SVN: r113445
2006-05-02 00:17:16 +00:00
DJ Delorie
ed606bc0c8 configure.in: Restore CFLAGS if GM P isn't present.
* configure.in: Restore CFLAGS if GM P isn't present.
* configure: Regenerate.

From-SVN: r113444
2006-05-01 20:17:08 -04:00
Kazu Hirata
94634f146e re PR target/27374 (*arm_movdi_vfp in config/arm/vfp.md has wrong output templates)
PR target/27374
	* config/arm/vfp.md (*arm_movdi_vfp): Correct the output
	templates for case 3 and 4.

From-SVN: r113436
2006-05-01 21:55:02 +00:00
DJ Delorie
2d5bc016ad vec.c: Include bconfig.h when appropriate.
* vec.c: Include bconfig.h when appropriate.
* Makefile.in (build/vec.o): Adjust dependencies.
* mkconfig.sh: Make sure config.h isn't used for build machine
compiles.

From-SVN: r113432
2006-05-01 16:57:20 -04:00
Zdenek Dvorak
2ce798794d tree-into-ssa.c (phis_to_rewrite, [...]): New variables.
* tree-into-ssa.c (phis_to_rewrite, blocks_with_phis_to_rewrite): New
	variables.
	(mark_phi_for_rewrite): New function.
	(insert_phi_nodes_for, mark_use_interesting): Call
	mark_phi_for_rewrite.
	(rewrite_update_phi_arguments): Traverse only phis in phis_to_rewrite.
	(update_ssa): Initialize and free phis_to_rewrite.

From-SVN: r113431
2006-05-01 20:52:21 +00:00
Zdenek Dvorak
ed541ddb26 re PR rtl-optimization/27291 (verify_flow_info failed: too many outgoing branch edges from bb 4)
PR rtl-optimization/27291
	* loop-doloop.c (add_test, doloop_modify): Handle the case condition is
	folded to a constant.

	* g++.dg/tree-ssa/pr27291.C: New test.

From-SVN: r113430
2006-05-01 20:46:22 +00:00
Zdenek Dvorak
dcccd88d38 re PR tree-optimization/27283 (ICE: SSA corruption - Conflict across an abnormal edge)
PR tree-optimization/27283
	* tree-ssa-loop-ivopts.c (struct nfe_cache_elt): Store just trees,
	not whole # of iteration descriptions.
	(niter_for_exit): Return just # of iterations.  Fail if # of iterations
	uses abnormal ssa name.
	(niter_for_single_dom_exit): Ditto.
	(find_induction_variables, may_eliminate_iv): Expect niter_for_exit to
	return just the number of iterations.

	* g++.dg/tree-ssa/pr27283.C: New test.

From-SVN: r113427
2006-05-01 20:05:57 +00:00
Andreas Tobler
a5dfac10a2 configure.ac: Simplify the mmap check a bit more.
2006-05-01  Andreas Tobler  <a.tobler@schweiz.ch>

	* configure.ac: Simplify the mmap check a bit more.
	* configure: Rebuilt.
	* include/config.h.in: Likewise.

From-SVN: r113426
2006-05-01 22:02:27 +02:00
Zdenek Dvorak
763f45275b re PR tree-optimization/27144 (segfault with -O2 on x86_64 (and powerpc64))
PR tree-optimization/27144
	* tree-ssa-loop-niter.c (derive_constant_upper_bound): New function.
	(record_estimate): Only record constant upper bound.
	(infer_loop_bounds_from_undefined): Call
	compute_estimated_nb_iterations just once.
	(proved_non_wrapping_p): Renamed to ...
	(n_of_executions_at_most): ... this.  Expect bound to be a constant.
	(convert_step_widening, scev_probably_wraps_p): Call
	n_of_executions_at_most instead of proved_non_wrapping_p.
	(substitute_in_loop_info): Do not replace values in bounds.
	* cfgloop.h (struct nb_iter_bound): Remove "additional" field.  Update
	comments.

	* gcc.dg/tree-ssa/loop-16.c: New test.

From-SVN: r113425
2006-05-01 19:42:01 +00:00
Richard Henderson
2a83cc5254 re PR c/27358 (ICE with invalid variable after #pragma omp parallel)
PR c/27358
        * c-parser.c (c_parser_skip_to_end_of_block_or_statement): Move after
        c_parser_skip_to_pragma_eol.  Convert to switch statement.  Handle
        CPP_PRAGMA.

From-SVN: r113421
2006-05-01 10:46:32 -07:00
Roger Sayle
0f57299d37 c-typeck.c (parser_build_binary_op): Don't call the function unsigned_conversion_warning to spot operand/result type...
* c-typeck.c (parser_build_binary_op): Don't call the function
	unsigned_conversion_warning to spot operand/result type overflow.
	(build_binary_op): Instead, call convert_and_check instead of
	convert to report the problem when the operands are promoted.
	* c-common.c (unsigned_conversion_warning): Make static.
	* c-common.h (unsigned_conversion_warning): Delete prototype.

	* gcc.dg/Wconversion-3.c: New test case.
	* gcc.dg/Wconversion-4.c: Likewise.


Co-Authored-By: Joseph Myers <joseph@codesourcery.com>

From-SVN: r113418
2006-05-01 16:51:19 +00:00
Roger Sayle
f0913ab8d6 boehm.cc (_Jv_InitGC): Check both HAVE_DLFCN_H and HAVE_DLADDR before calling...
* boehm.cc (_Jv_InitGC): Check both HAVE_DLFCN_H and HAVE_DLADDR
	before calling GC_register_has_static_roots_callback.
	(_Jv_RegisterLibForGc): Likewise, test for both HAVE_DLFCN_H and
	HAVE_DLADDR before calling dladdr.


Co-Authored-By: Andrew Haley <aph@redhat.com>

From-SVN: r113417
2006-05-01 16:28:42 +00:00
Richard Guenther
ea6431202d re PR target/26726 (-fivopts producing out of bounds array refs)
2006-05-01  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/26726
	* tree-ssa-loop-ivopts.c (idx_find_step): Mark source of the
	problem ...
	(find_interesting_uses_address): ... we work around here
	by folding INDIRECT_REFs in the substituted base.

	* g++.dg/tree-ssa/ivopts-1.C: New testcase.

From-SVN: r113414
2006-05-01 15:07:25 +00:00
Paolo Carlini
d814595c2c acinclude.m4 (GLIBCXX_ENABLE_WCHAR_T): Always check the presence of wctype.h, for use in GLIBCXX_ENABLE_C99.
2006-05-01  Paolo Carlini  <pcarlini@suse.de>

	* acinclude.m4 (GLIBCXX_ENABLE_WCHAR_T): Always check the
	presence of wctype.h, for use in GLIBCXX_ENABLE_C99.
	* configure: Regenerate.

From-SVN: r113413
2006-05-01 15:00:04 +00:00
Diego Novillo
444e96af87 omp-low.c (dump_omp_region): Add newlines.
* omp-low.c (dump_omp_region): Add newlines.

From-SVN: r113412
2006-05-01 10:45:47 -04:00
Richard Guenther
9386bd20a3 MAINTAINERS (Various Maintainers): Add myself as libgcc-math maintainer.
2006-05-01  Richard Guenther  <rguenther@suse.de>

	* MAINTAINERS (Various Maintainers): Add myself as libgcc-math
	maintainer.

From-SVN: r113409
2006-05-01 11:30:26 +00:00
Roger Sayle
71834ad346 common.opt (Woverflow): New command line option.
* common.opt (Woverflow): New command line option.
	* c-common.c (constant_expression_warning): Check warn_overflow.
	(overflow_waring): Pass OPT_Woverflow to warning.
	(unsigned_conversion_warning): Likewise.
	(convert_and_check): Likewise.
	* doc/invoke.texi: Document new command line option.

	* gcc.dg/Woverflow-1.c: New test case.
	* gcc.dg/Woverflow-2.c: Likewise.
	* gcc.dg/Woverflow-3.c: Likewise.

From-SVN: r113408
2006-05-01 04:27:15 +00:00
GCC Administrator
1c56bc4a7e Daily bump.
From-SVN: r113404
2006-05-01 00:17:05 +00:00
Mark Mitchell
5a8613b2d9 re PR c++/27094 (tree check: expected tree_list, have omp_return in build_call)
PR c++/27094
	* pt.c (tsubst_default_argument): Increment function_depth around
	call to tsubst_expr.
	* parser.c (cp_parser_parameter_declaration): Likewise.
	* decl2.c (mark_used): Tidy.
	PR c++/27094
	* g++.dg/template/defarg8.C: New test.

From-SVN: r113399
2006-04-30 23:21:38 +00:00
David Edelsohn
194c524aa2 rs6000.c (rs6000_override_options): Enable TARGET_NO_FP_IN_TOC for section anchors.
* config/rs6000/rs6000.c (rs6000_override_options): Enable
        TARGET_NO_FP_IN_TOC for section anchors.
        (optimization_options): Enable section anchors for all
        non-"Objective" languages.

From-SVN: r113395
2006-04-30 15:23:13 -04:00
Kenneth Zadeck
7b3bd50372 MAINTAINERS (Write After Approval): Add myself.
2006-04-30  Kenneth Zadeck <zadeck@naturalbridge.com>

	* MAINTAINERS (Write After Approval): Add myself.

From-SVN: r113392
2006-04-30 13:32:05 +00:00
Volker Reichelt
85990800b1 re PR c++/27278 (ICE with invalid operator declaration)
PR c++/27278
	* decl.c (grok_op_properties): Skip operators with invalid args
	when checking for class-type or enum-type args.

	* g++.dg/parse/operator7.C: New test.

From-SVN: r113389
2006-04-30 10:34:05 +00:00
Jerry DeLisle
4e72e1c5a2 re PR libfortran/27360 (Memory leaks when reading logicals)
2006-04-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/27360
	
	* io/list_read.c (read_logical):  Free line_buffer and free saved.

From-SVN: r113388
2006-04-30 03:19:37 +00:00
GCC Administrator
aedb974e2c Daily bump.
From-SVN: r113386
2006-04-30 00:17:16 +00:00