Commit Graph

110950 Commits

Author SHA1 Message Date
Uros Bizjak
bd82021880 test-expandargv.c (writeout_test): Check result of fwrite.
* testsuite/test-expandargv.c (writeout_test): Check result of fwrite.

From-SVN: r177529
2011-08-06 19:38:04 +02:00
Uros Bizjak
bc336d6308 sse-22.c (dg-options): Add -march=k8.
* gcc.target/i386/sse-22.c (dg-options): Add -march=k8.
	(pragma GCC target): Add avx, fma4, lzcnt and bmi options.
	* gcc.target/i386/sse-23.c (pragma GCC target): Add avx, fma4,
	lzcnt and bmi options.

From-SVN: r177528
2011-08-06 18:56:49 +02:00
Thomas Koenig
48b155b991 re PR fortran/50004 (ICE in c_ptr_tests_16.f90)
2011-08-06  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR fortran/50004
	* target-memory.c (gfc_target_expr-size): Don't clobber typespec
	for derived types.
	* simplify.c (gfc_simplify_transfer): Don't calculate source_size
	twice.

From-SVN: r177527
2011-08-06 15:19:45 +00:00
Paolo Bonzini
cc3801b0e6 Makefile.in (INCLUDES_FOR_TARGET): New.
2011-08-06  Paolo Bonzini  <bonzini@gnu.org>
            Mikael Morin   <mikael.morin@sfr.fr>

	* Makefile.in (INCLUDES_FOR_TARGET): New.
	(LIBGCC2_CFLAGS): Use it.
	(CRTSTUFF_CFLAGS): Use it instead of INCLUDES. 


Co-Authored-By: Mikael Morin <mikael.morin@sfr.fr>

From-SVN: r177522
2011-08-06 15:14:06 +00:00
H.J. Lu
56b6687b9e Add testcases for PR 47381.
2011-08-06  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/47381
	* gcc.dg/pr47381-1.c: New.
	* gcc.dg/pr47381-2.c: Likewise.
	* gcc.target/i386/pr47381.c: Likewise.

From-SVN: r177514
2011-08-06 07:57:52 -07:00
H.J. Lu
8f2b8cdefe Add testcases for PRs 47727/47372/47715.
2011-08-06  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/47727
	* gcc.dg/pr47727.c: New.

	PR target/47372
	* gcc.dg/pr47372-1.c: New.
	* gcc.dg/pr47372-2.c: Likewise.

	PR target/47715
	* gcc.dg/tls/pr47715-5.c: New.

From-SVN: r177513
2011-08-06 07:50:05 -07:00
H.J. Lu
7ac1b8a01e Add testcases for PRs 47449/47446.
2011-08-06  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/47449
	* gcc.target/i386/pr47449.c: New.

	PR target/47446
	* gcc.dg/pr47446-1.c: New.
	* gcc.dg/pr47446-2.c: Likewise.

From-SVN: r177512
2011-08-06 07:36:52 -07:00
H.J. Lu
08094409ca Add testcases for PRs 47766/47715.
2011-08-06  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/47766
	* gcc.dg/pr47766.c: New.

	PR target/47715
	* gcc.dg/tls/pr47715-1.c: New.
	* gcc.dg/tls/pr47715-2.c: Likewise.
	* gcc.dg/tls/pr47715-3.c: Likewise.
	* gcc.dg/tls/pr47715-4.c: Likewise.

From-SVN: r177511
2011-08-06 07:25:58 -07:00
Nicola Pero
0e0677a2f0 In libobjc/: 2011-08-06 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>

	PR libobjc/50002
	* class.c (__objc_update_classes_with_methods): Iterate over meta
	classes as well as normal classes when refreshing the method
	implementations.  This fixes replacing class methods.

2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>

	* class.c (class_getSuperclass): Fixed to work with meta classes
	still in construction too.

In gcc/testsuite/:
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>

	PR libobjc/50002
	* objc.dg/gnu-api-2-class.m: Updated comments.
	* obj-c++.dg/gnu-api-2-class.mm: Likewise.
	* objc.dg/gnu-api-2-class-meta.m: New test.
	* obj-c++.dg/gnu-api-2-class-meta.mm: Likewise.
	
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>
	
	PR libobjc/49882
	* obj-c++.dg/gnu-api-2-class.mm (main): Test class_getSuperclass()
	with classes that are in construction.

From-SVN: r177510
2011-08-06 14:20:09 +00:00
H.J. Lu
7dff453e64 Add testcases for PRs 48084/49504/49860.
2011-08-06  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/48084
	* gcc.target/i386/pr48084-1.c: New.
	* gcc.target/i386/pr48084-2.c: Likewise.
	* gcc.target/i386/pr48084-3.c: Likewise.
	* gcc.target/i386/pr48084-4.c: Likewise.
	* gcc.target/i386/pr48084-5.c: Likewise.

	PR rtl-optimization/49504
	* gcc.target/i386/pr49504.c: New.

	PR target/49860
	* gcc.dg/pr49860.c: New.

From-SVN: r177509
2011-08-06 07:05:39 -07:00
Uros Bizjak
f68c9aa8fe i386.c (ix86_compute_frame_layout): Simplify frame->save_regs_using_mov calculation.
* config/i386/i386.c (ix86_compute_frame_layout): Simplify
	frame->save_regs_using_mov calculation.

From-SVN: r177508
2011-08-06 14:48:13 +02:00
Andreas Schwab
2c7f9cc076 Remove conflict marker
From-SVN: r177507
2011-08-06 10:07:58 +00:00
Nicola Pero
e2852612bf In libobjc/: 2011-08-06 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>

	* class.c (class_getSuperclass): Fixed typo in comment.

From-SVN: r177506
2011-08-06 09:53:43 +00:00
Nicola Pero
3f54203792 In libobjc/: 2011-08-06 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>

	PR libobjc/49882
	* class.c (class_getSuperclass): Return the superclass if the
	class is in construction.
	* objc/runtime.h (class_getSuperclass): Updated documentation.

In gcc/testsuite/:
2011-08-06  Nicola Pero  <nicola.pero@meta-innovation.com>
	
	PR libobjc/49882
	* objc.dg/gnu-api-2-class.m (main): Test class_getSuperclass()
	with classes that are in construction.

From-SVN: r177505
2011-08-06 09:49:30 +00:00
Uros Bizjak
cd7c6bc5bf i386.md (ssemodesuffix): Remove V8SI mode.
* config/i386/i386.md (ssemodesuffix): Remove V8SI mode.
	* config/i386/sse.md (castmode): New mode attribute.
	(avx_<castmode><avxsizesuffix>_<castmode>): Rename from
	avx_<ssemodesuffix><avxsizesuffix>_<ssemodesuffix>.

From-SVN: r177504
2011-08-06 10:15:10 +02:00
Jason Merrill
b569be8ca6 re PR c++/48993 ([C++0x] segmentation fault when compiling this program with constexpr)
PR c++/48993
	* semantics.c (potential_constant_expression_1) [CALL_EXPR]: Sorry
	on 'this' in a constructor.

From-SVN: r177499
2011-08-06 00:34:45 -04:00
Jason Merrill
bb0a32e80d re PR c++/49921 ([C++0x] Segfault during compilation, decltype and operator->*)
PR c++/49921
	* semantics.c (finish_decltype_type): Call invalid_nonstatic_memfn_p.

From-SVN: r177498
2011-08-06 00:34:37 -04:00
Jason Merrill
dd56ca9f1c re PR c++/49669 ([C++0x] Compiler crashes with "internal compiler error: in perform_member_init, at cp/init.c:530")
PR c++/49669
	* init.c (perform_member_init): Handle invalid array initializer.

From-SVN: r177497
2011-08-06 00:34:29 -04:00
Jason Merrill
5c67ef9aef re PR c++/49988 (constexpr on ctor invokes improper initialization)
PR c++/49988
	* semantics.c (cxx_eval_array_reference): Handle failure to
	reduce the array operand to something we can work with.

From-SVN: r177496
2011-08-06 00:34:21 -04:00
GCC Administrator
de9ef71ca7 Daily bump.
From-SVN: r177495
2011-08-06 00:18:02 +00:00
Thomas Koenig
5f7c4bd72d re PR fortran/37211 (TRANSFER to characters: Size checking)
2011-08-05  Thomas Koenig  <tkoenig@gcc.gnu.org>

        PR fortran/37211
        * fortran/ChangeLog:  Correct PR number from last commit.
        * testsuite/ChangeLog:  Likewise.

From-SVN: r177491
2011-08-05 23:06:18 +00:00
H.J. Lu
8c14fefc3f Add a testcase for PR target/47369.
2011-08-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/47369
	* gcc.dg/pr47369-1.c: New.

From-SVN: r177490
2011-08-05 15:37:32 -07:00
H.J. Lu
9a55e3f6c6 Move gcc.target/i386/pr47364-[12].c gcc.c-torture/compile/pr47364-[12].c.
From-SVN: r177489
2011-08-05 15:27:47 -07:00
H.J. Lu
bc65f81fa1 Add gcc.target/i386/pr47364-2.c and gcc.dg/torture/pr47364-1.c.
From-SVN: r177488
2011-08-05 15:09:56 -07:00
H.J. Lu
f6d44f2016 Add a testcase for PR middle-end/47364.
2011-08-05  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/47364
	* gcc.dg/torture/pr47364-1.c: New.

From-SVN: r177487
2011-08-05 15:05:43 -07:00
Thomas Koenig
86dbed7d1b re PR fortran/37211 (TRANSFER to characters: Size checking)
2011-08-05  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR fortran/37221
	* gfortran.h (gfc_calculate_transfer_sizes):  Add prototype.
	* target-memory.h (gfc_target_interpret_expr):  Add boolean
	argument wether to convert wide characters.
	* target-memory.c (gfc_target_expr_size):  Also return length
	of characters for non-constant expressions if these can be
	determined from the cl.
	(interpret_array):  Add argument for gfc_target_interpret_expr.
	(gfc_interpret_derived):  Likewise.
	(gfc_target_interpret_expr):  Likewise.
	* check.c:  Include target-memory.h.
	(gfc_calculate_transfer_sizes):  New function.
	(gfc_check_transfer):  When -Wsurprising is in force, calculate
	sizes and warn if result is larger than size (check moved from
	gfc_simplify_transfer).
	* simplify.c (gfc_simplify_transfer):  Use
	gfc_calculate_transfer_sizes.  Remove warning.

2011-08-05  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR fortran/37221
	* gfortran.dg/transfer_check_2.f90:  New test case.

From-SVN: r177486
2011-08-05 21:51:59 +00:00
Gabriel Charette
7cfea2ef26 This hack to attach a line 0 source_location to the return statement of main...
This hack to attach a line 0 source_location to the
return statement of main, after parsing is over, was
creating a bug in the line_table, creating an extra
entry, which was creating problems now that we are
trying to serialize the line_table in pph.

* decl.c (finish_function): Remove unecessary line 0 hack.

From-SVN: r177485
2011-08-05 21:28:11 +00:00
Jan Hubicka
9911e25a27 + PR middle-end/49494 + * ipa-inline-analysis.c (remap_predicate): Add bounds check.
+ 	PR middle-end/49494
+ 	* ipa-inline-analysis.c (remap_predicate): Add bounds check.
+ 	* gfortran.dg/pr49494.f90: New testcase.

From-SVN: r177484
2011-08-05 20:56:05 +00:00
Jan Hubicka
75d3e6e372 re PR middle-end/49500 (gcc.dg/tls/alias-1.c)
PR middle-end/49500
	* tree-emultls.c (new_emutls_decl):Add alias_of parameter;
	handle aliases.
	(create_emultls_var):New function.
	(ipa_lower_emutls): Handle aliases correctly.

From-SVN: r177483
2011-08-05 20:52:03 +00:00
Jan Hubicka
f791d33387 re PR tree-optimization/49735 (mips64-elf libgcc build fails with apparently infinite recursion.)
PR middle-end/49735
        * gcc.c-torture/compile/pr49735.c: New testcase
        * ipa-inline.c (recursive_inlining): Look through aliases.

From-SVN: r177482
2011-08-05 20:20:07 +00:00
Jason Merrill
f93b21e270 i386.c (setup_incoming_varargs_ms_64): Move declarations to beginning of function.
* config/i386/i386.c (setup_incoming_varargs_ms_64): Move
	declarations to beginning of function.

From-SVN: r177481
2011-08-05 15:15:33 -04:00
Jason Merrill
d3de8016a5 re PR c++/47453 ([DR 1214] Various non-conforming behaviors with braced-init-list initialization)
PR c++/47453
	* typeck.c (build_x_compound_expr_from_list): Also complain
	about ({...}).

From-SVN: r177480
2011-08-05 15:15:25 -04:00
Jason Merrill
9127e99420 re PR c++/49812 (strange return type for built-in operator++(int, int))
PR c++/49812
	* typeck.c (cp_build_unary_op) [POSTINCREMENT_EXPR]: Strip cv-quals.

From-SVN: r177479
2011-08-05 15:12:24 -04:00
Jason Merrill
fcbc2bedbf re PR c++/49983 ([C++0x] Template types fail in range-based for.)
PR c++/49983
	* parser.c (cp_parser_range_for): Only do auto deduction in
	template if the range is non-dependent.

From-SVN: r177478
2011-08-05 15:12:16 -04:00
Jason Merrill
a034826198 init.c (perform_member_init): Always build_aggr_init for a class member with an explicit mem-initializer.
* init.c (perform_member_init): Always build_aggr_init
	for a class member with an explicit mem-initializer.

From-SVN: r177477
2011-08-05 15:12:09 -04:00
Jason Merrill
3bed46f67f * pt.c (unify) [TEMPLATE_TYPE_PARM]: Allow VLA for C++0x 'auto'.
From-SVN: r177476
2011-08-05 15:12:01 -04:00
Bernd Schmidt
2c331232e9 re PR rtl-optimization/49900 (ICE in advance_target_bb, at sched-ebb.c:691)
PR rtl-optimization/49900
	* sched-ebb.c (add_deps_for_risky_insns): Also add dependencies to
	ensure basic blocks stay in the same order.

From-SVN: r177475
2011-08-05 18:22:36 +00:00
Aldy Hernandez
44e9520681 s390.c (s390_expand_cs_hqi): Add new arguments to store_bit_field.
* config/s390/s390.c (s390_expand_cs_hqi): Add new arguments to
        store_bit_field.
        (s390_expand_atomic): Same.

From-SVN: r177467
2011-08-05 16:44:38 +00:00
Richard Henderson
eebc8f373b re PR rtl-optimization/49977 (CFI notes are missed for delayed slot)
PR rtl-opt/49977
        * dwarf2cfi.c (scan_insn_after): Split out of ...
        (scan_trace): ... here.  Correctly place notes wrt sequences.

From-SVN: r177466
2011-08-05 09:17:46 -07:00
Richard Henderson
6fe818aa72 re PR rtl-optimization/49977 (CFI notes are missed for delayed slot)
PR rtl-opt/49977
        * dwarf2cfi.c (scan_insn_after): Split out of ...
        (scan_trace): ... here.  Correctly place notes wrt sequences.

From-SVN: r177465
2011-08-05 09:17:13 -07:00
Kaz Kojima
7ac1744204 re PR rtl-optimization/49982 (ICE in fixup_args_size_notes, at expr.c:3625)
PR rtl-opt/49982
        * expr.c (fixup_args_size_notes): Look through no-op moves.

Co-Authored-By: Richard Henderson <rth@redhat.com>

From-SVN: r177464
2011-08-05 09:12:16 -07:00
Uros Bizjak
42443bdbc8 i386.md (*movdi_internal_rex64): Use "!o" constraint instead of "!m" for operand 0, alternative 4.
2011-08-05  Uros Bizjak  <ubizjak@gmail.com>

	* config/i386/i386.md (*movdi_internal_rex64): Use "!o" constraint
	instead of "!m" for operand 0, alternative 4.
	(*movdf_internal_rex64): Ditto for operand 0, alernative 6.

From-SVN: r177463
2011-08-05 18:06:09 +02:00
Nicolas Roche
28d711bf64 Makefile.in: Don't use directly ../xgcc to build shared libgnat.
2011-08-05  Nicolas Roche  <roche@adacore.com>

	* gcc-interface/Makefile.in: Don't use directly ../xgcc to build shared 
	libgnat. Use rather the value of GCC_FOR_TARGET. Fix issue with         
	canadian cross.
	* gcc-interface/Make-lang.in: Add support for canadian cross setting.

From-SVN: r177462
2011-08-05 17:57:05 +02:00
Arnaud Charlet
993f8920f4 [multiple changes]
2011-08-05  Matthew Heaney  <heaney@adacore.com>

	* a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Child_Count, Child_Depth):
	subprogram bodies declared out-of-order.

2011-08-05  Yannick Moy  <moy@adacore.com>

	* sem_util.adb (Unique_Name): only prefix with "standard" the names of
	entities directly in package Standard, otherwise skip the standard
	prefix.

From-SVN: r177461
2011-08-05 17:50:24 +02:00
Robert Dewar
9b3956ddfc a-cbmutr.adb: Minor reformatting
2011-08-05  Robert Dewar  <dewar@adacore.com>

	* a-cbmutr.adb: Minor reformatting
	(Allocate_Node): refactor node allocation algorithm

2011-08-05  Robert Dewar  <dewar@adacore.com>

	* opt.ads, opt.adb (Debug_Pragmas_Disabled): New switch.
	* sem_prag.adb (Analyze_Pragma, case Debug_Policy): Implement Disable
	mode.
	(Analyze_Pragma, case Check_Policy): Ditto.
	* sem_prag.ads (Check_Disabled): New function
	* snames.ads-tmpl: Add Name_Disable.

2011-08-05  Robert Dewar  <dewar@adacore.com>

	* gnat_rm.texi: Document implementation-defined policy DISABLE for
	pragmas Assertion_Policy, Check_Policy, Debug_Policy.

From-SVN: r177459
2011-08-05 17:36:47 +02:00
Arnaud Charlet
79e705d601 [multiple changes]
2011-08-05  Ed Schonberg  <schonberg@adacore.com>

	* sem_prag.adb (Analyze_Pragma, case Inline): reject an Inline pragma
	that appears in a generic formal part and applies to a formal
	subprogram.

2011-08-05  Robert Dewar  <dewar@adacore.com>

	* a-cbmutr.ads: Minor reformatting.

From-SVN: r177458
2011-08-05 17:34:38 +02:00
Arnaud Charlet
23b6decabf [multiple changes]
2011-08-05  Matthew Heaney  <heaney@adacore.com>

	* a-comutr.adb, a-cimutr.adb, a-cbmutr.adb (Read): do not use T'Valid
	to check count, check sign of value instead.
	* a-comutr.adb, a-cimutr.adb (Write): return immediately if tree empty
	(Copy_Subtree): allocate copy of source element
	(Equal_Subtree): compare elements, not access objects

2011-08-05  Vincent Celier  <celier@adacore.com>

	* gnat_ugn.texi: Fix VMS alternative.

From-SVN: r177457
2011-08-05 17:32:47 +02:00
Uros Bizjak
24911a5088 i386.md (*push<mode>2): Use "o" constraint instead of "m" for operand 0.
* config/i386/i386.md (*push<mode>2): Use "o" constraint instead
	of "m" for operand 0.  Add type and mode attribute.
	(*pushxf_nointeger"): Use "<" constraint for operand 0.
	(*pushdf_rex64): New pattern, split out of *pushdf.  Use "m"
	constraint instead of "o" for opreand 1.
	(*pushdf): Disable for TARGET_64BIT.  Correct mode attribute.

	* config/i386/predicates.md (lea_address_operand): Rename from
	no_seg_address_operand.
	* config/i386/i386.md (*lea_1): Update operand 1 predicate for rename.
	(*lea_1_zext): Ditto.
	(*lea_2): Ditto.
	(*lea_2_zext): Ditto.

	* config/i386/i386.c (ix86_print_operand_address): Handle SUBREGs of
	parts.base and parts.index.
	* config/i386/predicates.md (aligned_operand): Ditto.
	(cmpxchg8b_pic_memory_operand): Ditto.

From-SVN: r177456
2011-08-05 17:30:07 +02:00
Arnaud Charlet
8f05249cf1 Update comments.
From-SVN: r177455
2011-08-05 17:23:29 +02:00
Arnaud Charlet
811aa6e0a6 Update comments.
From-SVN: r177454
2011-08-05 17:18:29 +02:00