2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * trans-expr.c (get_tree_for_caf_expr): Fix handling of
        * polymorphic
        and derived-type coarrays.

2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * gfortran.dg/coarray_poly_4.f90: New.
        * gfortran.dg/coarray_poly_5.f90: New.



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209948 138bc75d-0d04-0410-961f-82ee72b054a4
2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * gfortran.h (gfc_init_coarray_decl): Remove.
        * parse.c (translate_all_program_units): Remove call to it.
        (gfc_parse_file): Update call.
        * trans.h (gfor_fndecl_caf_this_image,
        gfor_fndecl_caf_num_images): Add.
        (gfort_gvar_caf_num_images,
        gfort_gvar_caf_this_image): Remove.
        * trans-decl.c (gfor_fndecl_caf_this_image,
        gfor_fndecl_caf_num_images): Add.
        (gfort_gvar_caf_num_images,
        gfort_gvar_caf_this_image): Remove.
        (gfc_build_builtin_function_decls): Init new decl.
        (gfc_init_coarray_dec): Remove.
        (create_main_function): Change calls.
        * trans-intrinsic.c (trans_this_image, trans_image_index,
        conv_intrinsic_cobound): Generate call to new library function
        instead of to a static variable.
        * trans-stmt.c (gfc_trans_sync): Ditto.

2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * gfortran.dg/coarray_lib_this_image_1.f90: New.
        * gfortran.dg/coarray_lib_this_image_2.f90: New.

2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * caf/libcaf.h (_gfortran_caf_this_image,
        * _gfortran_caf_num_images):
        New prototypes.
        (_gfortran_caf_init): Change prototype.
        (mpi_token_t): New typedef.
        (TOKEN): New define.
        * caf/mpi.c (_gfortran_caf_this_image,
        * _gfortran_caf_num_images):
        New functions.
        (_gfortran_caf_init): Update.
        (_gfortran_caf_finalize, _gfortran_caf_register,
        _gfortran_caf_deregister): Use mpi_token_t.
        * caf/single.c (_gfortran_caf_this_image,
        * _gfortran_caf_num_images):
        New functions.
        (_gfortran_caf_init): Update.
        (_gfortran_caf_finalize, _gfortran_caf_register,
        _gfortran_caf_deregister): Use mpi_token_t, simplify.



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209951 138bc75d-0d04-0410-961f-82ee72b054a4
2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * resolve.c (resolve_function): Don't do
        assumed-size check for lcobound/ucobound.
        * trans-types.c (gfc_build_array_type): Only build an array
        descriptor with codimensions for allocatable coarrays.

2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * gfortran.dg/coarray_lib_this_image_2.f90: Update dump.
        * gfortran.dg/coarray_lib_token_4.f90: Ditto.
        * gfortran.dg/coarray/codimension.f90: New.



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209952 138bc75d-0d04-0410-961f-82ee72b054a4
2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * trans-decl.c (create_function_arglist): Add hidden coarray
        * arguments
        also for polymorphic coarrays.
        * trans-expr.c (gfc_conv_procedure_call): Pass hidden coarray
        arguments also for polymorphic coarrays.

2014-04-30  Tobias Burnus  <burnus@net-b.de>

        * gfortran.dg/coarray_poly_7.f90
        * gfortran.dg/coarray_poly_8.f90
        * gfortran.dg/coarray_poly_9.f90



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209953 138bc75d-0d04-0410-961f-82ee72b054a4
2014-04-30  Soundararajan Dhakshinamoorthy  <sounderarajan.d@atmel.com>

	* gcc.c-torture/execute/pr58419.c: Use dummy no-inline function
	instead of getpid.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209957 138bc75d-0d04-0410-961f-82ee72b054a4
	* go.test/go-test.exp (go-gc-tests): For rundir, pass extra files
	in go_compile_args rather than in argument to go-torture-execute.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209959 138bc75d-0d04-0410-961f-82ee72b054a4
compiler: Use backend interface for error detection.
Merge branch 'master' into saw_errors
Fix Make-lang rule for gogo-tree.cc.
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209966 138bc75d-0d04-0410-961f-82ee72b054a4
runtime: ask $GOC rather than $CC for the version and multi-os-directory

The Go compiler may have different values for these than the C compiler.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209967 138bc75d-0d04-0410-961f-82ee72b054a4
https://codereview.appspot.com/97870043/#msg4
	* go-backend.c: #include "diagnostics.h".
	(saw_errors): New function.
	* go-c.h (saw_errors): Declare.
	* Make-lang.in (GO_OBJS): Remove go/gogo-tree.o.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209968 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/56989
	* c-typeck.c (default_conversion): Use better location for
	error call.

	* gcc.dg/pr56989.c: New test.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209969 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/43245
	* doc/invoke.texi: Document -Wdiscarded-qualifiers.
c-family/
	* c.opt (Wdiscarded-qualifiers): Add.
c/
	* c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers
	instead of 0 to WARN_FOR_QUALIFIERS.
testsuite/
	* gcc.dg/pr43245.c: New test.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209970 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/29467
	* c-decl.c (declspecs_add_type): Pedwarn if boolean types are used
	in C89 mode.

	* gcc.dg/pr29467.c: New test.
	* gcc.dg/declspec-13.c: Renumber some dg-warnings.  Add dg-warnings
	about boolean types.
	* gfortran.dg/bind_c_usage_24_c.c: Include <stdbool.h>.  Change _Bool
	to bool.
	* gfortran.dg/c_f_pointer_logical_driver.c: Change _Bool to bool.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209971 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/
	* tree-if-conv.c (is_cond_scalar_reduction): New function.
	(convert_scalar_cond_reduction): Likewise.
	(predicate_scalar_phi): Add recognition and transformation
	of simple conditioanl reduction to be vectorizable.

gcc/testsuite/
	* gcc.dg/cond-reduc-1.c: New test.
	* gcc.dg/cond-reduc-2.c: Likewise.



git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209972 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/43395
c/
	* c-typeck.c (c_finish_return): Distinguish between label and variable
	when warning about returning local address.
cp/
	* typeck.c (maybe_warn_about_returning_address_of_local): Distinguish
	between label and variable when warning about returning local address.
testsuite/
	* c-c++-common/pr43395.c: New test.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209973 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/60257
	* c-typeck.c (warning_init): Add location_t parameter.  Call
	warning_at instead of warning.
	(push_init_level): Pass input_location to warning_init.
	(add_pending_init): Add location_t parameter.  Pass loc to
	warning_init.
	(set_nonincremental_init): Pass input_location to add_pending_init.
	(set_nonincremental_init_from_string): Likewise.
	(output_init_element): Pass loc to warning_init and to
	add_pending_init.

	* gcc.dg/pr60257.c: New test.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@209974 138bc75d-0d04-0410-961f-82ee72b054a4
	PR c/60915
	* c-parser.c (c_parser_declaration_or_fndef): Give better error if
	function-definition has an attribute after the declarator.

	* gcc.dg/pr60915.c: New test.


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