OSDN Git Service

pf3gnuchains/gcc-fork.git
15 years agoResync.
charlet [Thu, 31 Jul 2008 12:40:15 +0000 (12:40 +0000)]
Resync.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138395 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 12:37:42 +0000 (12:37 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* prj-part.adb, prj-part.ads, prj.adb, prj.ads, prj-env.adb:
Move back spec of Parse_Single_Project to body, as it is not called
outside of package Prj.Part.
(Project_Data): Remove components Linker_Name, Linker_Path and
Minimum_Linker_Options as they are no longer set.
Remove function There_Are_Ada_Sources from package Prj and move code
in the only place it was used, in Prj.Env.Set_Ada_Paths.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138394 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Ed Schonberg <schonberg@adacore.com>
charlet [Thu, 31 Jul 2008 12:37:33 +0000 (12:37 +0000)]
2008-07-31  Ed Schonberg  <schonberg@adacore.com>

* exp_aggr.adb (Aggr_Size_OK): If the aggregate has a single component
and the context is an object declaration with non-static bounds, treat
the aggregate as non-static.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138393 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Thomas Quinot <quinot@adacore.com>
charlet [Thu, 31 Jul 2008 12:37:24 +0000 (12:37 +0000)]
2008-07-31  Thomas Quinot  <quinot@adacore.com>

* tbuild.ads: Fix several occurrences of incorrectly referring to
Name_Find as Find_Name.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138392 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Thomas Quinot <quinot@adacore.com>
charlet [Thu, 31 Jul 2008 12:37:14 +0000 (12:37 +0000)]
2008-07-31  Thomas Quinot  <quinot@adacore.com>

* exp_ch9.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138391 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Bob Duff <duff@adacore.com>
charlet [Thu, 31 Jul 2008 12:37:04 +0000 (12:37 +0000)]
2008-07-31  Bob Duff  <duff@adacore.com>

* sinput.adb (Skip_Line_Terminators): Fix handling of LF/CR -- it was
recognized as two end-of-lines, but it should be just one.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138390 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * gnat.dg/missing_acc_check.adb: New test.
charlet [Thu, 31 Jul 2008 12:31:12 +0000 (12:31 +0000)]
* gnat.dg/missing_acc_check.adb: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138389 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Gary Dismukes <dismukes@adacore.com>
charlet [Thu, 31 Jul 2008 11:04:10 +0000 (11:04 +0000)]
2008-07-31  Gary Dismukes  <dismukes@adacore.com>

* exp_attr.adb (Enclosing_Object): New function local to handling of
access attributes,
for retrieving the innermost enclosing object prefix of a compound name.
(Expand_N_Attribute_Reference, N_Attribute_Access): In the case where an
Access attribute has a prefix that is a dereference of an access
parameter (or the prefix is a subcomponent selected from such a
dereference), apply an accessibility check to the access parameter.
Replaces code that rewrote the prefix as a type conversion (and that
didn't handle subcomponent cases).
Also, this is now only applied in the case of 'Access.

* exp_ch6.adb (Expand_Call): Add handling for the case of an access
discriminant passed as an actual to an access formal, passing the
Object_Access_Level of the object containing the access discriminant.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138388 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 11:04:00 +0000 (11:04 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* prj-nmsc.adb:
(Record_Ada_Source): Do not set Data.Sources, component has been removed

* prj.adb: Remove component Sources in record Project_Data

* prj.ads: Remove component Sources in record Project_Data

* sinput.ads, prj-util.ads: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138387 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Ed Schonberg <schonberg@adacore.com>
charlet [Thu, 31 Jul 2008 10:27:42 +0000 (10:27 +0000)]
2008-07-31  Ed Schonberg  <schonberg@adacore.com>

* exp_ch6.adb (Make_Build_In_Place_Call_In_Object_Declaration): Use
Insert_Actions to place the pointer declaration in the code, rather
than Insert_Before_And_Analyze, so that insertions of temporaries are
kept in the proper order when transient scopes are present.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138386 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 10:27:30 +0000 (10:27 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* prj-nmsc.adb (Check_Library_Attributes): Check if Linker'Switches or
Linker'Default_Switches are declared. Warn if they are declared.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138385 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Geert Bosch <bosch@adacore.com>
charlet [Thu, 31 Jul 2008 10:27:20 +0000 (10:27 +0000)]
2008-07-31  Geert Bosch  <bosch@adacore.com>

* arit64.c:
New file implementing __gnat_mulv64 signed integer multiplication with
overflow checking

* fe.h (Backend_Overflow_Checks_On_Target): Define for use by Gigi

* gcc-interface/gigi.h:
(standard_types): Add ADT_mulv64_decl
(mulv64_decl): Define subprogram declaration for __gnat_mulv64

* gcc-interface/utils.c:
(init_gigi_decls): Add initialization of mulv64_decl

* gcc-interface/trans.c:
(build_unary_op_trapv): New function
(build_binary_op_trapv): New function
(gnat_to_gnu): Use the above functions instead of
build_{unary,binary}_op

* gcc-interface/Makefile.in
(LIBGNAT_SRCS): Add arit64.c
(LIBGNAT_OBJS): Add arit64.o

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138384 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Hristian Kirtchev <kirtchev@adacore.com>
charlet [Thu, 31 Jul 2008 10:27:04 +0000 (10:27 +0000)]
2008-07-31  Hristian Kirtchev  <kirtchev@adacore.com>

* exp_attr.adb (Find_Stream_Subprogram): Check the base type instead
of the type when looking for stream subprograms for type String,
Wide_String and Wide_Wide_String.

* s-ststop.adb: Change the initialization expression of constant
Use_Block_IO.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138383 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * s-direio.adb (Reset): Replace pragma Unmodified by Warnings (Off),
charlet [Thu, 31 Jul 2008 10:26:43 +0000 (10:26 +0000)]
* s-direio.adb (Reset): Replace pragma Unmodified by Warnings (Off),
so that we can compile this file successfully with -gnatc.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138382 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 10:26:12 +0000 (10:26 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* s-regexp.ads: Minor comment fix

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138381 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Pascal Obry <obry@adacore.com>
charlet [Thu, 31 Jul 2008 10:26:05 +0000 (10:26 +0000)]
2008-07-31  Pascal Obry  <obry@adacore.com>

* s-finimp.ads: Minor reformatting.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138380 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Thomas Quinot <quinot@adacore.com>
charlet [Thu, 31 Jul 2008 10:25:50 +0000 (10:25 +0000)]
2008-07-31  Thomas Quinot  <quinot@adacore.com>

* g-pehage.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138379 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Sergey Rybin <rybin@adacore.com>
charlet [Thu, 31 Jul 2008 10:25:35 +0000 (10:25 +0000)]
2008-07-31  Sergey Rybin  <rybin@adacore.com>

* gnat_ugn.texi: Change the description of the
Overly_Nested_Control_Structures: now the rule always requires a
positive parameter for '+R' option

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138378 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Robert Dewar <dewar@adacore.com>
charlet [Thu, 31 Jul 2008 10:25:14 +0000 (10:25 +0000)]
2008-07-31  Robert Dewar  <dewar@adacore.com>

* sem_ch12.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138377 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Richard Guenther <rguenther@suse.de>
rguenth [Thu, 31 Jul 2008 10:25:11 +0000 (10:25 +0000)]
2008-07-31  Richard Guenther  <rguenther@suse.de>

* passes.c (init_optimization_passes): Always call
pass_early_warn_uninitialized.
* opts.c (decode_options): Do not warn about -Wuninitialized
at -O0.
* doc/invoke.texi (-Wuninitialized): Correct for enabling at -O0.
* doc/passes.texi (Warn for uninitialized variables): Adjust.

* gcc.dg/uninit-1-O0.c: New testcase.
* gcc.dg/uninit-2-O0.c: Likewise.
* gcc.dg/uninit-3-O0.c: Likewise.
* gcc.dg/uninit-4-O0.c: Likewise.
* gcc.dg/uninit-5-O0.c: Likewise.
* gcc.dg/uninit-6-O0.c: Likewise.
* gcc.dg/uninit-8-O0.c: Likewise.
* gcc.dg/uninit-9-O0.c: Likewise.
* gcc.dg/uninit-A-O0.c: Likewise.
* gcc.dg/uninit-B-O0.c: Likewise.
* gcc.dg/uninit-C-O0.c: Likewise.
* gcc.dg/uninit-D-O0.c: Likewise.
* gcc.dg/uninit-E-O0.c: Likewise.
* gcc.dg/uninit-F-O0.c: Likewise.
* gcc.dg/uninit-G-O0.c: Likewise.
* gcc.dg/uninit-H-O0.c: Likewise.
* gcc.dg/uninit-I-O0.c: Likewise.
* gcc.dg/uninit-10-O0.c: Likewise.
* gcc.dg/uninit-11-O0.c: Likewise.
* gcc.dg/uninit-12-O0.c: Likewise.
* gcc.dg/uninit-13-O0.c: Likewise.
* gcc.dg/uninit-14-O0.c: Likewise.
* gcc.dg/uninit-15-O0.c: Likewise.
* gcc.dg/Wall.c: Avoid uninitialized warning.
* gcc.dg/Wno-all.c: Likewise.
* gcc.dg/pr3074-1.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138376 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * mlib-utl.ads: Fix typo.
charlet [Thu, 31 Jul 2008 10:25:05 +0000 (10:25 +0000)]
* mlib-utl.ads: Fix typo.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138375 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * gnat.dg/specs/genericppc.ads: New test
charlet [Thu, 31 Jul 2008 09:46:03 +0000 (09:46 +0000)]
* gnat.dg/specs/genericppc.ads: New test

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138374 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync
charlet [Thu, 31 Jul 2008 09:43:09 +0000 (09:43 +0000)]
Resync

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138373 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Ed Schonberg <schonberg@adacore.com>
charlet [Thu, 31 Jul 2008 09:42:51 +0000 (09:42 +0000)]
2008-07-31  Ed Schonberg  <schonberg@adacore.com>

* sem_ch6.adb (Analyze_Generic_Subprogram_Body): After analysis,
transfer pre/postconditions from generic copy to original tree, so that
they will appear in each instance.
(Process_PPCs): Do not transform postconditions into a procedure in a
generic context, to prevent double expansion of check pragmas.

* sem_attr.adb: In an instance, the prefix of the 'result attribute
can be the renaming of the
current instance, so check validity of the name accordingly.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138372 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 09:42:39 +0000 (09:42 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* s-os_lib.adb: Minor comment fix

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138371 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Robert Dewar <dewar@adacore.com>
charlet [Thu, 31 Jul 2008 09:42:14 +0000 (09:42 +0000)]
2008-07-31  Robert Dewar  <dewar@adacore.com>

* einfo.adb (Spec_PPC): Now defined for generic subprograms

* einfo.ads (Spec_PPC): Now defined for generic subprograms

* sem_prag.adb (Check_Precondition_Postcondition): Handle generic
subprogram case

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138370 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync
charlet [Thu, 31 Jul 2008 08:30:58 +0000 (08:30 +0000)]
Resync

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138367 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Robert Dewar <dewar@adacore.com>
charlet [Thu, 31 Jul 2008 08:19:24 +0000 (08:19 +0000)]
2008-07-31  Robert Dewar  <dewar@adacore.com>

* gnat_ugn.texi: Update -gnatN documentation.

* gnat_rm.texi: Add note about pre/postcondition
pragmas not checked in conjunction with front-end inlining.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138366 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Vincent Celier <celier@adacore.com>
charlet [Thu, 31 Jul 2008 08:18:53 +0000 (08:18 +0000)]
2008-07-31  Vincent Celier  <celier@adacore.com>

* prj.adb, clean.adb, prj-nmsc.adb, prj.ads: Remove declarations that
were for gprmake only

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138365 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Ed Schonberg <schonberg@adacore.com>
charlet [Thu, 31 Jul 2008 08:17:31 +0000 (08:17 +0000)]
2008-07-31  Ed Schonberg  <schonberg@adacore.com>

sem_attr.adb: 'Result can have an ambiguous prefix, and is resolved
from context. This attribute must be usable in Ada95 mode.
The attribute can appear in the body of a function marked
Inline_Always, but in this case the postocondition is not enforced.

sem_prag.adb (Check_Precondition_Postcondition): within the expansion
of an inlined call pre- and postconditions are legal

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138364 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Robert Dewar <dewar@adacore.com>
charlet [Thu, 31 Jul 2008 08:17:03 +0000 (08:17 +0000)]
2008-07-31  Robert Dewar  <dewar@adacore.com>

* mlib-utl.ads: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138363 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR c/36970
jakub [Thu, 31 Jul 2008 08:02:49 +0000 (08:02 +0000)]
PR c/36970
* builtins.c (maybe_emit_free_warning): New function.
(expand_builtin): Process BUILT_IN_FREE even at -O0.  Call
maybe_emit_free_warning for BUILT_IN_FREE.

* gcc.dg/free-1.c: New test.
* gcc.dg/free-2.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138362 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR debug/36278
jakub [Thu, 31 Jul 2008 08:01:25 +0000 (08:01 +0000)]
PR debug/36278
* dwarf2out.c (get_context_die): New function.
(force_decl_die, force_type_die): Use it.
(dwarf2out_imported_module_or_decl): Likewise.  If base_type_die
returns NULL, force generation of DW_TAG_typedef and put that into
DW_AT_import.

* g++.dg/debug/namespace2.C: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138361 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR preprocessor/36649
jakub [Thu, 31 Jul 2008 07:59:18 +0000 (07:59 +0000)]
PR preprocessor/36649
* c-pch.c (c_common_read_pch): Save and restore
line_table->trace_includes across PCH restore.

* gcc.dg/pch/cpp-3.c: New test.
* gcc.dg/pch/cpp-3.hs: New file.
* gcc.dg/pch/cpp-3a.h: New file.
* gcc.dg/pch/cpp-3b.h: New file.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138360 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync
charlet [Thu, 31 Jul 2008 07:52:12 +0000 (07:52 +0000)]
Resync

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138358 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * mlib-utl.ads, prj-makr.ads: Add comments.
charlet [Thu, 31 Jul 2008 07:51:44 +0000 (07:51 +0000)]
* mlib-utl.ads, prj-makr.ads: Add comments.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138357 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-31 Robert Dewar <dewar@adacore.com>
charlet [Thu, 31 Jul 2008 07:51:32 +0000 (07:51 +0000)]
2008-07-31  Robert Dewar  <dewar@adacore.com>

* g-pehage.adb, g-pehage.ads: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138356 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR c++/11309
jason [Thu, 31 Jul 2008 05:07:10 +0000 (05:07 +0000)]
    PR c++/11309
        * tree.c (build_aggr_init_expr): Split out...
        (build_cplus_new): ...from here.
        (stabilize_init): Don't mess with AGGR_INIT_EXPR either.
        * init.c (build_new_1): new T() means value-initialization,
        not default-initialization.
        (build_vec_init): Likewise.
        (build_value_init_1): Use build_aggr_init_expr.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138355 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
aaronwl [Thu, 31 Jul 2008 00:18:07 +0000 (00:18 +0000)]
2008-07-30  Aaron W. LaFramboise  <aaronavay62@aaronwl.com>

* Makefile.in (EXTRA_GNATRTL_NONTASKING_OBJS) [WINDOWS]: Add
s-winext.o.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138353 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoDaily bump.
gccadmin [Thu, 31 Jul 2008 00:16:40 +0000 (00:16 +0000)]
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138351 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR ada/36554
ebotcazou [Wed, 30 Jul 2008 23:54:56 +0000 (23:54 +0000)]
    PR ada/36554
        * dwarf2out.c (is_subrange_type): Deal with BOOLEAN_TYPE.
ada/
        * back_end.adb (Call_Back_End): Pass Standard_Boolean to gigi.
        * gcc-interface/gigi.h (gigi): Take new standard_boolean parameter.
        * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Enumeration_Subtype>:
        Set precision to 1 for subtype of BOOLEAN_TYPE.
        (set_rm_size): Set TYPE_RM_SIZE_NUM for BOOLEAN_TYPE.
        (make_type_from_size): Deal with BOOLEAN_TYPE.
        * gcc-interface/misc.c (gnat_print_type): Likewise.
        * gcc-interface/trans.c (gigi): Take new standard_boolean parameter.
        Set boolean_type_node as its translation in the table, as well
        as boolean_false_node for False and boolean_true_node for True.
        * gcc-interface/utils.c (gnat_init_decl_processing): Create custom
        8-bit boolean_type_node and set its TYPE_RM_SIZE_NUM.
        (create_param_decl): Deal with BOOLEAN_TYPE.
        (build_vms_descriptor): Likewise.
        (build_vms_descriptor64): Likewise.
        (convert): Deal with BOOLEAN_TYPE like with ENUMERAL_TYPE.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138348 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Rafael Avila de Espindola <espindola@google.com>
espindola [Wed, 30 Jul 2008 23:23:33 +0000 (23:23 +0000)]
2008-07-30  Rafael Avila de Espindola  <espindola@google.com>

PR 36974
* final.c (call_from_call_insn): Handle COND_EXEC

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138347 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 H.J. Lu <hongjiu.lu@intel.com>
hjl [Wed, 30 Jul 2008 20:19:53 +0000 (20:19 +0000)]
2008-07-30  H.J. Lu  <hongjiu.lu@intel.com>

* builtins.c (std_gimplify_va_arg_expr): Replace
PREFERRED_STACK_BOUNDARY with MAX_SUPPORTED_STACK_ALIGNMENT.
* config/i386/i386.c (ix86_gimplify_va_arg): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138340 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 H.J. Lu <hongjiu.lu@intel.com>
hjl [Wed, 30 Jul 2008 19:24:02 +0000 (19:24 +0000)]
2008-07-30  H.J. Lu  <hongjiu.lu@intel.com>
    Joey Ye  <joey.ye@intel.com>

* gcc.dg/dfp/func-vararg-alternate-d128-2.c: New.
* gcc.dg/dfp/func-vararg-mixed-2.c: Likewise.
* gcc.dg/torture/stackalign/alloca-1.c: Likewise.
* gcc.dg/torture/stackalign/builtin-apply-1.c: Likewise.
* gcc.dg/torture/stackalign/builtin-apply-2.c: Likewise.
* gcc.dg/torture/stackalign/builtin-apply-3.c: Likewise.
* gcc.dg/torture/stackalign/builtin-apply-4.c: Likewise.
* gcc.dg/torture/stackalign/builtin-return-1.c: Likewise.
* gcc.dg/torture/stackalign/check.h: Likewise.
* gcc.dg/torture/stackalign/comp-goto-1.c: Likewise.
* gcc.dg/torture/stackalign/fastcall-1.c: Likewise.
* gcc.dg/torture/stackalign/global-1.c: Likewise.
* gcc.dg/torture/stackalign/inline-1.c: Likewise.
* gcc.dg/torture/stackalign/inline-2.c: Likewise.
* gcc.dg/torture/stackalign/nested-1.c: Likewise.
* gcc.dg/torture/stackalign/nested-2.c: Likewise.
* gcc.dg/torture/stackalign/nested-3.c: Likewise.
* gcc.dg/torture/stackalign/nested-4.c: Likewise.
* gcc.dg/torture/stackalign/nested-5.c: Likewise.
* gcc.dg/torture/stackalign/nested-6.c: Likewise.
* gcc.dg/torture/stackalign/non-local-goto-1.c: Likewise.
* gcc.dg/torture/stackalign/non-local-goto-2.c: Likewise.
* gcc.dg/torture/stackalign/non-local-goto-3.c: Likewise.
* gcc.dg/torture/stackalign/non-local-goto-4.c: Likewise.
* gcc.dg/torture/stackalign/non-local-goto-5.c: Likewise.
* gcc.dg/torture/stackalign/pr16660-1.c: Likewise.
* gcc.dg/torture/stackalign/pr16660-2.c: Likewise.
* gcc.dg/torture/stackalign/pr16660-3.c: Likewise.
* gcc.dg/torture/stackalign/regparm-1.c: Likewise.
* gcc.dg/torture/stackalign/ret-struct-1.c: Likewise.
* gcc.dg/torture/stackalign/setjmp-1.c: Likewise.
* gcc.dg/torture/stackalign/setjmp-2.c: Likewise.
* gcc.dg/torture/stackalign/setjmp-3.c: Likewise.
* gcc.dg/torture/stackalign/setjmp-4.c: Likewise.
* gcc.dg/torture/stackalign/sibcall-1.c: Likewise.
* gcc.dg/torture/stackalign/stackalign.exp: Likewise.
* gcc.dg/torture/stackalign/struct-1.c: Likewise.
* gcc.dg/torture/stackalign/vararg-1.c: Likewise.
* gcc.dg/torture/stackalign/vararg-2.c: Likewise.
* gcc.target/i386/align-main-1.c: Likewise.
* gcc.target/i386/align-main-2.c: Likewise.
* gcc.target/i386/pr32000-2.c: Likewise.
* gcc.target/i386/stackalign/asm-1.c: Likewise.
* gcc.target/i386/stackalign/return-1.c: Likewise.
* gcc.target/i386/stackalign/return-2.c: Likewise.
* gcc.target/i386/stackalign/return-3.c: Likewise.
* gcc.target/i386/stackalign/return-4.c: Likewise.
* gcc.target/i386/stackalign/return-5.c: Likewise.
* gcc.target/i386/stackalign/return-6.c: Likewise.
* gcc.target/i386/stackalign/stackalign.exp: Likewise.
* g++.dg/torture/stackalign/check.h: Likewise.
* g++.dg/torture/stackalign/eh-alloca-1.C: Likewise.
* g++.dg/torture/stackalign/eh-fastcall-1.C: Likewise.
* g++.dg/torture/stackalign/eh-global-1.C: Likewise.
* g++.dg/torture/stackalign/eh-inline-1.C: Likewise.
* g++.dg/torture/stackalign/eh-inline-2.C: Likewise.
* g++.dg/torture/stackalign/eh-vararg-1.C: Likewise.
* g++.dg/torture/stackalign/eh-vararg-2.C: Likewise.
* g++.dg/torture/stackalign/stackalign.exp: Likewise.
* g++.dg/torture/stackalign/stdcall-1.C: Likewise.
* g++.dg/torture/stackalign/test-unwind.h: Likewise.
* g++.dg/torture/stackalign/throw-1.C: Likewise.
* g++.dg/torture/stackalign/throw-2.C: Likewise.
* g++.dg/torture/stackalign/throw-3.C: Likewise.
* g++.dg/torture/stackalign/throw-4.C: Likewise.
* g++.dg/torture/stackalign/unwind-0.C: Likewise.
* g++.dg/torture/stackalign/unwind-1.C: Likewise.
* g++.dg/torture/stackalign/unwind-2.C: Likewise.
* g++.dg/torture/stackalign/unwind-3.C: Likewise.
* g++.dg/torture/stackalign/unwind-4.C: Likewise.
* g++.dg/torture/stackalign/unwind-5.C: Likewise.
* g++.dg/torture/stackalign/unwind-6.C: Likewise.

* gcc.target/i386/20060512-1.c: Add -mpreferred-stack-boundary=4.
(main): Move "popl" after check.
* gcc.target/i386/20060512-3.c: Likewise.

* gcc.target/i386/20060512-2.c: Add -mpreferred-stack-boundary=4.
Remove dg-error.

* gcc.target/i386/20060512-4.c: Add -mpreferred-stack-boundary=4.
Remove dg-warning.

* lib/target-supports.exp (check_effective_target_unaligned_stack):
Always return 0.
(check_effective_target_automatic_stack_alignment): New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138336 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Joey Ye <joey.ye@intel.com>
hjl [Wed, 30 Jul 2008 19:20:43 +0000 (19:20 +0000)]
2008-07-30  Joey Ye  <joey.ye@intel.com>
    H.J. Lu  <hongjiu.lu@intel.com>

* builtins.c (expand_builtin_setjmp_receiver): Replace
virtual_incoming_args_rtx with crtl->args.internal_arg_pointer.
(expand_builtin_apply_args_1): Likewise.
(expand_builtin_longjmp): Need DRAP for stack alignment.
(expand_builtin_apply): Likewise.

* caller-save.c (setup_save_areas): Call assign_stack_local_1
instead of assign_stack_local to allow alignment reduction.

* calls.c (emit_call_1): Need DRAP for stack alignment if
return pops.
(expand_call): Replace virtual_incoming_args_rtx with
crtl->args.internal_arg_pointer.
* stmt.c (expand_nl_goto_receiver): Likewise.

* cfgexpand.c (get_decl_align_unit): Estimate stack variable
alignment and store to stack_alignment_estimated and
max_used_stack_slot_alignment.
(expand_one_var): Likewise.
(expand_stack_alignment): New function.
(tree_expand_cfg): Initialize max_used_stack_slot_alignment
and stack_alignment_estimated fields in rtl_data.  Call
expand_stack_alignment at end.

* defaults.h (INCOMING_STACK_BOUNDARY): New.
(MAX_STACK_ALIGNMENT): Likewise.
(MAX_SUPPORTED_STACK_ALIGNMENT): Likewise.
(SUPPORTS_STACK_ALIGNMENT): Likewise.

* emit-rtl.c (gen_reg_rtx): Estimate stack alignment for
stack alignment when generating virtual registers.

* function.c (assign_stack_local): Renamed to ...
(assign_stack_local_1): This.  Add a parameter to indicate
if it is OK to reduce alignment.
(assign_stack_local): Use it.
(instantiate_new_reg): Instantiate virtual incoming args rtx
to vDRAP if stack realignment and DRAP is needed.
(assign_parms): Collect parameter/return type alignment and
contribute to stack_alignment_estimated.
(locate_and_pad_parm): Likewise.
(get_arg_pointer_save_area): Replace virtual_incoming_args_rtx
with crtl->args.internal_arg_pointer.

* function.h (rtl_data): Add new field drap_reg,
max_used_stack_slot_alignment, stack_alignment_estimated,
stack_realign_needed, need_drap, stack_realign_processed and
stack_realign_finalized.
(stack_realign_fp): New macro.
(stack_realign_drap): Likewise.

* global.c (compute_regsets): Frame pointer is needed when
stack is realigned.  Can eliminate frame pointer when stack is
realigned and dynamic realigned argument pointer isn't used.

* reload1.c (update_eliminables):  Frame pointer is needed
when stack is realigned.
(init_elim_table): Can eliminate frame pointer when stack is
realigned and dynamic realigned argument pointer isn't used.

* rtl.h (assign_stack_local_1): Declare new funtion.

* target-def.h (TARGET_UPDATE_STACK_BOUNDARY): New.
(TARGET_GET_DRAP_RTX): Likewise.
(TARGET_CALLS): Add TARGET_UPDATE_STACK_BOUNDARY and
TARGET_GET_DRAP_RTX.

* target.h (gcc_target): Add update_stack_boundary and
get_drap_rtx.

* tree-vectorizer.c (vect_can_force_dr_alignment_p): Replace
STACK_BOUNDARY with MAX_STACK_ALIGNMENT.

2008-07-30  Xuepeng Guo  <xuepeng.guo@intel.com>
    H.J. Lu  <hongjiu.lu@intel.com>

* dwarf2out.c (dw_fde_struct): Add stack_realignment, drap_reg,
vdrap_reg, stack_realign and drap_reg_saved.
(add_cfi): Don't allow redefining CFA when DRAP is used.
(reg_save): Handle stack alignment.
(dwarf2out_frame_debug_expr): Add rules 16-20 to handle stack
alignment.  Don't generate DWARF information for (set fp sp)
when DRAP is used.
(dwarf2out_begin_prologue): Initialize drap_reg and vdrap_reg
to INVALID_REGNUM.
(int_loc_descriptor): Move prototype forward.  Also define if
DWARF2_UNWIND_INFO is true.
(output_cfa_loc): Handle DW_CFA_expression.
(build_cfa_aligned_loc): New.
(based_loc_descr): Update assert for stack realign.  For local
variables, use sp+offset when stack is aligned without drap and
fp+offset when stack is aligned with drap.  For arguments, use
cfa+offset when drap is used to align stack.

2008-07-30  Joey Ye  <joey.ye@intel.com>
    H.J. Lu  <hongjiu.lu@intel.com>

* config/i386/i386.c (ix86_force_align_arg_pointer_string):
Break long line.
(ix86_gen_andsp): New.
(ix86_user_incoming_stack_boundary): Likewise.
(ix86_default_incoming_stack_boundary): Likewise.
(ix86_incoming_stack_boundary): Likewise.
(ix86_can_eliminate): Likewise.
(find_drap_reg): Likewise.
(ix86_update_stack_boundary): Likewise.
(ix86_get_drap_rtx): Likewise.
(ix86_finalize_stack_realign_flags): Likewise.
(TARGET_UPDATE_STACK_BOUNDARY): Likewise.
(TARGET_GET_DRAP_RTX): Likewise.
(override_options): Overide option value for new options.
(ix86_function_ok_for_sibcall): Remove check for
force_align_arg_pointer.
(ix86_handle_cconv_attribute): Likewise.
(ix86_function_regparm): Likewise.
(setup_incoming_varargs_64): Don't set stack_alignment_needed
here.
(ix86_va_start): Replace virtual_incoming_args_rtx with
crtl->args.internal_arg_pointer.
(ix86_select_alt_pic_regnum): Check DRAP register.
(ix86_save_reg): Replace force_align_arg_pointer with drap_reg.
(ix86_compute_frame_layout): Compute frame layout wrt stack
realignment.
(ix86_internal_arg_pointer): Just return
virtual_incoming_args_rtx.
(ix86_expand_prologue): Decide if stack realignment is needed
and generate prologue code accordingly.
(ix86_expand_epilogue): Generate epilogue code wrt stack
realignment is really needed or not.

* config/i386/i386.h (MAIN_STACK_BOUNDARY): New.
(ABI_STACK_BOUNDARY): Likewise.
(PREFERRED_STACK_BOUNDARY_DEFAULT): Likewise.
(STACK_REALIGN_DEFAULT): Likewise.
(INCOMING_STACK_BOUNDARY): Likewise.
(MAX_STACK_ALIGNMENT): Likewise.
(ix86_incoming_stack_boundary): Likewise.
(FORCE_PREFERRED_STACK_BOUNDARY_IN_MAIN): Removed.
(REAL_PIC_OFFSET_TABLE_REGNUM): Updated to use BX_REG.
(CAN_ELIMINATE): Defined with ix86_can_eliminate.
(machine_function): Remove force_align_arg_pointer.

* config/i386/i386.md (BX_REG): New.
(R13_REG): Likewise.

* config/i386/i386.opt (mforce_drap): New.
(mincoming-stack-boundary): Likewise.
(mstackrealign): Add Init(-1).

* config/i386/i386-protos.h (ix86_can_eliminate): New

2008-07-30  H.J. Lu  <hongjiu.lu@intel.com>

* doc/extend.texi: Update force_align_arg_pointer.

* doc/invoke.texi: Document -mincoming-stack-boundary.  Update
-mstackrealign.

* doc/tm.texi (MAX_STACK_ALIGNMENT): Add macro.
(INCOMING_STACK_BOUNDARY): Likewise.
(TARGET_UPDATE_STACK_BOUNDARY): New target hook.
(TARGET_GET_DRAP_RTX): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138335 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoPR rtl-optimization/36929
schwab [Wed, 30 Jul 2008 18:22:50 +0000 (18:22 +0000)]
PR rtl-optimization/36929
* dse.c (replace_inc_dec): Use emit_insn_before instead of
add_insn_before and fix argument order.
(replace_inc_dec_mem): Handle NULL rtx.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138333 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync.
charlet [Wed, 30 Jul 2008 17:39:56 +0000 (17:39 +0000)]
Resync.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138332 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Laurent Pautet <pautet@adacore.com>
charlet [Wed, 30 Jul 2008 17:38:55 +0000 (17:38 +0000)]
2008-07-30  Laurent Pautet  <pautet@adacore.com>

* g-pehage.adb:
Remove a limitation on the length of the words handled by the minimal
perfect hash function generator.

* g-pehage.ads:
Detail the use of subprograms Insert, Initialize, Compute and Finalize.
Fix some typos.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138331 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 17:38:25 +0000 (17:38 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* sem_ch8.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138330 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 17:38:16 +0000 (17:38 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* exp_util.ads (Find_Prim_Op): Document that Program_Error is raised
if no primitive operation is found.

* exp_util.adb: (Find_Prim_Op): Add comments for previous change

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138329 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 17:38:04 +0000 (17:38 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* exp_ch9.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138328 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * config/arm/arm.c (arm_compute_static_chain_stack_bytes): New
andrewjenner [Wed, 30 Jul 2008 16:28:01 +0000 (16:28 +0000)]
* config/arm/arm.c (arm_compute_static_chain_stack_bytes): New
function.
(arm_compute_initial_elimination_offset): Use it.
(arm_compute_save_reg_mask): Include static chain save slot when
calculating alignment.
(arm_get_frame_offsets): Ditto.
(thumb1_compute_save_reg_mask): Ensure we have a low register saved
that we can use to decrement the stack when the stack decrement
could be too big for an immediate value in a single insn.
(thumb1_expand_prologue): Avoid using r12 for stack decrement.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138327 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync.
charlet [Wed, 30 Jul 2008 15:56:34 +0000 (15:56 +0000)]
Resync.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138325 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Hristian Kirtchev <kirtchev@adacore.com>
charlet [Wed, 30 Jul 2008 15:53:21 +0000 (15:53 +0000)]
2008-07-30  Hristian Kirtchev  <kirtchev@adacore.com>

* einfo.adb: Flag245 is now used.
(Is_Primitive_Wrapper, Set_Is_Primitive_Wrapper): Relax the assertion
check to include functions.
(Is_Private_Primitive, Set_Is_Private_Primitive): New subprograms.
(Wrapped_Entity, Set_Wrapped_Entity): Relax the assertion check to
include functions.
(Write_Entity_Flags): Move flag Is_Primitive, add Is_Private_Primitive
to the list of displayed flags.

* einfo.ads: Update comment on the usage of Is_Primitive_Wrapper and
Wrapped_Entity. These two flags are now present in functions.
New flag Is_Private_Primitive.
(Is_Private_Primitive, Set_Is_Private_Primitive): New subprograms.

* exp_ch9.adb:
(Build_Wrapper_Bodies): New subprogram.
(Build_Wrapper_Body): The spec and body have been moved to in
Build_Wrapper_ Bodies. Code cleanup.
(Build_Wrapper_Spec): Moved to the spec of Exp_Ch9. Code cleanup.
Wrappers are now generated for primitives declared between the private
and full view of a concurrent type that implements an interface.
(Build_Wrapper_Specs): New subprogram.
(Expand_N_Protected_Body): Code reformatting. Replace the wrapper body
creation mechanism with a call to Build_Wrapper_Bodies.
(Expand_N_Protected_Type_Declaration): Code reformatting. Replace the
wrapper spec creation mechanism with a call to Build_Wrapper_Specs.
(Expand_N_Task_Body): Replace the wrapper body creation
mechanism with a call to Build_Wrapper_Bodies.
(Expand_N_Task_Type_Declaration): Replace the wrapper spec
creation mechanism with a call to Build_Wrapper_Specs.
(Is_Private_Primitive_Subprogram): New subprogram.
(Overriding_Possible): Code cleanup.
(Replicate_Entry_Formals): Renamed to Replicate_Formals, code cleanup.

* exp_ch9.ads (Build_Wrapper_Spec): Moved from the body of Exp_Ch9.

* sem_ch3.adb: Add with and use clause for Exp_Ch9.
(Process_Full_View): Build wrapper specs for all primitives
that belong to a private view completed by a concurrent type
implementing an interface.

* sem_ch6.adb (Analyze_Subprogram_Body): When the current subprogram
is a primitive of a
concurrent type with a private view that implements an interface, try to
find the proper spec.
(Analyze_Subprogram_Declaration): Mark a subprogram as a private
primitive if the type of its first parameter is a non-generic tagged
private type.
(Analyze_Subprogram_Specification): Code reformatting.
(Disambiguate_Spec): New routine.
(Find_Corresponding_Spec): Add a flag to controll the output of errors.
(Is_Private_Concurrent_Primitive): New routine.

* sem_ch6.ads:
(Find_Corresponding_Spec): Add a formal to control the output of errors.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138324 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 15:53:08 +0000 (15:53 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* uintp.adb (UI_GCD): Fix potential overflow

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138323 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Ed Schonberg <schonberg@adacore.com>
charlet [Wed, 30 Jul 2008 15:52:58 +0000 (15:52 +0000)]
2008-07-30  Ed Schonberg  <schonberg@adacore.com>

* sem_ch8.adb (Analyze_Subprogram_Renaming): When renaming an attribute
as a actual in an instance, check for a missing attribute to prevent
program_error on an illegal program.

* exp_util.adb (Find_Prim_Op): Rather than Assert (False), raise program
error if primitive is not found, so that exception can be handled
elsewhere on illegal programs.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138322 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Thomas Quinot <quinot@adacore.com>
charlet [Wed, 30 Jul 2008 15:52:47 +0000 (15:52 +0000)]
2008-07-30  Thomas Quinot  <quinot@adacore.com>

* rtsfind.adb (Check_RPC): Check version consistency even when not
generating RCI stubs. Provide more detailed error message in case of
mismatch.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138321 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 15:52:36 +0000 (15:52 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* gnatlink.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138320 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Richard Guenther <rguenther@suse.de>
rguenth [Wed, 30 Jul 2008 15:43:42 +0000 (15:43 +0000)]
2008-07-30  Richard Guenther  <rguenther@suse.de>

PR tree-optimization/36967
* tree-predcom.c (remove_stmt): Use gimple_assign_ssa_name_copy_p.
Release defs of statements we remove.

* gfortran.dg/pr36967.f: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138318 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * config/arm/arm.c (arm_expand_prologue): Use 0-length rtvec
froydnj [Wed, 30 Jul 2008 15:32:34 +0000 (15:32 +0000)]
    * config/arm/arm.c (arm_expand_prologue): Use 0-length rtvec
        instead of NULL_RTVEC.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138317 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR target/35866
froydnj [Wed, 30 Jul 2008 15:30:59 +0000 (15:30 +0000)]
PR target/35866

* config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Add clause for
vector modes.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138316 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agosync with src
bonzini [Wed, 30 Jul 2008 15:04:24 +0000 (15:04 +0000)]
sync with src

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138314 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoconfig: sync with src
bonzini [Wed, 30 Jul 2008 14:57:07 +0000 (14:57 +0000)]
config: sync with src
2008-07-25  Keith Seitz  <keiths@redhat.com>

* acinclude.m4: Remove libide, libgui, and all the other Tcl
functions.
* tcl.m4: New file.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138313 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Rafael Avila de Espindola <espindola@google.com>
espindola [Wed, 30 Jul 2008 13:59:58 +0000 (13:59 +0000)]
2008-07-30  Rafael Avila de Espindola  <espindola@google.com>

       * final.c (call_from_call_insn): New.
       (final_scan_insn): Call assemble_external on FUNCTION_DECLs.

2008-07-30  Rafael Avila de Espindola  <espindola@google.com>

* gcc.dg/visibility-14.c: New test.
* gcc.dg/visibility-15.c: New test.
* gcc.dg/visibility-16.c: New test.
* gcc.dg/visibility-17.c: New test.
* gcc.dg/visibility-18.c: New test.
* gcc.dg/visibility-19.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138310 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Dodji Seketeli <dseketel@redhat.com>
dodji [Wed, 30 Jul 2008 13:07:50 +0000 (13:07 +0000)]
2008-07-30  Dodji Seketeli  <dseketel@redhat.com>

PR c++/36767
* decl2.c (fix_temporary_vars_context_r): New function.
 (one_static_initialization_or_destruction): Make sure temporary
 variables part of the initialiser have their DECL_CONTEXT()
 properly set.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138308 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Doug Rupp <rupp@adacore.com>
charlet [Wed, 30 Jul 2008 13:06:45 +0000 (13:06 +0000)]
2008-07-30  Doug Rupp  <rupp@adacore.com>

* gigi.h (build_vms_descriptor64): New function prototype.
(fill_vms_descriptor): Modified function prototype.

* utils.c (build_vms_descriptor64): New function.

* utils2.c (fill_vms_descriptor): Fix handling on 32bit systems.

* trans.c (call_to_gnu): Call fill_vms_descriptor with new third
argument.

* decl.c (gnat_to_gnu_tree): For By_Descriptor mech, build both a
64bit and 32bit descriptor and save the 64bit version as an alternate
TREE_TYPE in the parameter.
(make_type_from_size) <RECORD_TYPE>: Use the appropriate mode for the
thin pointer.

* ada-tree.h (DECL_PARM_ALT, SET_DECL_PARM_ALT): New macros.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138307 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync
charlet [Wed, 30 Jul 2008 13:04:41 +0000 (13:04 +0000)]
Resync

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138306 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Jose Ruiz <ruiz@adacore.com>
charlet [Wed, 30 Jul 2008 13:03:32 +0000 (13:03 +0000)]
2008-07-30  Jose Ruiz  <ruiz@adacore.com>

* adaint.c
(__gnat_file_exists): Do not use __gnat_stat for RTX.
(__main for RTX in RTSS mode): Create this dummy procedure symbol to
avoid the use of this symbol from libgcc.a in RTX kernel mode.

* cio.c
(put_int, put_int_stderr, put_char, put_char_stderr): For RTX we call
the function RtPrintf for console output.

* argv.c Do not use the environ variable for RTX.

* gnatlink.adb (gnatlink): The part that handles the --RTS option has
been moved before the call to Osint.Add_Default_Search_Dirs in order
to take into account the flags in system.ads (RTX_RTSS_Kernel_Module)
from the appropriate run time.

* targparm.ads
(RTX_RTSS_Kernel_Module_On_Target): Add this flag that is set to True if
target is a RTSS module for RTX.

* targparm.adb (Targparm_Tags, RTX_Str, Targparm_Str): Add tag RTX for
RTX_RTSS_Kernel_Module
(Get_Target_Parameters): Add processing of RTX_RTSS_Kernel_Module flag.

* gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS for RTX): Use gcc
exception handling mechanism for Windows and RTX in Win32 mode, but
not for RTX in kernel mode (RTSS).
(LIBGNAT_SRCS): Remove ada.h

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138305 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 13:02:39 +0000 (13:02 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* osint.ads: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138304 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 13:02:30 +0000 (13:02 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* mlib-utl.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138303 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Robert Dewar <dewar@adacore.com>
charlet [Wed, 30 Jul 2008 13:02:21 +0000 (13:02 +0000)]
2008-07-30  Robert Dewar  <dewar@adacore.com>

* make.adb: Minor reformatting

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138302 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Paolo Bonzini <bonzini@gnu.org>
bonzini [Wed, 30 Jul 2008 12:17:17 +0000 (12:17 +0000)]
2008-07-30  Paolo Bonzini  <bonzini@gnu.org>

* configure.ac: Add makefile fragments for hpux.
* Makefile.def (flags_to_pass): Add ADA_CFLAGS.
* Makefile.tpl (HOST_EXPORTS): Pass ADA_CFLAGS.
* configure: Regenerate.
* Makefile.in: Regenerate.

config:
2008-07-30  Paolo Bonzini  <bonzini@gnu.org>

* mh-pa: New, from gcc/config/pa/x-ada.
* mh-pa-hpux10: New, from gcc/config/pa/x-ada-hpux10.

gcc:
2008-07-30  Paolo Bonzini  <bonzini@gnu.org>

* configure.ac: Substitute ADA_CFLAGS.
* configure: Regenerate.
* config.host: Remove mention of pa/x-ada and pa/x-ada-hpux10 files.
* Makefile.in: Remove mention of X_* variables.
* config/pa/x-ada-hpux10: Remove.
* config/pa/x-ada: Remove.

* doc/fragments.texi: Update.

gcc/ada:
2008-07-30  Paolo Bonzini  <bonzini@gnu.org>

* gcc-interface/Make-lang.in (ALL_ADAFLAGS): Remove X_ADAFLAGS and
T_ADAFLAGS, replace ALL_ADA_CFLAGS with ADA_CFLAGS.
(ALL_ADA_CFLAGS): Remove, replace throughout with ADA_CFLAGS.
* gcc-interface/Makefile.in (XCFLAGS, X_CFLAGS, X_CPPFLAGS, T_CPPFLAGS,
X_ADA_CFLAGS, T_ADA_CFLAGS, X_ADAFLAGS, T_ADAFLAGS, ADA_CFLAGS,
ALL_ADA_CFLAGS): Remove.
(ALL_ADAFLAGS, MOST_ADAFLAGS): Remove X_ADAFLAGS and T_ADAFLAGS,
        replace ALL_ADA_CFLAGS with ADA_CFLAGS.
(GCC_CFLAGS): Remove X_CFLAGS.
(LOOSE_CFLAGS): Remove X_CFLAGS and XCFLAGS.
(ALL_CPPFLAGS): Remove X_CPPFLAGS and T_CPPFLAGS.
(ADA_CFLAGS): Substitute.

gnattools:
2008-07-30  Paolo Bonzini  <bonzini@gnu.org>

* configure.ac (x_ada_cflags): Remove.
(ADA_CFLAGS): Substitute.
* configure: Regenerate.
* Makefile.in (ADA_CFLAGS): Substitute.
(T_ADA_CFLAGS, X_ADA_CFLAGS, ALL_ADA_CFLAGS): Remove.
(TOOLS_FLAGS_TO_PASS_1, TOOLS_FLAGS_TO_PASS_1re,
TOOLS_FLAGS_TO_PASS_NATIVE, TOOLS_FLAGS_TO_PASS_CROSS):
Pass ADA_CFLAGS.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138301 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agomove wrong gcc/ChangeLog entry to gnattools/ChangeLog
bonzini [Wed, 30 Jul 2008 12:09:47 +0000 (12:09 +0000)]
move wrong gcc/ChangeLog entry to gnattools/ChangeLog

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138300 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoFix date on entry headline.
hainque [Wed, 30 Jul 2008 10:15:19 +0000 (10:15 +0000)]
Fix date on entry headline.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138298 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * config/mips/irix-crti.asm: .hide __gcc_init and __gcc_fini.
hainque [Wed, 30 Jul 2008 10:13:46 +0000 (10:13 +0000)]
    * config/mips/irix-crti.asm: .hide __gcc_init and __gcc_fini.
        * config/mips/iris6.h (IRIX_SUBTARGET_LINK_SPEC, irix ld): Hide
        __dso_handle explicitly here.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138297 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-30 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
manu [Wed, 30 Jul 2008 08:30:32 +0000 (08:30 +0000)]
2008-07-30  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>

PR 34389
* c-typeck.c (build_binary_op): Encapsulate code into...
* c-common.c (shorten_binary_op): ...this new function.
(conversion_warning): Use the new function. Handle non-negative
constant in bitwise-and.
* c-common.h (shorten_binary_op): Declare.
cp/
* typeck.c (build_binary_op): Encapsulate code into
shorten_binary_op.
testsuite/
* gcc.dg/Wconversion-pr34389.c: New.
* g++.dg/warn/Wconversion-pr34389.C: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138296 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * scan.c (make_sstring_space): Add explicit conversions of
hainque [Wed, 30 Jul 2008 07:44:09 +0000 (07:44 +0000)]
* scan.c (make_sstring_space): Add explicit conversions of
allocator's return value.
* fix-header.c (recognized_function): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138295 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agogcc/ChangeLog
guerby [Wed, 30 Jul 2008 06:45:39 +0000 (06:45 +0000)]
gcc/ChangeLog
2008-07-29  Laurent Guerby <laurent@guerby.net>

        PR ada/5911
        * gnattools/Makefile.in: Replace stamp-gnatlib by
        stamp-gnatlib-rts.

gcc/ada/ChangeLog
2008-07-29  Laurent Guerby <laurent@guerby.net>

        PR ada/5911
        * gcc-interface/Makefile.in (MULTISUBDIR, RTSDIR): New variables.
        Pass MULTISUBDIR to recursive make. Use $(RTSDIR) instead of rts.
        Replace stamp-gnatlib* by stamp-gnatlib*-rts.
        * gcc-interface/Make-lang.in: Replace stamp-gnatlib2
        by stamp-gnatlib2-rts.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138294 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agogcc/ada/
rwild [Wed, 30 Jul 2008 05:28:53 +0000 (05:28 +0000)]
gcc/ada/
PR documentation/15479
* gnat-style.texi: Remove AdaCore copyright statement and GPL
statement for GNAT.  Add @copying stanza, use it.  Update to
GFDL 1.2.  Do not list GFDL as Invariant Section, do not list
title as Front-Cover Text.
* gnat_rm.texi: Likewise.
* gnat_ugn.texi: Likewise.

gcc/
* doc/cpp.texi: Update to GFDL 1.2.
* doc/gcc.texi: Do not list GPL as Invariant Section.
* doc/gccint.texi: Likewise.  Update copyright years.
* doc/install.texi: Update copyright years.

gcc/fortran/
* gfc-internals.texi: Update to GFDL 1.2.  Do not list GPL as
Invariant Section.
* gfortran.texi: Likewise.
* intrinsic.texi: Do not list GPL as Invariant Section.
* invoke.texi: Likewise.  Update copyright years.

gcc/java/
* gcj.texi: Update copyright years.  Do not list GPL as
Invariant Section.

libgomp/
* libgomp.texi: Update to GFDL 1.2.  Update copyright years.
Do not list GPL as Invariant Section.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138293 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR target/36955
amodra [Wed, 30 Jul 2008 02:43:05 +0000 (02:43 +0000)]
PR target/36955
* config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Add
a use of pic_offset_table_rtx for -msecure-plt __tls_get_addr calls.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138291 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoDaily bump.
gccadmin [Wed, 30 Jul 2008 00:16:57 +0000 (00:16 +0000)]
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138289 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * gcc.dg/pr32370.c: Force 64 bits on IA64.
sje [Tue, 29 Jul 2008 22:32:32 +0000 (22:32 +0000)]
* gcc.dg/pr32370.c: Force 64 bits on IA64.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138277 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoIndex: gcc/fortran/trans-expr.c
pault [Tue, 29 Jul 2008 20:44:09 +0000 (20:44 +0000)]
Index: gcc/fortran/trans-expr.c
===================================================================
*** gcc/fortran/trans-expr.c (revision 138273)
--- gcc/fortran/trans-expr.c (working copy)
***************
*** 1,6 ****
  /* Expression translation
!    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software
!    Foundation, Inc.
     Contributed by Paul Brook <paul@nowt.org>
     and Steven Bosscher <s.bosscher@student.tudelft.nl>

--- 1,6 ----
  /* Expression translation
!    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
!    Free Software Foundation, Inc.
     Contributed by Paul Brook <paul@nowt.org>
     and Steven Bosscher <s.bosscher@student.tudelft.nl>

*************** gfc_conv_component_ref (gfc_se * se, gfc
*** 395,400 ****
--- 395,434 ----
  }

+ /* This function deals with component references to components of the
+    parent type for derived type extensons.  */
+ static void
+ conv_parent_component_references (gfc_se * se, gfc_ref * ref)
+ {
+   gfc_component *c;
+   gfc_component *cmp;
+   gfc_symbol *dt;
+   gfc_ref parent;
+
+   dt = ref->u.c.sym;
+   c = ref->u.c.component;
+
+   /* Build a gfc_ref to recursively call gfc_conv_component_ref.  */
+   parent.type = REF_COMPONENT;
+   parent.next = NULL;
+   parent.u.c.sym = dt;
+   parent.u.c.component = dt->components;
+
+   if (dt->attr.extension && dt->components)
+     {
+       /* Return if the component is not in the parent type.  */
+       for (cmp = dt->components->next; cmp; cmp = cmp->next)
+  if (strcmp (c->name, cmp->name) == 0)
+    return;
+
+       /* Otherwise build the reference and call self.  */
+       gfc_conv_component_ref (se, &parent);
+       parent.u.c.sym = dt->components->ts.derived;
+       parent.u.c.component = c;
+       conv_parent_component_references (se, &parent);
+     }
+ }
+
  /* Return the contents of a variable. Also handles reference/pointer
     variables (all Fortran pointer references are implicit).  */

*************** gfc_conv_variable (gfc_se * se, gfc_expr
*** 561,566 ****
--- 595,603 ----
     break;

   case REF_COMPONENT:
+    if (ref->u.c.sym->attr.extension)
+      conv_parent_component_references (se, ref);
+
     gfc_conv_component_ref (se, ref);
     break;

Index: gcc/fortran/trans-array.c
===================================================================
*** gcc/fortran/trans-array.c (revision 138273)
--- gcc/fortran/trans-array.c (working copy)
*************** gfc_conv_resolve_dependencies (gfc_loopi
*** 3257,3270 ****
        if (ss->type != GFC_SS_SECTION)
   continue;

!       if (gfc_could_be_alias (dest, ss)
!      || gfc_are_equivalenced_arrays (dest->expr, ss->expr))
   {
!    nDepend = 1;
!    break;
   }
!
!       if (dest->expr->symtree->n.sym == ss->expr->symtree->n.sym)
   {
     lref = dest->expr->ref;
     rref = ss->expr->ref;
--- 3257,3272 ----
        if (ss->type != GFC_SS_SECTION)
   continue;

!       if (dest->expr->symtree->n.sym != ss->expr->symtree->n.sym)
   {
!    if (gfc_could_be_alias (dest, ss)
!  || gfc_are_equivalenced_arrays (dest->expr, ss->expr))
!      {
!        nDepend = 1;
!        break;
!      }
   }
!       else
   {
     lref = dest->expr->ref;
     rref = ss->expr->ref;
Index: gcc/fortran/symbol.c
===================================================================
*** gcc/fortran/symbol.c (revision 138273)
--- gcc/fortran/symbol.c (working copy)
*************** gfc_add_component (gfc_symbol *sym, cons
*** 1701,1706 ****
--- 1701,1714 ----
        tail = p;
      }

+   if (sym->attr.extension
+  && gfc_find_component (sym->components->ts.derived, name))
+     {
+       gfc_error ("Component '%s' at %C already in the parent type "
+   "at %L", name, &sym->components->ts.derived->declared_at);
+       return FAILURE;
+     }
+
    /* Allocate a new component.  */
    p = gfc_get_component ();

*************** gfc_find_component (gfc_symbol *sym, con
*** 1830,1846 ****
      if (strcmp (p->name, name) == 0)
        break;

    if (p == NULL)
      gfc_error ("'%s' at %C is not a member of the '%s' structure",
          name, sym->name);
!   else
      {
!       if (sym->attr.use_assoc && (sym->component_access == ACCESS_PRIVATE
!    || p->access == ACCESS_PRIVATE))
   {
     gfc_error ("Component '%s' at %C is a PRIVATE component of '%s'",
        name, sym->name);
!    p = NULL;
   }
      }

--- 1838,1873 ----
      if (strcmp (p->name, name) == 0)
        break;

+   if (p == NULL
+  && sym->attr.extension
+  && sym->components->ts.type == BT_DERIVED)
+     {
+       p = gfc_find_component (sym->components->ts.derived, name);
+       /* Do not overwrite the error.  */
+       if (p == NULL)
+  return p;
+     }
+
    if (p == NULL)
      gfc_error ("'%s' at %C is not a member of the '%s' structure",
          name, sym->name);
!
!   else if (sym->attr.use_assoc)
      {
!       if (p->access == ACCESS_PRIVATE)
   {
     gfc_error ("Component '%s' at %C is a PRIVATE component of '%s'",
        name, sym->name);
!    return NULL;
!  }
!
!       /* If there were components given and all components are private, error
!   out at this place.  */
!       if (p->access != ACCESS_PUBLIC && sym->component_access == ACCESS_PRIVATE)
!  {
!    gfc_error ("All components of '%s' are PRIVATE in structure"
!       " constructor at %C", sym->name);
!    return NULL;
   }
      }

Index: gcc/fortran/decl.c
===================================================================
*** gcc/fortran/decl.c (revision 138273)
--- gcc/fortran/decl.c (working copy)
*************** match_data_constant (gfc_expr **result)
*** 367,373 ****
        return MATCH_ERROR;
      }
    else if (sym->attr.flavor == FL_DERIVED)
!     return gfc_match_structure_constructor (sym, result);

    /* Check to see if the value is an initialization array expression.  */
    if (sym->value->expr_type == EXPR_ARRAY)
--- 367,373 ----
        return MATCH_ERROR;
      }
    else if (sym->attr.flavor == FL_DERIVED)
!     return gfc_match_structure_constructor (sym, result, false);

    /* Check to see if the value is an initialization array expression.  */
    if (sym->value->expr_type == EXPR_ARRAY)
*************** syntax:
*** 6250,6255 ****
--- 6250,6298 ----
  }

+ /* Check a derived type that is being extended.  */
+ static gfc_symbol*
+ check_extended_derived_type (char *name)
+ {
+   gfc_symbol *extended;
+
+   if (gfc_find_symbol (name, gfc_current_ns, 1, &extended))
+     {
+       gfc_error ("Ambiguous symbol in TYPE definition at %C");
+       return NULL;
+     }
+
+   if (!extended)
+     {
+       gfc_error ("No such symbol in TYPE definition at %C");
+       return NULL;
+     }
+
+   if (extended->attr.flavor != FL_DERIVED)
+     {
+       gfc_error ("'%s' in EXTENDS expression at %C is not a "
+   "derived type", name);
+       return NULL;
+     }
+
+   if (extended->attr.is_bind_c)
+     {
+       gfc_error ("'%s' cannot be extended at %C because it "
+   "is BIND(C)", extended->name);
+       return NULL;
+     }
+
+   if (extended->attr.sequence)
+     {
+       gfc_error ("'%s' cannot be extended at %C because it "
+   "is a SEQUENCE type", extended->name);
+       return NULL;
+     }
+
+   return extended;
+ }
+
+
  /* Match the optional attribute specifiers for a type declaration.
     Return MATCH_ERROR if an error is encountered in one of the handled
     attributes (public, private, bind(c)), MATCH_NO if what's found is
*************** syntax:
*** 6257,6263 ****
     checking on attribute conflicts needs to be done.  */

  match
! gfc_get_type_attr_spec (symbol_attribute *attr)
  {
    /* See if the derived type is marked as private.  */
    if (gfc_match (" , private") == MATCH_YES)
--- 6300,6306 ----
     checking on attribute conflicts needs to be done.  */

  match
! gfc_get_type_attr_spec (symbol_attribute *attr, char *name)
  {
    /* See if the derived type is marked as private.  */
    if (gfc_match (" , private") == MATCH_YES)
*************** gfc_get_type_attr_spec (symbol_attribute
*** 6295,6300 ****
--- 6338,6349 ----

        /* TODO: attr conflicts need to be checked, probably in symbol.c.  */
      }
+   else if (name && gfc_match(" , extends ( %n )", name) == MATCH_YES)
+     {
+       if (gfc_notify_std (GFC_STD_F2003, "Fortran 2003: derived type "
+      "extended at %C") == FAILURE)
+  return MATCH_ERROR;
+     }
    else
      return MATCH_NO;

*************** match
*** 6311,6318 ****
--- 6360,6369 ----
  gfc_match_derived_decl (void)
  {
    char name[GFC_MAX_SYMBOL_LEN + 1];
+   char parent[GFC_MAX_SYMBOL_LEN + 1];
    symbol_attribute attr;
    gfc_symbol *sym;
+   gfc_symbol *extended;
    match m;
    match is_type_attr_spec = MATCH_NO;
    bool seen_attr = false;
*************** gfc_match_derived_decl (void)
*** 6320,6336 ****
    if (gfc_current_state () == COMP_DERIVED)
      return MATCH_NO;

    gfc_clear_attr (&attr);

    do
      {
!       is_type_attr_spec = gfc_get_type_attr_spec (&attr);
        if (is_type_attr_spec == MATCH_ERROR)
   return MATCH_ERROR;
        if (is_type_attr_spec == MATCH_YES)
   seen_attr = true;
      } while (is_type_attr_spec == MATCH_YES);

    if (gfc_match (" ::") != MATCH_YES && seen_attr)
      {
        gfc_error ("Expected :: in TYPE definition at %C");
--- 6371,6397 ----
    if (gfc_current_state () == COMP_DERIVED)
      return MATCH_NO;

+   name[0] = '\0';
+   parent[0] = '\0';
    gfc_clear_attr (&attr);
+   extended = NULL;

    do
      {
!       is_type_attr_spec = gfc_get_type_attr_spec (&attr, parent);
        if (is_type_attr_spec == MATCH_ERROR)
   return MATCH_ERROR;
        if (is_type_attr_spec == MATCH_YES)
   seen_attr = true;
      } while (is_type_attr_spec == MATCH_YES);

+   /* Deal with derived type extensions.  */
+   if (parent[0])
+     extended = check_extended_derived_type (parent);
+
+   if (parent[0] && !extended)
+     return MATCH_ERROR;
+
    if (gfc_match (" ::") != MATCH_YES && seen_attr)
      {
        gfc_error ("Expected :: in TYPE definition at %C");
*************** gfc_match_derived_decl (void)
*** 6383,6392 ****
--- 6444,6477 ----
    if (attr.is_bind_c != 0)
      sym->attr.is_bind_c = attr.is_bind_c;

+
    /* Construct the f2k_derived namespace if it is not yet there.  */
    if (!sym->f2k_derived)
      sym->f2k_derived = gfc_get_namespace (NULL, 0);

+
+   if (extended && !sym->components)
+     {
+       gfc_component *p;
+       gfc_symtree *st;
+
+       /* Add the extended derived type as the first component.  */
+       gfc_add_component (sym, parent, &p);
+       sym->attr.extension = 1;
+       extended->refs++;
+       gfc_set_sym_referenced (extended);
+
+       p->ts.type = BT_DERIVED;
+       p->ts.derived = extended;
+       p->initializer = gfc_default_initializer (&p->ts);
+
+       /* Provide the links between the extended type and its extension.  */
+       if (!extended->f2k_derived)
+  extended->f2k_derived = gfc_get_namespace (NULL, 0);
+       st = gfc_new_symtree (&extended->f2k_derived->sym_root, sym->name);
+       st->n.sym = sym;
+     }
+
    gfc_new_block = sym;

    return MATCH_YES;
Index: gcc/fortran/gfortran.h
===================================================================
*** gcc/fortran/gfortran.h (revision 138273)
--- gcc/fortran/gfortran.h (working copy)
*************** typedef struct
*** 638,643 ****
--- 638,644 ----
    unsigned untyped:1;           /* No implicit type could be found.  */

    unsigned is_bind_c:1; /* say if is bound to C */
+   unsigned extension:1; /* extends a derived type */

    /* These flags are both in the typespec and attribute.  The attribute
       list is what gets read from/written to a module file.  The typespec
*************** typedef struct gfc_symbol
*** 1016,1024 ****

    gfc_formal_arglist *formal;
    struct gfc_namespace *formal_ns;
-
-   /* The namespace containing type-associated procedure symbols.  */
-   /* TODO: Make this union with formal?  */
    struct gfc_namespace *f2k_derived;

    struct gfc_expr *value; /* Parameter/Initializer value */
--- 1017,1022 ----
Index: gcc/fortran/ChangeLog
===================================================================
*** gcc/fortran/ChangeLog (revision 138273)
--- gcc/fortran/ChangeLog (working copy)
***************
*** 1,3 ****
--- 1,42 ----
+ 2008-07-29  Paul Thomas  <pault@gcc.gnu.org>
+
+  * trans-expr.c (conv_parent_component_references): New function
+  to build missing parent references.
+  (gfc_conv_variable): Call it
+  * symbol.c (gfc_add_component): Check that component name in a
+  derived type extension does not appear in parent.
+  (gfc_find_component): For a derived type extension, check if
+  the component appears in the parent derived type by calling
+  self. Separate errors for private components and private types.
+  * decl.c (match_data_constant): Add extra arg to call to
+  gfc_match_structure_constructor.
+  (check_extended_derived_type): New function to check that a
+  parent derived type exists and that it is OK for exension.
+  (gfc_get_type_attr_spec): Add extra argument 'name' and return
+  it if extends is specified.
+  (gfc_match_derived_decl): Match derived type extension and
+  build a first component of the parent derived type if OK. Add
+  the f2k namespace if not present.
+  * gfortran.h : Add the extension attribute.
+  * module.c : Handle attribute 'extension'.
+  * match.h : Modify prototypes for gfc_get_type_attr_spec and
+  gfc_match_structure_constructor.
+  * primary.c (build_actual_constructor): New function extracted
+  from gfc_match_structure_constructor and modified to call self
+  iteratively to build derived type extensions, when f2k named
+  components are used.
+  (gfc_match_structure_constructor): Do not throw error for too
+  many components if a parent type is being handled. Use
+  gfc_find_component to generate errors for non-existent or
+  private components.  Iteratively call self for derived type
+  extensions so that parent constructor is built.  If extension
+  and components left over, throw error.
+  (gfc_match_rvalue): Add extra arg to call to
+  gfc_match_structure_constructor.
+
+  * trans-array.c (gfc_conv_resolve_dependencies): If lhs and rhs
+  are the same symbol, aliassing does not matter.
+
  2008-07-29  Jan Hubicka  <jh@suse.cz>

   * options.c (gfc_post_options): Do not set flag_no_inline.
Index: gcc/fortran/module.c
===================================================================
*** gcc/fortran/module.c (revision 138273)
--- gcc/fortran/module.c (working copy)
*************** typedef enum
*** 1648,1654 ****
    AB_ELEMENTAL, AB_PURE, AB_RECURSIVE, AB_GENERIC, AB_ALWAYS_EXPLICIT,
    AB_CRAY_POINTER, AB_CRAY_POINTEE, AB_THREADPRIVATE, AB_ALLOC_COMP,
    AB_POINTER_COMP, AB_PRIVATE_COMP, AB_VALUE, AB_VOLATILE, AB_PROTECTED,
!   AB_IS_BIND_C, AB_IS_C_INTEROP, AB_IS_ISO_C, AB_ABSTRACT, AB_ZERO_COMP
  }
  ab_attribute;

--- 1648,1655 ----
    AB_ELEMENTAL, AB_PURE, AB_RECURSIVE, AB_GENERIC, AB_ALWAYS_EXPLICIT,
    AB_CRAY_POINTER, AB_CRAY_POINTEE, AB_THREADPRIVATE, AB_ALLOC_COMP,
    AB_POINTER_COMP, AB_PRIVATE_COMP, AB_VALUE, AB_VOLATILE, AB_PROTECTED,
!   AB_IS_BIND_C, AB_IS_C_INTEROP, AB_IS_ISO_C, AB_ABSTRACT, AB_ZERO_COMP,
!   AB_EXTENSION
  }
  ab_attribute;

*************** static const mstring attr_bits[] =
*** 1688,1693 ****
--- 1689,1695 ----
      minit ("ZERO_COMP", AB_ZERO_COMP),
      minit ("PROTECTED", AB_PROTECTED),
      minit ("ABSTRACT", AB_ABSTRACT),
+     minit ("EXTENSION", AB_EXTENSION),
      minit (NULL, -1)
  };

*************** mio_symbol_attribute (symbol_attribute *
*** 1801,1806 ****
--- 1803,1810 ----
   MIO_NAME (ab_attribute) (AB_PRIVATE_COMP, attr_bits);
        if (attr->zero_comp)
   MIO_NAME (ab_attribute) (AB_ZERO_COMP, attr_bits);
+       if (attr->extension)
+  MIO_NAME (ab_attribute) (AB_EXTENSION, attr_bits);

        mio_rparen ();

*************** mio_symbol_attribute (symbol_attribute *
*** 1919,1924 ****
--- 1923,1931 ----
       case AB_ZERO_COMP:
         attr->zero_comp = 1;
         break;
+      case AB_EXTENSION:
+        attr->extension = 1;
+        break;
       }
   }
      }
Index: gcc/fortran/trans-io.c
===================================================================
*** gcc/fortran/trans-io.c (revision 138273)
--- gcc/fortran/trans-io.c (working copy)
***************
*** 1,6 ****
  /* IO Code translation/library interface
!    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software
!    Foundation, Inc.
     Contributed by Paul Brook

  This file is part of GCC.
--- 1,6 ----
  /* IO Code translation/library interface
!    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
!    Free Software Foundation, Inc.
     Contributed by Paul Brook

  This file is part of GCC.
Index: gcc/fortran/match.h
===================================================================
*** gcc/fortran/match.h (revision 138273)
--- gcc/fortran/match.h (working copy)
*************** gfc_try get_bind_c_idents (void);
*** 182,191 ****
  match gfc_match_bind_c_stmt (void);
  match gfc_match_suffix (gfc_symbol *, gfc_symbol **);
  match gfc_match_bind_c (gfc_symbol *, bool);
! match gfc_get_type_attr_spec (symbol_attribute *);

  /* primary.c.  */
! match gfc_match_structure_constructor (gfc_symbol *, gfc_expr **);
  match gfc_match_variable (gfc_expr **, int);
  match gfc_match_equiv_variable (gfc_expr **);
  match gfc_match_actual_arglist (int, gfc_actual_arglist **);
--- 182,191 ----
  match gfc_match_bind_c_stmt (void);
  match gfc_match_suffix (gfc_symbol *, gfc_symbol **);
  match gfc_match_bind_c (gfc_symbol *, bool);
! match gfc_get_type_attr_spec (symbol_attribute *, char*);

  /* primary.c.  */
! match gfc_match_structure_constructor (gfc_symbol *, gfc_expr **, bool);
  match gfc_match_variable (gfc_expr **, int);
  match gfc_match_equiv_variable (gfc_expr **);
  match gfc_match_actual_arglist (int, gfc_actual_arglist **);
Index: gcc/fortran/primary.c
===================================================================
*** gcc/fortran/primary.c (revision 138273)
--- gcc/fortran/primary.c (working copy)
*************** gfc_free_structure_ctor_component (gfc_s
*** 1984,1994 ****
    gfc_free_expr (comp->val);
  }

! match
! gfc_match_structure_constructor (gfc_symbol *sym, gfc_expr **result)
  {
-   gfc_structure_ctor_component *comp_head, *comp_tail;
    gfc_structure_ctor_component *comp_iter;
    gfc_constructor *ctor_head, *ctor_tail;
    gfc_component *comp; /* Is set NULL when named component is first seen */
    gfc_expr *e;
--- 1984,2086 ----
    gfc_free_expr (comp->val);
  }

!
! /* Translate the component list into the actual constructor by sorting it in
!    the order required; this also checks along the way that each and every
!    component actually has an initializer and handles default initializers
!    for components without explicit value given.  */
! static gfc_try
! build_actual_constructor (gfc_structure_ctor_component **comp_head,
!    gfc_constructor **ctor_head, gfc_symbol *sym)
  {
    gfc_structure_ctor_component *comp_iter;
+   gfc_constructor *ctor_tail = NULL;
+   gfc_component *comp;
+
+   for (comp = sym->components; comp; comp = comp->next)
+     {
+       gfc_structure_ctor_component **next_ptr;
+       gfc_expr *value = NULL;
+
+       /* Try to find the initializer for the current component by name.  */
+       next_ptr = comp_head;
+       for (comp_iter = *comp_head; comp_iter; comp_iter = comp_iter->next)
+  {
+    if (!strcmp (comp_iter->name, comp->name))
+      break;
+    next_ptr = &comp_iter->next;
+  }
+
+       /* If an extension, try building the parent derived type by building
+   a value expression for the parent derived type and calling self.  */
+       if (!comp_iter && comp == sym->components && sym->attr.extension)
+  {
+    value = gfc_get_expr ();
+    value->expr_type = EXPR_STRUCTURE;
+    value->value.constructor = NULL;
+    value->ts = comp->ts;
+    value->where = gfc_current_locus;
+
+    if (build_actual_constructor (comp_head, &value->value.constructor,
+  comp->ts.derived) == FAILURE)
+      {
+        gfc_free_expr (value);
+        return FAILURE;
+      }
+    *ctor_head = ctor_tail = gfc_get_constructor ();
+    ctor_tail->expr = value;
+    continue;
+  }
+
+       /* If it was not found, try the default initializer if there's any;
+   otherwise, it's an error.  */
+       if (!comp_iter)
+  {
+    if (comp->initializer)
+      {
+        if (gfc_notify_std (GFC_STD_F2003, "Fortran 2003: Structure"
+    " constructor with missing optional arguments"
+    " at %C") == FAILURE)
+  return FAILURE;
+        value = gfc_copy_expr (comp->initializer);
+      }
+    else
+      {
+        gfc_error ("No initializer for component '%s' given in the"
+   " structure constructor at %C!", comp->name);
+        return FAILURE;
+      }
+  }
+       else
+  value = comp_iter->val;
+
+       /* Add the value to the constructor chain built.  */
+       if (ctor_tail)
+  {
+    ctor_tail->next = gfc_get_constructor ();
+    ctor_tail = ctor_tail->next;
+  }
+       else
+  *ctor_head = ctor_tail = gfc_get_constructor ();
+       gcc_assert (value);
+       ctor_tail->expr = value;
+
+       /* Remove the entry from the component list.  We don't want the expression
+   value to be free'd, so set it to NULL.  */
+       if (comp_iter)
+  {
+    *next_ptr = comp_iter->next;
+    comp_iter->val = NULL;
+    gfc_free_structure_ctor_component (comp_iter);
+  }
+     }
+   return SUCCESS;
+ }
+
+ match
+ gfc_match_structure_constructor (gfc_symbol *sym, gfc_expr **result, bool parent)
+ {
+   gfc_structure_ctor_component *comp_tail, *comp_head, *comp_iter;
    gfc_constructor *ctor_head, *ctor_tail;
    gfc_component *comp; /* Is set NULL when named component is first seen */
    gfc_expr *e;
*************** gfc_match_structure_constructor (gfc_sym
*** 1996,2005 ****
    match m;
    const char* last_name = NULL;

!   comp_head = comp_tail = NULL;
    ctor_head = ctor_tail = NULL;

!   if (gfc_match_char ('(') != MATCH_YES)
      goto syntax;

    where = gfc_current_locus;
--- 2088,2097 ----
    match m;
    const char* last_name = NULL;

!   comp_tail = comp_head = NULL;
    ctor_head = ctor_tail = NULL;

!   if (!parent && gfc_match_char ('(') != MATCH_YES)
      goto syntax;

    where = gfc_current_locus;
*************** gfc_match_structure_constructor (gfc_sym
*** 2047,2053 ****
     if (last_name)
       gfc_error ("Component initializer without name after"
          " component named %s at %C!", last_name);
!    else
       gfc_error ("Too many components in structure constructor at"
          " %C!");
     goto cleanup;
--- 2139,2145 ----
     if (last_name)
       gfc_error ("Component initializer without name after"
          " component named %s at %C!", last_name);
!    else if (!parent)
       gfc_error ("Too many components in structure constructor at"
          " %C!");
     goto cleanup;
*************** gfc_match_structure_constructor (gfc_sym
*** 2057,2095 ****
         strncpy (comp_tail->name, comp->name, GFC_MAX_SYMBOL_LEN + 1);
       }

!    /* Find the current component in the structure definition; this is
!       needed to get its access attribute in the private check below.  */
     if (comp)
!      this_comp = comp;
     else
       {
!        for (comp = sym->components; comp; comp = comp->next)
!  if (!strcmp (comp->name, comp_tail->name))
!    {
!      this_comp = comp;
!      break;
!    }
         comp = NULL; /* Reset needed!  */
-
-        /* Here we can check if a component name is given which does not
-   correspond to any component of the defined structure.  */
-        if (!this_comp)
-  {
-    gfc_error ("Component '%s' in structure constructor at %C"
-       " does not correspond to any component in the"
-       " constructed structure!", comp_tail->name);
-    goto cleanup;
-  }
       }
-    gcc_assert (this_comp);

!    /* Check the current component's access status.  */
!    if (sym->attr.use_assoc && this_comp->access == ACCESS_PRIVATE)
!      {
!        gfc_error ("Component '%s' is PRIVATE in structure constructor"
!   " at %C!", comp_tail->name);
!        goto cleanup;
!      }

     /* Check if this component is already given a value.  */
     for (comp_iter = comp_head; comp_iter != comp_tail;
--- 2149,2168 ----
         strncpy (comp_tail->name, comp->name, GFC_MAX_SYMBOL_LEN + 1);
       }

!    /* Find the current component in the structure definition and check its
!       access is not private.  */
     if (comp)
!      this_comp = gfc_find_component (sym, comp->name);
     else
       {
!        this_comp = gfc_find_component (sym, (const char *)comp_tail->name);
         comp = NULL; /* Reset needed!  */
       }

!    /* Here we can check if a component name is given which does not
!       correspond to any component of the defined structure.  */
!    if (!this_comp)
!      goto cleanup;

     /* Check if this component is already given a value.  */
     for (comp_iter = comp_head; comp_iter != comp_tail;
*************** gfc_match_structure_constructor (gfc_sym
*** 2111,2199 ****
     if (m == MATCH_ERROR)
       goto cleanup;

!    if (comp)
       comp = comp->next;
   }
        while (gfc_match_char (',') == MATCH_YES);

!       if (gfc_match_char (')') != MATCH_YES)
   goto syntax;
-
-       /* If there were components given and all components are private, error
-   out at this place.  */
-       if (sym->attr.use_assoc && sym->component_access == ACCESS_PRIVATE)
-  {
-    gfc_error ("All components of '%s' are PRIVATE in structure"
-       " constructor at %C", sym->name);
-    goto cleanup;
-  }
      }

!   /* Translate the component list into the actual constructor by sorting it in
!      the order required; this also checks along the way that each and every
!      component actually has an initializer and handles default initializers
!      for components without explicit value given.  */
!   for (comp = sym->components; comp; comp = comp->next)
!     {
!       gfc_structure_ctor_component **next_ptr;
!       gfc_expr *value = NULL;

!       /* Try to find the initializer for the current component by name.  */
!       next_ptr = &comp_head;
        for (comp_iter = comp_head; comp_iter; comp_iter = comp_iter->next)
   {
!    if (!strcmp (comp_iter->name, comp->name))
!      break;
!    next_ptr = &comp_iter->next;
!  }
!
!       /* If it was not found, try the default initializer if there's any;
!   otherwise, it's an error.  */
!       if (!comp_iter)
!  {
!    if (comp->initializer)
!      {
!        if (gfc_notify_std (GFC_STD_F2003, "Fortran 2003: Structure"
!    " constructor with missing optional arguments"
!    " at %C") == FAILURE)
!  goto cleanup;
!        value = gfc_copy_expr (comp->initializer);
!      }
!    else
!      {
!        gfc_error ("No initializer for component '%s' given in the"
!   " structure constructor at %C!", comp->name);
!        goto cleanup;
!      }
!  }
!       else
!  value = comp_iter->val;
!
!       /* Add the value to the constructor chain built.  */
!       if (ctor_tail)
!  {
!    ctor_tail->next = gfc_get_constructor ();
!    ctor_tail = ctor_tail->next;
!  }
!       else
!  ctor_head = ctor_tail = gfc_get_constructor ();
!       gcc_assert (value);
!       ctor_tail->expr = value;
!
!       /* Remove the entry from the component list.  We don't want the expression
!   value to be free'd, so set it to NULL.  */
!       if (comp_iter)
!  {
!    *next_ptr = comp_iter->next;
!    comp_iter->val = NULL;
!    gfc_free_structure_ctor_component (comp_iter);
   }
      }
!
!   /* No component should be left, as this should have caused an error in the
!      loop constructing the component-list (name that does not correspond to any
!      component in the structure definition).  */
!   gcc_assert (!comp_head);

    e = gfc_get_expr ();

--- 2184,2239 ----
     if (m == MATCH_ERROR)
       goto cleanup;

!    /* If not explicitly a parent constructor, gather up the components
!       and build one.  */
!    if (comp && comp == sym->components
!  && sym->attr.extension
!  && (comp_tail->val->ts.type != BT_DERIVED
!        ||
!      comp_tail->val->ts.derived != this_comp->ts.derived))
!      {
!        gfc_current_locus = where;
!        gfc_free_expr (comp_tail->val);
!
!        m = gfc_match_structure_constructor (comp->ts.derived,
!     &comp_tail->val, true);
!        if (m == MATCH_NO)
!  goto syntax;
!        if (m == MATCH_ERROR)
!  goto cleanup;
!      }
!
!     if (comp)
       comp = comp->next;
+
+    if (parent && !comp)
+      break;
   }
+
        while (gfc_match_char (',') == MATCH_YES);

!       if (!parent && gfc_match_char (')') != MATCH_YES)
   goto syntax;
      }

!   if (build_actual_constructor (&comp_head, &ctor_head, sym) == FAILURE)
!     goto cleanup;

!   /* No component should be left, as this should have caused an error in the
!      loop constructing the component-list (name that does not correspond to any
!      component in the structure definition).  */
!   if (comp_head && sym->attr.extension)
!     {
        for (comp_iter = comp_head; comp_iter; comp_iter = comp_iter->next)
   {
!    gfc_error ("component '%s' at %L has already been set by a "
!       "parent derived type constructor", comp_iter->name,
!       &comp_iter->where);
   }
+       goto cleanup;
      }
!   else
!     gcc_assert (!comp_head);

    e = gfc_get_expr ();

*************** gfc_match_rvalue (gfc_expr **result)
*** 2396,2402 ****
        if (sym == NULL)
   m = MATCH_ERROR;
        else
!  m = gfc_match_structure_constructor (sym, &e);
        break;

      /* If we're here, then the name is known to be the name of a
--- 2436,2442 ----
        if (sym == NULL)
   m = MATCH_ERROR;
        else
!  m = gfc_match_structure_constructor (sym, &e, false);
        break;

      /* If we're here, then the name is known to be the name of a
Index: gcc/testsuite/ChangeLog
===================================================================
*** gcc/testsuite/ChangeLog (revision 138273)
--- gcc/testsuite/ChangeLog (working copy)
***************
*** 1,3 ****
--- 1,15 ----
+ 2008-07-29  Paul Thomas  <pault@gcc.gnu.org>
+
+  * gfortran.dg/extends_1.f03: New test.
+  * gfortran.dg/extends_2.f03: New test.
+  * gfortran.dg/extends_3.f03: New test.
+  * gfortran.dg/extends_4.f03: New test.
+  * gfortran.dg/extends_5.f03: New test.
+  * gfortran.dg/extends_6.f03: New test.
+  * gfortran.dg/private_type_6.f90: Modify error message.
+  * gfortran.dg/structure_constructor_7.f03: Modify error message.
+  * gfortran.dg/structure_constructor_8.f03: Modify error message.
+
  2008-07-29  Richard Guenther  <rguenther@suse.de>

   PR tree-optimization/36945
Index: gcc/testsuite/gfortran.dg/extends_1.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_1.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_1.f03 (revision 0)
***************
*** 0 ****
--- 1,73 ----
+ ! { dg-do run }
+ ! A basic functional test of derived type extension.
+ !
+ ! Contributed by Paul Thomas  <pault@gcc.gnu.org>
+ !
+ module persons
+   type :: person
+     character(24) :: name = ""
+     integer :: ss = 1
+   end type person
+ end module persons
+
+ module person_education
+   use persons
+   type, extends(person) :: education
+     integer ::  attainment = 0
+     character(24) :: institution = ""
+   end type education
+ end module person_education
+
+   use person_education
+   type, extends(education) :: service
+     integer :: personnel_number = 0
+     character(24) :: department = ""
+   end type service
+
+   type, extends(service) :: person_record
+     type (person_record), pointer :: supervisor => NULL ()
+   end type person_record
+
+   type(person_record), pointer :: recruit, supervisor
+
+ ! Check that references by ultimate component work
+
+   allocate (supervisor)
+   supervisor%name = "Joe Honcho"
+   supervisor%ss = 123455
+   supervisor%attainment = 100
+   supervisor%institution = "Celestial University"
+   supervisor%personnel_number = 1
+   supervisor%department = "Directorate"
+
+   recruit => entry ("John Smith", 123456, 1, "Bog Hill High School", &
+                     99, "Records", supervisor)
+
+   if (trim (recruit%name) /= "John Smith") call abort
+   if (recruit%name /= recruit%service%name) call abort
+   if (recruit%supervisor%ss /= 123455) call abort
+   if (recruit%supervisor%ss /= supervisor%person%ss) call abort
+
+   deallocate (supervisor)
+   deallocate (recruit)
+ contains
+   function entry (name, ss, attainment, institution, &
+                   personnel_number, department, supervisor) result (new_person)
+     integer :: ss, attainment, personnel_number
+     character (*) :: name, institution, department
+     type (person_record), pointer :: supervisor, new_person
+
+     allocate (new_person)
+
+ ! Check mixtures of references
+     new_person%person%name = name
+     new_person%service%education%person%ss = ss
+     new_person%service%attainment = attainment
+     new_person%education%institution = institution
+     new_person%personnel_number = personnel_number
+     new_person%service%department = department
+     new_person%supervisor => supervisor
+   end function
+ end
+
+ ! { dg-final { cleanup-modules "persons person_education" } }
Index: gcc/testsuite/gfortran.dg/extends_2.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_2.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_2.f03 (revision 0)
***************
*** 0 ****
--- 1,66 ----
+ ! { dg-do run }
+ ! A test of f95 style constructors with derived type extension.
+ !
+ ! Contributed by Paul Thomas  <pault@gcc.gnu.org>
+ !
+ module persons
+   type :: person
+     character(24) :: name = ""
+     integer :: ss = 1
+   end type person
+ end module persons
+
+ module person_education
+   use persons
+   type, extends(person) :: education
+     integer ::  attainment = 0
+     character(24) :: institution = ""
+   end type education
+ end module person_education
+
+   use person_education
+   type, extends(education) :: service
+     integer :: personnel_number = 0
+     character(24) :: department = ""
+   end type service
+
+   type, extends(service) :: person_record
+     type (person_record), pointer :: supervisor => NULL ()
+   end type person_record
+
+   type(person_record), pointer :: recruit, supervisor
+
+ ! Check that simple constructor works
+   allocate (supervisor)
+   supervisor%service = service ("Joe Honcho", 123455, 100, &
+                                 "Celestial University", 1, &
+                                 "Directorate")
+
+   recruit => entry ("John Smith", 123456, 1, "Bog Hill High School", &
+                     99, "Records", supervisor)
+
+   if (trim (recruit%name) /= "John Smith") call abort
+   if (recruit%name /= recruit%service%name) call abort
+   if (recruit%supervisor%ss /= 123455) call abort
+   if (recruit%supervisor%ss /= supervisor%person%ss) call abort
+
+   deallocate (supervisor)
+   deallocate (recruit)
+ contains
+   function entry (name, ss, attainment, institution, &
+                   personnel_number, department, supervisor) result (new_person)
+     integer :: ss, attainment, personnel_number
+     character (*) :: name, institution, department
+     type (person_record), pointer :: supervisor, new_person
+
+     allocate (new_person)
+
+ ! Check nested constructors
+     new_person = person_record (education (person (name, ss), &
+                                 attainment, institution), &
+                                 personnel_number, department, &
+                                 supervisor)
+   end function
+ end
+
+ ! { dg-final { cleanup-modules "persons person_education" } }
Index: gcc/testsuite/gfortran.dg/extends_3.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_3.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_3.f03 (revision 0)
***************
*** 0 ****
--- 1,71 ----
+ ! { dg-do run }
+ ! A test of f2k style constructors with derived type extension.
+ !
+ ! Contributed by Paul Thomas  <pault@gcc.gnu.org>
+ !
+ module persons
+   type :: person
+     character(24) :: name = ""
+     integer :: ss = 1
+   end type person
+ end module persons
+
+ module person_education
+   use persons
+   type, extends(person) :: education
+     integer ::  attainment = 0
+     character(24) :: institution = ""
+   end type education
+ end module person_education
+
+   use person_education
+   type, extends(education) :: service
+     integer :: personnel_number = 0
+     character(24) :: department = ""
+   end type service
+
+   type, extends(service) :: person_record
+     type (person_record), pointer :: supervisor => NULL ()
+   end type person_record
+
+   type(person_record), pointer :: recruit, supervisor
+
+ ! Check that F2K constructor with missing entries works
+   allocate (supervisor)
+   supervisor%service = service (NAME = "Joe Honcho", SS= 123455)
+
+   recruit => entry ("John Smith", 123456, 1, "Bog Hill High School", &
+                     99, "Records", supervisor)
+
+   if (supervisor%ss /= 123455) call abort
+   if (trim (supervisor%name) /= "Joe Honcho") call abort
+   if (trim (supervisor%institution) /= "") call abort
+   if (supervisor%attainment /= 0) call abort
+
+   if (trim (recruit%name) /= "John Smith") call abort
+   if (recruit%name /= recruit%service%name) call abort
+   if (recruit%supervisor%ss /= 123455) call abort
+   if (recruit%supervisor%ss /= supervisor%person%ss) call abort
+
+   deallocate (supervisor)
+   deallocate (recruit)
+ contains
+   function entry (name, ss, attainment, institution, &
+                   personnel_number, department, supervisor) result (new_person)
+     integer :: ss, attainment, personnel_number
+     character (*) :: name, institution, department
+     type (person_record), pointer :: supervisor, new_person
+
+     allocate (new_person)
+
+ ! Check F2K constructor with order shuffled a bit
+     new_person = person_record (NAME = name, SS =ss, &
+                                 DEPARTMENT = department, &
+                                 INSTITUTION = institution, &
+                                 PERSONNEL_NUMBER = personnel_number, &
+                                 ATTAINMENT = attainment, &
+                                 SUPERVISOR = supervisor)
+   end function
+ end
+
+ ! { dg-final { cleanup-modules "persons person_education" } }
Index: gcc/testsuite/gfortran.dg/extends_4.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_4.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_4.f03 (revision 0)
***************
*** 0 ****
--- 1,52 ----
+ ! { dg-do run }
+ ! Check that derived type extension is compatible with renaming
+ ! the parent type and that allocatable components are OK.  At
+ ! the same time, private type and components are checked.
+ !
+ ! Contributed by Paul Thomas  <pault@gcc.gnu.org>
+ !
+ module mymod
+   type :: a
+     real, allocatable :: x(:)
+     integer, private :: ia = 0
+   end type a
+   type :: b
+     private
+     real, allocatable :: x(:)
+     integer :: i
+   end type b
+ contains
+   function set_b () result (res)
+     type(b) :: res
+     allocate (res%x(2))
+     res%x = [10.0, 20.0]
+     res%i = 1
+   end function
+   subroutine check_b (arg)
+     type(b) :: arg
+     if (any (arg%x /= [10.0, 20.0])) call abort
+     if (arg%i /= 1) call abort
+   end subroutine
+ end module mymod
+
+   use mymod, e => a
+   type, extends(e) :: f
+     integer :: if
+   end type f
+   type, extends(b) :: d
+     integer :: id
+   end type d
+
+   type(f) :: p
+   type(d) :: q
+
+   p = f (x = [1.0, 2.0], if = 3)
+   if (any (p%e%x /= [1.0, 2.0])) call abort
+
+   q%b = set_b ()
+   call check_b (q%b)
+   q = d (b = set_b (), id = 99)
+   call check_b (q%b)
+ end
+
+ ! { dg-final { cleanup-modules "persons person_education" } }
Index: gcc/testsuite/gfortran.dg/extends_5.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_5.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_5.f03 (revision 0)
***************
*** 0 ****
--- 1,27 ----
+ ! { dg-do compile }
+ ! Some errors for derived type extension.
+ !
+ ! Contributed by Paul Thomas  <pault@gcc.gnu.org>
+ !
+ module m
+   use iso_c_binding
+   type :: date
+     sequence
+     integer :: yr, mon
+     integer,public :: day
+   end type
+   type, bind(c) :: dt
+     integer(c_int) :: yr, mon
+     integer(c_int) :: day
+   end type
+ end module m
+
+   use m
+   type, extends(date) :: datetime ! { dg-error "because it is a SEQUENCE type" }
+   end type ! { dg-error "Expecting END PROGRAM" }
+
+   type, extends(dt) :: dt_type ! { dg-error "because it is BIND" }
+   end type ! { dg-error "Expecting END PROGRAM" }
+ end
+
+ ! { dg-final { cleanup-modules "m" } }
Index: gcc/testsuite/gfortran.dg/extends_6.f03
===================================================================
*** gcc/testsuite/gfortran.dg/extends_6.f03 (revision 0)
--- gcc/testsuite/gfortran.dg/extends_6.f03 (revision 0)
***************
*** 0 ****
--- 1,49 ----
+ ! { dg-do compile }
+ ! Some errors pointed out in the development of the patch.
+ !
+ ! Contributed by Tobias Burnus  <burnus@net-b.de>
+ !
+ module m
+   type :: date
+     private
+     integer :: yr, mon
+     integer,public :: day
+   end type
+   type :: dt
+     integer :: yr, mon
+     integer :: day
+   end type
+ end module m
+
+   use m
+   type, extends(date) :: datetime
+     integer :: hr, min, sec
+   end type
+   type(datetime) :: o_dt
+
+   type :: one
+     integer :: i
+   end type one
+
+   type, extends(one) :: two
+     real :: r
+   end type two
+
+   o_dt%day = 5  ! VALID but failed in first version of EXTENDS patch
+   o_dt%yr  = 5  ! { dg-error "All components of 'date' are PRIVATE" }
+
+   t = two(one = one(4), i = 5, r=4.4) ! { dg-error "has already been set" }
+
+   call foo
+ contains
+   subroutine foo
+     use m, date_type => dt
+     type, extends(date_type) :: dt_type
+     end type
+     type (dt_type) :: foo_dt
+     foo_dt%date_type%day = 1
+     foo_dt%dt%day = 1 ! { dg-error "not a member" }
+   end subroutine
+ end
+
+ ! { dg-final { cleanup-modules "m" } }
Index: gcc/testsuite/gfortran.dg/private_type_6.f90
===================================================================
*** gcc/testsuite/gfortran.dg/private_type_6.f90 (revision 138273)
--- gcc/testsuite/gfortran.dg/private_type_6.f90 (working copy)
*************** program foo_test
*** 19,25 ****
    TYPE(footype) :: foo
    TYPE(bartype) :: foo2
    foo  = footype(1) ! { dg-error "All components of 'footype' are PRIVATE" }
!   foo2 = bartype(1,2) ! { dg-error "'dummy2' is PRIVATE" }
    foo2%dummy2 = 5 ! { dg-error "is a PRIVATE component" }
  end program foo_test
  ! { dg-final { cleanup-modules "foomod" } }
--- 19,25 ----
    TYPE(footype) :: foo
    TYPE(bartype) :: foo2
    foo  = footype(1) ! { dg-error "All components of 'footype' are PRIVATE" }
!   foo2 = bartype(1,2) ! { dg-error "is a PRIVATE component" }
    foo2%dummy2 = 5 ! { dg-error "is a PRIVATE component" }
  end program foo_test
  ! { dg-final { cleanup-modules "foomod" } }
Index: gcc/testsuite/gfortran.dg/structure_constructor_7.f03
===================================================================
*** gcc/testsuite/gfortran.dg/structure_constructor_7.f03 (revision 138273)
--- gcc/testsuite/gfortran.dg/structure_constructor_7.f03 (working copy)
*************** PROGRAM test
*** 13,18 ****
    TYPE(basics_t) :: basics

    basics = basics_t (42, 1.5, 1000) ! { dg-error "Too many components" }
!   basics = basics_t (42, xxx = 1000) ! { dg-error "Component 'xxx'" }

  END PROGRAM test
--- 13,18 ----
    TYPE(basics_t) :: basics

    basics = basics_t (42, 1.5, 1000) ! { dg-error "Too many components" }
!   basics = basics_t (42, xxx = 1000) ! { dg-error "is not a member" }

  END PROGRAM test
Index: gcc/testsuite/gfortran.dg/structure_constructor_8.f03
===================================================================
*** gcc/testsuite/gfortran.dg/structure_constructor_8.f03 (revision 138273)
--- gcc/testsuite/gfortran.dg/structure_constructor_8.f03 (working copy)
*************** PROGRAM test
*** 47,54 ****
    struct2 = allpriv_t ()

    ! These should fail
!   struct1 = haspriv_t (1, 2) ! { dg-error "'b' is PRIVATE" }
!   struct1 = haspriv_t (b = 2, a = 1) ! { dg-error "'b' is PRIVATE" }

    ! This should fail as all components are private
    struct2 = allpriv_t (5) ! { dg-error "of 'allpriv_t' are PRIVATE" }
--- 47,54 ----
    struct2 = allpriv_t ()

    ! These should fail
!   struct1 = haspriv_t (1, 2) ! { dg-error "is a PRIVATE component" }
!   struct1 = haspriv_t (b = 2, a = 1) ! { dg-error "is a PRIVATE component" }

    ! This should fail as all components are private
    struct2 = allpriv_t (5) ! { dg-error "of 'allpriv_t' are PRIVATE" }

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138275 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoMoved to gcc-interface directory.
charlet [Tue, 29 Jul 2008 20:43:33 +0000 (20:43 +0000)]
Moved to gcc-interface directory.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138274 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-29 Paolo Carlini <paolo.carlini@oracle.com>
paolo [Tue, 29 Jul 2008 19:34:36 +0000 (19:34 +0000)]
2008-07-29  Paolo Carlini  <paolo.carlini@oracle.com>

* include/debug/set.h: Minor formatting fixes.
* include/debug/multiset.h: Likewise.
* include/debug/safe_association.h: Likewise.
* include/debug/vector: Likewise.
* include/debug/map.h: Likewise.
* include/debug/string: Likewise.
* include/debug/multimap.h: Likewise.
* include/bits/stl_list.h: Likewise.
* include/bits/stl_map.h: Likewise.
* include/bits/stl_set.h: Likewise.
* include/bits/stl_multimap.h: Likewise.
* include/bits/stl_vector.h: Likewise.
* include/bits/stl_multiset.h: Likewise.
* include/bits/stl_bvector.h: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138263 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * trans.c (process_inlined_subprograms): Remove tree_really_inline
charlet [Tue, 29 Jul 2008 18:52:26 +0000 (18:52 +0000)]
* trans.c (process_inlined_subprograms): Remove tree_really_inline
check.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138261 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoMoved to gcc-interface.
charlet [Tue, 29 Jul 2008 18:51:30 +0000 (18:51 +0000)]
Moved to gcc-interface.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138260 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * c-decl.c (merge_decls): Do not handle DECL_INLINE.
hubicka [Tue, 29 Jul 2008 17:10:55 +0000 (17:10 +0000)]
* c-decl.c (merge_decls): Do not handle DECL_INLINE.
(grokdeclarator): Likewise.
* langhooks.c (lhd_warn_unused_global_decl): Use
DECL_DECLARED_INLINE_P.
* print-tree.c (print_node): Remove DECL_INLINE check.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138258 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-29 Richard Guenther <rguenther@suse.de>
rguenth [Tue, 29 Jul 2008 17:09:26 +0000 (17:09 +0000)]
2008-07-29  Richard Guenther  <rguenther@suse.de>

PR tree-optimization/36945
* tree-ssa-sccvn.h (copy_reference_ops_from_ref): Declare.
* tree-ssa-sccvn.c (copy_reference_ops_from_ref): Export.
Record invariant addresses un-decomposed.
(copy_reference_ops_from_call): Record reference call
arguments properly.  Simplify.
* tree-ssa-pre.c (create_component_ref_by_pieces_1): New
helper split out from ...
(create_component_ref_by_pieces): ... here.  Simplify.
Prepare for recursive invocation for call arguments.
(create_expression_by_pieces): Adjust call to
create_component_ref_by_pieces.
(compute_avail): Process operand 2 of reference ops.

* gcc.dg/tree-ssa/ssa-pre-18.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138257 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-29 Richard Guenther <rguenther@suse.de>
rguenth [Tue, 29 Jul 2008 17:07:42 +0000 (17:07 +0000)]
2008-07-29  Richard Guenther  <rguenther@suse.de>

* gimplify.c (gimplify_expr): Clear TREE_SIDE_EFFECTS for
OBJ_TYPE_REF.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138256 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-29 Paolo Carlini <paolo.carlini@oracle.com>
paolo [Tue, 29 Jul 2008 17:06:24 +0000 (17:06 +0000)]
2008-07-29  Paolo Carlini  <paolo.carlini@oracle.com>

* include/std/utility: Include <initializer_list>, per the current WP.

* testsuite/lib/libstdc++.exp (check_v3_target_cstdint): Tweak,
don't use -std=gnu++0x unnecessarily.
* testsuite/18_support/numeric_limits/char16_32_t.cc: Use
dg-require-cstdint.
* testsuite/18_support/headers/cstdint/types_std_c++0x.cc: Likewise.
* testsuite/tr1/8_c_compatibility/cstdint/types_std_tr1.cc: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138255 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * trans.c (process_inlined_subprograms): Remove tree_really_inline
hubicka [Tue, 29 Jul 2008 17:02:45 +0000 (17:02 +0000)]
* trans.c (process_inlined_subprograms): Remove tree_really_inline
check.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138254 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * class.c (build_utf8_ref): Set DECL_SIZE and DECL_SIZE_UNIT
jakub [Tue, 29 Jul 2008 16:31:18 +0000 (16:31 +0000)]
* class.c (build_utf8_ref): Set DECL_SIZE and DECL_SIZE_UNIT
from ctype's sizes.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138252 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * class.c (build_utf8_ref): Pad initializer string to utf8const_type's
jakub [Tue, 29 Jul 2008 16:30:32 +0000 (16:30 +0000)]
* class.c (build_utf8_ref): Pad initializer string to utf8const_type's
alignment.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138251 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago PR c++/36852
jakub [Tue, 29 Jul 2008 16:29:33 +0000 (16:29 +0000)]
PR c++/36852
* tree.c (cplus_array_hash, build_cplus_array_type_1): Hash on
TYPE_UID instead of pointers.

* g++.dg/pch/array-1.C: New test.
* g++.dg/pch/array-1.Hs: New file.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138250 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * c-format.c (check_format_types): Revert unwanted checkin.
jakub [Tue, 29 Jul 2008 16:27:50 +0000 (16:27 +0000)]
* c-format.c (check_format_types): Revert unwanted checkin.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138249 138bc75d-0d04-0410-961f-82ee72b054a4

15 years agoResync.
charlet [Tue, 29 Jul 2008 15:50:16 +0000 (15:50 +0000)]
Resync.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138248 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * gcc-interface: New directory.
charlet [Tue, 29 Jul 2008 15:46:37 +0000 (15:46 +0000)]
* gcc-interface: New directory.

* ada-tree.def, cuintp.c, gigi.h, Makefile.in, targtyps.c, ada.h,
utils.c, ada-tree.h, decl.c, lang.opt, Make-lang.in, trans.c,
config-lang.in, deftarg.c, lang-specs.h, misc.c, utils2.c: Moved
to gcc-interface subdirectory.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138246 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago2008-07-29 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
aaronwl [Tue, 29 Jul 2008 14:10:03 +0000 (14:10 +0000)]
2008-07-29  Aaron W. LaFramboise  <aaronavay62@aaronwl.com>

* Makefile.in (EXTRA_GNATRTL_NONTASKING_OBJS): Remove extra s-win32.o.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138245 138bc75d-0d04-0410-961f-82ee72b054a4

15 years ago * flags.h (flag_really_no_inline): Remove.
hubicka [Tue, 29 Jul 2008 11:00:58 +0000 (11:00 +0000)]
* flags.h (flag_really_no_inline): Remove.
* cgraph.c (cgraph_function_possibly_inlined_p): Simplify.
* toplev.c (flag_really_no_inline): Remove.
* c-cppbuiltin.c (c_cpp_builtins): Use flag_no_inline.
* ipa-inline.c (cgraph_decide_inlining): Do not check flag_no_inline.
(cgraph_decide_inlining_incrementally): Likewise.
(compute_inline_parameters): Likewise.
* opts.c (decode_options): Simplify.
* c-opts.c (c_common_post_options): Do not set flag_no_inline.
* common.opt (finline): Initialize to 1.
* tree-inline.c (inlinable_function_p): Check flag_no_inline.

* lang.c (java_post_options): Remove handling of flag_no_inline.

* misc.c (gnat_post_options): Do not set flag_no_inline.

* options.c (gfc_post_options): Do not set flag_no_inline.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138238 138bc75d-0d04-0410-961f-82ee72b054a4