[Bug fortran/92736] Error when using a variable from a module in a submodule and its parent module.

2019-12-01 Thread chinoune.mehdi at hotmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92736

--- Comment #4 from Chinoune  ---
(In reply to Steve Kargl from comment #3)
> On Sun, Dec 01, 2019 at 05:41:21AM +, chinoune.mehdi at hotmail dot com
> wrote:
> > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92736
> > 
> > --- Comment #2 from Chinoune  ---
> > (In reply to kargl from comment #1)
> > > Not sure the code is conforming, and don't have time to
> > > investigate (unless someone is willing to cough up $$).
> > > 
> > > Workaround 1.  Remove "use m1, only : i" in submodule(m2)
> > > as 'i' is already available from module m2.
> > > 
> > > Workaround 2.  Use Fortran's renaming scheme.  Thus, change
> > > the submodule(m2) to 'Use m1, only : j=>i'
> > 
> > You introduced a regression and it is your duty to fix it.
> 
> When it comes to gfortran, I have no duty to you or anyone else.
> I have neither the time nor now the inclination to look at this
> bug (unless someone coughs up  (price just went up ;)).

With $$$ I can get a the best Fortran Compiler from Intel. Why should I pay you
 for just one little bug?!
And I didn't complain about the bug, I did just report it. If you don't like
people reporting bugs in open-source programs then you should better leave.

[Bug c++/92743] New: doc: -Wattribute-alias improperly indexed

2019-12-01 Thread akim.demaille at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92743

Bug ID: 92743
   Summary: doc: -Wattribute-alias improperly indexed
   Product: gcc
   Version: 9.2.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: akim.demaille at gmail dot com
  Target Milestone: ---

The documentation indexes the option with the leading `-`, contrary to the rest
of the documentation.

See
https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc/Option-Index.html#Option-Index.

[Bug c++/92743] doc: -Wattribute-alias improperly indexed

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92743

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2019-12-01
 CC||marxin at gcc dot gnu.org
   Assignee|unassigned at gcc dot gnu.org  |marxin at gcc dot 
gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Martin Liška  ---
Let me fix it.

[Bug tree-optimization/92742] [10 Regression] ICE in info_for_reduction, at tree-vect-loop.c:4367

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92742

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2019-12-01
 CC||marxin at gcc dot gnu.org
  Known to work||9.2.0
   Assignee|unassigned at gcc dot gnu.org  |rguenth at gcc dot 
gnu.org
   Target Milestone|--- |10.0
 Ever confirmed|0   |1
  Known to fail||10.0

--- Comment #1 from Martin Liška  ---
Confirmed, started with r277882.

[Bug target/92744] New: [10 Regression] error: insn does not satisfy its constraints since r278439

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92744

Bug ID: 92744
   Summary: [10 Regression] error: insn does not satisfy its
constraints since r278439
   Product: gcc
   Version: 9.0
Status: UNCONFIRMED
  Keywords: ice-on-valid-code
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: marxin at gcc dot gnu.org
CC: jakub at gcc dot gnu.org
  Target Milestone: ---
  Host: x86_64-pc-linux-gnu

I see following ICE:

$ cat return.ii
class A {
public:
  typedef float __dec32 __attribute__((mode(SD)));
  __dec32 __val;
};
bool operator!=(A p1, A p2) { return p1.__val != p2.__val; }
void fn1();
void fn2(A p1, A p2) {
  if (p1 != p2)
fn1();
}

$ g++ return.ii -fno-tree-ccp -Os -c
return.ii: In function ‘void fn2(A, A)’:
return.ii:11:1: error: insn does not satisfy its constraints:
   11 | }
  | ^
(insn 43 4 9 2 (parallel [
(set (reg:SI 21 xmm1 [ p2 ])
(reg:SI 20 xmm0 [orig:84 p1 ] [84]))
(set (reg:SI 20 xmm0 [orig:84 p1 ] [84])
(reg:SI 21 xmm1 [ p2 ]))
]) "return.ii":9:3 78 {*swapsi}
 (nil))
during RTL pass: cprop_hardreg
return.ii:11:1: internal compiler error: in extract_constrain_insn, at
recog.c:2195
0x7e973a _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
/home/marxin/Programming/gcc/gcc/rtl-error.c:108
0x7e9760 _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
/home/marxin/Programming/gcc/gcc/rtl-error.c:118
0x7e79e3 extract_constrain_insn(rtx_insn*)
/home/marxin/Programming/gcc/gcc/recog.c:2195
0x109c6ef copyprop_hardreg_forward_1
/home/marxin/Programming/gcc/gcc/regcprop.c:802
0x109d50e execute
/home/marxin/Programming/gcc/gcc/regcprop.c:1367
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See  for instructions.

[Bug target/92744] [10 Regression] error: insn does not satisfy its constraints since r278439

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92744

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2019-12-01
  Known to work||9.2.0
Version|9.0 |10.0
   Target Milestone|--- |10.0
 Ever confirmed|0   |1
  Known to fail||10.0

[Bug tree-optimization/92740] induct2 (from polyhedron) regresses 267% with -O2 -ftree-vectorize -ftree-slp-vectorize -fvect-cost-modes=dynamic compared to -O2

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92740

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |WAITING
   Last reconfirmed||2019-12-01
 CC||marxin at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #2 from Martin Liška  ---
Can you please point to LNT number where you see it?

[Bug tree-optimization/92738] [10 regression] Large code size growth for -O2 binaries between 2019-05-19...2019-05-29

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92738

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2019-12-01
 CC||marxin at gcc dot gnu.org
  Known to work||9.2.0
 Blocks||26163
   Target Milestone|--- |10.0
 Ever confirmed|0   |1
  Known to fail||10.0


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26163
[Bug 26163] [meta-bug] missed optimization in SPEC (2k17, 2k and 2k6 and 95)

[Bug tree-optimization/92741] [10 Regression] ICE: verify_gimple failed (error: invalid vector types in nop conversion)

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92741

Martin Liška  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2019-12-01
 CC||marxin at gcc dot gnu.org
  Known to work||9.2.0
   Assignee|unassigned at gcc dot gnu.org  |rsandifo at gcc dot 
gnu.org
   Target Milestone|--- |10.0
 Ever confirmed|0   |1
  Known to fail||10.0

--- Comment #1 from Martin Liška  ---
Confirmed, started with r278245.

[Bug target/92744] [10 Regression] error: insn does not satisfy its constraints since r278439

2019-12-01 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92744

Jakub Jelinek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek  ---
Honza mentioned this too.  I'll have a look.

[Bug c++/91369] Implement P0784R7: constexpr new

2019-12-01 Thread lutztonineubert at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91369

Toni Neubert  changed:

   What|Removed |Added

 CC||lutztonineubert at gmail dot 
com

--- Comment #21 from Toni Neubert  ---
I get: 'allocated storage has not been deallocated' when using
prvalues/xvalues:

struct A {
constexpr A() : p{new int} {}
constexpr ~A() {
delete p;
}
int* p;
};

constexpr bool test() {
A{};
return true;
}

constexpr auto res = test();
static_assert(res);

[Bug c++/92743] doc: -Wattribute-alias improperly indexed

2019-12-01 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92743

Eric Gallager  changed:

   What|Removed |Added

   Keywords||diagnostic, documentation,
   ||easyhack
 CC||egallager at gcc dot gnu.org
   Severity|normal  |trivial

[Bug tree-optimization/92738] [10 regression] Large code size growth for -O2 binaries between 2019-05-19...2019-05-29

2019-12-01 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92738

--- Comment #3 from Martin Liška  ---
One of the big changes that caused that:
https://lnt.opensuse.org/db_default/v4/SPEC/graph?plot.0=21.264.4

[Bug c++/92745] New: Initializing array with vec4 results in compile error

2019-12-01 Thread milasudril at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92745

Bug ID: 92745
   Summary: Initializing array with vec4 results in compile error
   Product: gcc
   Version: 8.3.0
   URL: https://gcc.godbolt.org/z/sxvR3G
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: milasudril at gmail dot com
  Target Milestone: ---
Target: Any

In GCC 8.3 and later the following code fails to compile:

#include 

template
using vec4_t __attribute__((vector_size(4*sizeof(T = float;

auto transpose(std::array, 4> col)
{
std::array, 4> ret{vec4_t{col[0][0], col[1][0],
col[2][0], col[3][0]},
vec4_t{col[0][1], col[1][1],
col[2][1], col[3][1]},
vec4_t{col[0][2], col[1][2],
col[2][2], col[3][2]},
vec4_t{col[0][3], col[1][3],
col[2][3], col[3][3]}};
return ret;
}


x86-64 gcc 8.3
-O3
1

x86-64 gcc 8.3 - 1240ms
: In function 'auto transpose(std::array<__vector(4) float, 4>)':

:11:102: error: too many initializers for 'std::array<__vector(4)
float, 4>'

 vec4_t{col[0][3],
col[1][3], col[2][3], col[3][3]}};

   
  ^

Compiler returned: 1

It compiles with GCC 8.2 and earlier, and also the latest version of clang.

[Bug target/92723] [10 Regression] ICE in expand_shift_1, at expmed.c:2635

2019-12-01 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92723

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jamborm at gcc dot gnu.org
   Target Milestone|--- |10.0
Summary|ICE in expand_shift_1, at   |[10 Regression] ICE in
   |expmed.c:2635   |expand_shift_1, at
   ||expmed.c:2635

--- Comment #4 from Jakub Jelinek  ---
ICEs since r275982.

[Bug 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 Thread jvdelisle at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90374

--- Comment #7 from Jerry DeLisle  ---
(In reply to anlauf from comment #6)
> (In reply to Jerry DeLisle from comment #5)
> > Author: jvdelisle
> > Date: Thu Nov 28 18:33:20 2019
> > New Revision: 278817
> 
> Jerry,
> 
> your change to format.c generates a warning here:
> 
> ../../../trunk/libgfortran/io/format.c: In function 'parse_format_list':
> ../../../trunk/libgfortran/io/format.c:1029:7: warning: suggest explicit
> braces to avoid am
> biguous 'else' [-Wdangling-else]
>  1029 |if (t != FMT_POSINT)
>   |   ^
> 
> Looking at the context:
> 
> t = format_lex (fmt);
> if (t != FMT_POSINT)
>   if (t == FMT_ZERO)
> {
> 
> this seems to make sense (to me).  Do you plan to add {}?

Hi Herald, I saw that also, so plan to add the braces.

[Bug testsuite/92622] FAIL: gcc.dg/Warray-bounds-22.c on ILP32: missing warnings for VLA on lines 67 and 69

2019-12-01 Thread sandra at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92622

sandra at gcc dot gnu.org changed:

   What|Removed |Added

 CC||sandra at gcc dot gnu.org

--- Comment #2 from sandra at gcc dot gnu.org ---
I've been seeing this random failure on nios2-elf and nios2-linux-gnu, too.

[Bug fortran/82904] [8/9/10 Regression] ICE in make_ssa_name_fn, at tree-ssanames.c:261

2019-12-01 Thread anlauf at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82904

anlauf at gcc dot gnu.org changed:

   What|Removed |Added

 CC||anlauf at gcc dot gnu.org

--- Comment #6 from anlauf at gcc dot gnu.org ---
Do I understand Richard's comment correctly that we should get for

   character(:), allocatable, save :: x

in the dump sth. like:

  static integer(kind=4) _F.x = 0;
  static character(kind=1)[1:_F.x] * x = 0B;

i.e. the length should be initialized to 0?

[Bug 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 Thread jvdelisle at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90374

--- Comment #8 from Jerry DeLisle  ---
Author: jvdelisle
Date: Sun Dec  1 22:29:43 2019
New Revision: 278886

URL: https://gcc.gnu.org/viewcvs?rev=278886&root=gcc&view=rev
Log:
2019-12-01  Jerry DeLisle  

PR fortran/90374
* io/format.c (parse_format_list): Add braces to disambiguate
conditional.

Modified:
trunk/libgfortran/ChangeLog
trunk/libgfortran/io/format.c

[Bug 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 Thread jvdelisle at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90374

--- Comment #9 from Jerry DeLisle  ---
(In reply to anlauf from comment #6)
---snip---
> Jerry,
> 
> your change to format.c generates a warning here:
> 
> ../../../trunk/libgfortran/io/format.c: In function 'parse_format_list':
> ../../../trunk/libgfortran/io/format.c:1029:7: warning: suggest explicit
---snip---
> {
> 
> this seems to make sense (to me).  Do you plan to add {}?

Hi Herald, I saw that also, so did add the braces.

[Bug c++/87403] [Meta-bug] Issues that suggest a new warning

2019-12-01 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87403

--- Comment #3 from Eric Gallager  ---
David Malcolm's new static analyzer might solve some of these

[Bug c++/68230] Unused function parameters not reported by -Wunused-parameter when only used recursively (add -Wparameter-only-used-recursively instead?)

2019-12-01 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68230

Eric Gallager  changed:

   What|Removed |Added

   See Also||https://gcc.gnu.org/bugzill
   ||a/show_bug.cgi?id=32562

--- Comment #11 from Eric Gallager  ---
bug 32562 is related (that's for functions, this is for parameters)

[Bug other/89863] [meta-bug] Issues that static analyzers (cppcheck, clang-static-analyzer) find that gcc misses

2019-12-01 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89863

Eric Gallager  changed:

   What|Removed |Added

 CC||dmalcolm at gcc dot gnu.org

--- Comment #5 from Eric Gallager  ---
Some of the bugs that this one depends upon might be useful inspiration for the
new analyzer that David Malcolm is working on.

[Bug target/92499] nios2 backend needs to consider allocated object size, not C object size for gprel optimization

2019-12-01 Thread sandra at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92499

--- Comment #9 from sandra at gcc dot gnu.org ---
Author: sandra
Date: Mon Dec  2 03:52:15 2019
New Revision: 278891

URL: https://gcc.gnu.org/viewcvs?rev=278891&root=gcc&view=rev
Log:
2019-12-01  Sandra Loosemore  

Fix bugs relating to flexibly-sized objects in nios2 backend.

PR target/92499

gcc/c/
* c-decl.c (flexible_array_type_p): Move to common code.

gcc/
* config/nios2/nios2.c (nios2_in_small_data_p): Do not consider
objects of flexible types to be small if they have internal linkage
or are declared extern.
* config/nios2/nios2.h (ASM_OUTPUT_ALIGNED_LOCAL): Replace with...
(ASM_OUTPUT_ALIGNED_DECL_LOCAL): ...this.  Use targetm.in_small_data_p
instead of the size of the object initializer.
* tree.c (flexible_array_type_p): Move from C front end, and
generalize to handle fields in non-C structures.
* tree.h (flexible_array_type_p): Declare.

gcc/testsuite/
* gcc.target/nios2/pr92499-1.c: New.
* gcc.target/nios2/pr92499-2.c: New.
* gcc.target/nios2/pr92499-3.c: New.

Added:
trunk/gcc/testsuite/gcc.target/nios2/pr92499-1.c
trunk/gcc/testsuite/gcc.target/nios2/pr92499-2.c
trunk/gcc/testsuite/gcc.target/nios2/pr92499-3.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/c/ChangeLog
trunk/gcc/c/c-decl.c
trunk/gcc/config/nios2/nios2.c
trunk/gcc/config/nios2/nios2.h
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree.c
trunk/gcc/tree.h

[Bug target/92132] new test case gcc.dg/vect/vect-cond-reduc-4.c fails with its introduction in r277067

2019-12-01 Thread helijia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92132

--- Comment #7 from Li Jia He  ---
Author: helijia
Date: Mon Dec  2 06:23:56 2019
New Revision: 278892

URL: https://gcc.gnu.org/viewcvs?rev=278892&root=gcc&view=rev
Log:
[rs6000]Fix PR92098 by backporting vec_cmp and vcond_mask supports to
gcc-9-branch

As PR92132 added vec_cmp_* and vcond_mask_* supports on trunk.  This is a
partial backport of vec_{cmp,cmpu} interface and related expand
to gcc-9-branch to fix PR92098.

gcc/ChangeLog

2019-12-02  Li Jia He  

Partial backport from mainline
PR target/92098
2019-11-08  Kewen Lin  

PR target/92132
* config/rs6000/predicates.md
(signed_or_equality_comparison_operator): New predicate.
(unsigned_or_equality_comparison_operator): Likewise.
* config/rs6000/rs6000.md (one_cmpl2): Remove expand.
(one_cmpl3_internal): Rename to one_cmpl2.
* config/rs6000/vector.md
(vcond_mask_ for VEC_I and VEC_I): New expand.
(vec_cmp for VEC_I and VEC_I): Likewise.
(vec_cmpu for VEC_I and VEC_I): Likewise.

gcc/testsuite/ChangeLog

2019-12-02  Li Jia He  

Partial backport from trunk
PR target/92098
2019-11-08  Kewen Lin  

PR target/92132
* gcc.target/powerpc/pr92132-fp-1.c: New test.
* gcc.target/powerpc/pr92132-fp-2.c: New test.


Added:
branches/gcc-9-branch/gcc/testsuite/gcc.target/powerpc/pr92098-int-1.c
branches/gcc-9-branch/gcc/testsuite/gcc.target/powerpc/pr92098-int-2.c
Modified:
branches/gcc-9-branch/gcc/ChangeLog
branches/gcc-9-branch/gcc/config/rs6000/predicates.md
branches/gcc-9-branch/gcc/config/rs6000/rs6000.md
branches/gcc-9-branch/gcc/config/rs6000/vector.md
branches/gcc-9-branch/gcc/testsuite/ChangeLog

[Bug target/92098] [9 Regression] After r262333, the following code cannot be vectorized on powerpc64le.

2019-12-01 Thread helijia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92098

--- Comment #3 from Li Jia He  ---
Author: helijia
Date: Mon Dec  2 06:23:56 2019
New Revision: 278892

URL: https://gcc.gnu.org/viewcvs?rev=278892&root=gcc&view=rev
Log:
[rs6000]Fix PR92098 by backporting vec_cmp and vcond_mask supports to
gcc-9-branch

As PR92132 added vec_cmp_* and vcond_mask_* supports on trunk.  This is a
partial backport of vec_{cmp,cmpu} interface and related expand
to gcc-9-branch to fix PR92098.

gcc/ChangeLog

2019-12-02  Li Jia He  

Partial backport from mainline
PR target/92098
2019-11-08  Kewen Lin  

PR target/92132
* config/rs6000/predicates.md
(signed_or_equality_comparison_operator): New predicate.
(unsigned_or_equality_comparison_operator): Likewise.
* config/rs6000/rs6000.md (one_cmpl2): Remove expand.
(one_cmpl3_internal): Rename to one_cmpl2.
* config/rs6000/vector.md
(vcond_mask_ for VEC_I and VEC_I): New expand.
(vec_cmp for VEC_I and VEC_I): Likewise.
(vec_cmpu for VEC_I and VEC_I): Likewise.

gcc/testsuite/ChangeLog

2019-12-02  Li Jia He  

Partial backport from trunk
PR target/92098
2019-11-08  Kewen Lin  

PR target/92132
* gcc.target/powerpc/pr92132-fp-1.c: New test.
* gcc.target/powerpc/pr92132-fp-2.c: New test.


Added:
branches/gcc-9-branch/gcc/testsuite/gcc.target/powerpc/pr92098-int-1.c
branches/gcc-9-branch/gcc/testsuite/gcc.target/powerpc/pr92098-int-2.c
Modified:
branches/gcc-9-branch/gcc/ChangeLog
branches/gcc-9-branch/gcc/config/rs6000/predicates.md
branches/gcc-9-branch/gcc/config/rs6000/rs6000.md
branches/gcc-9-branch/gcc/config/rs6000/vector.md
branches/gcc-9-branch/gcc/testsuite/ChangeLog

[Bug ipa/92133] Support multi versioning on self recursive function

2019-12-01 Thread fxue at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92133

--- Comment #7 from fxue at gcc dot gnu.org ---
Author: fxue
Date: Mon Dec  2 06:37:30 2019
New Revision: 278893

URL: https://gcc.gnu.org/viewcvs?rev=278893&root=gcc&view=rev
Log:
Enable recursive function versioning

2019-12-02  Feng Xue 

PR ipa/92133
* doc/invoke.texi (ipa-cp-max-recursive-depth): Document new option.
(ipa-cp-min-recursive-probability): Likewise.
* params.opt (ipa-cp-max-recursive-depth): New.
(ipa-cp-min-recursive-probability): Likewise.
* ipa-cp.c (ipcp_lattice::add_value): Add two new parameters
val_p and unlimited.
(self_recursively_generated_p): New function.
(get_val_across_arith_op): Likewise.
(propagate_vals_across_arith_jfunc): Add constant propagation for
self-recursive function.
(incorporate_penalties): Do not penalize pure self-recursive function.
(good_cloning_opportunity_p): Dump node_is_self_scc flag.
(propagate_constants_topo): Set node_is_self_scc flag for cgraph node.
(get_info_about_necessary_edges): Relax hotness check for edge to
self-recursive function.
* ipa-prop.h (ipa_node_params): Add new field node_is_self_scc.

2019-12-02  Feng Xue  

PR ipa/92133
* gcc.dg/ipa/ipa-clone-2.c: New test.

Added:
trunk/gcc/testsuite/gcc.dg/ipa/ipa-clone-2.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/doc/invoke.texi
trunk/gcc/ipa-cp.c
trunk/gcc/ipa-prop.h
trunk/gcc/params.opt
trunk/gcc/testsuite/ChangeLog

[Bug c++/92746] New: [10 Regression] ICE in check_noexcept_r, at cp/except.c:1114

2019-12-01 Thread asolokha at gmx dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92746

Bug ID: 92746
   Summary: [10 Regression] ICE in check_noexcept_r, at
cp/except.c:1114
   Product: gcc
   Version: 10.0
Status: UNCONFIRMED
  Keywords: ice-on-valid-code
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: asolokha at gmx dot com
  Target Milestone: ---

g++-10.0.0-alpha20191201 snapshot (r278886) ICEs when compiling the following
testcase, reduced from
test/CXX/concepts-ts/dcl.dcl/dcl.spec/dcl.spec.concept/p1.cpp from the clang
9.0.0 test suite, w/ -fconcepts:

template concept bool C3() { return true; }
static_assert(noexcept(C3()), "function concept should be treated as if
noexcept(true) specified");

% g++-10.0.0-alpha20191201 -fconcepts -c vtdkmihj.cc
vtdkmihj.cc:2:33: internal compiler error: in check_noexcept_r, at
cp/except.c:1114
2 | static_assert(noexcept(C3()), "function concept should be treated
as if noexcept(true) specified");
  | ^
0x5fec0a check_noexcept_r
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/except.c:1114
0x11e6c1c walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*),
void*, hash_set >*,
tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*),
void*, hash_set >*))
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/tree.c:11957
0x11ea5eb walk_tree_without_duplicates_1(tree_node**, tree_node*
(*)(tree_node**, int*, void*), void*, tree_node* (*)(tree_node**, int*,
tree_node* (*)(tree_node**, int*, void*), void*, hash_set >*))
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/tree.c:12313
0x8de9ec expr_noexcept_p(tree_node*, int)
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/except.c:1212
0x8deb6e finish_noexcept_expr(tree_node*, int)
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/except.c:1197
0x95422d cp_parser_unary_expression
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:8320
0x92f774 cp_parser_binary_expression
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:9480
0x930806 cp_parser_assignment_expression
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:9780
0x930049 cp_parser_constant_expression
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:10074
0x930342 cp_parser_static_assert
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:14580
0x964d7f cp_parser_declaration
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:13322
0x9653a0 cp_parser_translation_unit
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:4721
0x9653a0 c_parse_file()
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/cp/parser.c:43048
0xa7493f c_common_parse_file()
   
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191201/work/gcc-10-20191201/gcc/c-family/c-opts.c:1185

[Bug tree-optimization/92734] Missing match.pd simplification done by fold_binary_loc on generic

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92734

--- Comment #2 from Richard Biener  ---
We have a set of special-case patterns for simple associations in match.pd, one
for this case seems missing, like the group

  /* Match patterns that allow contracting a plus-minus pair
 irrespective of overflow issues.  */
  /* (A +- B) - A   ->  +- B */
  /* (A +- B) -+ B  ->  A */
  /* A - (A +- B)   -> -+ B */
  /* A +- (B -+ A)  ->  +- B */

closest match is

  /* CST1 - (CST2 - A) -> CST3 + A  */
  (simplify
   (minus CONSTANT_CLASS_P@1 (minus CONSTANT_CLASS_P@2 @0))
   (with { tree cst = const_binop (MINUS_EXPR, type, @1, @2); }
(if (cst && !TREE_OVERFLOW (cst))
 (plus { cst; } @0

which "just" seems to lack a (convert? ...) around the inner minus.

And yes, reassoc would be the pass to handle this, maybe in the very late
if/when
we decide to switch the IL to -fwapv semantics there.

[Bug fortran/92736] [9/10 Regression] Error when using a variable from a module in a submodule and its parent module.

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92736

Richard Biener  changed:

   What|Removed |Added

   Priority|P3  |P4
 Status|UNCONFIRMED |NEW
  Known to work||7.5.0, 8.3.0, 9.2.0
   Keywords||rejects-valid
   Last reconfirmed||2019-12-02
 Ever confirmed|0   |1
Summary|Error when using a variable |[9/10 Regression] Error
   |from a module in a  |when using a variable from
   |submodule and its parent|a module in a submodule and
   |module. |its parent module.
   Target Milestone|--- |9.3
  Known to fail||10.0, 9.2.1

--- Comment #5 from Richard Biener  ---
Confirmed.  ifort accepts the code so I assume it is valid.

[Bug tree-optimization/92738] [10 regression] Large code size growth for -O2 binaries between 2019-05-19...2019-05-29

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92738

Richard Biener  changed:

   What|Removed |Added

   Keywords||missed-optimization,
   ||needs-bisection

--- Comment #4 from Richard Biener  ---
There is

2019-05-23  Richard Biener  

PR tree-optimization/88440
* opts.c (default_options_table): Enable
-ftree-loop-distribute-patterns
at -O[2s]+.
* tree-loop-distribution.c (generate_memset_builtin): Fold the
generated call.
(generate_memcpy_builtin): Likewise.
(distribute_loop): Pass in whether to only distribute patterns.
(prepare_perfect_loop_nest): Also allow size optimization.
(pass_loop_distribution::execute): When optimizing a loop
nest for size allow pattern replacement.

but that should cause code-size shrinking... (just try
-fno-tree-loop-distribute-patterns and see if fixed)

[Bug tree-optimization/92741] [10 Regression] ICE: verify_gimple failed (error: invalid vector types in nop conversion)

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92741

Richard Biener  changed:

   What|Removed |Added

   Keywords||missed-optimization

--- Comment #2 from Richard Biener  ---
_2 = (vector(2) int) { 0, 0, 0, 0 };

that's also not folded.

[Bug tree-optimization/92741] [10 Regression] ICE: verify_gimple failed (error: invalid vector types in nop conversion)

2019-12-01 Thread rsandifo at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92741

rsandifo at gcc dot gnu.org  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED

--- Comment #3 from rsandifo at gcc dot gnu.org  
---
Mine.

[Bug c++/92745] [8/9/10 Regression] Initializing array with vec4 results in compile error

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92745

Richard Biener  changed:

   What|Removed |Added

   Priority|P3  |P2
 Status|UNCONFIRMED |NEW
  Known to work||7.5.0
   Keywords||rejects-valid
   Last reconfirmed||2019-12-02
 Ever confirmed|0   |1
Summary|Initializing array with |[8/9/10 Regression]
   |vec4 results in compile |Initializing array with
   |error   |vec4 results in compile
   ||error
   Target Milestone|--- |8.4

--- Comment #1 from Richard Biener  ---
Confirmed.

[Bug c++/92746] [10 Regression] ICE in check_noexcept_r, at cp/except.c:1114

2019-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92746

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|--- |10.0