gcc/libgfortran/intrinsics
Paul Thomas 7fb43006b2 re PR fortran/37577 ([meta-bug] change internal array descriptor format for better syntax, C interop TR, rank 15)
2018-25-01  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/37577
	* array.c (gfc_match_array_ref): If standard earlier than F2008
	it is an error if the reference dimension is greater than 7.
	libgfortran.h : Increase GFC_MAX_DIMENSIONS to 15. Change the
	dtype masks and shifts accordingly.
	* trans-array.c (gfc_conv_descriptor_dtype): Use the dtype
	type node to check the field.
	(gfc_conv_descriptor_dtype): Access the rank field of dtype.
	(duplicate_allocatable_coarray): Access the rank field of the
	dtype descriptor rather than the dtype itself.
	* trans-expr.c (get_scalar_to_descriptor_type): Store the type
	of 'scalar' on entry and use its TREE_TYPE if it is ARRAY_TYPE
	(ie. a character).
	(gfc_conv_procedure_call): Pass TREE_OPERAND (tmp,0) to
	get_scalar_to_descriptor_type if the actual expression is a
	constant.
	(gfc_trans_structure_assign): Assign the rank directly to the
	dtype rank field.
	* trans-intrinsic.c (gfc_conv_intrinsic_rank): Cast the result
	to default integer kind.
	(gfc_conv_intrinsic_sizeof): Obtain the element size from the
	'elem_len' field of the dtype.
	* trans-io.c (gfc_build_io_library_fndecls): Replace
	gfc_int4_type_node with dtype_type_node where necessary.
	(transfer_namelist_element): Use gfc_get_dtype_rank_type for
	scalars.
	* trans-types.c : Provide 'get_dtype_type_node' to acces the
	dtype_type_node and, if necessary, build it.
	The maximum size of an array element is now determined by the
	maximum value of size_t.
	Update the description of the array descriptor, including the
	type def for the dtype_type.
	(gfc_get_dtype_rank_type): Build a constructor for the dtype.
	Distinguish RECORD_TYPEs that are BT_DERIVED or BT_CLASS.
	(gfc_get_array_descriptor_base): Change the type of the dtype
	field to dtype_type_node.
	(gfc_get_array_descr_info): Get the offset to the rank field of
	the dtype.
	* trans-types.h : Add a prototype for 'get_dtype_type_node ()'.
	* trans.h : Define the indices of the dtype fields.

2018-25-01  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/37577
	* gfortran.dg/coarray_18.f90: Allow dimension 15 for F2008.
	* gfortran.dg/coarray_lib_this_image_2.f90: Change 'array1' to
	'array01' in the tree dump comparison.
	* gfortran.dg/coarray_lib_token_4.f90: Likewise.
	* gfortran.dg/inline_sum_1.f90: Similar - allow two digits.
	* gfortran.dg/rank_1.f90: Allow dimension 15 for F2008.

2018-25-01  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/37577
	* caf/single.c (_gfortran_caf_failed_images): Access the 'type'
	and 'elem_len' fields of the dtype instead of the shifts.
	(_gfortran_caf_stopped_images): Likewise.
	* intrinsics/associated.c (associated): Compare the 'type' and
	'elem_len' fields instead of the dtype.
	* caf/date_and_time.c : Access the dtype fields rather using
	shifts and masks.
	* io/transfer.c (transfer_array ): Comment on item count.
	(set_nml_var,st_set_nml_var): Change dtype type and use fields.
	(st_set_nml_dtio_var): Likewise.
	* libgfortran.h : Change definition of GFC_ARRAY_DESCRIPTOR and
	add a typedef for the dtype_type. Change the GFC_DTYPE_* macros
	to access the dtype fields.

From-SVN: r257065
2018-01-25 19:09:40 +00:00
..
abort.c Update copyright years. 2018-01-03 11:03:58 +01:00
access.c Update copyright years. 2018-01-03 11:03:58 +01:00
args.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
associated.c re PR fortran/37577 ([meta-bug] change internal array descriptor format for better syntax, C interop TR, rank 15) 2018-01-25 19:09:40 +00:00
c99_functions.c Update copyright years. 2018-01-03 11:03:58 +01:00
chdir.c Update copyright years. 2018-01-03 11:03:58 +01:00
chmod.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
clock.c Update copyright years. 2018-01-03 11:03:58 +01:00
cpu_time.c Update copyright years. 2018-01-03 11:03:58 +01:00
cshift0.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
ctime.c Update copyright years. 2018-01-03 11:03:58 +01:00
date_and_time.c re PR fortran/37577 ([meta-bug] change internal array descriptor format for better syntax, C interop TR, rank 15) 2018-01-25 19:09:40 +00:00
dprod_r8.f90 Update copyright years. 2018-01-03 11:03:58 +01:00
dtime.c Update copyright years. 2018-01-03 11:03:58 +01:00
env.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
eoshift0.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
eoshift2.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
erfc_scaled_inc.c Update copyright years. 2018-01-03 11:03:58 +01:00
erfc_scaled.c Update copyright years. 2018-01-03 11:03:58 +01:00
etime.c Update copyright years. 2018-01-03 11:03:58 +01:00
execute_command_line.c Update copyright years. 2018-01-03 11:03:58 +01:00
exit.c Update copyright years. 2018-01-03 11:03:58 +01:00
extends_type_of.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
f2c_specifics.F90 Update copyright years. 2018-01-03 11:03:58 +01:00
fnum.c Update copyright years. 2018-01-03 11:03:58 +01:00
gerror.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
getcwd.c Update copyright years. 2018-01-03 11:03:58 +01:00
getlog.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
getXid.c Update copyright years. 2018-01-03 11:03:58 +01:00
hostnm.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
ierrno.c Update copyright years. 2018-01-03 11:03:58 +01:00
ishftc.c Update copyright years. 2018-01-03 11:03:58 +01:00
kill.c Update copyright years. 2018-01-03 11:03:58 +01:00
link.c Update copyright years. 2018-01-03 11:03:58 +01:00
move_alloc.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
mvbits.c Update copyright years. 2018-01-03 11:03:58 +01:00
pack_generic.c Update copyright years. 2018-01-03 11:03:58 +01:00
perror.c Update copyright years. 2018-01-03 11:03:58 +01:00
rand.c Update copyright years. 2018-01-03 11:03:58 +01:00
random.c Update copyright years. 2018-01-03 11:03:58 +01:00
rename.c Update copyright years. 2018-01-03 11:03:58 +01:00
reshape_generic.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
reshape_packed.c Update copyright years. 2018-01-03 11:03:58 +01:00
selected_char_kind.c Update copyright years. 2018-01-03 11:03:58 +01:00
selected_int_kind.f90 Update copyright years. 2018-01-03 11:03:58 +01:00
selected_real_kind.f90 Update copyright years. 2018-01-03 11:03:58 +01:00
signal.c Update copyright years. 2018-01-03 11:03:58 +01:00
size.c Update copyright years. 2018-01-03 11:03:58 +01:00
sleep.c Update copyright years. 2018-01-03 11:03:58 +01:00
spread_generic.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00
stat.c Update copyright years. 2018-01-03 11:03:58 +01:00
string_intrinsics_inc.c PR 78534 Change character length from int to size_t 2018-01-05 21:01:12 +02:00
string_intrinsics.c Update copyright years. 2018-01-03 11:03:58 +01:00
symlnk.c Update copyright years. 2018-01-03 11:03:58 +01:00
system_clock.c Update copyright years. 2018-01-03 11:03:58 +01:00
system.c Update copyright years. 2018-01-03 11:03:58 +01:00
time_1.h Update copyright years. 2018-01-03 11:03:58 +01:00
time.c Update copyright years. 2018-01-03 11:03:58 +01:00
umask.c Update copyright years. 2018-01-03 11:03:58 +01:00
unlink.c Update copyright years. 2018-01-03 11:03:58 +01:00
unpack_generic.c libgfortran.h (GFC_DTYPE_COPY): New macro. 2018-01-07 14:11:11 +00:00