Go to file
Eric Botcazou a517d6c19a [Ada] AI12-0001: Independence and Representation clauses for atomic objects
2019-12-16  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

	* gcc-interface/decl.c (gnat_to_gnu_entity): Adjust calls to
	validate_size.
	(gnat_to_gnu_component_type): Likewise.
	(gnat_to_gnu_field): Likewise and pass string for error messages.
	(components_need_strict_alignment): Remove test on Is_Aliased and
	add test for the independence of the component.
	(validate_size): Add S1 and S2 string parameters and use them to
	give better error messages for fields.  Tweak a couple of messages.
	* einfo.ads (Has_Independent_Components): Document more cases.
	(Is_Independent): Likewise.
	(Strict_Alignment): Document new semantics.
	* exp_ch9.adb (Install_Private_Data_Declarations): Also set the
	Is_Independent flag along with Is_Aliased on the renaming
	entity.
	* freeze.adb (Size_Known): Remove always-false test and add test
	for the strict-alignment on the record type.  Remove redundant
	tests and add test for the strict-alignment on the component
	type.
	(Check_Strict_Alignment): Set the flag if the type is by-ref and
	remove now redundant conditions.  Set the flag on an array type
	if it has aliased components.  In the record type case, do not
	set type for C_Pass_By_Copy convention.
	(Freeze_Array_Type): Move code checking for conflicts between
	representation aspects and clauses to before specific handling
	of packed array types. Give a warnind instead of an error for a
	conflict with pragma Pack.  Do not test Has_Pragma_Pack for the
	specific handling of packed array types.
	(Freeze_Record_Type): Move error checking of representation
	clause to...
	(Freeze_Entity): ...here after Check_Strict_Alignment is called.
	* sem_aggr.adb (Array_Aggr_Subtype): Also set the Is_Independent
	flag along with Is_Aliased on the Itype.
	* sem_ch13.adb (Check_Record_Representation_Clause): Do not set
	the RM size for a strict-alignment type.
	* sem_ch3.adb (Add_Interface_Tag_Components): Also set the
	Is_Independent flag along with Is_Aliased on the tag.
	(Add_Interface_Tag_Components): Likewise on the offset.
	(Analyze_Component_Declaration): Likewise on the component.
	(Analyze_Object_Declaration): Likewise on the object.
	(Constrain_Array): Likewise on the array.
	(Record_Type_Declaration: Likewise on the tag.
	(Array_Type_Declaration): Also set the
	Has_Independent_Components flag along with
	Has_Aliased_Components on the array.
	(Copy_Array_Base_Type_Attributes): Copy
	Has_Independent_Components.
	(Copy_Array_Subtype_Attributes): Copy Is_Atomic, Is_Independent
	and Is_Volatile_Full_Access.
	(Analyze_Iterator_Specification): Set Is_Independent on the loop
	variable according to Independent_Components on the array.
	* sem_ch5.adb: Likewise.
	* sem_ch6.adb (Process_Formals): Also set the Is_Independent
	flag along with Is_Aliased on the formal.

gcc/testsuite/

	* gnat.dg/specs/clause_on_volatile.ads,
	gnat.dg/specs/size_clause3.ads: Update expected diagnostics.

From-SVN: r279430
2019-12-16 10:34:33 +00:00
config
contrib Byte vs column awareness for diagnostic-show-locus.c (PR 49973) 2019-12-09 20:03:47 +00:00
fixincludes
gcc [Ada] AI12-0001: Independence and Representation clauses for atomic objects 2019-12-16 10:34:33 +00:00
gnattools
gotools
include [PATCH] Fix slowness in demangler 2019-11-16 10:14:14 -07:00
INSTALL
intl
libada
libatomic
libbacktrace libbacktrace: add DWARF 5 support 2019-12-13 20:04:47 +00:00
libcc1 typeck.c (check_for_casting_away_constness): Add location_t parameter and use it. 2019-12-09 20:28:39 +00:00
libcpp re PR preprocessor/92919 (invalid memory access in wide_str_to_charconst when running ucn2.C testcase (caught by hwasan)) 2019-12-14 23:18:53 +01:00
libdecnumber Fix libdecnumber handling of non-canonical BID significands (PR middle-end/91226). 2019-12-09 13:59:24 +00:00
libffi
libgcc MSP430: Add -fno-exceptions multilib 2019-12-11 19:19:50 +00:00
libgfortran re PR libfortran/90374 (Fortran 2018: Support d0.d, e0.d, es0.d, en0.d, g0.d and ew.d e0 edit descriptors for output) 2019-12-01 22:29:43 +00:00
libgo re PR go/92861 (Passes relative time to sem_timedwait on GNU/Hurd) 2019-12-09 18:03:53 +00:00
libgomp Fix potential race condition in OpenACC "exit data" operations 2019-12-13 23:14:15 +00:00
libhsail-rt
libiberty Fix read buffer overflow in split_directories 2019-12-06 15:20:06 -07:00
libitm musl: Fix invalid tls model in libgomp and libitm PR91938 2019-12-03 11:13:38 +00:00
libobjc Unbreak objc build – with --enable-maintainer-mode 2019-11-26 21:16:30 +01:00
liboffloadmic
libphobos
libquadmath
libsanitizer re PR sanitizer/92154 (new glibc breaks arm bootstrap due to libsanitizer) 2019-11-26 10:08:31 +01:00
libssp
libstdc++-v3 libstdc++: Simplify std::common_comparison_category 2019-12-12 14:35:55 +00:00
libvtv
lto-plugin
maintainer-scripts Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
zlib
.dir-locals.el
.gitattributes
.gitignore
ABOUT-NLS
ar-lib
ChangeLog configure.ac: Factor out common cases for compare_exclusions. 2019-12-11 20:59:35 +00:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in MSP430: Add -fno-exceptions multilib 2019-12-11 19:19:50 +00:00
config.guess
config.rpath
config.sub
configure configure.ac: Factor out common cases for compare_exclusions. 2019-12-11 20:59:35 +00:00
configure.ac configure.ac: Factor out common cases for compare_exclusions. 2019-12-11 20:59:35 +00:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.RUNTIME
depcomp
install-sh
libtool-ldflags
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS Add myself to MAINTAINERS file. 2019-12-10 14:21:22 +00:00
Makefile.def
Makefile.in
Makefile.tpl
missing
mkdep
mkinstalldirs
move-if-change
multilib.am
README
symlink-tree
test-driver
ylwrap

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.