gcc.git
5 years agoavx512f-vfixupimmpd-2.c: Fix the test cases for VFIXUPIMM* intrinsics.
Wei Xiao [Thu, 17 Jan 2019 10:01:07 +0000 (10:01 +0000)]
avx512f-vfixupimmpd-2.c: Fix the test cases for VFIXUPIMM* intrinsics.

gcc/testsuite/ChangeLog
2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

* gcc.target/i386/avx512f-vfixupimmpd-2.c: Fix the test cases for
VFIXUPIMM* intrinsics.
* gcc.target/i386/avx512f-vfixupimmps-2.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmsd-2.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmss-2.c: Ditto.

From-SVN: r268014

5 years agore PR target/88794 (fixupimm intrinsics are unusable)
Wei Xiao [Thu, 17 Jan 2019 09:54:56 +0000 (09:54 +0000)]
re PR target/88794 (fixupimm intrinsics are unusable)

gcc/ChangeLog
2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

PR target/88794
Revert:

2018-11-06  Wei Xiao  <wei3.xiao@intel.com>

* config/i386/avx512fintrin.h: Update VFIXUPIMM* intrinsics.
(_mm512_fixupimm_round_pd): Update parameters and builtin.
(_mm512_maskz_fixupimm_round_pd): Ditto.
(_mm512_fixupimm_round_ps): Ditto.
(_mm512_maskz_fixupimm_round_ps): Ditto.
(_mm_fixupimm_round_sd): Ditto.
(_mm_maskz_fixupimm_round_sd): Ditto.
(_mm_fixupimm_round_ss): Ditto.
(_mm_maskz_fixupimm_round_ss): Ditto.
(_mm512_fixupimm_pd): Ditto.
(_mm512_maskz_fixupimm_pd): Ditto.
(_mm512_fixupimm_ps): Ditto.
(_mm512_maskz_fixupimm_ps): Ditto.
(_mm_fixupimm_sd): Ditto.
(_mm_maskz_fixupimm_sd): Ditto.
(_mm_fixupimm_ss): Ditto.
(_mm_maskz_fixupimm_ss): Ditto.
(_mm512_mask_fixupimm_round_pd): Update builtin.
(_mm512_mask_fixupimm_round_ps): Ditto.
(_mm_mask_fixupimm_round_sd): Ditto.
(_mm_mask_fixupimm_round_ss): Ditto.
(_mm512_mask_fixupimm_pd): Ditto.
(_mm512_mask_fixupimm_ps): Ditto.
(_mm_mask_fixupimm_sd): Ditto.
(_mm_mask_fixupimm_ss): Ditto.
* config/i386/avx512vlintrin.h:
(_mm256_fixupimm_pd): Update parameters and builtin.
(_mm256_maskz_fixupimm_pd): Ditto.
(_mm256_fixupimm_ps): Ditto.
(_mm256_maskz_fixupimm_ps): Ditto.
(_mm_fixupimm_pd): Ditto.
(_mm_maskz_fixupimm_pd): Ditto.
(_mm_fixupimm_ps): Ditto.
(_mm_maskz_fixupimm_ps): Ditto.
(_mm256_mask_fixupimm_pd): Update builtin.
(_mm256_mask_fixupimm_ps): Ditto.
(_mm_mask_fixupimm_pd): Ditto.
(_mm_mask_fixupimm_ps): Ditto.
* config/i386/i386-builtin-types.def: Add new types and remove useless ones.
* config/i386/i386-builtin.def: Update builtin definitions.
* config/i386/i386.c: Handle new builtin types and remove useless ones.
* config/i386/sse.md: Update VFIXUPIMM* patterns.
(<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
(<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
(<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Update.
(avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
(avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
(avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Update.
* config/i386/subst.md:
(round_saeonly_sd_mask_operand4): Add new subst_attr.
(round_saeonly_sd_mask_op4): Ditto.
(round_saeonly_expand_operand5): Ditto.
(round_saeonly_expand): Update.

gcc/testsuite/ChangeLog
2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

PR target/88794
Revert:
2018-11-06  Wei Xiao  <wei3.xiao@intel.com>

* gcc.target/i386/avx-1.c: Update tests for VFIXUPIMM* intrinsics.
* gcc.target/i386/avx512f-vfixupimmpd-1.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmpd-2.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmps-1.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmsd-1.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmsd-2.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmss-1.c: Ditto.
* gcc.target/i386/avx512f-vfixupimmss-2.c: Ditto.
* gcc.target/i386/avx512vl-vfixupimmpd-1.c: Ditto.
* gcc.target/i386/avx512vl-vfixupimmps-1.c: Ditto.
* gcc.target/i386/sse-13.c: Ditto.
* gcc.target/i386/sse-14.c: Ditto.
* gcc.target/i386/sse-22.c: Ditto.
* gcc.target/i386/sse-23.c: Ditto.
* gcc.target/i386/testimm-10.c: Ditto.
* gcc.target/i386/testround-1.c: Ditto.

From-SVN: r268013

5 years agore PR target/88794 (fixupimm intrinsics are unusable)
Wei Xiao [Thu, 17 Jan 2019 09:34:00 +0000 (09:34 +0000)]
re PR target/88794 (fixupimm intrinsics are unusable)

2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

        PR target/88794
        Revert:
        2018-11-12  Wei Xiao  <wei3.xiao@intel.com>

        * config/i386/sse.md: Combine VFIXUPIMM* patterns
        (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
        (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
        (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Remove.
        (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
        (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
        (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Remove.

From-SVN: r268012

5 years agore PR target/88794 (fixupimm intrinsics are unusable)
Wei Xiao [Thu, 17 Jan 2019 08:51:01 +0000 (08:51 +0000)]
re PR target/88794 (fixupimm intrinsics are unusable)

gcc/ChangeLog:
2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

        PR target/88794
        Revert:
        2018-12-15  Jakub Jelinek  <jakub@redhat.com>

        PR target/88489
        * config/i386/sse.md (UNSPEC_SFIXUPIMM): New unspec enumerator.
        (avx512f_sfixupimm<mode><mask_name><round_saeonly_name>): Use it
        instead of UNSPEC_FIXUPIMM.

gcc/testsuite/ChangeLog:
2019-01-17  Wei Xiao  <wei3.xiao@intel.com>

        PR target/88794
        Revert:
        2018-12-15  Jakub Jelinek  <jakub@redhat.com>

        PR target/88489
        * gcc.target/i386/avx512vl-vfixupimmsd-2.c: New test.
        * gcc.target/i386/avx512vl-vfixupimmss-2.c: New test.

From-SVN: r268011

5 years agore PR lto/86736 (g++.dg/asan/pr81021.C -O2 -flto -flto-partition=none ICE at dwarf2...
Richard Biener [Thu, 17 Jan 2019 08:45:00 +0000 (08:45 +0000)]
re PR lto/86736 (g++.dg/asan/pr81021.C   -O2 -flto -flto-partition=none ICE at dwarf2out.c:31111)

2019-01-17  Richard Biener  <rguenther@suse.de>

PR lto/86736
* dwarf2out.c (want_pubnames): Never generate pubnames sections
and friends for the LTO part of debug info.

From-SVN: r268010

5 years agore PR tree-optimization/86214 (Strongly increased stack usage)
Jakub Jelinek [Thu, 17 Jan 2019 08:05:12 +0000 (09:05 +0100)]
re PR tree-optimization/86214 (Strongly increased stack usage)

PR tree-optimization/86214
* cfgexpand.c (add_stack_var_conflict): Don't add any conflicts
if x == y.

From-SVN: r268009

5 years agore PR rtl-optimization/88870 (ICE: Segmentation fault (in df_worklist_propagate_backw...
Jakub Jelinek [Thu, 17 Jan 2019 08:04:28 +0000 (09:04 +0100)]
re PR rtl-optimization/88870 (ICE: Segmentation fault (in df_worklist_propagate_backward))

PR rtl-optimization/88870
* dce.c (deletable_insn_p): Never delete const/pure calls that can
throw if we can't alter the cfg or delete dead exceptions.
(mark_insn): Don't call find_call_stack_args for such calls.

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

From-SVN: r268008

5 years ago[rs6000] Support more prototypes for vec_ld and vec_st.
Kewen Lin [Thu, 17 Jan 2019 07:49:24 +0000 (07:49 +0000)]
[rs6000] Support more prototypes for vec_ld and vec_st.

2019-01-17  Kewen Lin  <linkw@gcc.gnu.org>

gcc/ChangeLog
    * doc/extend.texi: Add four new prototypes for vec_ld and seven new
    prototypes for vec_st.
    * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add entries
    for scalar address type variants of altivec_vec_ld/altivec_vec_st,
    mainly on signed/unsigned long long and double.

gcc/testsuite/ChangeLog
    * gcc.target/powerpc/altivec_vld_vst_addr.c: New test.

From-SVN: r268007

5 years ago[PR87768] reset location wrapper suppression when reentering top level
Alexandre Oliva [Thu, 17 Jan 2019 07:32:29 +0000 (07:32 +0000)]
[PR87768] reset location wrapper suppression when reentering top level

Concepts-checking and other kinds of early tsubsting may often take
place while location wrappers are suppressed, e.g. because we've
triggered template instantiation within template parameter lists.

With that, exprs that are usually wrapped by VIEW_CONVERT_EXPRs
location wrappers may end up wrapped by NON_LVALUE_EXPRs that are not
marked as location wrappers.  If such NON_LVALUE_EXPRs tsubsted exprs
undergo another round of tsubsting, say for constraint checking, or
even for another round of specialization, they will be rejected by
tsubst_copy_and_build.

This patch arranges for suppress_location_wrappers to be saved and
reset when pushing to the top level, and restored when popping from
it.

for  gcc/cp/ChangeLog

PR c++/87768
* cp-tree.h (saved_scope): Add suppress_location_wrappers.
* name-lookup.c (do_push_to_top_level): Save and reset it.
(do_pop_from_top_level): Restore it.

for  gcc/testsuite/ChangeLog

PR c++/87768
* g++.dg/concepts/pr87768.C: New.

From-SVN: r268006

5 years ago[PR86648] use auto identifier for class placeholder templates
Alexandre Oliva [Thu, 17 Jan 2019 07:32:16 +0000 (07:32 +0000)]
[PR86648] use auto identifier for class placeholder templates

dwarf2out recognizes unspecified auto types by the identifier.  C++
template class placeholders are unspecified auto types that take the
identifier of the class rather than those used by preexisting auto
types, so dwarf2out ICEs when it finds one of those.  Alas, they may
be visible to dwarf2out, since the types of e.g. static data members
of templates are only deduced at member instantiation, i.e., if the
data member is actually referenced, but the data member is added as a
field, still with unspecified auto placeholder type, when the
enclosing class is instantiated.

I've changed placeholder creator to use an auto identifier instead,
which allowed dropping the placeholder test in C++'s is_auto (alas, it
can't be used in dwarf2out, think LTO).  To avoid losing information
in error messages and dumps and whatnot, I've added code to recognize
placeholders for template classes say A and print them out as
A<...auto...>.

for  gcc/cp/ChangeLog

PR c++/86648
        * pt.c (make_template_placeholder): Use auto_identifier.
        (is_auto): Drop CLASS_PLACEHOLDER_TEMPLATE test.
        * error.c (dump_type): Handle template placeholders.
        * cxx-pretty-print.c (pp_cx_unqualified_id): Likewise.

for  gcc/testsuite/ChangeLog

PR c++/86648
        * gcc.dg/cpp1z/pr86648.C: New.

From-SVN: r268005

5 years ago[PR88146] avoid diagnostics diffs if cdtor_returns_this
Alexandre Oliva [Thu, 17 Jan 2019 04:49:55 +0000 (04:49 +0000)]
[PR88146] avoid diagnostics diffs if cdtor_returns_this

Diagnostics for testsuite/g++.dg/cpp0x/inh-ctor32.C varied across
platforms.  Specifically, on ARM, the diagnostics within the subtest
derived_ctor::inherited_derived_ctor::constexpr_noninherited_ctor did
not match those displayed on other platforms, and the test failed.

The difference seemed to have to do with locations assigned to ctors,
but it was more subtle: on ARM, the instantiation of bor's template
ctor was nested within the instantiation of bar's template ctor
inherited from bor.  The reason turned out to be related with the
internal return type of ctors: arm_cxx_cdtor_returns_this is enabled
for because of AAPCS, while cxx.cdtor_returns_this is disabled on most
other platforms.  While convert_to_void returns early with a VOID
expr, the non-VOID return type of the base ctor CALL_EXPR causes
convert_to_void to inspect the called decl for nodiscard attributes:
maybe_warn_nodiscard -> cp_get_fndecl_from_callee ->
maybe_constant_init -> cxx_eval_outermost_constant_expr ->
instantiate_constexpr_fns -> nested instantiation.

The internal return type assigned to a cdtor should not affect
instantiation (constexpr or template) decisions, IMHO.  We know it
affects diagnostics, but I have a hunch this might bring deeper issues
with it, so I've arranged for the CALL_EXPR handler in convert_to_void
to disregard cdtors, regardless of the ABI.

for  gcc/cp/ChangeLog

PR c++/88146
* cvt.c (convert_to_void): Handle all cdtor calls as if
returning void.

From-SVN: r268004

5 years ago[PATCH, rs6000, testsuite] Fix PR87306
Kewen Lin [Thu, 17 Jan 2019 03:03:38 +0000 (03:03 +0000)]
[PATCH, rs6000, testsuite] Fix PR87306

    PR target/87306
    * gcc.dg/vect/bb-slp-pow-1.c: Modify to reflect that
    the loop is not vectorized on POWER unless hardware
    misaligned loads are available.

From-SVN: r268003

5 years agoruntime: dropg before CAS g status to _Grunnable/_Gwaiting
Ian Lance Taylor [Thu, 17 Jan 2019 02:14:28 +0000 (02:14 +0000)]
runtime: dropg before CAS g status to _Grunnable/_Gwaiting

    Currently, we dropg (which clears gp.m) after we CAS the g status
    to _Grunnable or _Gwaiting. Immediately after CASing the g status,
    another thread may CAS it to _Gscan status and scan its stack.
    With precise stack scan, it accesses gp.m in order to switch to g
    and back (in doscanstackswitch). This races with dropg. If
    doscanstackswitch reads gp.m, then dropg runs, when we restore
    the m at the end of the scan it will set to a stale value. Worse,
    if dropg runs after doscanstackswitch sets the new m, gp will be
    running with a nil m.

    To fix this, we do dropg before CAS g status to _Grunnable or
    _Gwaiting. We can do this safely if we are CASing from _Grunning,
    as we own the g when it is in _Grunning. There is one case where
    we CAS from _Gsyscall to _Grunnable. It is not safe to dropg when
    it is in _Gsyscall, as precise stack scan needs to read gp.m in
    order to signal the m. So we need to introduce a transient state,
    _Gexitingsyscall, between _Gsyscall and _Grunnable, where the GC
    should not scan its stack.

    In is a little unfortunate that we have to add another g status.
    We could reuse an existing one (e.g. _Gcopystack), but it is
    clearer and safer to just use a new one, as Austin suggested.

    Reviewed-on: https://go-review.googlesource.com/c/158157

From-SVN: r268001

5 years agoDaily bump.
GCC Administrator [Thu, 17 Jan 2019 00:16:26 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r267999

5 years ago[libbacktrace] Handle DW_FORM_GNU_strp_alt
Tom de Vries [Thu, 17 Jan 2019 00:08:05 +0000 (00:08 +0000)]
[libbacktrace] Handle DW_FORM_GNU_strp_alt

Handle DW_FORM_GNU_strp_alt which references the .debug_str section in the
.gnu_debugaltlink file.

2019-01-17  Tom de Vries  <tdevries@suse.de>

PR libbacktrace/82857
* dwarf.c (read_attribute): Handle DW_FORM_GNU_strp_alt
using altlink.

From-SVN: r267996

5 years ago[libbacktrace] Handle alt FORMS without .gnu_debugaltlink
Tom de Vries [Thu, 17 Jan 2019 00:07:53 +0000 (00:07 +0000)]
[libbacktrace] Handle alt FORMS without .gnu_debugaltlink

Handle DW_FORM_GNU_strp_alt and DW_FORM_GNU_ref_alt references robustly in
presence of missing .gnu_debugaltlink file.

2019-01-17  Tom de Vries  <tdevries@suse.de>

* dwarf.c (enum attr_val_encoding): Add ATTR_VAL_NONE.
(read_attribute): Add altlink parameter.  Handle missing altlink for
DW_FORM_GNU_strp_alt and DW_FORM_GNU_ref_alt.
(find_address_ranges, build_address_map, build_dwarf_data): Add and
handle altlink parameter.
(read_referenced_name, read_function_entry): Add argument to
read_attribute call.

From-SVN: r267995

5 years ago[libbacktrace] Add altlink field to struct dwarf_data
Tom de Vries [Thu, 17 Jan 2019 00:07:43 +0000 (00:07 +0000)]
[libbacktrace] Add altlink field to struct dwarf_data

Add an altlink field to struct dwarf_data, and initialize it with the pointer
to the struct dwarf_data for the .gnu_debugaltlink.

2019-01-17  Tom de Vries  <tdevries@suse.de>

* dwarf.c (struct dwarf_data): Add altlink field.
(backtrace_dwarf_add): Add and handle fileline_altlink parameter.
* elf.c (elf_add): Add argument to backtrace_dwarf_add call.
(phdr_callback, backtrace_initialize): Add argument to elf_add calls.
* internal.h (backtrace_dwarf_add): Add fileline_altlink parameter.
* pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
* xcoff.c (xcoff_add): Same.

From-SVN: r267994

5 years ago[libbacktrace] Return struct dwarf_data pointer from elf_add
Tom de Vries [Thu, 17 Jan 2019 00:07:32 +0000 (00:07 +0000)]
[libbacktrace] Return struct dwarf_data pointer from elf_add

Allow the caller of elf_add access to the struct dwarf_data pointer
corresponding to the added elf.

2019-01-17  Tom de Vries  <tdevries@suse.de>

* internal.h (backtrace_dwarf_add): Add fileline_entry parameter.
* dwarf.c (backtrace_dwarf_add): Add and handle fileline_entry parameter.
* elf.c (elf_add): Add and handle fileline_entry parameter.  Add
argument to backtrace_dwarf_add call.
(phdr_callback, backtrace_initialize): Add argument to elf_add calls.
* pecoff.c (coff_add): Add argument to backtrace_dwarf_add call.
* xcoff.c (xcoff_add): Same.

From-SVN: r267993

5 years ago[libbacktrace] Read .gnu_debugaltlink
Tom de Vries [Thu, 17 Jan 2019 00:07:21 +0000 (00:07 +0000)]
[libbacktrace] Read .gnu_debugaltlink

Read the elf file pointed at by the .gnu_debugaltlink section, and verify that
the build id matches.

2019-01-17  Tom de Vries  <tdevries@suse.de>

* elf.c (elf_add): Add and handle with_buildid_data and
with_buildid_size parameters.  Handle .gnu_debugaltlink section.
(phdr_callback, backtrace_initialize): Add arguments to elf_add calls.

From-SVN: r267992

5 years agoFix failing filesystem tests on mingw targets
Jonathan Wakely [Wed, 16 Jan 2019 23:11:10 +0000 (23:11 +0000)]
Fix failing filesystem tests on mingw targets

* config/abi/pre/gnu.ver (GLIBCXX_3.4.26): Add exports for fstream
constructors and open members taking wide strings. Fix patterns for
filesystem::path members to match wstring_view parameters. Add
exports for shared_ptr members used by directory iterators.
* src/c++17/fs_ops.cc (remove(const path&, error_code&)): Clear the
error code parameter if the file doesn't exist.
* src/filesystem/ops.cc (remove(const path&, error_code&)):
Likewise.
* testsuite/27_io/filesystem/operations/canonical.cc: Fix expected
values for mingw targets, where "/" is not an absolute path. Do not
test symlinks on mingw targets.
* testsuite/experimental/filesystem/operations/canonical.cc: Likewise.
* testsuite/27_io/filesystem/operations/copy.cc: Do not test symlinks
on mingw targets.
* testsuite/experimental/filesystem/operations/copy.cc: Likewise.
* testsuite/27_io/filesystem/operations/create_directories.cc: Check
that each component of the path is created.
* testsuite/experimental/filesystem/operations/create_directories.cc:
Likewise.
* testsuite/27_io/filesystem/operations/exists.cc: Do not test
permissions on mingw targets.
* testsuite/experimental/filesystem/operations/exists.cc: Likewise.
* testsuite/27_io/filesystem/operations/is_empty.cc: Likewise.
* testsuite/experimental/filesystem/operations/is_empty.cc: Likewise.
* testsuite/27_io/filesystem/operations/permissions.cc: XFAIL for
mingw targets.
* testsuite/experimental/filesystem/operations/permissions.cc:
Likewise.
* testsuite/27_io/filesystem/operations/remove.cc: Do not test
symlinks or permissions on mingw targets.
* testsuite/experimental/filesystem/operations/remove.cc: Likewise.
* testsuite/27_io/filesystem/operations/remove_all.cc: Do not test
symlinks on mingw targets.
* testsuite/experimental/filesystem/operations/remove_all.cc:
Likewise.
* testsuite/27_io/filesystem/operations/status.cc: Do not test
permissions on mingw targets.
* testsuite/27_io/filesystem/operations/weakly_canonical.cc: Do not
test symlinks on mingw targets.
* testsuite/experimental/filesystem/operations/space.cc: Fix test
for mingw targets.

From-SVN: r267991

5 years agosyscall: mark C syscall functions noescape
Ian Lance Taylor [Wed, 16 Jan 2019 22:38:33 +0000 (22:38 +0000)]
syscall: mark C syscall functions noescape

    Many C syscall functions take pointer arguments. The pointers
    don't escape in the C functions. Mark the C functions noescape so
    calling them doesn't need allocation.

    Reviewed-on: https://go-review.googlesource.com/c/158158

From-SVN: r267989

5 years ago[libbacktrace] Factor out read_referenced_name_from_attr
Tom de Vries [Wed, 16 Jan 2019 20:47:02 +0000 (20:47 +0000)]
[libbacktrace] Factor out read_referenced_name_from_attr

Factor out the common handling of DW_AT_abstract_origin and
DW_AT_specification from read_function_entry and read_referenced_name.

2019-01-16  Tom de Vries  <tdevries@suse.de>

* dwarf.c (read_referenced_name_from_attr): New function.  Factor out
of ...
  (read_referenced_name): ... here, and ...
(read_function_entry): ... here.

From-SVN: r267986

5 years ago[D] Fix failing EH execution test on i386.
Iain Buclaw [Wed, 16 Jan 2019 20:40:21 +0000 (20:40 +0000)]
[D] Fix failing EH execution test on i386.

Turn off partitioning unless it was explicitly requested, as it doesn't
work with D exception chaining, where personality routines use LSDA to
determine whether two thrown exceptions are in the same context.

The following distills what was failing in the D testsuite.
```
try {
  try {
    fn();  // throws "1"
  }
  finally {
    throw new Exception("2");
  }
}
catch (Exception e) {
  assert(e.msg == "1");
  assert(e.next.msg == "2");
}
```

gcc/d/ChangeLog:

PR d/87824
* d-lang.cc (d_post_options): Disable implicit
-forder-blocks-and-partition.

From-SVN: r267985

5 years agoFix ICE due to "combine" creating unreachable EH blocks (PR target/88861)
David Malcolm [Wed, 16 Jan 2019 20:13:23 +0000 (20:13 +0000)]
Fix ICE due to "combine" creating unreachable EH blocks (PR target/88861)

PR target/88861 reports an ICE in "ce2" due to an unreachable
basic block.

The block becomes unreachable in "combine" when delete_noop_moves
deletes an insn with a REG_EH_REGION, deleting the EH edge, the
only edge leading to the basic block.

Normally, rest_of_handle_combine would call cleanup_cfg, deleting
unreachable blocks, if combine_instructions returns true, and
combine_instructions does return true for some cases of edge-removal,
but it doesn't for this case, leading to the ICE.

This patch updates delete_noop_moves so that it returns true if
it deletes any edges, and passes that through to combine_instructions,
so that it too will return true if any edges were deleted, ensuring that
cleanup_cfg will be called by rest_of_handle_combine for this case,
deleting the now-unreachable block, and fixing the ICE.

gcc/ChangeLog:
PR target/88861
* combine.c (delete_noop_moves): Convert to "bool" return,
returning true if any edges are eliminated.
(combine_instructions): Also return true if delete_noop_moves
returns true.

gcc/testsuite/ChangeLog:
PR target/88861
* g++.dg/torture/pr88861.C: New test.

From-SVN: r267984

5 years agoaarch64-builtins.c (aarch64_simd_expand_args): Use correct max nunits for endian...
Tamar Christina [Wed, 16 Jan 2019 18:29:00 +0000 (18:29 +0000)]
aarch64-builtins.c (aarch64_simd_expand_args): Use correct max nunits for endian swap.

2019-01-16  Tamar Christina  <tamar.christina@arm.com>

* config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
correct max nunits for endian swap.
(aarch64_expand_fcmla_builtin): Correct subreg code.
* config/aarch64/aarch64-simd.md (aarch64_fcmla_lane<rot><mode>,
aarch64_fcmla_laneq<rot>v4hf, aarch64_fcmlaq_lane<rot><mode>): Correct
lane endianness.

From-SVN: r267983

5 years agoFix PR88046 on AArch64 and Arm bare metal targets.
Tamar Christina [Wed, 16 Jan 2019 17:50:38 +0000 (17:50 +0000)]
Fix PR88046 on AArch64 and Arm bare metal targets.

gcc/testsuite/ChangeLog:

PR debug/88046
* g++.dg/lto/pr88046_0.C: Check for shared and fPIC.

From-SVN: r267980

5 years agodecl.c (grokdeclarator): Use locations[ds_storage_class] in error messages about...
Paolo Carlini [Wed, 16 Jan 2019 16:16:54 +0000 (16:16 +0000)]
decl.c (grokdeclarator): Use locations[ds_storage_class] in error messages about ill-formed uses of mutable.

/cp
2019-01-16  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (grokdeclarator): Use locations[ds_storage_class] in
error messages about ill-formed uses of mutable.

/testsuite
2019-01-16  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/other/pr33558.C: Test location too.
* g++.dg/other/pr33558-2.C: Likewise.
* g++.dg/parse/crash4.C: Likewise.
* g++.old-deja/g++.brendan/err-msg11.C: Likewise.
* g++.old-deja/g++.mike/p7635.C: Likewise.
* g++.old-deja/g++.other/decl6.C: Likewise.

From-SVN: r267978

5 years agoPR c++/78244 - narrowing conversion in template not detected.
Marek Polacek [Wed, 16 Jan 2019 15:58:34 +0000 (15:58 +0000)]
PR c++/78244 - narrowing conversion in template not detected.

* call.c (perform_implicit_conversion_flags): Set
IMPLICIT_CONV_EXPR_BRACED_INIT.
* cp-tree.h (IMPLICIT_CONV_EXPR_BRACED_INIT): New.
* pt.c (tsubst_copy_and_build): Use it.

* g++.dg/cpp0x/Wnarrowing13.C: New test.
* g++.dg/cpp0x/Wnarrowing14.C: New test.

From-SVN: r267976

5 years agoalpha.c (alpha_gimplify_va_arg): Handle split indirect COMPLEX_TYPE arguments.
Uros Bizjak [Wed, 16 Jan 2019 15:33:34 +0000 (16:33 +0100)]
alpha.c (alpha_gimplify_va_arg): Handle split indirect COMPLEX_TYPE arguments.

* config/alpha/alpha.c (alpha_gimplify_va_arg):
Handle split indirect COMPLEX_TYPE arguments.

From-SVN: r267973

5 years ago__builtin_<add/sub>_overflow issues on AArch64 (redux) (cont)
Richard Earnshaw [Wed, 16 Jan 2019 15:22:08 +0000 (15:22 +0000)]
__builtin_<add/sub>_overflow issues on AArch64 (redux) (cont)

And the ChangeLog for PR target/86891 fix.

From-SVN: r267972

5 years ago__builtin_<add/sub>_overflow issues on AArch64 (redux)
Richard Earnshaw [Wed, 16 Jan 2019 15:18:05 +0000 (15:18 +0000)]
__builtin_<add/sub>_overflow issues on AArch64 (redux)

Further investigation showed that my previous patch for this issue was
still incomplete.

The problem stemmed from what I suspect was a mis-understanding of the
way overflow is calculated on aarch64 when values are subtracted (and
hence in comparisons).  In this case, unlike addition, the carry flag
is /cleared/ if there is overflow (technically, underflow) and set
when that does not happen.  This patch clears up this issue by using
CCmode for all subtractive operations (this can fully describe the
normal overflow conditions without anything particularly fancy);
clears up the way we express normal unsigned overflow using CC_Cmode
(the result of a sum is less than one of the operands) and adds a new
mode, CC_ADCmode to handle expressing overflow of an add-with-carry
operation, where the standard idiom is no-longer sufficient to
describe the overflow condition.

PR target/86891
* config/aarch64/aarch64-modes.def: Add comment about how the carry
bit is set by add and compare.
(CC_ADC): New CC_MODE.
* config/aarch64/aarch64.c (aarch64_select_cc_mode): Use variables
to cache the code and mode of X.  Adjust the shape of a CC_Cmode
comparison.  Add detection for CC_ADCmode.
(aarch64_get_condition_code_1): Update code support for CC_Cmode.  Add
CC_ADCmode.
* config/aarch64/aarch64.md (uaddv<mode>4): Use LTU with CCmode.
(uaddvti4): Comparison result is in CC_ADCmode and the condition is GEU.
(add<mode>3_compareC_cconly_imm): Delete.  Merge into...
(add<mode>3_compareC_cconly): ... this.  Restructure the comparison
to eliminate the need for zero-extending the operands.
(add<mode>3_compareC_imm): Delete.  Merge into ...
(add<mode>3_compareC): ... this.  Restructure the comparison to
eliminate the need for zero-extending the operands.
(add<mode>3_carryin): Use LTU for the overflow detection.
(add<mode>3_carryinC): Use CC_ADCmode for the result of the carry out.
Reexpress comparison for overflow.
(add<mode>3_carryinC_zero): Update for change to add<mode>3_carryinC.
(add<mode>3_carryinC): Likewise.
(add<mode>3_carryinV): Use LTU for carry between partials.
* config/aarch64/predicates.md (aarch64_carry_operation): Update
handling of CC_Cmode and add CC_ADCmode.
(aarch64_borrow_operation): Likewise.

From-SVN: r267971

5 years agore PR c/51628 (__attribute__((packed)) is unsafe in some cases (i.e. add -Waddress...
Jakub Jelinek [Wed, 16 Jan 2019 14:18:47 +0000 (15:18 +0100)]
re PR c/51628 (__attribute__((packed)) is unsafe in some cases (i.e. add -Waddress-of-packed-member, etc.))

PR c/51628
PR target/88682
* c-c++-common/pr51628-10.c (unaligned_int128_t): Add
may_alias attribute.

From-SVN: r267970

5 years agoFix Arm big-endian regressions.
Tamar Christina [Wed, 16 Jan 2019 11:25:10 +0000 (11:25 +0000)]
Fix Arm big-endian regressions.

gcc/ChangeLog:

* config/arm/arm-protos.h (neon_vcmla_lane_prepare_operands): Remove patternmode.
* config/arm/arm.c (neon_vcmla_lane_prepare_operands): Likewise.
* config/arm/neon.md (neon_vcmla_lane<rot><mode>, neon_vcmla_laneq<rot><mode>,
neon_vcmlaq_lane<rot><mode>): Remove endianness conversion.

From-SVN: r267969

5 years agoExtend locations where to seach for Fortran pre-include.
Martin Liska [Wed, 16 Jan 2019 09:38:21 +0000 (10:38 +0100)]
Extend locations where to seach for Fortran pre-include.

2019-01-16  Martin Liska  <mliska@suse.cz>

* Makefile.in: Set TOOL_INCLUDE_DIR and NATIVE_SYSTEM_HEADER_DIR
for GCC driver.
* config/gnu-user.h (TARGET_F951_OPTIONS): Add 'finclude%s/' as
a new argument.
* gcc.c (add_sysrooted_hdrs_prefix): New function.
(path_prefix_reset): Move up in the source file.
(find_fortran_preinclude_file): Make complex search for the
fortran header files.

From-SVN: r267967

5 years agoAdd self to maintainers list.
Kewen Lin [Wed, 16 Jan 2019 08:23:05 +0000 (08:23 +0000)]
Add self to maintainers list.

2019-01-16  Kewen Lin  <linkw@gcc.gnu.org>

    * MAINTAINERS (Write After Approval): Add myself.

From-SVN: r267965

5 years agoPR libstdc++/88738 treat shared_ptr and unique_ptr more like plain old pointers
Ulrich Drepper [Wed, 16 Jan 2019 08:01:22 +0000 (08:01 +0000)]
PR libstdc++/88738 treat shared_ptr and unique_ptr more like plain old pointers

        PR libstdc++/88738
        Warn about unused comparisons of shared_ptr/unique_ptr
        * include/bits/c++config [_GLIBCXX_NODISCARD]: Define.
        * include/bits/shared_ptr.h: Use it for operator ==, !=,
        <, <=, >, >= for shared_ptr.
        * include/bits/unique_ptr.h: Likewise for unique_ptr.

From-SVN: r267964

5 years ago[libbacktrace] Unify function name preference handling
Tom de Vries [Wed, 16 Jan 2019 07:46:56 +0000 (07:46 +0000)]
[libbacktrace] Unify function name preference handling

Both read_function_entry and read_referenced_name implement a priority scheme
for names.  The priorities are:
- 1st: DW_AT_linkage_name
- 2nd: Name from DW_AT_abstract_origin or DW_AT_specification
- 3rd: DW_AT_name.

Ensure both functions fully adhere to it.

2019-01-16  Tom de Vries  <tdevries@suse.de>

* dwarf.c (read_referenced_name): Don't allow DW_AT_name to override any
name.
(read_function_entry): Same.  Don't allow name found via
DW_AT_abstract_origin or case DW_AT_specification to override linkage
name.

From-SVN: r267963

5 years agoAdd myself
Xiong Hu Luo [Wed, 16 Jan 2019 07:41:23 +0000 (07:41 +0000)]
Add myself

From-SVN: r267962

5 years agoDaily bump.
GCC Administrator [Wed, 16 Jan 2019 00:16:17 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r267961

5 years agogodump.c (go_output_typedef): When outputting a typedef...
Nikhil Benesch [Tue, 15 Jan 2019 23:54:37 +0000 (23:54 +0000)]
godump.c (go_output_typedef): When outputting a typedef...

gcc/:
        * godump.c (go_output_typedef): When outputting a typedef, refer
to the underlying type by its name and not its structure.
gcc/testsuite:
        * gcc.misc-tests/godump-1.c: Add test case for typedef before
struct.

From-SVN: r267958

5 years agoFix ICE on class-template argument deduction (PR c++/88795)
David Malcolm [Tue, 15 Jan 2019 23:29:15 +0000 (23:29 +0000)]
Fix ICE on class-template argument deduction (PR c++/88795)

PR c++/88795 reports an ICE building a function_type for a deduction guide
when the substitution into the function signature fails, due to an
error_mark_node being returned from tsubst_arg_types but not being checked
for.  This error_mark_node gets used as the TYPE_ARG_TYPES, leading to
ICEs in various places that assume this is a TREE_LIST.

This patch checks the result of tsubst_arg_types and propagates the failure
if it returns error_mark_node.  It also adds an assertion to
build_function_type, to fail faster if passed in error_mark_node.

gcc/cp/ChangeLog:
PR c++/88795
* pt.c (build_deduction_guide): Bail out if tsubst_arg_types
fails.

gcc/testsuite/ChangeLog:
PR c++/88795
* g++.dg/template/pr88795.C: New test.

gcc/ChangeLog:
PR c++/88795
* tree.c (build_function_type): Assert that arg_types is not
error_mark_node.

From-SVN: r267957

5 years agoruntime: add padding to FFI type of struct ending with zero-sized field
Ian Lance Taylor [Tue, 15 Jan 2019 23:21:24 +0000 (23:21 +0000)]
runtime: add padding to FFI type of struct ending with zero-sized field

    CL 157557 changes the compiler to add one byte padding to
    non-empty struct ending with a zero-sized field. Add the same
    padding to the FFI type, so reflect.Call works.

    This fixes test/fixedbugs/issue26335.go in the main repo.

    Reviewed-on: https://go-review.googlesource.com/c/158018

From-SVN: r267956

5 years ago[D] Move building of typeof(null) values to a common function.
Iain Buclaw [Tue, 15 Jan 2019 23:02:43 +0000 (23:02 +0000)]
[D] Move building of typeof(null) values to a common function.

gcc/d/ChangeLog:

* d-codegen.cc (build_typeof_null_value): New function.
* d-tree.h (build_typeof_null_value): Declare.
* d-convert.cc (convert_expr): Use build_typeof_null_value.
* expr.cc (ExprVisitor::visit(NullExp)): Likewise.

From-SVN: r267955

5 years agore PR fortran/43136 (Excess copy-in/copy-out with character argument)
Thomas Koenig [Tue, 15 Jan 2019 22:20:26 +0000 (22:20 +0000)]
re PR fortran/43136 (Excess copy-in/copy-out with character argument)

2019-01-15  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/43136
* resolve.c (resolve_array_ref): Add equal_length argument; set it
if the length of the substring equals that of the orignal
variable.
(resolve_ref): Remove the substring if it is equal in length to
the original variable, unless it is an EXPR_SUBSTRING).

2019-01-15  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/43136
* gfortran.dg/actual_array_substr_3.f90: New test.

From-SVN: r267954

5 years agore PR fortran/43072 (unneeded temporary (s=s+f(a)))
Thomas Koenig [Tue, 15 Jan 2019 22:18:55 +0000 (22:18 +0000)]
re PR fortran/43072 (unneeded temporary (s=s+f(a)))

2019-01-15  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/43072
* resolve.c (resolve_array_ref): Add equal_length argument; set it
if the length of the substring equals that of the orignal
variable.
(resolve_ref): Remove the substring if it is equal in length to
the original variable, unless it is an EXPR_SUBSTRING).

2019-01-15  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/43072
* gfortran.dg/actual_array_substr_3.f90: New test.

From-SVN: r267953

5 years agocompiler, runtime: panic on uncomparable map key, even if map is empty
Ian Lance Taylor [Tue, 15 Jan 2019 20:32:39 +0000 (20:32 +0000)]
compiler, runtime: panic on uncomparable map key, even if map is empty

    This ports https://golang.org/cl/155918 from the master repo.

        runtime: panic on uncomparable map key, even if map is empty

        Reorg map flags a bit so we don't need any extra space for the extra flag.

    This is a pre-req for updating libgo to the Go 1.12beta2 release.

    Reviewed-on: https://go-review.googlesource.com/c/157858

From-SVN: r267950

5 years agore PR fortran/81849 (Size of automatic array argument specified by host-associated...
Steven G. Kargl [Tue, 15 Jan 2019 20:17:35 +0000 (20:17 +0000)]
re PR fortran/81849 (Size of automatic array argument specified by host-associated  variable.)

2019-01-15  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/81849
* resolve.c (resolve_symbol): Host associated varaibles can appear
in the specification statement of a RESULT array.

2019-01-15  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/81849
* gfortran.dg/pr81849.f90: New test.

From-SVN: r267948

5 years agotrans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Deal with exprs that are indirect refer...
Paul Thomas [Tue, 15 Jan 2019 19:52:08 +0000 (19:52 +0000)]
trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Deal with exprs that are indirect references; ie.

2019-01-15  Paul Thomas  <pault@gcc.gnu.org>

* trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Deal with exprs
that are indirect references; ie. dummy arguments.

2019-01-15  Paul Thomas  <pault@gcc.gnu.org>

* gfortran.dg/ISO_Fortran_binding_2.c : Change reference to
ISO_Fortran_binding_2.h.

From-SVN: r267946

5 years agore PR c++/88866 (g++.dg/cpp0x/variadic126.C fails with -std=c++2a)
Marek Polacek [Tue, 15 Jan 2019 18:35:01 +0000 (18:35 +0000)]
re PR c++/88866 (g++.dg/cpp0x/variadic126.C fails with -std=c++2a)

PR c++/88866
* g++.dg/cpp0x/variadic126.C: Tweak dg-error.

From-SVN: r267944

5 years ago* g++.dg/ext/utf-cvt-char8_t.C: Pass -fsigned-char.
Jason Merrill [Tue, 15 Jan 2019 18:26:00 +0000 (13:26 -0500)]
* g++.dg/ext/utf-cvt-char8_t.C: Pass -fsigned-char.

From-SVN: r267942

5 years agoPR inline-asm/52813 revisited
Richard Sandiford [Tue, 15 Jan 2019 16:46:54 +0000 (16:46 +0000)]
PR inline-asm/52813 revisited

The original patch for this PR made it an error to list the stack
pointer in the clobber list of an inline asm.  However, the general
feeling seemed to be that going straight to a hard error was too harsh,
since there's quite a bit of existing code that has the clobber.

This patch implements the compromise discussed on IRC of making it
a -Wdeprecated warning instead.

2019-01-15  Richard Sandiford  <richard.sandiford@arm.com>

gcc/
PR inline-asm/52813
* doc/extend.texi: Document that listing the stack pointer in the
clobber list of an asm is a deprecated feature.
* common.opt (Wdeprecated): Moved from c-family/c.opt.
* cfgexpand.c (asm_clobber_reg_is_valid): Issue a -Wdeprecated
warning instead of an error for clobbers of the stack pointer.
Add a note explaining why.

gcc/c-family/
PR inline-asm/52813
* c.opt (Wdeprecated): Move documentation and variable to common.opt.

gcc/d/
PR inline-asm/52813
* lang.opt (Wdeprecated): Reference common.opt instead of c.opt.

gcc/testsuite/
PR inline-asm/52813
* gcc.target/i386/pr52813.c (test1): Turn the diagnostic into a
-Wdeprecated warning and expect a following note:.

From-SVN: r267941

5 years agore PR debug/88046 (ICE in add_data_member_location_attribute at gcc/dwarf2out.c:19237...
Richard Biener [Tue, 15 Jan 2019 16:06:42 +0000 (16:06 +0000)]
re PR debug/88046 (ICE in add_data_member_location_attribute at gcc/dwarf2out.c:19237 since r261885)

2019-01-15  Richard Biener  <rguenther@suse.de>

PR debug/88046
* dwarf2out.c (gen_member_die): Do not generate inheritance
DIEs late.

* g++.dg/lto/pr88046_0.C: New testcase.

From-SVN: r267940

5 years agore PR tree-optimization/88855 (ICE: verify_ssa failed (error: SSA_NAME_OCCURS_IN_ABNO...
Richard Biener [Tue, 15 Jan 2019 15:37:29 +0000 (15:37 +0000)]
re PR tree-optimization/88855 (ICE: verify_ssa failed (error: SSA_NAME_OCCURS_IN_ABNORMAL_PHI should be set))

2019-01-15  Richard Biener  <rguenther@suse.de>

PR tree-optimization/88855
* tree-if-conv.c (combine_blocks): Collect
SSA_NAME_OCCURS_IN_ABNORMAL_PHI from propagated out virtuals.

* gcc.dg/pr88855.c: New testcase.

From-SVN: r267939

5 years agoUpdate value of __cpp_lib_shared_ptr_arrays macro
Jonathan Wakely [Tue, 15 Jan 2019 13:13:11 +0000 (13:13 +0000)]
Update value of __cpp_lib_shared_ptr_arrays macro

* include/bits/shared_ptr_base.h (__cpp_lib_shared_ptr_arrays): Define
as 201611L, because P0497R0 changes are supported.
* include/std/version (__cpp_lib_shared_ptr_arrays): Likewise.

From-SVN: r267938

5 years agoFix more missing or incorrect feature test macros
Jonathan Wakely [Tue, 15 Jan 2019 12:58:19 +0000 (12:58 +0000)]
Fix more missing or incorrect feature test macros

* include/bits/erase_if.h [__cplusplus > 201703L]
(__cpp_lib_erase_if): Only define for C++2a.
* include/std/iterator [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
(__cpp_lib_null_iterators): Define.
* include/std/version [__cplusplus >= 201402L && !_GLIBCXX_DEBUG]
(__cpp_lib_null_iterators): Define.
[__cpp_impl_destroying_delete] (__cpp_lib_destroying_delete): Define.

From-SVN: r267937

5 years agoFix missing or incorrect feature test macros
Jonathan Wakely [Tue, 15 Jan 2019 12:01:12 +0000 (12:01 +0000)]
Fix missing or incorrect feature test macros

* doc/xml/manual/status_cxx2017.xml: Document P0032R3 and P0307R2
status.
* include/bits/stl_uninitialized.h (__cpp_lib_raw_memory_algorithms):
Define.
* include/std/any (__cpp_lib_any): Define as 201606L, because P0032R3
changes are supported.
* include/std/optional (__cpp_lib_optional): Likewise.
* include/std/variant (__cpp_lib_variant): Likewise.
* include/std/version [!__STRICT_ANSI__]
(__cpp_lib_uncaught_exceptions): Define as long integer.
[__cplusplus >= 201703L] (__cpp_lib_any)
(__cpp_lib_raw_memory_algorithms, __cpp_lib_uncaught_exceptions)
(__cpp_lib_variant): Define for C++17.
[__cplusplus >= 201703L] (__cpp_lib_optional): Update value and define
as long integer.
* libsupc++/exception (__cpp_lib_uncaught_exceptions): Define as long
integer.

From-SVN: r267936

5 years ago* doc/xml/manual/status_cxx2020.xml: Update P1123R0 status.
Jonathan Wakely [Tue, 15 Jan 2019 10:34:18 +0000 (10:34 +0000)]
* doc/xml/manual/status_cxx2020.xml: Update P1123R0 status.

From-SVN: r267935

5 years ago[nvptx] Handle assignment to gang-level reduction variable
Tom de Vries [Tue, 15 Jan 2019 10:11:16 +0000 (10:11 +0000)]
[nvptx] Handle assignment to gang-level reduction variable

2019-01-15  Tom de Vries  <tdevries@suse.de>

PR target/80547
* config/nvptx/nvptx.c (nvptx_goacc_reduction_init): Handle
lhs == NULL_TREE for gang-level reduction.

* testsuite/libgomp.oacc-c-c++-common/gang-reduction-var-assignment.c:
New test.

From-SVN: r267934

5 years agore PR ipa/88788 (Infinite loop in malloc_candidate_p_1 since r264838)
Richard Biener [Tue, 15 Jan 2019 09:37:22 +0000 (09:37 +0000)]
re PR ipa/88788 (Infinite loop in malloc_candidate_p_1 since r264838)

2019-01-15  Richard Biener  <rguenther@suse.de>
    Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>

PR ipa/88788
* ipa-pure-const.c (malloc_candidate_p_1): Add parameter visited and
return true if SSA_NAME is already marked in visited bitmap.
(malloc_candidate_p): Pass visited to malloc_candidate_p_1.

Co-Authored-By: Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
From-SVN: r267933

5 years agodecl.c (start_decl): Improve error location.
Paolo Carlini [Tue, 15 Jan 2019 09:36:43 +0000 (09:36 +0000)]
decl.c (start_decl): Improve error location.

/cp
2019-01-15  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (start_decl): Improve error location.
* decl2.c (grokfield): Likewise.

/testsuite
2019-01-15  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/diagnostic/typedef-initialized.C: New.

/cp
2019-01-15  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (grokdeclarator): Move further up the location_t loc
declaration and use the location when building a TYPE_DECL for
a typedef name.
* decl2.c (grokbitfield): Use DECL_SOURCE_LOCATION in the error
about an ill-formed bit-field as typedef.

/testsuite
2019-01-15  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/diagnostic/bitfld3.C: New.

From-SVN: r267932

5 years agore PR tree-optimization/88775 (Optimize std::string assignment)
Jakub Jelinek [Tue, 15 Jan 2019 08:11:00 +0000 (09:11 +0100)]
re PR tree-optimization/88775 (Optimize std::string assignment)

PR tree-optimization/88775
* match.pd (cmp (convert1?@2 addr@0) (convert2? addr@1)): Optimize
equal == 0 equality pointer comparisons some more if compared in
integral types and either one points to an automatic var and the
other to a global, or we can prove at least one points to the middle
or both point to start or both point to end.

* gcc.dg/tree-ssa/pr88775-1.c: New test.
* gcc.dg/tree-ssa/pr88775-2.c: New test.

From-SVN: r267931

5 years agoLower sampling rate for autofdo bootstrap
Andi Kleen [Tue, 15 Jan 2019 03:49:45 +0000 (03:49 +0000)]
Lower sampling rate for autofdo bootstrap

autofdo create_gcov uses a lot of memory for large sample files.
Since gcc runs quite long the sample files generated during
the bootstrap are fairly ig.

Currently I can't even build make autoprofiledbootstrap on my system at
home because create_gcov needs more than 12GB and runs out of memory.

This should probably be fixed in create_gcov, but for now
lowering the sampling rate works well enough for me. The bootstrap
run is long enough that it gets good enough data in any case.

gcc/:
2019-01-14  Andi Kleen  <ak@linux.intel.com>

* Makefile.in: Lower autofdo sampling rate by 10x.
* Makefile.tpl: Dito.

From-SVN: r267930

5 years agoDaily bump.
GCC Administrator [Tue, 15 Jan 2019 00:16:22 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r267929

5 years agoPR c++/88825 - ICE with bogus function return type deduction.
Marek Polacek [Mon, 14 Jan 2019 22:01:24 +0000 (22:01 +0000)]
PR c++/88825 - ICE with bogus function return type deduction.

* typeck.c (can_do_nrvo_p): Check error_mark_node.

* g++.dg/cpp1y/auto-fn55.C: New test.

From-SVN: r267926

5 years agoc-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision and __cpp_nontyp...
Jakub Jelinek [Mon, 14 Jan 2019 20:12:11 +0000 (21:12 +0100)]
c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision and __cpp_nontype_template_parameter_auto.

* c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
and __cpp_nontype_template_parameter_auto.  Add a comment that
__cpp_template_auto is deprecated.

* g++.dg/cpp1z/feat-cxx1z.C: Add tests for
__cpp_guaranteed_copy_elision and __cpp_nontype_template_parameter_auto
feature test macros.
* g++.dg/cpp2a/feat-cxx2a.C: Likewise.

From-SVN: r267925

5 years agoPR c++/88830 - ICE with abstract class.
Marek Polacek [Mon, 14 Jan 2019 20:09:10 +0000 (20:09 +0000)]
PR c++/88830 - ICE with abstract class.

* decl2.c (maybe_emit_vtables): Check CLASSTYPE_LAZY_DESTRUCTOR.
Fix formatting.

* g++.dg/other/abstract7.C: New test.

From-SVN: r267924

5 years agoImplement P0482R5, char8_t: A type for UTF-8 characters and strings
Tom Honermann [Mon, 14 Jan 2019 19:55:51 +0000 (19:55 +0000)]
Implement P0482R5, char8_t: A type for UTF-8 characters and strings

gcc/cp/
* cvt.c (type_promotes_to): Handle char8_t promotion.
* decl.c (grokdeclarator): Handle invalid type specifier
combinations involving char8_t.
* lex.c (init_reswords): Add char8_t as a reserved word.
* mangle.c (write_builtin_type): Add name mangling for char8_t (Du).
* parser.c (cp_keyword_starts_decl_specifier_p)
(cp_parser_simple_type_specifier): Recognize char8_t as a simple
type specifier.
(cp_parser_string_literal): Use char8_array_type_node for the type
of CPP_UTF8STRING.
(cp_parser_set_decl_spec_type): Tolerate char8_t typedefs in system
headers.
* rtti.c (emit_support_tinfos): type_info support for char8_t.
* tree.c (char_type_p): Recognize char8_t as a character type.
* typeck.c (string_conv_p): Handle conversions of u8 string
literals of char8_t type.
(check_literal_operator_args): Handle UDLs with u8 string literals
of char8_t type.
* typeck2.c (ordinary_char_type_p): New.
(digest_init_r): Disallow initializing a char array with a u8 string
literal.
gcc/c-family/
* c-common.c (c_common_reswords): Add char8_t.
(fix_string_type): Use char8_t for the type of u8 string literals.
(c_common_get_alias_set): char8_t doesn't alias.
(c_common_nodes_and_builtins): Define char8_t as a builtin type in
C++.
(c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
(keyword_begins_type_specifier): Add RID_CHAR8.
* c-common.h (rid): Add RID_CHAR8.
(c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
Define char8_type_node and char8_array_type_node.
* c-cppbuiltin.c (cpp_atomic_builtins): Predefine
__GCC_ATOMIC_CHAR8_T_LOCK_FREE.
(c_cpp_builtins): Predefine __cpp_char8_t.
* c-lex.c (lex_string): Use char8_array_type_node as the type of
CPP_UTF8STRING.
(lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
* c-opts.c: If not otherwise specified, enable -fchar8_t when
targeting C++2a.
* c.opt: Add the -fchar8_t command line option.
libiberty/
* cp-demangle.c (cplus_demangle_builtin_types)
(cplus_demangle_type): Add name demangling for char8_t (Du).
* cp-demangle.h: Increase D_BUILTIN_TYPE_COUNT to accommodate the
new char8_t type.

From-SVN: r267923

5 years agoPR target/88638 - FAIL: fsf-nsstring-format-1.s on darwin
Martin Sebor [Mon, 14 Jan 2019 18:44:00 +0000 (18:44 +0000)]
PR target/88638 - FAIL: fsf-nsstring-format-1.s on darwin

gcc/c-family/ChangeLog:

PR target/88638
* c-attribs.c (positional_argument): Call valid_format_string_type_p
and issue errors if it fails.
* c-common.h (valid_format_string_type_p): Declare.
* c-format.c (valid_stringptr_type_p): Rename...
(valid_format_string_type_p): ...to this and make extern.
(handle_format_arg_attribute): Adjust to new name.
(check_format_string): Same.

gcc/testsuite/ChangeLog:

PR target/88638
* gcc.dg/format/attr-8.c: New test.
* gcc.dg/darwin-cfstring-format-1.c: Adjust diagnostics.
* gcc.dg/format/attr-3.c: Same.
* obj-c++.dg/fsf-nsstring-format-1.mm: Same.
* objc.dg/fsf-nsstring-format-1.m: Same.

gcc/ChangeLog:

PR target/88638
* doc/extend.texi (Darwin Format Checks): Clarify.

From-SVN: r267922

5 years agoFix location of tls_wrapper_fn (PR gcov-profile/88263).
Martin Liska [Mon, 14 Jan 2019 18:40:34 +0000 (19:40 +0100)]
Fix location of tls_wrapper_fn (PR gcov-profile/88263).

2019-01-14  Martin Liska  <mliska@suse.cz>

PR gcov-profile/88263
* decl2.c (get_tls_wrapper_fn): Use DECL_SOURCE_LOCATION
as location of the TLS wrapper.
2019-01-14  Martin Liska  <mliska@suse.cz>

PR gcov-profile/88263
* g++.dg/gcov/pr88263-2.C: New test.

From-SVN: r267921

5 years agoinvoke.texi (-Wmemset-transposed-args): Fix typos, adjust wording.
Martin Sebor [Mon, 14 Jan 2019 18:26:32 +0000 (11:26 -0700)]
invoke.texi (-Wmemset-transposed-args): Fix typos, adjust wording.

gcc/ChangeLog:

* invoke.texi (-Wmemset-transposed-args): Fix typos, adjust wording.

From-SVN: r267920

5 years agogenmatch.c (dt_simplify::gen_1): Change dumping dependent on whether we are in (simpl...
Richard Biener [Mon, 14 Jan 2019 13:11:43 +0000 (13:11 +0000)]
genmatch.c (dt_simplify::gen_1): Change dumping dependent on whether we are in (simplify ...) or (match ...) context.

2019-01-14  Richard Biener  <rguenther@suse.de>

* genmatch.c (dt_simplify::gen_1): Change dumping dependent on
whether we are in (simplify ...) or (match ...) context.

From-SVN: r267917

5 years agore PR rtl-optimization/88796 (-fstack-protector* kills RTL DSE opportunities)
Jakub Jelinek [Mon, 14 Jan 2019 12:01:01 +0000 (13:01 +0100)]
re PR rtl-optimization/88796 (-fstack-protector* kills RTL DSE opportunities)

PR rtl-optimization/88796
* emit-rtl.h (struct rtl_data): Add stack_protect_guard_decl field.
* cfgexpand.c (stack_protect_prologue): Initialize
crtl->stack_protect_guard_decl.
* function.c (stack_protect_epilogue): Use it instead of calling
targetm.stack_protect_guard again.
* dse.c (check_mem_read_rtx): Ignore MEM_VOLATILE_P reads from
MEMs with MEM_EXPR equal to crtl->stack_protect_guard or
crtl->stack_protect_guard_decl.
* config/i386/i386.c (ix86_stack_protect_guard): Set TREE_THIS_VOLATILE
on the returned MEM_EXPR.

* gcc.target/i386/pr88796.c: New test.

From-SVN: r267916

5 years agoUndo undesirable part of r267850 2019-01-11 commit.
Jakub Jelinek [Mon, 14 Jan 2019 10:47:09 +0000 (11:47 +0100)]
Undo undesirable part of r267850 2019-01-11 commit.

From-SVN: r267914

5 years ago[D] Merge upstream dmd cd2034cd7
Iain Buclaw [Mon, 14 Jan 2019 10:38:00 +0000 (10:38 +0000)]
[D] Merge upstream dmd cd2034cd7

One fix in the asm statement parser to stop parsing if the end of the
statement has been reached, and moves all inline asm tests to gdc.dg.
These being adjusted where necessary to test the GCC style instead.

gcc/testsuite/ChangeLog:

2019-01-14  Iain Buclaw  <ibuclaw@gdcproject.org>

* gdc.dg/asm1.d: New test.
* gdc.dg/asm2.d: New test.
* gdc.dg/asm3.d: New test.
* gdc.dg/asm4.d: New test.
* lib/gdc.exp (gdc_init): Set gcc_error_prefix and gcc_warning_prefix.

From-SVN: r267913

5 years agore PR libfortran/88776 (Namelist read from stdin: loss of data)
Jerry DeLisle [Mon, 14 Jan 2019 00:22:00 +0000 (00:22 +0000)]
re PR libfortran/88776 (Namelist read from stdin: loss of data)

2019-01-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

PR libfortran/88776
* io/open.c (newunit): Free format buffer if the unit specified is for
stdin, stdout, or stderr.

* gfortran.dg/namelist_96.f90: New test.

From-SVN: r267910

5 years agoDaily bump.
GCC Administrator [Mon, 14 Jan 2019 00:16:12 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r267909

5 years agore PR fortran/88803 (gfortran documentation warning: '.' or ',' must follow @xref)
Dominique d'Humieres [Sun, 13 Jan 2019 19:18:46 +0000 (20:18 +0100)]
re PR fortran/88803 (gfortran documentation warning: '.' or ',' must follow @xref)

2019-01-13  Dominique d'Humieres  <dominiq@gcc.gnu.org>

PR fortran/88803
* gfortran.texi: Replace @xref with @ref and adjust the sentence.

From-SVN: r267906

5 years agore PR fortran/57992 (Pointless packing of contiguous arrays for simply contiguous...
Thomas Koenig [Sun, 13 Jan 2019 14:57:39 +0000 (14:57 +0000)]
re PR fortran/57992 (Pointless packing of contiguous arrays for simply contiguous functions results as actual arguments)

2019-01-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/57992
* trans-array.c (gfc_conv_array_parameter):  Do not pack/unpack
functions with contiguous results.

2019-01-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/59345
* gfortran.dg/internal_pack_18.f90: New test.

From-SVN: r267905

5 years agoC-family: Replace "may may" with "may" in warning message
H.J. Lu [Sun, 13 Jan 2019 12:53:47 +0000 (12:53 +0000)]
C-family: Replace "may may" with "may" in warning message

gcc/c-family/

* c-warn.c (warn_for_address_or_pointer_of_packed_member):
Replace "may may" with "may" in warning message.

gcc/testsuite/

* gcc.dg/pr51628-20.c: Updated.
* gcc.dg/pr51628-21.c: Likewise.
* gcc.dg/pr51628-25.c: Likewise.

From-SVN: r267904

5 years agore PR fortran/59345 (_gfortran_internal_pack on compiler generated temps)
Thomas Koenig [Sun, 13 Jan 2019 11:06:03 +0000 (11:06 +0000)]
re PR fortran/59345 (_gfortran_internal_pack on compiler generated temps)

2019-01-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/59345
* trans-array.c (gfc_conv_array_parameter): Remove TODO.  Do not
pack/unpack results of functions which return an explicit-shaped
or allocatable array.

2019-01-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/59345
* gfortran.dg/internal_pack_17.f90: New test.
* gfortran.dg/alloc_comp_auto_array_3.f90: Adjust number of calls
to builtin_free.

From-SVN: r267903

5 years agore PR fortran/61765 ([F03] Rejects valid BIND(C) ENTRY)
Steven G. Kargl [Sun, 13 Jan 2019 04:02:46 +0000 (04:02 +0000)]
re PR fortran/61765 ([F03] Rejects valid BIND(C) ENTRY)

2019-01-12  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/61765
* resolve.c (gfc_verify_binding_labels): Break if-elseif-elseif
structure into independent if's with a return to simplify logic.
Avoid a check for ENTRY name with bind(c).

2019-01-12  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/61765
* gfortran.dg/pr61765.f90: New test.

From-SVN: r267902

5 years agoDaily bump.
GCC Administrator [Sun, 13 Jan 2019 00:16:28 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r267901

5 years agore PR libfortran/88776 (Namelist read from stdin: loss of data)
Jerry DeLisle [Sat, 12 Jan 2019 23:06:47 +0000 (23:06 +0000)]
re PR libfortran/88776 (Namelist read from stdin: loss of data)

2019-01-12  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

PR libfortran/88776
* io/list_read.c (namelist_read): Use nml_err_ret path on read error
not based on stdin_unit.

From-SVN: r267898

5 years ago[nvptx] Enable setting vector length using -fopenacc-dim -- testcases
Tom de Vries [Sat, 12 Jan 2019 22:19:31 +0000 (22:19 +0000)]
[nvptx] Enable setting vector length using -fopenacc-dim -- testcases

Add some test-cases that set vector length using -fopenacc-dim.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* testsuite/libgomp.oacc-c-c++-common/pr85486-2.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-2.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-5.c: New test.
* testsuite/libgomp.oacc-fortran/gemm-2.f90: New test.

From-SVN: r267897

5 years ago[nvptx] Enable setting vector length using -fopenacc-dim
Tom de Vries [Sat, 12 Jan 2019 22:19:15 +0000 (22:19 +0000)]
[nvptx] Enable setting vector length using -fopenacc-dim

Enable setting vector length using -fopenacc-dim, f.i. -fopenacc-dim=::128.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* config/nvptx/nvptx.c (nvptx_goacc_validate_dims_1): Alow setting
vector length using -fopenacc-dim.

* plugin/plugin-nvptx.c (nvptx_exec): Update error message.

From-SVN: r267896

5 years ago[nvptx] Add vector_length 64 test-cases
Tom de Vries [Sat, 12 Jan 2019 22:19:02 +0000 (22:19 +0000)]
[nvptx] Add vector_length 64 test-cases

Add some test-cases using vector_length 64.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* testsuite/libgomp.oacc-c-c++-common/vector-length-64-1.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-64-2.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-64-3.c: New test.

From-SVN: r267895

5 years ago[nvptx] Force vl32 if calling vector-partitionable routines -- test-cases
Tom de Vries [Sat, 12 Jan 2019 22:18:50 +0000 (22:18 +0000)]
[nvptx] Force vl32 if calling vector-partitionable routines -- test-cases

Add test-cases for "[nvptx] Force vl32 if calling vector-partitionable
routines".

2019-01-12  Tom de Vries  <tdevries@suse.de>

PR target/85486
* testsuite/libgomp.oacc-c-c++-common/pr85486-3.c: New test.
* testsuite/libgomp.oacc-c-c++-common/pr85486.c: New test.

From-SVN: r267894

5 years ago[nvptx] Don't emit barriers for empty loops -- test-cases
Tom de Vries [Sat, 12 Jan 2019 22:18:39 +0000 (22:18 +0000)]
[nvptx] Don't emit barriers for empty loops -- test-cases

Add test-cases for PR85381.

2019-01-12  Tom de Vries  <tdevries@suse.de>

PR target/85381
* testsuite/libgomp.oacc-c-c++-common/pr85381-5.c: New test.
* testsuite/libgomp.oacc-c-c++-common/pr85381.c: New test.

From-SVN: r267893

5 years ago[nvptx] Enable large vectors -- reduction testcases
Tom de Vries [Sat, 12 Jan 2019 22:18:27 +0000 (22:18 +0000)]
[nvptx] Enable large vectors -- reduction testcases

Add various reduction test-cases with vector length 128.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* testsuite/libgomp.oacc-c-c++-common/vred2d-128.c: New test.
* testsuite/libgomp.oacc-fortran/gemm.f90: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-10.c: New test.

From-SVN: r267892

5 years ago[nvptx] Enable large vectors -- test-cases
Tom de Vries [Sat, 12 Jan 2019 22:18:11 +0000 (22:18 +0000)]
[nvptx] Enable large vectors -- test-cases

Add various test-cases with vector length 128.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* testsuite/libgomp.oacc-c-c++-common/vector-length-128-7.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-4.c: New test.
* testsuite/libgomp.oacc-c-c++-common/vector-length-128-6.c: New test.

From-SVN: r267891

5 years ago[nvptx] Update insufficient launch message for variable vector_length
Tom de Vries [Sat, 12 Jan 2019 22:18:00 +0000 (22:18 +0000)]
[nvptx] Update insufficient launch message for variable vector_length

Update message in nvptx libgomp plugin about insufficient resources to launch
kernel, to accommodate for the fact the vector_length can now be variable.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* plugin/plugin-nvptx.c (nvptx_exec): Update insufficient hardware
resources diagnostic.

From-SVN: r267890

5 years ago[nvptx] Enable large vectors
Tom de Vries [Sat, 12 Jan 2019 22:17:42 +0000 (22:17 +0000)]
[nvptx] Enable large vectors

Allow vector_length clauses to accept values larger than warp size.  Note that
this does not enable setting vector_length to values larger than warp size using
-fopenacc-dim.

2019-01-12  Tom de Vries  <tdevries@suse.de>

* config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Take larger vector
lengths into account.

* testsuite/libgomp.oacc-c-c++-common/vector-length-128-1.c: Expect
vector length to be 128.
* testsuite/libgomp.oacc-c-c++-common/parallel-dims.c: Expect vector
length 2097152 to be reduced to 1024 instead of 32.

From-SVN: r267889

5 years agodecl.c (cp_finish_decl): Improve error location.
Paolo Carlini [Sat, 12 Jan 2019 21:59:50 +0000 (21:59 +0000)]
decl.c (cp_finish_decl): Improve error location.

/cp
2019-01-12  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (cp_finish_decl): Improve error location.
* decl2.c (grokfield): Likewise, improve two locations.

/testsuite
2019-01-12  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/cpp0x/pr62101.C: Test locations too.
* g++.dg/inherit/pure1.C: Likewise.

From-SVN: r267888

5 years agodecl.c (cp_finish_decl): Improve error location.
Paolo Carlini [Sat, 12 Jan 2019 21:59:03 +0000 (21:59 +0000)]
decl.c (cp_finish_decl): Improve error location.

/cp
2019-01-12  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (cp_finish_decl): Improve error location.
* decl2.c (grokfield): Likewise, improve two locations.

/testsuite
2019-01-12  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/cpp0x/pr62101.C: Test locations too.
* g++.dg/inherit/pure1.C: Likewise.

From-SVN: r267887

5 years agognu.h (TARGET_THREAD_SSP_OFFSET): Define.
Svante Signell [Sat, 12 Jan 2019 21:17:56 +0000 (21:17 +0000)]
gnu.h (TARGET_THREAD_SSP_OFFSET): Define.

* config/i386/gnu.h (TARGET_THREAD_SSP_OFFSET): Define.
(TARGET_CAN_SPLIT_STACK): Define.
(TARGET_THREAD_SPLIT_STACK_OFFSET): Define.

From-SVN: r267886

5 years agoDocument merge process for dmd, druntime and phobos.
Iain Buclaw [Sat, 12 Jan 2019 19:50:41 +0000 (19:50 +0000)]
Document merge process for dmd, druntime and phobos.

gcc/d/ChangeLog:

* README.gcc: New file.

libphobos/ChangeLog:

* README.gcc: New file.

From-SVN: r267885

5 years agoISO_Fortran_binding_2.f90: Remove because of reports of ICEs.
Paul Thomas [Sat, 12 Jan 2019 18:34:30 +0000 (18:34 +0000)]
ISO_Fortran_binding_2.f90: Remove because of reports of ICEs.

2019-01-12  Paul Thomas  <pault@gcc.gnu.org>

* gfortran.dg/ISO_Fortran_binding_2.f90 : Remove because of
reports of ICEs.
* gfortran.dg/ISO_Fortran_binding_2.c : Ditto.

From-SVN: r267884

5 years ago* params.def (inline-unit-growth): Set to 40.
Jan Hubicka [Sat, 12 Jan 2019 18:18:23 +0000 (19:18 +0100)]
* params.def (inline-unit-growth): Set to 40.

From-SVN: r267883

5 years agotree-ssa-loop-ivopts.c (find_inv_vars): Fix a comment typo.
Jakub Jelinek [Sat, 12 Jan 2019 16:55:45 +0000 (17:55 +0100)]
tree-ssa-loop-ivopts.c (find_inv_vars): Fix a comment typo.

* tree-ssa-loop-ivopts.c (find_inv_vars): Fix a comment typo.

* c-typeck.c (convert_for_assignment): Fix a comment typo.

From-SVN: r267882

5 years agogfortran.texi: Add description in sections on TS 29113 and further interoperability...
Paul Thomas [Sat, 12 Jan 2019 15:25:52 +0000 (15:25 +0000)]
gfortran.texi: Add description in sections on TS 29113 and further interoperability with C.

2019-01-12  Paul Thomas  <pault@gcc.gnu.org>

* gfortran.texi : Add description in sections on TS 29113 and
further interoperability with C.
* trans-array.c (gfc_conv_descriptor_attribute): New function.
(gfc_get_dataptr_offset): Remove static function attribute.
* trans-array.h : Add prototypes for above functions.
* trans-decl.c : Add declarations for the library functions
cfi_desc_to_gfc_desc and gfc_desc_to_cfi_desc.
* trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): New function.
(gfc_conv_procedure_call): Call it for scalar and array actual
arguments, when the formal arguments are bind_c with assumed
shape or assumed rank.
* trans.h : External declarations for gfor_fndecl_cfi_to_gfc
and gfor_fndecl_gfc_to_cfi.

2019-01-12  Paul Thomas  <pault@gcc.gnu.org>

* gfortran.dg/ISO_Fortran_binding_1.f90 : New test.
* gfortran.dg/ISO_Fortran_binding_1.c : Auxilliary file for test.
* gfortran.dg/ISO_Fortran_binding_2.f90 : New test.
* gfortran.dg/ISO_Fortran_binding_2.c : Auxilliary file for test.
* gfortran.dg/bind_c_array_params_2.f90 : Change search string
for dump tree scan.

2019-01-12  Paul Thomas  <pault@gcc.gnu.org>

* ISO_Fortran_binding.h : New file.
* Makefile.am : Include ISO_Fortran_binding.c in the list of
files to compile.
* Makefile.in : Regenerated.
* gfortran.map : Add _gfortran_cfi_desc_to_gfc_desc,
_gfortran_gfc_desc_to_cfi_desc and the CFI API functions.
* runtime/ISO_Fortran_binding.c : New file containing the new
functions added to the map.

From-SVN: r267881