Commit Graph

74758 Commits

Author SHA1 Message Date
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
Volker Reichelt
b1482d1512 re PR c++/11471 (ICE on illegal use of typedef'd member class)
PR c++/11471
	PR c++/27102
	* g++.dg/template/crash48.C: New test.

From-SVN: r113382
2006-04-29 21:39:54 +00:00
Volker Reichelt
139a78c724 re PR c++/27279 (ICE with invalid constructor declaration)
PR c++/27279
	* decl.c (copy_fn_p): Skip functions with invalid first arg.

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

From-SVN: r113378
2006-04-29 20:48:45 +00:00
Paolo Carlini
bfdb907ca2 locale_facets.tcc (num_get<>::_M_extract_float): Special case main parsing loop for !_M_allocated (i.e., "C" locale).
2006-04-29  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/locale_facets.tcc (num_get<>::_M_extract_float):
	Special case main parsing loop for !_M_allocated (i.e., "C" locale).
	(num_get<>::_M_extract_int): Likewise.
	* include/bits/locale_facets.h (num_get<>::_M_find): New.

From-SVN: r113377
2006-04-29 18:16:47 +00:00
Francois-Xavier Coudert
49914d0380 re PR fortran/25681 (ICE with len of array of derived type)
PR fortran/25681

	* simplify.c (simplify_len): Character variables with constant
	length can be simplified.

	* gfortran.df/char_type_len.f90: New test.

From-SVN: r113376
2006-04-29 16:31:26 +00:00
H.J. Lu
c69a7fb7a6 re PR fortran/27351 (Use variable after free in gfc_conv_array_transpose)
2006-04-29  H.J. Lu  <hongjiu.lu@intel.com>

	PR fortran/27351
	* trans-array.c (gfc_conv_array_transpose): Move gcc_assert
	before gfc_conv_expr_descriptor.

From-SVN: r113375
2006-04-29 07:25:42 -07:00
Bryce McKinlay
23bc3a894d link.cc (_Jv_Linker::resolve_pool_entry): Don't pass vtable_index to resolve_method.
2006-04-28  Bryce McKinlay  <mckinlay@redhat.com>

	* link.cc (_Jv_Linker::resolve_pool_entry): Don't pass vtable_index
	to resolve_method.
	* interpret.cc (insn_invokevirtual): Use method->index, not
	vtable_index. Check accflag FINAL to determine finals. Only do
	explicit null check if calling a final method. Use
	throw_null_pointer_exception.
	(invokevirtual_resolved): Likewise.
	(null_pointer_exc): Remove static field.
	(throw_null_pointer_exception): Always define. Throw a new
	NullPointerException every time.
	* include/java-interp.h (_Jv_ResolvedMethod): Remove vtable_index
	field.
	* include/execution.h (resolve_method): Remove vtable_index argument.

From-SVN: r113370
2006-04-29 02:35:50 +01:00
GCC Administrator
f6326de601 Daily bump.
From-SVN: r113368
2006-04-29 00:17:12 +00:00
Jerry DeLisle
74ab8c2dae re PR fortran/27304 (gfortran: Warn/abort when format in write does not fit passed arguments)
2006-04-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/27304
	* gfortran.dg/fmt_exhaust.f90: New test.

From-SVN: r113364
2006-04-29 00:02:10 +00:00
Jerry DeLisle
c4ee121ad5 re PR fortran/27304 (gfortran: Warn/abort when format in write does not fit passed arguments)
2006-04-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR libgfortran/27304
	* io/transfer.c (formatted_transfer_scalar):  Generate error if data
	descriptors are exhausted.
	* io/format.c (next_format0): Fix comment.

From-SVN: r113363
2006-04-28 23:55:30 +00:00
Eric Christopher
4f8bdef929 darwin-c.c (darwin_ms_struct): Move this
2006-04-28  Eric Christopher  <echristo@apple.com>

        * config/darwin-c.c (darwin_ms_struct): Move this
        (darwin_set_default_type_attributes): and this...
        * config/darwin.c: ... here.
        * config/darwin.h (darwin_ms_struct): Declare.

From-SVN: r113358
2006-04-28 20:52:01 +00:00
Andrew MacLeod
a5f844647b The condition the assert was flawed.
2006-04-28  Andrew MacLeod  <amacleod@redhat.com>

	* tree-ssa-dom.c (propagate_rhs_into_lhs): Fix assert clause.

From-SVN: r113356
2006-04-28 20:39:18 +00:00
Roger Sayle
a0f0ab9fc1 re PR c/25309 (ICE on initialization of a huge array)
PR c/25309
	* c-typeck.c (struct spelling): Make I an unsigned HOST_WIDE_INT.
	(push_array_bounds): Delete prototype.  Change BOUNDS argument to
	an unsigned HOST_WIDE_INT.
	(print_spelling): Use HOST_WIDE_INT_PRINT_UNSIGNED to output the
	array index.
	(really_start_incremental_init): No need to call convert because
	bitsize_zero_node is already of type bitsizetype.
	(push_init_level): Extract the value of constructor_index as an
	unsigned HOST_WIDE_INT quantity, using tree_low_cst.
	(process_init_element): Likewise.

	* gcc.dg/large-size-array-2.c: New test case.

From-SVN: r113355
2006-04-28 19:59:57 +00:00
Jan Beulich
87ceee7236 MAINTAINERS (Write After Approval): Add myself.
2006-04-28  Jan Beulich  <jbeulich@novell.com>

	* MAINTAINERS (Write After Approval): Add myself.

From-SVN: r113350
2006-04-28 14:44:20 +00:00
Richard Guenther
a4858cb066 re PR target/26826 (ICE in reg_or_subregno, at jump.c:2011)
2006-04-28  Richard Guenther  <rguenther@suse.de>

	PR target/26826
	* gcc.target/i386/pr26826.c: New testcase.

From-SVN: r113348
2006-04-28 14:36:14 +00:00
Matthias Klose
9edaf51efb - add missing ChangeLog entry, see PR27334
From-SVN: r113347
2006-04-28 14:05:42 +00:00
Joseph Myers
c7370b8375 gcc.c (process_command): Add program name to GCC_EXEC_PREFIX value before passing to make_relative_prefix.
* gcc.c (process_command): Add program name to GCC_EXEC_PREFIX
	value before passing to make_relative_prefix.

From-SVN: r113345
2006-04-28 13:15:36 +01:00
Alan Modra
bb6a0ee1c5 re PR middle-end/27260 (ICE in expand_expr_real_1, at expr.c:6750)
gcc/
	PR middle-end/27260
	* builtins.c (expand_builtin_memset): Expand val in original mode.
gcc/testsuite/
	PR middle-end/27260
	* gcc.c-torture/execute/pr27260.c: New.

From-SVN: r113341
2006-04-28 13:11:34 +09:30
Alan Modra
5cd9edb524 re PR middle-end/27095 (O2 produces duplicate code)
PR middle-end/27095
	* gcc.dg/pr27095.c: New.

From-SVN: r113340
2006-04-28 13:06:15 +09:30
Mark Mitchell
33a1b314e5 re PR c++/27292 (ICE on casts on bitfields)
PR c++/27292
	* tree.c (rvalue): Convert bitfields to their declared types.
	PR c++/27292
	* g++.dg/conversion/bitfield4.C: New test.

From-SVN: r113339
2006-04-28 02:40:58 +00:00
GCC Administrator
6a0ca517a3 Daily bump.
From-SVN: r113331
2006-04-28 00:17:21 +00:00
Eric Christopher
16d6f99461 target-def.h (TARGET_SET_DEFAULT_TYPE_ATTRIBUTES): Bracket with #ifndef/#endif.
2006-04-27  Eric Christopher  <echristo@apple.com>

        * target-def.h (TARGET_SET_DEFAULT_TYPE_ATTRIBUTES): Bracket
        with #ifndef/#endif.
        * config/darwin-c.c (darwin_ms_struct): New.
        (darwin_pragma_ms_struct): Ditto.
        (darwin_set_default_type_attributes): Ditto.
        * config/darwin-protos.h (darwin_pragma_ms_struct): Declare.
        * config/darwin.h (DARWIN_REGISTER_TARGET_PRAGMAS):
        Register ms_struct pragma.
        * config/i386/darwin.h (REGISTER_TARGET_PRAGMAS): Declare.
        (TARGET_SET_DEFAULT_TYPE_ATTRIBUTES): Ditto.
        * config/rs6000/rs6000.c (rs6000_set_default_type_attributes): Call
        darwin_set_default_type_attributes if TARGET_MACHO.

2006-04-27  Eric Christopher  <echristo@apple.com>

        * gcc.dg/pragma-ms_struct.c: New.

From-SVN: r113327
2006-04-27 22:53:23 +00:00
Benjamin Kosnik
6f3d6562d8 TODO: Update.
2006-04-27  Benjamin Kosnik  <bkoz@redhat.com>

	* docs/html/17_intro/TODO: Update.

From-SVN: r113325
2006-04-27 22:49:28 +00:00
Andreas Tobler
2a67186a24 configure.ac: Add an additional checks for dladdr and dlopen on dld.
2006-04-28  Andreas Tobler  <a.tobler@schweiz.ch>

	* configure.ac: Add an additional checks for dladdr and dlopen on dld.
	* configure: Rebuilt.

From-SVN: r113323
2006-04-28 00:20:03 +02:00
Andrew MacLeod
6c00f606c1 Implement new immediate use iterators.
2006-04-27  Andrew MacLeod  <amacleod@redhat.com>

	PR tree-optimization/26854
	* tree-vrp.c (remove_range_assertions): Use new Immuse iterator.
	* doc/tree-ssa.texi: Update immuse iterator documentation.
	* tree-ssa-math-opts.c (execute_cse_reciprocals_1): Use new iterator.
	* tree-ssa-dom.c (propagate_rhs_into_lhs): Use new iterator.
	* tree-flow-inline.h (end_safe_imm_use_traverse, end_safe_imm_use_p,
	first_safe_imm_use, next_safe_imm_use): Remove.
	(end_imm_use_stmt_p): New.  Check for end of immuse stmt traversal.
	(end_imm_use_stmt_traverse): New.  Terminate immuse stmt traversal.
	(move_use_after_head): New.  Helper function to sort immuses in a stmt.
	(link_use_stmts_after): New.  Link all immuses in a stmt consescutively.
	(first_imm_use_stmt): New.  Get first stmt in an immuse list.
	(next_imm_use_stmt): New.  Get next stmt in an immuse list.
	(first_imm_use_on_stmt): New.  Get first immuse on a stmt.
	(end_imm_use_on_stmt_p): New.  Check for end of immuses on a stmt.
	(next_imm_use_on_stmt): New.  Move to next immuse on a stmt.
	* tree-ssa-forwprop.c (forward_propagate_addr_expr): Use new iterator.
	* lambda-code.c (lambda_loopnest_to_gcc_loopnest): Use new iterator.
	(perfect_nestify): Use new iterator.
	* tree-vect-transform.c (vect_create_epilog_for_reduction): Use new 
	iterator.
	* tree-flow.h (struct immediate_use_iterator_d): Add comments.
	(next_imm_name): New field in struct immediate_use_iterator_d.
	(FOR_EACH_IMM_USE_SAFE, BREAK_FROM_SAFE_IMM_USE): Remove.
	(FOR_EACH_IMM_USE_STMT, BREAK_FROM_IMM_USE_STMT, 
	FOR_EACH_IMM_USE_ON_STMT): New immediate use iterator macros.
	* tree-cfg.c (replace_uses_by): Use new iterator.
	* tree-ssa-threadedge.c (lhs_of_dominating_assert): Use new iterator.
	* tree-ssa-operands.c (correct_use_link): Remove.
	(finalize_ssa_use_ops): No longer call correct_use_link.

From-SVN: r113321
2006-04-27 20:22:17 +00:00
Mark Mitchell
8fcd79cbcd re PR c++/27102 (ICE with invalid class name in function template)
PR c++/27102
	* typeck2.c (cxx_incomplete_type_diagnostic): Handle
	TYPENAME_TYPE.
	PR c++/27102
	* g++.dg/template/crash47.C: New test.

From-SVN: r113320
2006-04-27 19:02:54 +00:00
Stuart Hastings
9613eaffa4 t-darwin (DARWIN_EXTRA_CRT_BUILD_CFLAGS): New.
* config/rs6000/t-darwin (DARWIN_EXTRA_CRT_BUILD_CFLAGS): New.
	* config/t-darwin (crt3.o): Use it.
	* config/rs6000/rs6000.c (rs6000_initialize_trampoline): Remove
	'pmode', use Pmode instead of SImode for SYMBOL_REF.
	* config/rs6000/rs6000.md (call_indirect_nonlocal_sysv,
	call_nonlocal_sysv, call_value_indirect_nonlocal_sysv,
	call_value_nonlocal_sysv): Suffix with the "P" macro for 32/64
	support.

From-SVN: r113319
2006-04-27 18:57:11 +00:00
Roger Sayle
135c2bd408 expmed.c (store_fixed_bit_field): If we're not optimizing for size...
* expmed.c (store_fixed_bit_field): If we're not optimizing for
	size, force the intermediate into a new pseudo rather instead of
	performing both a bitwise AND and a bitwise IOR in memory.

From-SVN: r113318
2006-04-27 17:26:03 +00:00
Richard Guenther
921b02cd1f re PR rtl-optimization/26685 (documentation refer to nonexisting --param max-cse-insns)
2006-04-27  Richard Guenther  <rguenther@suse.de>

	PR rtl-optimization/26685
	* params.def (PARAM_MAX_CSE_INSNS): Correct typo that named
	this one "max-flow-memory-locations".

From-SVN: r113300
2006-04-27 14:25:49 +00:00
Richard Guenther
67ac6e637c re PR tree-optimization/25148 (compare_values assumes that CST in a + CST (and a - CST) is always postive)
2006-04-27  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/25148
	* tree-vrp.c (compare_values): Remove code dealing with
	comparisons against type min/max value.  Honour overflow
	and negative constants in code dealing with comparisons
	of plus and minus expressions.
	(value_inside_range): Use fold_binary with LE_EXPR and
	GE_EXPR rather than compare_values.

From-SVN: r113298
2006-04-27 13:52:44 +00:00
Dirk Mueller
869170df10 xmmintrin.h (_mm_shuffle_pi16): make available for SSE.
2006-04-27  Dirk Mueller  <dmueller@suse.de>

        * config/i386/xmmintrin.h (_mm_shuffle_pi16): make available
        for SSE.

        * testsuite/gcc.target/i386/sse-7.c: build with -msse.

From-SVN: r113297
2006-04-27 11:13:45 +00:00
H.J. Lu
ded5b063bb re PR testsuite/27274 (execution test of gcc.dg/i386-sse-9.c fails on non-SSE CPU)
2006-04-26  H.J. Lu  <hongjiu.lu@intel.com>

	PR testsuite/27274:
	* gcc.target/i386/sse-9.c: Include "../../gcc.dg/i386-cpuid.h".
	(main): Exit if processor doesn't support SSE.

From-SVN: r113296
2006-04-26 23:13:40 -07:00