Commit Graph

176948 Commits

Author SHA1 Message Date
Gary Dismukes 6618a9b67c [Ada] Two typo fixes
2020-06-02  Gary Dismukes  <dismukes@adacore.com>

gcc/ada/

	* sem_ch3.adb: Two typo fixes.
2020-06-02 04:58:08 -04:00
Eric Botcazou 663091bc78 [Ada] Fix small oversight in latest change for Replace_Discriminants
2020-06-02  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

	* sem_ch3.adb (Replace_Discriminants): Preserve the Etype of the
	Name of N_Variant_Part nodes when rewriting it.
2020-06-02 04:58:07 -04:00
Eric Botcazou 25d744bb6c [Ada] Do not set the bounds of integer types to be universal
2020-06-02  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

	* sem_ch3.adb (Signed_Integer_Type_Declaration): Change the type
	of the bounds from Universal_Integer to Implicit_Base.
2020-06-02 04:58:06 -04:00
Arnaud Charlet a6b13d324f [Ada] Address potentially uninitialized variables and dead code
2020-06-02  Arnaud Charlet  <charlet@adacore.com>

gcc/ada/

	* bcheck.adb, binde.adb, bindo-diagnostics.adb, checks.adb,
	exp_aggr.adb, exp_ch3.adb, exp_ch4.adb, exp_ch7.adb,
	exp_ch9.adb, gnatname.adb, sem_case.adb, sem_ch13.adb,
	sem_ch5.adb, sem_prag.adb, sem_util.adb, uintp.adb, urealp.adb,
	xoscons.adb, xr_tabls.adb, xref_lib.adb: Initialize objects more
	explicitly and add corresponding assertions. Remove dead code.
	Also add a few Annotate pragmas to help static analysis.
	* libgnat/a-caldel.adb, libgnat/a-calend.adb,
	libgnat/a-ngcoty.adb, libgnat/a-ngelfu.adb,
	libgnat/a-ngrear.adb, libgnat/a-strfix.adb,
	libgnat/g-calend.adb, libgnat/g-catiio.adb,
	libgnat/g-comlin.adb, libgnat/g-debpoo.adb,
	libgnat/g-dirope.adb, libgnat/g-hesorg.adb,
	libgnat/g-pehage.adb, libgnat/g-socket.adb, libgnat/i-cobol.adb,
	libgnat/s-dwalin.adb, libgnat/s-dwalin.ads,
	libgnat/s-fatgen.adb, libgnat/s-gearop.adb,
	libgnat/s-genbig.adb, libgnat/s-imgrea.adb,
	libgnat/s-os_lib.adb, libgnat/s-rannum.adb,
	libgnat/s-regpat.adb, libgnat/s-trasym__dwarf.adb,
	libgnat/s-valrea.adb: Ditto.
2020-06-02 04:58:05 -04:00
Eric Botcazou 5c726f3e42 [Ada] Fix bogus error for clause on derived type with variant part
2020-06-02  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

	* sem_ch3.adb (Replace_Components): Rename into...
	(Replace_Discriminants): ...this.  Replace girder discriminants
	with non-girder ones.  Do not replace components.
	* sem_ch13.adb (Check_Record_Representation_Clause): Deal with
	non-girder discriminants correctly.
2020-06-02 04:58:04 -04:00
Piotr Trojanek e386872e9c [Ada] Use new API when creating a special SPARK heap entity
2020-06-02  Piotr Trojanek  <trojanek@adacore.com>

gcc/ada/

	* lib-xref-spark_specific.adb (Create_Heap): use a new variant
	of Name_Enter to directly converts String to Make_Id.
2020-06-02 04:58:03 -04:00
Gary Dismukes dab8e60838 [Ada] Typo corrections and minor reformatting
2020-06-02  Gary Dismukes  <dismukes@adacore.com>

gcc/ada/

	* exp_attr.adb, par-ch4.adb, par-util.adb, scans.ads, scng.adb,
	sem_attr.adb, sem_ch4.adb, sinfo.ads: Typo corrections and minor
	reformatting.
2020-06-02 04:58:03 -04:00
Arnaud Charlet fb3fc196ad [Ada] Treat attribute Img equivalent to attribute Image
2020-06-02  Arnaud Charlet  <charlet@adacore.com>

gcc/ada/

	* snames.ads-tmpl (Name_Img, Attribute_Img): Make it an
	attribute returning renamable functions.
2020-06-02 04:58:02 -04:00
Yannick Moy 0b8eceff72 [Ada] Allow GNATprove to set overflow mode
2020-06-02  Yannick Moy  <moy@adacore.com>

gcc/ada/

	* sem_prag.adb, sem_prag.ads (Set_Overflow_Mode): New procedure
	to set overflow mode.
2020-06-02 04:58:01 -04:00
Piotr Trojanek a92db26245 [Ada] Reuse Is_Package_Or_Generic_Package where possible
2020-06-02  Piotr Trojanek  <trojanek@adacore.com>

gcc/ada/

	* contracts.adb, einfo.adb, exp_ch9.adb, sem_ch12.adb,
	sem_ch4.adb, sem_ch7.adb, sem_ch8.adb, sem_elab.adb,
	sem_type.adb, sem_util.adb: Reuse Is_Package_Or_Generic_Package
	where possible (similarly, reuse Is_Concurrent_Type if it was
	possible in the same expressions).
2020-06-02 04:58:00 -04:00
Iain Buclaw 86b14bb1a9 Fix unrecognised -mcpu target 'armv7-a' on arm-wrs-vxworks7
In the removal of arm-wrs-vxworks, the default cpu was updated from arm8
to armv7-a, but this is not recognized as a valid -mcpu target.  There
is however generic-armv7-a, which was likely the intended cpu that
should have been used instead.

gcc/ChangeLog:

	PR target/95420
	* config.gcc (arm-wrs-vxworks7*): Set default cpu to generic-armv7-a.
2020-06-02 10:36:52 +02:00
Iain Buclaw 70f6320462 d: Fix segfault in build_frontend_type on alpha-*-*
The va_list type for Alpha includes a nameless dummy field for alignment
purposes.  To transpose this into D, a field named "__pad%d" is inserted
into the struct definition.

It was also noticed that in the D front-end AST copy of the backend
type, all offsets for fields generated by build_frontend_type were set
to zero due to a wrong assumption that DECL_FIELD_OFFSET would have a
non-zero value.  This has been fixed to use byte_position instead.

gcc/d/ChangeLog:

	* d-builtins.cc (build_frontend_type): Handle struct fields with NULL
	DECL_NAME.  Use byte_position to get the real field offset.
2020-06-02 09:33:51 +02:00
Jonathan Wakely 9a8bac4d7e
contrib: Improve comments and error text
* gcc-changelog/git_commit.py (GitCommit.check_mentioned_files):
	Improve error text.
2020-06-02 08:38:31 +02:00
Martin Liska e8546a6593
Update link to LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update hash of local patches.
2020-06-02 08:03:48 +02:00
Martin Liska f18ab18032
Reapply all revisions mentioned in LOCAL_PATCHES.
(cherry picked from commit 21bb1625bd)
2020-06-02 08:02:15 +02:00
Martin Liska 3c6331c29f
Libsanitizer: merge from master.
Merged from revision b638b63b99d66786cb37336292604a2ae3490cfd.

The patch successfully bootstraps on x86_64-linux-gnu and
ppc64le-linux-gnu. I also tested ppc64-linux-gnu that exposed:
https://reviews.llvm.org/D80864 (which is fixed on master).

Abidiff looks happy and I made UBSAN and ASAN bootstrap on
x86_64-linux-gnu.

I'm planning to do merge from master twice a year, once now and
next time short before stage1 closes.

I am going to install the patches as merge from master is obvious
and I haven't made anything special.

libsanitizer/ChangeLog:

	* MERGE: Merge from master.
2020-06-02 08:02:07 +02:00
Kito Cheng 2b11374cb8 testsuite: Disable colorization for ubsan test
- Run gcc testsuite with qemu will print out ascii color code for
   ubsan related testcase, however several testcase didn't consider
   that, so disable colorization prevent such problem and simplify the
   process when adding testcase in future.

 - Verified on native X86 and RISC-V qemu full system mode and user mode.

gcc/testsuite/ChangeLog:

	* lib/ubsan-dg.exp (orig_ubsan_options_saved): New
	(orig_ubsan_options): Ditto.
	(ubsan_init): Store UBSAN_OPTIONS and set UBSAN_OPTIONS.
	(ubsan_finish): Restore UBSAN_OPTIONS.
2020-06-02 10:25:42 +08:00
Patrick Palka c2449995ca c++: constrained lambda inside template [PR92633]
When regenerating a constrained lambda during instantiation of an
enclosing template, we are forgetting to substitute into the lambda's
constraints.  Fix this by substituting through the constraints during
tsubst_lambda_expr.

gcc/cp/ChangeLog:

	PR c++/92633
	PR c++/92838
	* pt.c (tsubst_function_decl): Don't do set_constraints when
	regenerating a lambda.
	(tsubst_lambda_expr): Substitute into the lambda's constraints
	and do set_constraints here.

gcc/testsuite/ChangeLog:

	PR c++/92633
	PR c++/92838
	* g++.dg/cpp2a/concepts-lambda11.C: New test.
	* g++.dg/cpp2a/concepts-lambda12.C: New test.
2020-06-01 21:37:04 -04:00
GCC Administrator 4a9aa9dec7 Daily bump. 2020-06-02 00:16:25 +00:00
Jonathan Wakely cd3f067b82 libstdc++: Fix filesystem::u8path for mingw targets (PR 95392)
When I refactored filesystem::path string conversions in
r11-587-584d52b088f9fcf78704b504c3f1f07e17c1cded I failed to update the
mingw-specific code in filesystem::u8path, causing a bootstrap failure.

This fixes it, and further refactors the mingw-specific code along the
same lines as the previous commit. All conversions from UTF-8 strings to
wide strings now use the same helper function, __wstr_from_utf8.

	PR libstdc++/95392
	* include/bits/fs_path.h (path::_S_to_string): Move to
	namespace-scope and rename to ...
	(__detail::__string_from_range): ... this.
	[WINDOWS] (__detail::__wstr_from_utf8): New function template to
	convert a char sequence containing UTF-8 to wstring.
	(path::_S_convert(Iter, Iter)): Adjust call to _S_to_string.
	(path::_S_convert_loc(Iter, Iter, const locale&)): Likewise.
	(u8path(InputIterator, InputIterator)) [WINDOWS]: Use
	__string_from_range to obtain a contiguous range and
	__wstr_from_utf8 to obtain a wide string.
	(u8path(const Source&)) [WINDOWS]: Use __effective_range to
	obtain a contiguous range and __wstr_from_utf8 to obtain a wide
	string.
	(path::_S_convert(const _EcharT*, const _EcharT)) [WINDOWS]:
	Use __wstr_from_utf8.
2020-06-02 00:07:05 +01:00
Jeff Law c7969df1c5 Fix 92085-2.c ICE due to having (const_int 0) as the destination of a set.
gcc/
	* lower-subreg.c (resolve_simple_move): If simplify_gen_subreg_concatn
	returns (const_int 0) for the destination, then emit nothing.
2020-06-01 17:18:03 -04:00
Jason Merrill 172f2c42a1 c++: vptr ubsan and object of known type [PR95466]
Another case where we can't find the OBJ_TYPE_REF_OBJECT in the
OBJ_TYPE_REF_EXPR.  So let's just evaluate the sanitize call first.

gcc/cp/ChangeLog:

	PR c++/95466
	PR c++/95311
	PR c++/95221
	* class.c (build_vfn_ref): Revert 95311 change.
	* cp-ubsan.c (cp_ubsan_maybe_instrument_member_call): Build a
	COMPOUND_EXPR.

gcc/testsuite/ChangeLog:

	PR c++/95466
	* g++.dg/ubsan/vptr-17.C: New test.
2020-06-01 16:52:47 -04:00
Uros Bizjak 832c1192eb i386: Add __attribute__ ((gcc_struct)) to struct fenv [PR95418]
Windows ABI (MinGW) is different than Linux ABI when bitfileds are involved.
The following patch adds __attribute__ ((gcc_struct)) to struct fenv in order
to match the layout of x87 state image in memory.

2020-06-01  Uroš Bizjak  <ubizjak@gmail.com>

libatomic/ChangeLog:
	* config/x86/fenv.c (struct fenv): Add __attribute__ ((gcc_struct)).

libgcc/ChangeLog:
	* config/i386/sfp-exceptions.c (struct fenv):
	Add __attribute__ ((gcc_struct)).

libgfortran/ChangeLog:
	PR libfortran/95418
	* config/fpu-387.h (struct fenv): Add __attribute__ ((gcc_struct)).
2020-06-01 22:29:20 +02:00
Iain Sandoe 88f48e2967 coroutines: Correct handling of references in parm copies [PR95350].
Adjust to handle rvalue refs the same way as clang, and to correct
the handling of moves when a copy CTOR is present.  This is one area
where we could make things easier for the end-user (as was implemented
before this change), however there needs to be agreement about when the
full statement containing a coroutine call ends (i.e. when the ramp
terminates or when the coroutine terminates).

gcc/cp/ChangeLog:

	PR c++/95350
	* coroutines.cc (struct param_info): Remove rv_ref field.
	(build_actor_fn): Remove specifial rvalue ref handling.
	(morph_fn_to_coro): Likewise.

gcc/testsuite/ChangeLog:

	PR c++/95350
	* g++.dg/coroutines/torture/func-params-08.C: Adjust test to
	reflect that all rvalue refs are dangling.
	* g++.dg/coroutines/torture/func-params-09-awaitable-parms.C:
	Likewise.
	* g++.dg/coroutines/pr95350.C: New test.
2020-06-01 19:44:22 +01:00
Jonathan Wakely 118158b646 libstdc++: Fix __gnu_test::input_iterator_wrapper::operator++(int)
I noticed recently that our input_iterator_wrapper utility for writing
tests has the following post-increment operator:

    void
    operator++(int)
    {
      ++*this;
    }

That fails to meet the Cpp17InputIterator requirement that *r++ is
valid. This change makes it return a non-void proxy type that can be
deferenced to produce another proxy, which is convertible to the
value_type. The second proxy converts to const T& to ensure it can't be
written to.

	* testsuite/util/testsuite_iterators.h:
	(input_iterator_wrapper::operator++(int)): Return proxy object.
2020-06-01 18:30:47 +01:00
Jan Hubicka 1746d5f3e6 Cleanup global decl stream reference streaming, part 2
gcc/ChangeLog:

2020-06-01  Jan Hubicka  <hubicka@ucw.cz>

	* lto-streamer.h (enum LTO_tags): Remove LTO_field_decl_ref,
	LTO_function_decl_ref, LTO_label_decl_ref, LTO_namespace_decl_ref,
	LTO_result_decl_ref, LTO_type_decl_ref, LTO_type_ref,
	LTO_const_decl_ref, LTO_imported_decl_ref,
	LTO_translation_unit_decl_ref, LTO_global_decl_ref and
	LTO_namelist_decl_ref; add LTO_global_stream_ref.
	* lto-streamer-in.c (lto_input_tree_ref): Simplify.
	(lto_input_scc): Update.
	(lto_input_tree_1): Update.
	* lto-streamer-out.c (lto_indexable_tree_ref): Simlify.
	* lto-streamer.c (lto_tag_name): Update.
2020-06-01 19:13:58 +02:00
Jonathan Wakely 258059d91b libstdc++: Document API changes in GCC 10
* doc/xml/manual/evolution.xml: Document deprecation of
	__is_nullptr_t and removal of std::allocator members.
	* doc/html/manual/api.html: Regenerate.
2020-06-01 16:50:53 +01:00
Jonathan Wakely a1ffe9b6f4 libstdc++: Fix incorrect Docbook links
The <xref> element creates the link text automatically from the link
target, rather than using the text node child of the element. This can
be changed by using an endterm attribute, but it's simpler to just use
the <link> element instead.

	* doc/xml/manual/containers.xml: Replace <xref> with <link>.
	* doc/xml/manual/evolution.xml: Likewise.
	* doc/html/manual/api.html: Regenerate.
	* doc/html/manual/containers.html: Regenerate.
2020-06-01 16:49:31 +01:00
Gerald Pfeifer e41b988cc5 libstdc++: Update/streamline Valgrind references
* doc/xml/faq.xml: Adjust Valgrind reference and remove another.
	* doc/html/faq.html: Regenerate.
2020-06-01 17:04:22 +02:00
Jan Hubicka ff7da2b5d6 Cleanup global decl stream reference streaming, part 1
This patch further simplifies way we reffer to global stream.  Every function
section has vector of references to global trees which are populated during
streaming.  This vector is for some reason divided into field_decls, fn_decls,
type_decls, types, namespace_decls, labels_decls and var_decls which contains
also other things.

There is no benefit for this split except perhaps for making the indexes
bit smaller and possibly better encodable by ulebs.  This however does not
pay back and makes things unnecesarily complex.
We may want to re-add multiple tables if we start streaming something else than
trees into the global stream, but that would not work with current
infrastructure anyway.

The patch drops different streams and I checked that it results in reduction of
global stream and apparently very small increase in function streams but it may
be just because I updated tree in between the tests. This will be fixed by
incremental patch.

[WPA] Compression: 86220483 input bytes, 217762146 uncompressed bytes (ratio: 2.525643)
[WPA] Compression: 111735464 input bytes, 297410918 uncompressed bytes (ratio: 2.661741)
[WPA] Size of mmap'd section decls: 86220483 bytes
[WPA] Size of mmap'd section function_body: 14353447 bytes

to:

[WPA] Compression: 85754594 input bytes, 216006049 uncompressed bytes (ratio: 2.518886)
[WPA] Compression: 111370381 input bytes, 295746052 uncompressed bytes (ratio: 2.655518)
[WPA] Size of mmap'd section decls: 85754594 bytes
[WPA] Size of mmap'd section function_body: 14447946 bytes

The patch also removes some of ugly macro generators of accessors functions and
makes it easier to further optimize the way we stream references to trees which
I plan to do incrementally.

I also made the API for streaming referneces symmetric.  I.e. you
stream out by
  lto_output_var_decl_ref
and stream in by
  lto_input_var_decl_ref

instead streaming out by
  lto_output_var_decl_index
and streaming in by
  decl_index = streamer_read_uhwi (ib);
  lto_file_decl_data_get_fn_decl (file_data, decl_index);

lto-bootstrapped/regtested x86_64-linux, will commit it shortly.

gcc/ChangeLog:

2020-06-01  Jan Hubicka  <hubicka@ucw.cz>

	* ipa-reference.c (stream_out_bitmap): Use lto_output_var_decl_ref.
	(ipa_reference_read_optimization_summary): Use lto_intput_var_decl_ref.
	* lto-cgraph.c (lto_output_node): Likewise.
	(lto_output_varpool_node): Likewise.
	(output_offload_tables): Likewise.
	(input_node): Likewise.
	(input_varpool_node): Likewise.
	(input_offload_tables): Likewise.
	* lto-streamer-in.c (lto_input_tree_ref): Declare.
	(lto_input_var_decl_ref): Declare.
	(lto_input_fn_decl_ref): Declare.
	* lto-streamer-out.c (lto_indexable_tree_ref): Use only one decl stream.
	(lto_output_var_decl_index): Rename to ..
	(lto_output_var_decl_ref): ... this.
	(lto_output_fn_decl_index): Rename to ...
	(lto_output_fn_decl_ref): ... this.
	* lto-streamer.h (enum lto_decl_stream_e_t): Remove per-type streams.
	(DEFINE_DECL_STREAM_FUNCS): Remove.
	(lto_output_var_decl_index): Remove.
	(lto_output_fn_decl_index): Remove.
	(lto_output_var_decl_ref): Declare.
	(lto_output_fn_decl_ref): Declare.
	(lto_input_var_decl_ref): Declare.
	(lto_input_fn_decl_ref): Declare.
2020-06-01 15:57:32 +02:00
Feng Xue c055929ff2 Fix dump in clone materialization
2020-06-01  Feng Xue  <fxue@os.amperecomputing.com>

gcc/
	* cgraphclones.c (materialize_all_clones): Adjust replace map dump.
	* ipa-param-manipulation.c (ipa_dump_adjusted_parameters): Do not
	dump infomation if there is no adjusted parameter.
	* (ipa_param_adjustments::dump): Adjust prefix spaces for dump string.
2020-06-01 16:58:17 +08:00
Aldy Hernandez 62efd1c481 Move array bounds checking into its own file.
gcc/
	* Makefile.in (gimple-array-bounds.o): New.
	* tree-vrp.c: Move array bounds code...
	* gimple-array-bounds.cc: ...here...
	* gimple-array-bounds.h: ...and here.
2020-06-01 09:50:48 +02:00
Aldy Hernandez 4a5e9d0089 Move value_range_equiv code to its own file.
gcc/
	* Makefile.in (OBJS): Add value-range-equiv.o.
	* tree-vrp.c (*value_range_equiv*): Move to...
	* value-range-equiv.cc: ...here.
	* tree-vrp.h (class value_range_equiv): Move to...
	* value-range-equiv.h: ...here.
	* vr-values.h: Include value-range-equiv.h.
2020-06-01 09:48:43 +02:00
Feng Xue 32633ec815 Fix missed IPA-CP on by-ref argument directly passed through (PR 93429)
2020-06-01  Feng Xue  <fxue@os.amperecomputing.com>

gcc/
	PR ipa/93429
	* ipa-cp.c (propagate_aggs_across_jump_function): Check aggregate
	lattice for simple pass-through by-ref argument.

gcc/testsuite/
	PR ipa/93429
	* gcc.dg/ipa/ipcp-agg-8.c: Change dump string.
	* gcc.dg/ipa/ipcp-agg-13.c: New test.
2020-06-01 14:10:04 +08:00
GCC Administrator e7340ed74a Daily bump. 2020-06-01 00:16:26 +00:00
Gerald Pfeifer 0feb332152 libstdc++: Remove stray change from previous commit
There is a stray change (introducing a bogus line at the top) that
came via 2babbb6760c43bcd803a5e168ef5ecb0be8a5121; remove that again.

	* doc/xml/manual/policy_data_structures_biblio.xml: Remove
	stray change.
2020-06-01 02:10:24 +02:00
Gerald Pfeifer 2babbb6760 libstdc++: Switch www.cs.princeton.edu to https
* doc/xml/manual/policy_data_structures_biblio.xml: Switch
	www.cs.princeton.edu to https.
	* doc/html/manual/policy_data_structures.html: Regenerate.
2020-06-01 02:03:48 +02:00
Douglas B Rupp 0edfc1fd22 Check for more missing math decls on vxworks.
Use the GLIBCXX_CHECK_MATH_DECL macro to check for the full list of
vxworks math decls.

libstdc++-v3/ChangeLog

	* crossconfig.m4 (<*-vxworks>): Check for more math decls.
	* configure: Rebuild.
2020-05-31 14:32:27 -07:00
Iain Sandoe 1bb8085046 coroutines: Avoid functions with unlowered coroutine trees [PR95087].
Diagnosing bad uses of 'return' in coroutines is somewhat
tricky, since the user can use the keyword before we know
that the function is a coroutine (where such returns are not
permitted).  At present, we are just doing a check for any
use of 'return' and erroring on that.  However, we can't then
pass the function body on, since it will contain unlowered
coroutine trees.

This avoids the issue by dropping the entire function body
under that circumstance.  We could do better (for 11) but
this is intended to allow back-port of other fixes to 10.

gcc/cp/ChangeLog:

	PR c++/95087
	* coroutines.cc (morph_fn_to_coro): If we see an
	early fatal error, drop the erroneous function body.

gcc/testsuite/ChangeLog:

	PR c++/95087
	* g++.dg/coroutines/co-return-syntax-08-bad-return.C:
	Adjust the testcase to do the compile (rather than an
	-fsyntax-only parse).
2020-05-31 20:48:09 +01:00
Iain Buclaw 7248bf60a2 contrib: Add v850e1-elf to config-list.mk
This comment was added in SVN r173410, v850e1-* was added to config.sub
in SVN r174691 (around 2011).  So it should no longer apply.

contrib/ChangeLog:

	* config-list.mk (LIST): Add v850e1-elf.
2020-05-31 21:41:55 +02:00
Iain Buclaw 5f35a8288b contrib: Add or1k-elf, or1k-linux-*, and or1k-rtems to config-list.mk
Support for OpenRISC target was added in SVN r265963.

contrib/ChangeLog:

	* config-list.mk (LIST): Add or1k-elf, or1k-linux-*, and or1k-rtems.
2020-05-31 21:41:16 +02:00
Iain Buclaw 30da9dc40c contrib: Remove arm-wrs-vxworks from config-list.mk
Support for arm-wrs-vxworks was removed in git r10-4684.

contrib/ChangeLog:

	* config-list.mk (LIST): Remove arm-wrs-vxworks.
2020-05-31 21:40:11 +02:00
Iain Buclaw 95625d3580 contrib: Remove cris-linux and crisv32-* from config-list.mk
Support for crisv32-*-* and cris-*-linux* was removed in git r11-214.

contrib/ChangeLog:

	* config-list.mk (LIST): Remove cris-linux, crisv32-elf, and
	crisv32-linux.
2020-05-31 21:37:19 +02:00
Iain Sandoe 3cf2a9e047 coroutines: Remove up some unused values.
The build_new_method_call allows us to inspect the
function decl used.  In most cases, this is not used
and we can just set the parm to NULL.

gcc/cp/ChangeLog:

	* coroutines.cc (build_co_await): Remove unused
	variable.
	(finish_co_await_expr): Likewise.
	(finish_co_yield_expr): Likewise; revise comment.
2020-05-31 19:32:01 +01:00
Jeff Law c25d0fa4d7 Fix execute/20071219-1.c regression on H8 due to loss of REG_INC notes in peephole2.
gcc/
	* lra.c (add_auto_inc_notes): Remove function.
	* reload1.c (add_auto_inc_notes): Similarly.  Move into...
	* rtlanal.c (add_auto_inc_notes): New function.
	* rtl.h (add_auto_inc_notes): Add prototype.
	* recog.c (peep2_attempt): Scan and add REG_INC notes to new insns
	as needed.
2020-05-31 11:18:15 -06:00
Jan Hubicka 05430b9b6a Cleanup indexable tree streaming.
gcc/

	* lto-section-out.c (lto_output_decl_index): Remove.
	(lto_output_field_decl_index): Move to lto-streamer-out.c
	(lto_output_fn_decl_index): Move to lto-streamer-out.c
	(lto_output_namespace_decl_index): Remove.
	(lto_output_var_decl_index): Remove.
	(lto_output_type_decl_index): Remove.
	(lto_output_type_ref_index): Remove.
	* lto-streamer-out.c (output_type_ref): Remove.
	(lto_get_index): New function.
	(lto_output_tree_ref): Remove.
	(lto_indexable_tree_ref): New function.
	(lto_output_var_decl_index): Move here from lto-section-out.c; simplify.
	(lto_output_fn_decl_index): Move here from lto-section-out.c; simplify.
	(stream_write_tree_ref): Update.
	(lto_output_tree): Update.
	* lto-streamer.h (lto_output_decl_index): Remove prototype.
	(lto_output_field_decl_index): Remove prototype.
	(lto_output_namespace_decl_index): Remove prototype.
	(lto_output_type_decl_index): Remove prototype.
	(lto_output_type_ref_index): Remove prototype.
	(lto_output_var_decl_index): Move.
	(lto_output_fn_decl_index): Move
2020-05-31 17:36:58 +02:00
Iain Buclaw 1d2d5afc80 contrib: Add pru-elf to config-list.mk
Support for the TI PRU target was added in SVN r272202.

contrib/ChangeLog:

	* config-list.mk (LIST): Add pru-elf.
2020-05-31 14:43:51 +02:00
Thomas Koenig 811f902b76 Finalization depends on the expression, not on the component.
This patch fixes a 8/9/10/11 regression, where finalized types
were not finalized (and deallocated), which led to memory
leaks.

gcc/fortran/ChangeLog:

2020-05-24  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR fortran/94361
	* class.c (finalize_component): Use expr->finalized instead of
	comp->finalized.
	* gfortran.h (gfc_component): Remove finalized member.
	(gfc_expr): Add it here instead.

gcc/testsuite/ChangeLog:

2020-05-24  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR fortran/94361
	* gfortran.dg/finalize_28.f90: Adjusted free counts.
	* gfortran.dg/finalize_33.f90: Likewise.
	* gfortran.dg/finalize_34.f90: Likewise.
	* gfortran.dg/finalize_35.f90: New test.
2020-05-31 12:00:07 +02:00
Jakub Jelinek dc8c02ca1c expr: Fix fallout from optimize store_expr from STRING_CST [PR95052]
> Can't hurt, and debugging the assert tripping is likely a hell of a lot easier
> than debugging the resultant incorrect code.   So if it passes, then I'd say go
> for it.

Testing passed, so I've committed it with those asserts (and thankfully I've
added them!) but it apparently broke Linux kernel build on arm.

The problem is that if the STRING_CST is very short, while the full object
has BLKmode, the short string could very well have
QImode/HImode/SImode/DImode and in that case it wouldn't take the path that
copies the string and then clears the remaining space, but different paths
in which it will ICE because of those asserts and without those it would
just emit wrong-code.

The following patch fixes it by enforcing BLKmode for the string MEM, even
if it is short, so that we copy it and memset the rest.

2020-05-31  Jakub Jelinek  <jakub@redhat.com>

	PR middle-end/95052
	* expr.c (store_expr): For shortedned_string_cst, ensure temp has
	BLKmode.

	* gcc.dg/pr95052.c: New test.
2020-05-31 11:54:41 +02:00
Jeff Law 6dda860844 Disable brabc/brabs patterns as their length computation is horribly broken and leads to incorrect code generation.
* config/h8300/jumpcall.md (brabs, brabc): Disable patterns.
2020-05-30 21:53:28 -06:00