Commit Graph

103760 Commits

Author SHA1 Message Date
Rainer Orth
bc8359ff68 pragma-init-fini.c: Skip on i?86-*-solaris2.8 && !gas.
* gcc.dg/pragma-init-fini.c: Skip on i?86-*-solaris2.8 && !gas.
	* gcc.dg/pragma-init-fini-2.c: XFAIL on i?86-*-solaris2.8 && !gas.

From-SVN: r165363
2010-10-12 11:52:02 +00:00
Joseph Myers
f938f60cb6 flag-types.h: New.
* flag-types.h: New.
	* Makefile.in (TH_H): Include $(OPTIONS_H) instead of $(FLAGS_H).
	(FLAGS_H): Include flag-types.h.  Include $(OPTIONS_H) instead of
	options.h.
	(OPTIONS_H): Define.
	(c-family/c-opts.o, lto-opts.o, opts.o): Use $(OPTIONS_H) instead
	of options.h.
	* configure.ac (tm_include_list): Include options.h not flags.h.
	* configure: Regenerate.
	* flags.h: Include flag-types.h.  Include options.h at top of file
	again.
	(enum debug_info_type, enum debug_info_level, enum
	debug_info_usage, enum symbol_visibility, struct visibility_flags,
	enum ira_algorithm, enum ira_region, enum excess_precision, enum
	graph_dump_types, enum stack_check_type, enum
	warn_strict_overflow_code): Move to flag-types.h
	* opth-gen.awk: Include flag-types.h in options.h.

ada:
	* gcc-interface/Make-lang.in (ada/misc.o): Use $(OPTIONS_H)
	instead of options.h.

java:
	* Make-lang.in (java/lang.o): Use $(OPTIONS_H) instead of
	options.h.

From-SVN: r165362
2010-10-12 12:25:16 +01:00
Arnaud Charlet
beacce0274 [multiple changes]
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* gnat_rm.texi: Clarify that 'Old can be used in preconditions and
	postcondition pragmas.

2010-10-12  Robert Dewar  <dewar@adacore.com>

	* errout.ads, erroutc.adb: The # insertion now handles from in place of
	at.
	* exp_prag.adb (Expand_Pragma_Check): Suppress generated default
	message if new switch Exception_Locations_Suppressed is set.
	(Expand_Pragma_Check): Revised wording for default message for case
	of precondition or postcondition.
	* namet.ads, namet.adb (Build_Location_String): New procedure.
	* opt.ads (List_Inherited_Pre_Post): New flag.
	* sem_ch12.adb (Analyze_Generic_Subprogram_Declaration): Add call to
	list inherited pre/post aspects.
	* sem_ch13.adb (Analyze_Aspect_Specification): Improve generation of
	messages for precondition/postcondition cases.
	* sem_ch6.adb (Process_PPCs): General cleanup, and list inherited PPC's
	if flag List_Inherited_Pre_Post is set True.
	(Process_PPCs): Add initial handling for inherited preconditions
	(List_Inherited_Pre_Post_Aspects): New procedure
	* sem_ch6.ads (List_Inherited_Pre_Post_Aspects): New procedure
	* sem_disp.adb (Inherited_Subprograms): New function
	* sem_disp.ads (Inherited_Subprograms): New function
	* sem_prag.adb (Check_Duplicate_Pragma): Clean up handling of
	pre/postcondition.
	(Check_Precondition_Postcondition): Check for inherited aspects
	* sem_warn.adb: Process -gnatw.l/w.L setting List_Inherited_Pre_Post
	* sinfo.ads, sinfo.adb (Split_PPC): New flag.
	* sinput.ads, sinput.adb (Build_Location_String): New function.
	* usage.adb: Add line for -gnatw.l/-gnatw.L

2010-10-12  Javier Miranda  <miranda@adacore.com>

	* exp_util.adb (Remove_Side_Effects): Remove wrong code.

2010-10-12  Arnaud Charlet  <charlet@adacore.com>

	* xref_lib.adb: Add handling of j/J letters.

From-SVN: r165361
2010-10-12 13:00:42 +02:00
Jakub Jelinek
a4feaa7167 expr.c (store_expr): Share code for STRING_CST and MEM_REF of &STRING_CST cases.
* expr.c (store_expr): Share code for STRING_CST and
	MEM_REF of &STRING_CST cases.  Don't require BLKmode, instead
	check if target is a MEM.

From-SVN: r165360
2010-10-12 12:58:14 +02:00
Arnaud Charlet
2551782dc3 [multiple changes]
2010-10-12  Pascal Obry  <obry@adacore.com>

	* adaint.c (__gnat_number_of_cpus): Add implementation for Windows.

2010-10-12  Arnaud Charlet  <charlet@adacore.com>

	* make.adb (Globalize): New procedure.
	(Compile): Set Do_Codepeer_Globalize_Step when -gnatC is used.
	(Gnatmake): Call Globalize when needed.
	(Process_Restrictions_Or_Restriction_Warnings): Ignore Restrictions
	pragmas in CodePeer mode.
	(Adjust_Global_Switches): Set No_Initialize_Scalars in CodePeer mode,
	to generate simpler and consistent code.

2010-10-12  Bob Duff  <duff@adacore.com>

	* exp_util.adb (Remove_Side_Effects): Disable previous change,
	can cause side effects to be duplicated.

From-SVN: r165359
2010-10-12 12:49:00 +02:00
Arnaud Charlet
f0709ca650 [multiple changes]
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* sem_ch6.adb (Process_PPCs): Handle inherited postconditions.

2010-10-12  Arnaud Charlet  <charlet@adacore.com>

	* exp_disp.adb (Set_All_DT_Position): Disable emit error message on
	abstract inherited private operation in CodePeer mode.

From-SVN: r165358
2010-10-12 12:41:11 +02:00
Arnaud Charlet
7730df143c [multiple changes]
2010-10-12  Thomas Quinot  <quinot@adacore.com>

	* a-exetim.ads: Minor reformatting.
	* g-socket.ads (Port_Type): Better definition corresponding to the
	actual standard range.
	* exp_ch5.adb: Add comment.
	* sem_aux.adb: Minor reformatting.

2010-10-12  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch12.adb (Copy_Generic_Node): If node is a string literal, remove
	string_literal_subtype so that a new one can be constructed in the
	scope of the instance.

From-SVN: r165357
2010-10-12 12:38:39 +02:00
Arnaud Charlet
c775c2094b [multiple changes]
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* exp_ch9.adb (Has_Pragma_Priority): New name for Has_Priority_Pragma
	* gnat_rm.texi (pragma Suppress_All): Document new placement rules
	* par-prag.adb (P_Pragma, case Suppress_All): Set
	Has_Pragma_Suppress_All flag.
	* sem_prag.adb (Has_Pragma_Priority): New name for Has_Priority_Pragma
	(Analyze_Pragma, case Suppress_All): Remove placement check
	(Process_Compilation_Unit_Pragmas): Use Has_Pragma_Suppress_All flag
	* sem_prag.ads (Process_Compilation_Unit_Pragmas): Update documentation
	* sinfo.adb (Has_Pragma_Suppress_All): New flag
	(Has_Pragma_Priority): New name for Has_Priority_Pragma
	* sinfo.ads (Has_Pragma_Suppress_All): New flag
	(Has_Pragma_Priority): New name for Has_Priority_Pragma

2010-10-12  Arnaud Charlet  <charlet@adacore.com>

	* lib-xref.ads: Mark j/J as reserved for C++ classes.

2010-10-12  Jose Ruiz  <ruiz@adacore.com>

	* a-exetim-default.ads, a-exetim-posix.adb: New.
	* gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for linux): Use the
	POSIX Realtime support to implement CPU clocks.
	(EXTRA_GNATRTL_TASKING_OBJS for linux): Add the a-exetim.o object
	to the tasking library.
	(THREADSLIB): Make the POSIX.1b Realtime Extensions library (librt)
	available for shared libraries.
	* gcc-interface/Make-lang.in: Update dependencies.

2010-10-12  Robert Dewar  <dewar@adacore.com>

	* sem_ch13.adb (Analyze_Aspect_Specifications): For Pre/Post, break
	apart expressions with AND THEN clauses into separate pragmas.
	* sinput.ads, sinput.adab (Get_Logical_Line_Number_Img): New function.

From-SVN: r165356
2010-10-12 12:32:58 +02:00
Robert Dewar
811ef5ba91 par-ch13.adb (P_Aspect_Specifications): Fix handling of 'Class aspects
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* par-ch13.adb (P_Aspect_Specifications): Fix handling of 'Class aspects
	* sem_ch13.adb (Analyze_Aspect_Specifications): Fix bad Sloc on aspects
	* sem_prag.adb (Fix_Error): Only change pragma names for pragmas from
	aspects.
	(Check_Optional_Identifier): Handle case of direct arguments
	(Chain_PPC): Test for abstract case, giving appropriate messages
	* sinfo.ads, sinfo.adb (Class_Present): Allowed on N_Pragma node

From-SVN: r165355
2010-10-12 12:20:00 +02:00
Arnaud Charlet
92cbddaa2a [multiple changes]
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* par-endh.adb (Check_End): Don't swallow semicolon or aspects after
	END RECORD.
	* sem_attr.adb (Eval_Attribute): Code clean up.

2010-10-12  Robert Dewar  <dewar@adacore.com>

	* par-ch12.adb (P_Formal_Private_Type_Definition): Improve error
	messages and recovery for case of out of order Abstract/Tagged/Private
	keywords.
	* par-ch3.adb (P_Type_Declaration): Improve error messages and recovery
	for case of out of order Abstract/Tagged/Private keywords.

2010-10-12  Ed Schonberg  <schonberg@adacore.com>

	* inline.adb (Analyze_Inlined_Bodies): Restrict previous change to case
	where child unit is main unit of compilation.

From-SVN: r165354
2010-10-12 11:42:31 +02:00
Arnaud Charlet
718deaf1af [multiple changes]
2010-10-12  Robert Dewar  <dewar@adacore.com>

	* aspects.ads, aspects.adb (Move_Aspects): New procedure.
	* atree.ads, atree.adb: (New_Copy): Does not copy aspect specifications
	* sinfo.ads, par-ch3.adb, par-ch6.adb, par-ch7.adb, par-ch9.adb,
	par-endh.adb, par-ch13.adb, par-ch12.adb: Modify grammar to include
	aspect specifications.
	Recognize aspect specifications for all cases
	* par.adb: Recognize aspect specifications for all cases
	* sem_ch12.ads, sem_ch12.adb (Copy_Generic_Node): Copies aspect
	specifications.
	* sem_ch3.adb (Analyze_Subtype_Declaration): Improve patch to freeze
	generic actual types (was missing some guards before).
	* sem_ch9.adb (Analyze_Single_Protected_Declaration): Copy aspects to
	generated object
	(Analyze_Single_Task_Declaration): Copy aspects to generated object

2010-10-12  Eric Botcazou  <ebotcazou@adacore.com>

	* usage.adb (usage): Adjust line for -gnatn switch.

2010-10-12  Robert Dewar  <dewar@adacore.com>

	* sem_attr.adb (Eval_Attribute): Only leave change active for aspect
	spec case.

2010-10-12  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch6.adb (Analyze_Subprogram_Declaration): If this is a
	declaration of a null procedure resolve the types of the profile of the
	generated null body now.

From-SVN: r165353
2010-10-12 11:10:13 +02:00
Rainer Orth
6832435e85 gcc_update: Run $GCC_HG pull and update separately.
* gcc_update: Run $GCC_HG pull and update separately.
	Check parents for SVN revision.

From-SVN: r165352
2010-10-12 08:54:10 +00:00
Jakub Jelinek
d95828db91 rtl.h: Include hashtab.h.
* rtl.h: Include hashtab.h.
	(iterative_hash_rtx): New prototype.
	* rtl.c (iterative_hash_rtx): New function.
	* dwarf2out.c (dw_loc_list_node): Add hash and emitted fields.
	(output_loc_list): Return immediately if emitted is set,
	set it.
	(hash_loc_operands, hash_locs, hash_loc_list,
	compare_loc_operands, compare_locs, loc_list_hash, loc_list_eq,
	optimize_location_lists_1, optimize_location_lists): New function.
	(dwarf2out_finish): Call optimize_location_lists.
	* Makefile.in (RTL_BASE_H): Depend on $(HASHTAB_H).

From-SVN: r165351
2010-10-12 08:24:07 +02:00
Ralf Wildenhues
8207e1fb1b Fix PR testsuite/45974 by reverting r165323 for now.
gcc/:
	PR testsuite/45974
	Revert:
	* Makefile.in ($(lang_checks_parallel))
	($(lang_checks_parallelized)): Use single quotes for
	$(RUNTESTFLAGS), to allow passing quoted content.

From-SVN: r165350
2010-10-12 05:03:52 +00:00
Nicola Pero
debfbfeefc In libobjc/: 2010-10-12 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-12  Nicola Pero  <nicola.pero@meta-innovation.com>

        * Makefile.in (C_SOURCE_FILES): Added protocols.c.
        * objc-private/protocols.h: New.
        * protocols.c: New.
        * init.c: Include objc-private/protocols.h.
        (__objc_exec_class): Call __objc_protocols_init on startup.
        (__objc_init_protocols): Call __objc_protocols_add_protocol.
        * objc-private/runtime.h: Use (struct objc_method_list *) instead
        of MethodList_t, and (struct objc_method *) instead of Method_t.
        * objc/deprecated/struct_objc_class.h: Define
        __objc_STRUCT_OBJC_CLASS_defined.
        * objc-private/module-abi-8.h (struct
        objc_method_description_list): New.
        (struct objc_class): Only define if
        __objc_STRUCT_OBJC_CLASS_defined is undefined.
        * objc/runtime.h (class_getName): New.
        (objc_getProtocol): New.
        (objc_copyProtocolList): New.
        (class_addProtocol): New.
        (class_conformsToProtocol): New.
        (class_copyProtocolList): New.
        (protocol_conformsToProtocol): New.
        (protocol_isEqual): New.
        (protocol_getName): New.
        (protocol_getMethodDescription): New.
        (protocol_copyMethodDescriptionList): New.
        (protocol_getProperty): New.
        (protocol_copyPropertyList): New.
        (protocol_copyProtocolList): New.
        * class.c (class_getName): New.
        * selector.c (sel_isEqual): New.

From-SVN: r165349
2010-10-12 02:43:25 +00:00
Nicola Pero
524660d2e3 In libobjc/: 2010-10-12 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-12  Nicola Pero  <nicola.pero@meta-innovation.com>

        * selector.c (sel_getName): Return "<null selector>" for a NULL
        argument.
        (sel_get_name): Return 0 for a NULL argument.
        * objc/runtime.h (sel_getName): Updated documentation.

        * objc-private/hash.h (class_hash_table): Unused declaration
        removed.
        (module_hash_table): Same.
        * objc/deprecated/hash.h: Same changes.

From-SVN: r165348
2010-10-12 00:27:02 +00:00
GCC Administrator
4d218f5c72 Daily bump.
From-SVN: r165347
2010-10-12 00:18:57 +00:00
John David Anglin
5dbae3676b linux-atomic.c (__sync_val_compare_and_swap_4): Return actual_oldval.
* config/pa/linux-atomic.c (__sync_val_compare_and_swap_4): Return
	actual_oldval.  Use __builtin_expect.
	(SUBWORD_VAL_CAS): Likewise.

From-SVN: r165339
2010-10-11 22:40:22 +00:00
Paolo Carlini
a0a2a39912 [multiple changes]
2010-10-11  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* testsuite/23_containers/bitset/cons/2.cc: Tweak.

2010-10-11  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/std/bitset (bitset<>::bitset(const _CharT*,
	typename std::basic_string<>::size_type, _CharT, _CharT)):
	Implement new proposed resolution for DR 1325.
	* include/debug/bitset: Likewise.
	* include/profile/bitset: Likewise.
	* testsuite/23_containers/bitset/cons/dr1325-1.cc: New.
	* testsuite/23_containers/bitset/cons/dr1325-2.cc: Likewise.

From-SVN: r165338
2010-10-11 22:32:01 +00:00
Nathan Froyd
2c8865f1c1 recog.c (nonmemory_operand): Call immediate_operand for CONSTANT_P operands.
* recog.c (nonmemory_operand): Call immediate_operand for
	CONSTANT_P operands.

From-SVN: r165334
2010-10-11 21:50:58 +00:00
Benjamin Kosnik
63835102f4 api.xml: Add link to 4.5 generated docs.
2010-10-11  Benjamin Kosnik  <bkoz@redhat.com>

	* doc/xml/api.xml: Add link to 4.5 generated docs.

From-SVN: r165332
2010-10-11 21:28:17 +00:00
Uros Bizjak
bbc8841ba1 i386.md (movmem<mode>): Macroize expander from movmem{si,di} using SWI48 mode iterator.
* config/i386/i386.md (movmem<mode>): Macroize expander from
	movmem{si,di} using SWI48 mode iterator.
	(*strmovsi_1): Macroize insn pattern from *strmovsi_1 and
	*strmovsi_rex_1 using P mode iterator.
	(*strmovhi_1): Ditto from *strmovhi_1 and *strmovhi_rex_1.
	(*strmovqi_1): Ditto from *strmovqi_1 and *strmovqi_rex_1.
	(*rep_movsi): Ditto from *rep_movsi and *rep_movsi_rex64.
	(*rep_movqi): Ditto from *rep_movqi and *rep_movqi_rex64.
	(setmem<mode>): Macroize expander from setmem{si,di} using
	SWI48 mode iterator.
	(*strsetsi_1): Macroize insn pattern from *strsetsi_1 and
	*strsetsi_rex_1 using P mode iterator.
	(*strsethi_1): Ditto from *strsethi_1 and *strsethi_rex_1.
	(*strsetqi_1): Ditto from *strsetqi_1 and *strsetqi_rex_1.
	(*rep_stossi): Ditto from *rep_stossi and *rep_stossi_rex64.
	(*rep_stosqi): Ditto from *rep_stosqi and *rep_stosqi_rex64.
	(*cmpstrnqi_nz_1): Ditto from *cmpstrnqi_nz_1 and *cmpstrnqi_nz_rex_1.
	(*cmpstrnqi_1): Ditto from *cmpstrnqi_1 and *cmpstrnqi_rex_1.
	(strlen<mode>): Macroize expander from strlen{si,di} using SWI48x
	mode iterator.
	(*strlenqi_1): Macroize insn pattern from *strlenqi_1 and
	*strlenqi_rex_1 using P mode iterator.

From-SVN: r165331
2010-10-11 22:32:15 +02:00
Martin Jambor
7c663eb022 re PR c++/45562 (ICE: SIGSEGV in cp_build_unary_op (typeck.c:5083) with -std=gnu++0x -fipa-cp-clone -fcompare-debug)
2010-10-11  Martin Jambor  <mjambor@suse.cz>

	PR c++/45562
	* cp/cp-tree.h (current_class_ref): Check that cp_function_chain is
	non-NULL.
	* cp/call.c (build_cxx_call): Likewise.

From-SVN: r165330
2010-10-11 22:23:04 +02:00
Bernd Schmidt
579c1bf349 re PR bootstrap/45445 (ARM bootstrap failure: comparison failures after stage 3)
PR bootstrap/45445
	* ira-lives.c (mark_pseudo_reg_live, mark_pseudo_reg_dead): New
	static functions.
	(mark_ref_live, mark_ref_dead): Use them.
	(make_pseudo_conflict): New arg ORIG_DREG.  All callers changed.
	Save the original reg, and use the new functions.
	(check_and_make_def_use_conflict): New arg ORIG_DREG.  All callers
	changed.
	(check_and_make_def_conflict): Save the original reg.

From-SVN: r165329
2010-10-11 19:39:37 +00:00
Rainer Orth
30aeeca452 dyn_load.c: Fix typo.
* dyn_load.c: Fix typo.
	* pthread_support.c (GC_get_thread_stack_base) [DEBUG_THREADS]:
	Use GC_printf0.

From-SVN: r165328
2010-10-11 19:06:24 +00:00
Martin Jambor
3f1f0ae316 re PR middle-end/45699 (Incorrect copy constructor generated with -O)
2010-10-11  Martin Jambor  <mjambor@suse.cz>

	PR middle-end/45699
	* gimple-fold.c (gimple_fold_obj_type_ref_known_binfo): Choose among
	thunks.

	* testsuite/g++.dg/torture/pr45699.C: New test.
	* testsuite/g++.dg/otr-fold-1.C: Adjusted.
	* testsuite/g++.dg/otr-fold-1.C: Likewise.

From-SVN: r165327
2010-10-11 20:45:23 +02:00
Nicola Pero
90a2689f4d In libobjc/: 2010-10-11 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-11  Nicola Pero  <nicola.pero@meta-innovation.com>

        * class.c (objc_getClassList): New.
        (objc_getRequiredClass): New.
        (objc_getMetaClass): New.
        (objc_lookupClass): New.
        (objc_getClass): New.
        (__objc_get_unknown_class_handler): New.
        (objc_setGetUnknownClassHandler): New.
        (objc_get_class): Use __objc_get_unknown_class_handler.
        (objc_lookup_class): Call objc_getClass.
        * objc/objc-api.h: Updated comment and copyright notice.
        * objc/runtime.h: Updated comments.
        (objc_getClass): New.
        (objc_lookupClass): New.
        (objc_getMetaClass): New.
        (objc_getRequiredClass): New.
        (objc_getClassList): New.
        (objc_setGetUnknownClassHandler): New.
        (objc_get_unknown_class_handler): New.
        * objc-private/runtime.h: Use __objc_private_runtime_INCLUDE_GNU
        instead of __objc_runtime_INCLUDE_GNU as include guard.
        * objc-private/error.h (_objc_abort): Mark as noreturn.

From-SVN: r165326
2010-10-11 18:17:19 +00:00
Ralf Wildenhues
6c0098673b New contrib/test_recheck script to rerun unsuccessful tests.
contrib/:
	* test_recheck: New script.

From-SVN: r165324
2010-10-11 18:04:01 +00:00
Ralf Wildenhues
9dd57a6ef8 Fix quoting for RUNTESTFLAGS in gcc/.
gcc/:
	* Makefile.in ($(lang_checks_parallel))
	($(lang_checks_parallelized)): Use single quotes for
	$(RUNTESTFLAGS), to allow passing quoted content.

From-SVN: r165323
2010-10-11 18:02:41 +00:00
Ralf Wildenhues
e4590d6388 Fix PR bootstrap/35855: awk character classes.
gcc/:
	PR bootstrap/35855
	* opt-functions.awk (BEGIN): New section.
	(lower, upper, digit, alnum): New variables.
	(static_var, opt_sanitized_name): Use alnum instead of character
	classes, for non-C locale.
	* optc-gen.awk: Likewise.
	* opth-gen.awk: Likewise.

From-SVN: r165322
2010-10-11 17:58:53 +00:00
Anatoly Sokolov
fba42e243e target.def (preferred_reload_class): New hook.
* target.def (preferred_reload_class): New hook.
	* doc/tm.texi.in (TARGET_PREFERRED_RELOAD_CLASS): Document.
	* doc/tm.texi: Regenerate.
	* targhooks.c (default_preferred_reload_class): New function.
	* targhooks.h (default_preferred_reload_class): Declare.
	* reload.c (find_dummy_reload): Change preferred_class variable type
	from enum reg_class to reg_class_t. Use TARGET_PREFERRED_RELOAD_CLASS
	target hook.
	(find_reloads): Change goal_alternative array type from int to
	reg_class_t. Use TARGET_PREFERRED_RELOAD_CLASS target hook.
	(push_reload, find_reloads_address_part): Use
	TARGET_PREFERRED_RELOAD_CLASS target hook.
	* reload1.c (emit_input_reload_insns): Ditto.
	* ira-costs.c (copy_cost): Use TARGET_PREFERRED_RELOAD_CLASS target
	hook. Change rclass argument and secondary_class variable types from
	'enum reg_class' to reg_class_t.

	* config/i386/i386.h (PREFERRED_RELOAD_CLASS): Remove.
	* config/i386/i386-protos (ix86_preferred_reload_class): Remove.
	* config/i386/i386.c (ix86_preferred_reload_class): Make static.
	Change regclass argument and result types from enum reg_class to
	reg_class_t.
	(TARGET_PREFERRED_RELOAD_CLASS): Define.

From-SVN: r165321
2010-10-11 21:41:24 +04:00
Eric Botcazou
43c3628797 simplify-rtx.c (simplify_unary_operation_1): Use unsigned arithmetics in masking operations.
* simplify-rtx.c (simplify_unary_operation_1): Use unsigned arithmetics
	in masking operations.
	(simplify_const_unary_operation): Likewise.
	(simplify_binary_operation_1): Likewise.
	(simplify_const_binary_operation): Likewise.
	(simplify_const_relational_operation): Likewise.
	(simplify_ternary_operation): Likewise.
	(simplify_immed_subreg): Likewise.

From-SVN: r165320
2010-10-11 17:15:41 +00:00
John David Anglin
74b90fe2a0 re PR middle-end/45862 (SUPPORTS_WEAK is documented as a C expression, used as a compile time constant)
PR middle-end/45862
	* doc/tm.texi.in (SUPPORTS_WEAK): Update.
	(TARGET_SUPPORTS_WEAK): New.
	* doc/tm.texi: Regenerate.
	* defaults.h (SUPPORTS_WEAK): Update comment.
	(TARGET_SUPPORTS_WEAK): New.
	* dwarf2asm.c (USE_LINKONCE_INDIRECT): Update define.
	* varasm.c (assemble_external): Use TARGET_SUPPORTS_WEAK instead of
	SUPPORTS_WEAK.
	(merge_weak, declare_weak, do_assemble_alias, supports_one_only,
	make_decl_one_only): Likewise.
	* config/pa/som.h (SUPPORTS_WEAK): Rename defines to
	TARGET_SUPPORTS_WEAK.
	(SUPPORTS_ONE_ONLY, MAKE_DECL_ONE_ONLY): Use TARGET_SUPPORTS_WEAK
	instead of SUPPORTS_WEAK.

From-SVN: r165319
2010-10-11 16:52:12 +00:00
Rainer Orth
2861cfa1eb * config/sparc/gmon-sol2.c: Don't include coretypes.h, tm.h.
From-SVN: r165318
2010-10-11 16:43:56 +00:00
Nathan Froyd
9dc1704f8e decl.c (java_init_decl_processing): Use build_function_type_list instead of build_function_type.
* decl.c (java_init_decl_processing): Use build_function_type_list
	instead of build_function_type.
	* jcf-parse.c (java_emit_static_constructor): Likewise.
	* builtins.c (initialize_builtins): Likewise.

From-SVN: r165317
2010-10-11 16:23:52 +00:00
Arnaud Charlet
1928f45020 [multiple changes]
2010-10-11  Robert Dewar  <dewar@adacore.com>

	* debug.adb: Remove d.A flag to delay address clause (not needed any
	more). Add d.A flag to enable tree read/write of aspect spec hash table
	* sem_ch13.adb (Analyze_Aspect_Specifications): Properly delay address
	clause.
	(Rep_Item_Too_Late): No need for special processing for delayed rep
	items (and it caused difficulties in the address case).
	* tree_gen.adb: Only write aspect spec hash table if -gnatd.A is set
	* tree_in.adb: Only write aspect spec hash table if -gnatd.A is set

2010-10-11  Pat Rogers  <rogers@adacore.com>

	* gnat_ugn.texi: Minor editing.

From-SVN: r165316
2010-10-11 17:47:23 +02:00
Nick Clifton
40b7ae584b pr44197.c: Require visibility support.
* gcc.c-torture/compile/pr44197.c: Require visibility support.
        Allow for a user label prefix.

From-SVN: r165315
2010-10-11 15:15:09 +00:00
Nathan Froyd
5095da95bd vec.h (VEC_qsort): Define.
gcc/
	* vec.h (VEC_qsort): Define.
	* dbxout.c (output_used_types): Use it.
	* df-scan.c (df_sort_and_compress_refs): Likewise.
	(df_sort_and_compress_mws): Likewise.
	* genautomata.c (uniq_sort_alt_states): Likewise.
	(evaluate_equiv_classes): Likewise.
	(output_trans_table): Likewise.
	(output_state): Likewise.
	* gimplify.c (compare_case_labels): Likewise.
	* graphite-sese-to-poly.c (graphite_sort_dominated_info): Likewise.
	* ipa.c (build_cdtor_fns): Likewise.
	* lto.c (lto_wpa_write_files): Likewise.
	* sel-sched.c (fill_vec_av_set): Likewise.
	* tree-predcom.c (determine_roots_comp): Likewise.
	* tree-sra.c (sort_and_spliace_var_accesses): Likewise.
	(splice_param_accesses): Likewise.
	* tree-ssa-live.c (dump_enumerated_decls): Likewise.
	* tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
	(reassociate_bb): Likewise.
	* tree-ssa-sccvn.c (sort_scc): Likewise.
	* tree-ssa-structalias.c (sort_fieldstack): Likewise.

gcc/ada/
	* gcc-interface/utils2.c (gnat_build_constructor): Use VEC_qsort.

From-SVN: r165314
2010-10-11 15:08:28 +00:00
Ian Lance Taylor
3748f5c9d3 tree.h (TREE_THIS_NOTRAP): Use TREE_CHECK5.
* tree.h (TREE_THIS_NOTRAP): Use TREE_CHECK5.
	* emit-rtl.c (set_mem_attributes_minus_bitpos): Only check
	TREE_THIS_NOTRAP when appropriate.
	(get_spill_slot_decl): Don't set TREE_THIS_NOTRAP on the new
	VAR_DECL.
	* gimplify.c (gimplify_expr): Copy NOTRAP from INDIRECT_REF to
	newly created MEM_REF.

From-SVN: r165313
2010-10-11 14:56:39 +00:00
Hariharan Sandanagobalane
c159751bf5 picochip-protos.h (picochip_function_arg): Delete.
* config/picochip/picochip-protos.h (picochip_function_arg): Delete.
	(picochip_incoming_function_arg): Delete.
	(picochip_arg_advance): Delete.
	* config/picochip/picochip.h (FUNCTION_ARG): Delete.
	(FUNCTION_INCOMING_ARG): Delete.
	(FUNCTION_ARG_ADVANCE): Delete.
	* config/picochip/picochip.c (picochip_function_arg): Take a
	const_tree and a bool.
	(picochip_incoming_function_arg): Likewise.
	(picochip_arg_advance): Likewise.
	(TARGET_FUNCTION_ARG, TARGET_FUNCTION_INCOMING_ARG): Define.
	(TARGET_FUNCTION_ARG_ADVANCE): Define.

From-SVN: r165312
2010-10-11 14:52:16 +00:00
Andi Kleen
3414bf5384 Add missing ChangeLog.
From-SVN: r165311
2010-10-11 14:15:12 +00:00
Kai Tietz
9df2493c38 lto-plugin.c (dump_symtab): Correct printf argument type.
2010-10-11  Kai Tietz  <kai.tietz@onevision.com>

        * lto-plugin.c (dump_symtab): Correct printf argument type.
        (finish_conflict_resolution): Initialize resolution.

From-SVN: r165310
2010-10-11 16:14:54 +02:00
Andi Kleen
a2a997bace Fix typo in earlier checksum change
I'm checking in a fix as obvious for this typo in the earlier checksum
change.

gcc/objcp

2010-10-11  Andi Kleen  <ak@linux.intel.com>

	* Make-lang.in (cc1objplus-checksum.c): Use correct temporary
	name.

From-SVN: r165309
2010-10-11 14:14:22 +00:00
John David Anglin
7d26a391fd re PR middle-end/45955 (FAIL: gcc.dg/initpri1.c (test for excess errors))
PR middle-end/45955
	* ipa.c (build_cdtor): Delete endless loop.

From-SVN: r165308
2010-10-11 14:02:03 +00:00
Jason Merrill
e90b1c4a4a pt.c (tsubst_default_argument): Handle DEFAULT_ARG.
* pt.c (tsubst_default_argument): Handle DEFAULT_ARG.
	(tsubst_default_arguments): Only do this once for cloned fns.
	(tsubst): Use typedef_variant_p.  Handle LANG_TYPE.  Don't
	handle expressions.
	(tsubst_expr): Avoid calling tsubst_expr for non-expressions.
	(tsubst_copy_and_build): Likewise.
	(tsubst_initializer_list): Likewise.
	(tsubst_copy): Change default to gcc_unreachable.  Handle
	OVERLOAD and PTRMEM_CST.

From-SVN: r165307
2010-10-11 09:25:50 -04:00
Jason Merrill
9c3c8ad740 re PR lto/45959 (ICE: tree code 'template_type_parm' is not supported in gimple streams with -flto/-fwhopr)
PR lto/45959
	PR lto/45960
	* pt.c (tsubst_copy) [INTEGER_CST]: Instantiate the type.

From-SVN: r165306
2010-10-11 09:25:37 -04:00
Andi Kleen
d6d5951a4a Build compiler checksum from object files v2
gcc/

2010-10-07  Andi Kleen  <ak@linux.intel.com>

	* Makefile.in (MOSTLYCLEANFILES): Remove cc1*dummy, add
	checksum-options.
	(checksum-options): Add.
	(cc1-dummy): Remove.
	(cc1-checksum): Change to run checksum over object files
	and options only.
	* dummy-checksum.c: Remove.
	* genchecksum.c: Update copyright.
	(usage): Allow multiple arguments.
	(BLOCKSIZE): Add.
	(dosum): Change for incremental checksum. Remove C output.
	(main): Iterate over all argument files. Add C output.

gcc/cp

2010-10-07  Andi Kleen  <ak@linux.intel.com>

	* Make-lang.in (c++_OBJS): Remove dummy-checksum.o.
	(cc1plus-dummy): Remove.
	(cc1plus-checksum): Change to run checksum over object files
        and options only.

gcc/objc

2010-10-07  Andi Kleen  <ak@linux.intel.com>

	* Make-lang.in (cc1obj-dummy): Remove.
	(cc1obj-checksum): Change to run checksum over object files
        and options only.

gcc/objcp

2010-10-07  Andi Kleen  <ak@linux.intel.com>

	* Make-lang.in (cc1objplus-dummy): Remove.
	(cc1objplus-checksum): Change to run checksum over object files
        and options only.

From-SVN: r165305
2010-10-11 13:06:50 +00:00
Joseph Myers
128dc8e230 params.c (set_param_value_internal): New.
* params.c (set_param_value_internal): New.
	(set_param_value): Use set_param_value_internal.
	(maybe_set_param_value, set_default_param_value): New.
	* params.h (PARAM_VALUE, PARAM_SET_P): Make into rvalues.
	(maybe_set_param_value, set_default_param_value): Declare.
	* config/arm/arm.c (arm_option_override): Use
	maybe_set_param_value.
	* config/i386/i386.c (ix86_option_override_internal): Use
	maybe_set_param_value.
	* config/ia64/ia64.c (ia64_option_default_params,
	TARGET_OPTION_DEFAULT_PARAMS): New.
	(ia64_option_optimization): Move some code to
	ia64_option_default_params.
	* config/picochip/picochip.c (picochip_option_override): Use
	maybe_set_param_value.
	* config/rs6000/rs6000.c (rs6000_option_default_params,
	TARGET_OPTION_DEFAULT_PARAMS): New.
	(rs6000_option_override_internal): Use maybe_set_param_value.
	(rs6000_option_optimization): Move some code to
	rs6000_option_default_params.
	* config/s390/s390.c (s390_option_override): Use
	maybe_set_param_value.
	* config/sh/sh.c (sh_option_default_params,
	TARGET_OPTION_DEFAULT_PARAMS): New.
	(sh_option_optimization): Move some code to
	sh_option_default_params.
	* config/sparc/sparc.c (sparc_option_override): Use
	maybe_set_param_value.
	* config/spu/spu.c (spu_option_default_params,
	TARGET_OPTION_DEFAULT_PARAMS): New.
	(spu_option_optimization): Move some code to
	spu_option_default_params.
	(spu_option_override): Use maybe_set_param_value.
	* doc/tm.texi.in (TARGET_OPTION_DEFAULT_PARAMS): New @hook.
	* doc/tm.texi: Regenerate.
	* ggc-common.c (init_ggc_heuristics): Use set_default_param_value.
	* opts.c (init_options_once): Use PARAM_VALUE not direct access to
	compiler_params.
	(default_options_optimization): Use maybe_set_param_value.
	(finish_options): Use maybe_set_param_value.
	* target.def (target_option.default_params): New hook.
	* toplev.c (general_init): Call
	targetm.target_option.default_params.

From-SVN: r165303
2010-10-11 13:28:40 +01:00
Ira Rosen
4907769827 re PR tree-optimization/45902 (CPU2006 benchmark sphinx3 fails with vectorization)
PR tree-optimization/45902
	* tree-vect-slp.c (vect_get_constant_vectors): Use statement's
	vector type for constants, unless it's a pointer.

From-SVN: r165302
2010-10-11 12:18:47 +00:00
Andreas Krebbel
a6510374cc s390.md (*mov<mode>cc): lgoc -> locg and stgoc -> stocg.
2010-10-11  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>

	* config/s390/s390.md (*mov<mode>cc): lgoc -> locg and stgoc -> stocg.

From-SVN: r165301
2010-10-11 11:49:46 +00:00