[Bug lto/66180] New: [6 Regression] many -Wodr false positives when building LLVM with -flto

2015-05-17 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66180

Bug ID: 66180
   Summary: [6 Regression] many -Wodr false positives when
building LLVM with -flto
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: lto
  Assignee: unassigned at gcc dot gnu.org
  Reporter: trippels at gcc dot gnu.org
CC: hubicka at gcc dot gnu.org
  Target Milestone: ---

for example:
trippels@gcc2-power8 llvm_build % cmake -DCMAKE_INSTALL_PREFIX=~/llvm-install
-DCMAKE_BUILD_TYPE=release -DLLVM_ENABLE_ASSERTIONS=on
-DLLVM_TARGETS_TO_BUILD="PowerPC" -DCMAKE_CXX_FLAGS_RELEASE:STRING="-O3
-DNDEBUG -pipe -flto=60"
-DCMAKE_EXE_LINKER_FLAGS="-Wl,-O1,--hash-style=gnu,--gc-sections,--icf=safe"
-DENABLE_PIC=1 -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
-DLLVM_BINUTILS_INCDIR=/home/trippels/include
-DCMAKE_C_COMPILER=/home/trippels/gcc_6/usr/local/bin/gcc
-DCMAKE_CXX_COMPILER=/home/trippels/gcc_6/usr/local/bin/g++ ~/llvm

trippels@gcc2-power8 llvm_build % make -j120
...
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/ext/aligned_buffer.h:43:12:
warning: type ‘struct __aligned_buffer’ violates one definition rule [-Wodr]
 struct __aligned_buffer
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/ext/aligned_buffer.h:43:12:
note: a type with the same name but different base type is defined in another
translation unit
 struct __aligned_buffer
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/type_traits:1985:12: note:
type name ‘std::aligned_storage<104ul, 8ul>’ should match type name
‘std::aligned_storage<96ul, 8ul>’  
 struct aligned_storage
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/type_traits:1985:12: note: the
incompatible type is defined here
 struct aligned_storage
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_tree.h:134:12:
warning: type ‘struct _Rb_tree_node’ violates one definition rule [-Wodr]
 struct _Rb_tree_node : public _Rb_tree_node_base
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_tree.h:134:12: note:
a different type is defined in another translation unit
 struct _Rb_tree_node : public _Rb_tree_node_base
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_tree.h:149:41: note:
the first difference of corresponding definitions is field ‘_M_storage’
   __gnu_cxx::__aligned_buffer<_Val> _M_storage;
  ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_tree.h:149:41: note:
a field of same name but different type is defined in another translation unit
   __gnu_cxx::__aligned_buffer<_Val> _M_storage;
  ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/ext/aligned_buffer.h:43:12:
note: type ‘struct __aligned_buffer’ should match type ‘struct
__aligned_buffer’ that itself violate one definition rule
 struct __aligned_buffer
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/ext/aligned_buffer.h:43:12:
note: the incompatible type is defined here
 struct __aligned_buffer
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:96:12:
warning: type ‘struct pair’ violates one definition rule [-Wodr]
 struct pair
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:96:12: note: a
different type is defined in another translation unit
 struct pair
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:102:11: note:
the first difference of corresponding definitions is field ‘second’
   _T2 second;/// @c second is a copy of the second object
^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:102:11: note:
a field of same name but different type is defined in another translation unit
   _T2 second;/// @c second is a copy of the second object
^
/home/trippels/llvm/tools/clang/utils/TableGen/ClangDiagnosticsEmitter.cpp:131:10:
note: type ‘struct GroupInfo’ defined in anonymous namespace can not match type
‘struct GroupInfo’
   struct GroupInfo {
   ^
/home/trippels/llvm/tools/clang/utils/TableGen/ClangSACheckersEmitter.cpp:73:8:
note: the incompatible type defined in anonymous namespace in another
translation unit
 struct GroupInfo {
 ^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:99:19:
warning: type ‘struct second_type’ violates one definition rule [-Wodr]
   typedef _T2 second_type;   /// @c second_type is the second bound type
^
/home/trippels/gcc_6/usr/local/include/c++/6.0.0/bits/stl_pair.h:99:19: note: a
different type is defined in another translation unit
   typedef _T2 second_type;   /// @c second_type is the second bound type
^
/home/trippels/llvm/tools/clang/utils/TableGen/Clan

[Bug lto/66180] [6 Regression] many -Wodr false positives when building LLVM with -flto

2015-05-17 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66180

--- Comment #1 from Andrew Pinski  ---
Some look real to me due to anonymous namespace usage.


[Bug lto/66180] [6 Regression] many -Wodr false positives when building LLVM with -flto

2015-05-17 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66180

--- Comment #2 from Markus Trippelsdorf  ---
(In reply to Andrew Pinski from comment #1)
> Some look real to me due to anonymous namespace usage.

Can you elaborate on that? I always thought that anonymous namespaces
where a good tool for fixing ODR issues?


[Bug target/66140] ICE at extract_insn, at recog.c:2343 when compiling for alpha with gcc-5.1.1

2015-05-17 Thread uros at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66140

--- Comment #6 from uros at gcc dot gnu.org ---
Author: uros
Date: Sun May 17 07:24:27 2015
New Revision: 223266

URL: https://gcc.gnu.org/viewcvs?rev=223266&root=gcc&view=rev
Log:
PR target/66140
* config/alpha/alpha.c (get_aligned_mem): Also look for reload
replacements in memory addresses.
(get_unaligned_address): Ditto.

testsuite/ChangeLog:

PR target/66140
* gcc.target/alpha/pr66140.c: New test.


Added:
branches/gcc-4_9-branch/gcc/testsuite/gcc.target/alpha/pr66140.c
Modified:
branches/gcc-4_9-branch/gcc/ChangeLog
branches/gcc-4_9-branch/gcc/config/alpha/alpha.c
branches/gcc-4_9-branch/gcc/testsuite/ChangeLog


[Bug target/66140] ICE at extract_insn, at recog.c:2343 when compiling for alpha with gcc-5.1.1

2015-05-17 Thread uros at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66140

--- Comment #7 from uros at gcc dot gnu.org ---
Author: uros
Date: Sun May 17 07:26:56 2015
New Revision: 223267

URL: https://gcc.gnu.org/viewcvs?rev=223267&root=gcc&view=rev
Log:
PR target/66140
* config/alpha/alpha.c (get_aligned_mem): Also look for reload
replacements in memory addresses.
(get_unaligned_address): Ditto.

testsuite/ChangeLog:

PR target/66140
* gcc.target/alpha/pr66140.c: New test.


Added:
branches/gcc-4_8-branch/gcc/testsuite/gcc.target/alpha/pr66140.c
Modified:
branches/gcc-4_8-branch/gcc/ChangeLog
branches/gcc-4_8-branch/gcc/config/alpha/alpha.c
branches/gcc-4_8-branch/gcc/testsuite/ChangeLog


[Bug lto/66180] [6 Regression] many -Wodr false positives when building LLVM with -flto

2015-05-17 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66180

--- Comment #3 from Markus Trippelsdorf  ---
BTW gcc-5 crashes when building LLVM with lto (looks like
a dup of PR66027):

Linking CXX executable ../../../../bin/clang
  constant 64>
unit size  constant 8>
align 8 symtab 0 alias set -1 canonical type 0x3fff7fddac98>
lto1: internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1543
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.


[Bug lto/66027] lto1: internal compiler error: in odr_types_equivalent_p

2015-05-17 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66027

Markus Trippelsdorf  changed:

   What|Removed |Added

 Status|WAITING |NEW
 CC||trippels at gcc dot gnu.org
  Known to work||6.0
   Target Milestone|--- |5.2
  Known to fail||5.0

--- Comment #6 from Markus Trippelsdorf  ---
Confirmed.


Linking CXX executable ../../bin/llvm-dsymutil
[100%] Built target clang-format  
  constant 64>
unit size  constant 8>
align 8 symtab 0 alias set -1 canonical type 0x3fff85f1c438>
lto1: internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1543
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.
lto-wrapper: fatal error: /home/trippels/gcc_5/usr/local/bin/g++ returned 1
exit status
compilation terminated.
/home/trippels/bin/ld: fatal error: lto-wrapper failed
collect2: error: ld returned 1 exit status
tools/clang/tools/diagtool/CMakeFiles/diagtool.dir/build.make:228: recipe for
target 'bin/diagtool' failed
make[2]: *** [bin/diagtool] Error 1
CMakeFiles/Makefile2:14311: recipe for target
'tools/clang/tools/diagtool/CMakeFiles/diagtool.dir/all' failed
make[1]: *** [tools/clang/tools/diagtool/CMakeFiles/diagtool.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs
Linking CXX executable ../../../../bin/clang
  constant 64>
unit size  constant 8>
align 8 symtab 0 alias set -1 canonical type 0x3fff7fddac98>
lto1: internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1543
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.
lto-wrapper: fatal error: /home/trippels/gcc_5/usr/local/bin/g++ returned 1
exit status
compilation terminated.
/home/trippels/bin/ld: fatal error: lto-wrapper failed
collect2: error: ld returned 1 exit status
tools/clang/tools/arcmt-test/CMakeFiles/arcmt-test.dir/build.make:108: recipe
for target 'bin/arcmt-test' failed
make[2]: *** [bin/arcmt-test] Error 1
CMakeFiles/Makefile2:14900: recipe for target
'tools/clang/tools/arcmt-test/CMakeFiles/arcmt-test.dir/all' failed
make[1]: *** [tools/clang/tools/arcmt-test/CMakeFiles/arcmt-test.dir/all] Error
2
Linking CXX shared library ../../../../lib/libclang.so
/home/trippels/llvm/include/llvm/ADT/ImmutableMap.h:26:32: warning: type ‘const
struct value_type’ violates one definition rule [-Wodr]
   typedef const std::pair value_type;
^
/home/trippels/llvm/include/llvm/ADT/ImmutableMap.h:26:32: note: a different
type is defined in another translation unit
   typedef const std::pair value_type;
^
/home/trippels/gcc_5/usr/local/include/c++/5.0.1/bits/stl_pair.h:102:11: note:
the first difference of corresponding definitions is field ‘second’
   _T2 second;/// @c second is a copy of the second object
   ^
/home/trippels/gcc_5/usr/local/include/c++/5.0.1/bits/stl_pair.h:102:11: note:
a field of same name but different type is defined in another translation unit
   _T2 second;/// @c second is a copy of the second object
   ^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/SimpleStreamChecker.cpp:30:8:
note: type ‘struct StreamState’ defined in anonymous namespace can not match
type ‘struct StreamState’
 struct StreamState {
^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:29:8:
note: the incompatible type defined in anonymous namespace in another
translation unit
 struct StreamState {
^
/home/trippels/llvm/include/llvm/ADT/ImmutableMap.h:30:21: warning: type ‘const
struct data_type’ violates one definition rule [-Wodr]
   typedef const S   data_type;
 ^
/home/trippels/llvm/include/llvm/ADT/ImmutableMap.h:30:21: note: a different
type is defined in another translation unit
   typedef const S   data_type;
 ^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/SimpleStreamChecker.cpp:32:32:
note: the first difference of corresponding definitions is field ‘K’
   enum Kind { Opened, Closed } K;
^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:30:53:
note: a field of same name but different type is defined in another translation
unit
   enum Kind { Opened, Closed, OpenFailed, Escaped } K;
 ^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/SimpleStreamChecker.cpp:32:8:
note: type ‘Kind’ defined in anonymous namespace can not match type ‘Kind’
   enum Kind { Opened, Closed } K;
^
/home/trippels/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:3

[Bug target/66140] ICE at extract_insn, at recog.c:2343 when compiling for alpha with gcc-5.1.1

2015-05-17 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66140

Uroš Bizjak  changed:

   What|Removed |Added

 Target||alpha
 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED
   Target Milestone|4.9.3   |4.8.5

--- Comment #8 from Uroš Bizjak  ---
Fixed everywhere.

[Bug ipa/66181] New: [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

Bug ID: 66181
   Summary: [6 Regression]: /usr/include/bits/types.h:134:16: ICE:
verify_type failed
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: ipa
  Assignee: unassigned at gcc dot gnu.org
  Reporter: ubizjak at gmail dot com
  Target Milestone: ---

Recent commits caused following ICE, reproducible with to-be attached source
and a crosscompiler from x86_64-linux-gnu to alpha-linux-gnu:

$ /ssd/uros/gcc-build-alpha/gcc/cc1plus -O2 -g -std=gnu++0x -fpreprocessed -o
xxx.s stdc++.ii

In file included from /usr/include/ctype.h:26:0,
 from
/space/homedirs/uros/gcc-build/alphaev68-unknown-linux-gnu/libstdc++-v3/include/cctype:42,
 from
/space/homedirs/uros/gcc-svn/trunk/libstdc++-v3/include/precompiled/stdc++.h:35:
/usr/include/bits/types.h:134:16: error: type variant differs by
TYPE_NO_FORCE_BLK.
 __STD_TYPE __FSID_T_TYPE __fsid_t; /* Type of file system IDs.  */
 ^
  constant 64>
unit size  constant 8>
align 32 symtab -884711424 alias set -1 canonical type 0x7fd1cb443348
fields 
asm_written no-force-blk BLK size 
unit size 
align 32 symtab -884711344 alias set -1 canonical type
0x7fd1cb443540 domain >
nonlocal decl_3 BLK file /usr/include/bits/types.h line 134 col 29 size
 unit size 
align 32 offset_align 128
offset 
bit offset  context 
chain 
nonlocal in_system_header decl_4 VOID file
/usr/include/bits/types.h line 134 col 16
align 1 context  result

   >> context 
full-name "struct"
X() X(constX&) this=(X&) n_parents=0 use_template=0 interface-unknown
chain >
  constant 64>
unit size  constant 8>
align 32 symtab 0 alias set -1 canonical type 0x7fd1cb443348
fields 
asm_written no-force-blk BLK size 
unit size 
align 32 symtab -884711344 alias set -1 canonical type
0x7fd1cb443540 domain >
nonlocal decl_3 BLK file /usr/include/bits/types.h line 134 col 29 size
 unit size 
align 32 offset_align 128
offset 
bit offset  context 
chain 
nonlocal in_system_header decl_4 VOID file
/usr/include/bits/types.h line 134 col 16
align 1 context  result

   >> context 
full-name "struct"
X() X(constX&) this=(X&) n_parents=0 use_template=0 interface-unknown
chain >
/usr/include/bits/types.h:134:16: internal compiler error: verify_type failed
0xe50e82 verify_type(tree_node const*)
/home/uros/gcc-svn/trunk/gcc/tree.c:13012
0x8958c4 gen_type_die_with_usage
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20250
0x8942ad gen_decl_die
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20987
0x892983 gen_member_die
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:19945
0x892983 gen_struct_or_union_type_die
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20038
0x892983 gen_tagged_type_die
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20227
0x89607d gen_type_die_with_usage
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20381
0x8942ad gen_decl_die
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:20987
0x89507c dwarf2out_decl
/home/uros/gcc-svn/trunk/gcc/dwarf2out.c:21397
0xb2253f rest_of_type_compilation(tree_node*, int)
/home/uros/gcc-svn/trunk/gcc/passes.c:309
0x5ec7f8 finish_struct_1(tree_node*)
/home/uros/gcc-svn/trunk/gcc/cp/class.c:6723
0x5eded4 finish_struct(tree_node*, tree_node*)
/home/uros/gcc-svn/trunk/gcc/cp/class.c:6888
0x628662 cp_parser_class_specifier_1
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:19868
0x628662 cp_parser_class_specifier
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:20096
0x628662 cp_parser_type_specifier
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:14734
0x63cf3d cp_parser_decl_specifier_seq
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:11965
0x6506f1 cp_parser_simple_declaration
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:11542
0x649973 cp_parser_block_declaration
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:11489
0x654522 cp_parser_declaration
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:11386
0x652c48 cp_parser_declaration_seq_opt
/home/uros/gcc-svn/trunk/gcc/cp/parser.c:11272
Please submit a full bug report,
...

Caused by one of:

2015-05-16  Jan HUbicka  

* toplev.c (emit_debug_global_declarations): Do not output debug info
when doing slim LTO objects.

2015-05-16  Jan HUbicka  

* ipa-utils.h (warn_types_mismatch, odr_or_derived_type_p,
odr_types_equivalent_p): Declare.
(odr_type_p): Use gcc_checking_assert.
(type_in_anonymous_namespace_p) Declare.
(type_with_linkage_p): Declare.
* common.opt (Wlto-type-mismatch): New warning.
* ipa-devirt.c (compound_

[Bug ipa/66181] [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

--- Comment #1 from Uroš Bizjak  ---
Created attachment 35557
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35557&action=edit
Preprocessed source

Preprocessed source

[Bug ipa/66181] [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread ubizjak at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

Uroš Bizjak  changed:

   What|Removed |Added

 CC||hubicka at gcc dot gnu.org

--- Comment #2 from Uroš Bizjak  ---
Adding CC.

[Bug fortran/66182] New: Unneeded temporary for elemental functions of function results

2015-05-17 Thread tkoenig at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66182

Bug ID: 66182
   Summary: Unneeded temporary for elemental functions of function
results
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: enhancement
  Priority: P3
 Component: fortran
  Assignee: unassigned at gcc dot gnu.org
  Reporter: tkoenig at gcc dot gnu.org
  Target Milestone: ---

ig25@linux-fd1f:~/Krempel/Assign> cat matmul.f90
program main
  complex, dimension(3,3) :: a,b,c
  real, dimension(3,3) :: ar, ai, br, bi
  call random_number(ar)
  call random_number(ai)
  call random_number(br)
  call random_number(bi)
  a = ar + (0.,1.)*ai
  b = br + (0.,1.)*bi
  c = conjg(matmul(a,b))
  print *,c
end program main

ig25@linux-fd1f:~/Krempel/Assign> gfortran -Warray-temporaries matmul.f90
matmul.f90:10:12:

   c = conjg(matmul(a,b))
1
Warning: Creating array temporary at (1) [-Warray-temporaries]

This should be replaced by

  c = matmul(a,b)
  c = conjg(c)


[Bug ada/66162] Bug box compiling Ada.Finalization with -gnatc

2015-05-17 Thread simon at pushface dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66162

--- Comment #2 from simon at pushface dot org ---
(In reply to Eric Botcazou from comment #1)
> Why on Earth are you doing this?  No plan to look into it.

Because I agree with Randy Brukardt in
https://groups.google.com/d/msg/comp.lang.ada/ECJm5qlxZKA/RKXuEQWN4NYJ that
“[n]ot having bounded containers is pretty much like not having arrays”.

It’s quite possible to build the Ada 2012 Bounded Vectors & Hashed Maps (&
presumably other bounded containers) without finalization provided you’re
willing to hack out iterators and references, which is the way I’ve gone up to
now; but it seems a real shame not to go the whole hog.

People who want to write Ada for MCUs aren’t necessarily in the high-integrity
world; some would want to cram as much of the language as possible into the
RTS.

[Bug ipa/66004] [6 Regression]: performance of 26_numerics/random/negative_binomial_distribution/operators/values.cc

2015-05-17 Thread hp at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66004

--- Comment #4 from Hans-Peter Nilsson  ---
(In reply to Hans-Peter Nilsson from comment #3)
> Something supposedly very good happened recently, because:
> r223225 18369501023
> 
> I'll just have to find out what caused that 50% cut!  The test-case is
> unchanged.
> If the cause is related to inlining heuristics, I'll close this PR for sure.

Ignore that.  I misobserved the "nearby" test-case
26_numerics/random/poisson_distribution/operators/values.cc probably because
there was a test-run still in progress.  Still, that similar test-case indeed
seems to have lower initialization numbers.  Lesson learned: always
double-check your end-point observations before bisecting.


[Bug ada/66162] Bug box compiling Ada.Finalization with -gnatc

2015-05-17 Thread ebotcazou at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66162

--- Comment #3 from Eric Botcazou  ---
> People who want to write Ada for MCUs aren’t necessarily in the
> high-integrity world; some would want to cram as much of the language as
> possible into the RTS.

That's not the problem., just avoid using -gnatc on the runtime.

[Bug fortran/37131] inline matmul for small matrix sizes

2015-05-17 Thread tkoenig at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=37131

--- Comment #31 from Thomas Koenig  ---
Author: tkoenig
Date: Sun May 17 13:45:07 2015
New Revision: 223268

URL: https://gcc.gnu.org/viewcvs?rev=223268&root=gcc&view=rev
Log:
2015-05-17  Thomas Koenig  

PR fortran/37131
* gfortran.dg/matmul_bounds_6.f90:  New test.
* gfortran.dg/matmul_bounds_7.f90:  New test.


Added:
trunk/gcc/testsuite/gfortran.dg/matmul_bounds_6.f90
trunk/gcc/testsuite/gfortran.dg/matmul_bounds_7.f90
Modified:
trunk/gcc/testsuite/ChangeLog


[Bug lto/66027] lto1: internal compiler error: in odr_types_equivalent_p

2015-05-17 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66027

--- Comment #7 from Markus Trippelsdorf  ---
trippels@gcc75 ~ % cat ASTContext_preproc.cpp
namespace std {
template  struct pair {
  _T1 first;
  _T2 second;
};
template  pair<_T1, _T2> make_pair(_T1, _T2);
}
namespace llvm {
class StringRef;
}
using llvm::StringRef;
namespace llvm {
class StringRef {
  char *Data;
  unsigned long Length;

public:
  StringRef(int);
};
}
class A {
public:
  void m_fn1(StringRef Name) { std::make_pair(Name, nullptr); }
};
class B {
  A &Idents;
  int m_fn2() const;
};
int B::m_fn2() const { Idents.m_fn1(0); }


trippels@gcc75 ~ % cat CIndex_preproc.cpp
namespace std {
template  struct pair {
  _T1 first;
  _T2 second;
};
template  pair<_T1, _T2> make_pair(_T1, _T2);
}
namespace llvm {
class StringRef {
  char *Data;
  unsigned long Length;
};
}
void annotatePreprocessorTokens() {
  llvm::StringRef Name;
  std::make_pair(Name, nullptr);
}

trippels@gcc75 ~ % ~/gcc_5/usr/local/bin/g++ -fPIC -flto -std=c++14 -O2 -c
ASTContext_preproc.cpp
trippels@gcc75 ~ % ~/gcc_5/usr/local/bin/g++ -fPIC -flto -std=c++14 -shared -o
/dev/null CIndex_preproc.cpp ASTContext_preproc.o
  constant 64>
unit size  constant 8>
align 8 symtab 0 alias set 0 canonical type 0x7f2accfb9b28>
lto1: internal compiler error: in odr_types_equivalent_p, at ipa-devirt.c:1543
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.
lto-wrapper: fatal error: /home/trippels/gcc_5/usr/local/bin/g++ returned 1
exit status
compilation terminated.
/home/trippels/bin/ld: fatal error: lto-wrapper failed
collect2: error: ld returned 1 exit status


[Bug ada/66162] Bug box compiling Ada.Finalization with -gnatc

2015-05-17 Thread simon at pushface dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66162

--- Comment #4 from simon at pushface dot org ---
(In reply to Eric Botcazou from comment #3)
> > People who want to write Ada for MCUs aren’t necessarily in the
> > high-integrity world; some would want to cram as much of the language as
> > possible into the RTS.
> 
> That's not the problem., just avoid using -gnatc on the runtime.

I see, sorry for the misunderstanding. That was the workround I had thought of.
The reason I used -gnatc is that the latest Emacs ada-mode doesn’t have a
compile-current-file, just check-current-file; and it’s worked for the rest of
the runtime!

That said, I get a very similar error compiling something that _uses_ the
runtime:

--  Copyright (C) Simon Wright 

--  This unit is free software; you can redistribute it and/or modify it
--  as you wish. This unit is distributed in the hope that it will be
--  useful, but WITHOUT ANY WARRANTY; without even the implied warranty
--  of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

with Ada.Finalization;
package Finalizing is

   type F is new Ada.Finalization.Controlled with record
  V : Integer;
   end record;

   overriding
   procedure Adjust (Obj : in out F);

   overriding
   procedure Finalize (Obj : in out F);

end Finalizing;

results in

$ PATH=/opt/gcc-5.1.0/bin:$PATH gprbuild -P testbed -c -u -f -gnatc
finalizing.adb
arm-eabi-gcc -c -g -Og -gnatqQafoy -gnatwaL.X -gnatc finalizing.adb
+===GNAT BUG DETECTED==+
| 5.1.0 (arm-eabi) Constraint_Error erroneous memory access|
| Error detected at finalizing.ads:19:4|
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.|
| Use a subject line meaningful to you and us to track the bug.|
| Include the entire contents of this bug box in the report.   |
| Include the exact command that you entered.  |
| Also include sources listed below.   |
+==+

where line 19 is the declaration of procedure Finalize.

Your suggested workround is OK for this too.

[Bug target/66174] [6 Regression] ICE: in extract_insn, at recog.c:2341 (unrecognizable insns) with -ftree-vectorize -mavx512ifma

2015-05-17 Thread uros at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66174

--- Comment #5 from uros at gcc dot gnu.org ---
Author: uros
Date: Sun May 17 15:08:16 2015
New Revision: 223269

URL: https://gcc.gnu.org/viewcvs?rev=223269&root=gcc&view=rev
Log:
PR target/66174
* config/i386/i386.c (expand_vec_perm_blend): Enable HImode and
QImode inner modes for TARGET_AVX512BW.  Force mask operand
to a register for AVX512F modes.

testsuite/ChangeLog:

PR target/66174
* gcc.target/i386/pr66174.c: New test.


Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/i386/i386.c
trunk/gcc/testsuite/ChangeLog


[Bug ada/66162] segfault on code using controlled types in -gnatc mode

2015-05-17 Thread ebotcazou at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66162

Eric Botcazou  changed:

   What|Removed |Added

 Status|SUSPENDED   |NEW
Summary|Bug box compiling   |segfault on code using
   |Ada.Finalization with   |controlled types in -gnatc
   |-gnatc  |mode

--- Comment #5 from Eric Botcazou  ---
> That said, I get a very similar error compiling something that _uses_ the
> runtime:
> 
> --  Copyright (C) Simon Wright 
> 
> --  This unit is free software; you can redistribute it and/or modify it
> --  as you wish. This unit is distributed in the hope that it will be
> --  useful, but WITHOUT ANY WARRANTY; without even the implied warranty
> --  of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
> 
> with Ada.Finalization;
> package Finalizing is
> 
>type F is new Ada.Finalization.Controlled with record
>   V : Integer;
>end record;
> 
>overriding
>procedure Adjust (Obj : in out F);
> 
>overriding
>procedure Finalize (Obj : in out F);
> 
> end Finalizing;

OK, this one ought to compile with -gnatc.


[Bug libstdc++/65942] [5/6 Regression] [C++14] cannot use std::function as comparator in algorithms

2015-05-17 Thread a...@cloudius-systems.com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65942

--- Comment #10 from Avi Kivity  ---
Any chance that the fix can be committed?  gcc 5 is useless for me without
this.


[Bug target/66183] New: FAIL: gcc.dg/torture/pr66123.c

2015-05-17 Thread danglin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66183

Bug ID: 66183
   Summary: FAIL: gcc.dg/torture/pr66123.c
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: target
  Assignee: unassigned at gcc dot gnu.org
  Reporter: danglin at gcc dot gnu.org
  Target Milestone: ---
  Host: hppa-unknown-linux-gnu
Target: hppa-unknown-linux-gnu
 Build: hppa-unknown-linux-gnu

spawn -ignore SIGHUP /home/dave/gnu/gcc/objdir/gcc/xgcc
-B/home/dave/gnu/gcc/obj
dir/gcc/ /home/dave/gnu/gcc/gcc/gcc/testsuite/gcc.dg/torture/pr66123.c
-fno-diag
nostics-show-caret -fdiagnostics-color=never -O0 -S -o pr66123.s
/home/dave/gnu/gcc/gcc/gcc/testsuite/gcc.dg/torture/pr66123.c: In function
'test
':
/home/dave/gnu/gcc/gcc/gcc/testsuite/gcc.dg/torture/pr66123.c:11:1: internal
com
piler error: in pa_output_global_address, at config/pa/pa.c:5421
0xa982df pa_output_global_address(_IO_FILE*, rtx_def*, int)
../../gcc/gcc/config/pa/pa.c:5421
0x3f0833 output_operand(rtx_def*, int)
../../gcc/gcc/final.c:3880
0x3f15ab output_asm_insn(char const*, rtx_def**)
../../gcc/gcc/final.c:3777
0x3f1eaf final_scan_insn(rtx_insn*, _IO_FILE*, int, int, int*)
../../gcc/gcc/final.c:3058
0x3f315b final(rtx_insn*, _IO_FILE*, int)   
../../gcc/gcc/final.c:20860x3f3eff rest_of_handle_final   
../../gcc/gcc/final.c:4492
0x3f3eff execute
../../gcc/gcc/final.c:4567


[Bug target/66183] FAIL: gcc.dg/torture/pr66123.c

2015-05-17 Thread danglin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66183

--- Comment #1 from John David Anglin  ---
(gdb) p debug_rtx (x)
(const:SI (plus:SI (label_ref:SI 29)
(const_int -2 [0xfffe])))


[Bug target/65979] Multiple issues in conftest.c prevent build on sh4-linux-gnu

2015-05-17 Thread glaubitz at physik dot fu-berlin.de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65979

--- Comment #11 from John Paul Adrian Glaubitz  ---
So, I have tried disabling some of the patches but it seems that these depend
on each other. Thus, I will probably have to checkout gcc from source via git
and revert the patches using git.

Unless there is a better suggestion?

PS: For the time being, I rebuild gcc-4.9_4.9.2-10 with a forged -16+sh4
version number such that we have a working gcc on sh4 again.

Adrian


[Bug ipa/65873] [5 Regression] Failure to inline always_inline memcpy

2015-05-17 Thread hubicka at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65873

--- Comment #10 from Jan Hubicka  ---
Author: hubicka
Date: Sun May 17 17:43:04 2015
New Revision: 223270

URL: https://gcc.gnu.org/viewcvs?rev=223270&root=gcc&view=rev
Log:

PR ipa/65873
* ipa-inline.c (can_inline_edge_p): Allow early inlining of always
inlines across optimization boundary; be tolerant about COMDAT;
allow inlining across -fstrict-aliasing boundary.

Modified:
branches/gcc-5-branch/gcc/ChangeLog
branches/gcc-5-branch/gcc/ipa-inline.c


[Bug c++/66184] New: Rejection of partial specialization of a variable template in a non-global namespace

2015-05-17 Thread Casey at Carter dot net
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66184

Bug ID: 66184
   Summary: Rejection of partial specialization of a variable
template in a non-global namespace
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: Casey at Carter dot net
  Target Milestone: ---

Created attachment 35558
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35558&action=edit
testcase.cpp

Both 5.1.0 on Wandbox and 6.0 r223061 reject this program:

namespace foo {
template  constexpr bool same = false;
template <> constexpr bool same = true;
template  constexpr bool same = true;

static_assert(same, "");
static_assert(!same, "");
}

int main() {}

with error message:

bug2.cpp:4:35: error: specialization of ‘template constexpr const
bool foo::same< ,  >’ in
different namespace [-fpermissive]
 template  constexpr bool same = true;
   ^
bug2.cpp:2:40: error:   from definition of ‘template constexpr
const bool foo::same< ,  >’
[-fpermissive]
 template  constexpr bool same = false;
^
The full specialization of same is accepted regardless of namespace.
Both versions compile the program correctly if "same" is in the global
namespace.

[Bug libstdc++/65942] [5/6 Regression] [C++14] cannot use std::function as comparator in algorithms

2015-05-17 Thread harald at gigawatt dot nl
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65942

Harald van Dijk  changed:

   What|Removed |Added

 CC||harald at gigawatt dot nl

--- Comment #11 from Harald van Dijk  ---
GCC and clang are instantiating constexpr function bodies when only the
signature should be checked (when they appear in unevaluated expressions). A
shorter example program:

template  constexpr int f(T t) { return t; }
int main() { sizeof(f("")); }

This is rejected by GCC and clang, but accepted by Intel and Sun C++. As far as
I can tell, it should be accepted. f is used in a context where a definition of
f is not required, so f should not be instantiated. f is used in a way that
involves overload resolution, so a declaration of f is instantiated, but that
declaration does not contain the error that GCC and clang report.

GCC and clang accept it when constexpr is removed.

It's made worse by the fact that it happens even in SFINAE contexts, where such
an error should at worst lead to a substitution failure:

template  constexpr int f(T t) { return t; }
template  void g(T) { }
void g(...) { }
int main() { g(""); }

Here, either the use of f(T()) is an error, so overload resolution should
discard the first g overload, and the program should be accepted, or the use of
f(T()) is valid, so overload resolution should prefer the first g overload, and
the program should still be accepted. But even this is rejected by GCC and
clang.

Even if this gets worked around in libstdc++, it's probably worth tracking this
as a C++ frontend bug as well.

The programs in my comment here are accepted by G++ 4.5.4 (with -std=c++0x),
and rejected by 4.6.4 and later.


[Bug tree-optimization/66185] New: ICE on valid code at -O3 on x86_64-linux-gnu

2015-05-17 Thread su at cs dot ucdavis.edu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66185

Bug ID: 66185
   Summary: ICE on valid code at -O3 on x86_64-linux-gnu
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: su at cs dot ucdavis.edu
  Target Milestone: ---

The following code causes an ICE when compiled with the current gcc trunk at
-O3 on x86_64-linux-gnu in both 32-bit and 64-bit modes. 

It is a regression from 5.1.x. 


$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/6.0.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr/local/gcc-trunk
--enable-languages=c,c++ --disable-werror --enable-multilib
Thread model: posix
gcc version 6.0.0 20150517 (experimental) [trunk revision 223265] (GCC) 
$ 
$ gcc-trunk -O2 small.c; ./a.out
$ gcc-5.1 -O3 small.c; ./a.out
$ 
$ gcc-trunk -O3 small.c
small.c: In function ‘main’:
small.c:5:1: internal compiler error: Segmentation fault
 main ()
  ^
0xacd85f crash_signal
../../gcc-trunk/gcc/toplev.c:380
0xd066c8 vec::operator[](unsigned
int)
../../gcc-trunk/gcc/vec.h:736
0xd066c8 vec::operator[](unsigned int)
../../gcc-trunk/gcc/vec.h:1202
0xd066c8 vect_analyze_slp_instance
../../gcc-trunk/gcc/tree-vect-slp.c:1805
0xd07606 vect_analyze_slp(_loop_vec_info*, _bb_vec_info*, unsigned int)
../../gcc-trunk/gcc/tree-vect-slp.c:1897
0xd07ad6 vect_slp_analyze_bb_1
../../gcc-trunk/gcc/tree-vect-slp.c:2431
0xd07ad6 vect_slp_analyze_bb(basic_block_def*)
../../gcc-trunk/gcc/tree-vect-slp.c:2561
0xd09e42 execute
../../gcc-trunk/gcc/tree-vectorizer.c:662
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
$ 





unsigned int a;
int b[5], c;

int
main ()
{
  for (c = 0; c < 4; c++)
b[c] = b[c+1] > ((b[0] > 0) > a);

  return 0;
}

[Bug tree-optimization/66186] New: wrong code at -O3 on x86_64-linux-gnu

2015-05-17 Thread su at cs dot ucdavis.edu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66186

Bug ID: 66186
   Summary: wrong code at -O3 on x86_64-linux-gnu
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: tree-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: su at cs dot ucdavis.edu
  Target Milestone: ---

The current gcc trunk (as well as 4.9.x and 5.1.x) miscompiles the following
code on x86_64-linux at -O3 in both 32-bit and 64-bit modes. 

This is a regression from 4.8.x. 


$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/6.0.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr/local/gcc-trunk
--enable-languages=c,c++ --disable-werror --enable-multilib
Thread model: posix
gcc version 6.0.0 20150517 (experimental) [trunk revision 223265] (GCC) 
$ 
$ gcc-trunk -O2 small.c; ./a.out
$ gcc-4.8.4 -O3 small.c; ./a.out
$ 
$ gcc-trunk -O3 small.c
$ ./a.out
Segmentation fault (core dumped)
$ gcc-5.1 -O3 small.c 
$ ./a.out
Segmentation fault (core dumped)
$ gcc-4.9.2 -O3 small.c
$ ./a.out
Segmentation fault (core dumped)
$ 


--


int a;

int
main ()
{
  int b = -1, d, e = 0, f[2] = { 0 };
  unsigned short c = b;
  for (; e < 3; e++)
for (d = 0; d < 2; d++)
  if (a < 0)
for (d = 0; d < 2; d++)
  if (f[c])
break;
  return 0;
}


[Bug rtl-optimization/66187] New: wrong code at -O1, -O2 and -O3 on x86_64-linux-gnu

2015-05-17 Thread su at cs dot ucdavis.edu
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66187

Bug ID: 66187
   Summary: wrong code at -O1, -O2 and -O3 on x86_64-linux-gnu
   Product: gcc
   Version: 6.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: rtl-optimization
  Assignee: unassigned at gcc dot gnu.org
  Reporter: su at cs dot ucdavis.edu
  Target Milestone: ---

The current gcc trunk miscompiles the following code on x86_64-linux at -O1,
-O2 and -O3 in both 32-bit and 64-bit modes. 

This is a regression from 5.1.x. 


$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/6.0.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr/local/gcc-trunk
--enable-languages=c,c++ --disable-werror --enable-multilib
Thread model: posix
gcc version 6.0.0 20150517 (experimental) [trunk revision 223265] (GCC) 
$ 
$ gcc-trunk -O0 small.c; ./a.out
$ gcc-trunk -Os small.c; ./a.out
$ gcc-5.1 -O1 small.c; ./a.out
$ 
$ gcc-trunk -O1 small.c
$ ./a.out
Aborted (core dumped)
$ 


-


struct
{
  short f1;
} b;

int a = 1, e = -1;
short f;

int
main ()
{
  int g;
  f = e;
  g = b.f1 < 0 ? 0 : f + b.f1;
  if ((g & -4) < 0)
a = 0;

  if (a)
__builtin_abort ();

  return 0;
}


[Bug ipa/66181] [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread clyon at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

Christophe Lyon  changed:

   What|Removed |Added

 CC||clyon at gcc dot gnu.org

--- Comment #3 from Christophe Lyon  ---
Seen when cross-building GCC for ARM targets too.

The problem appeared with r223252:
2015-05-16  Jan HUbicka  

* tree.c (verify_type_variant): Verify tree_base and type_common flags.
(verify_type): Verify STRING_FLAG.


[Bug target/66047] [5 Regression] vlc compilation failure with target attribute

2015-05-17 Thread hubicka at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66047

--- Comment #6 from Jan Hubicka  ---
Author: hubicka
Date: Sun May 17 19:41:23 2015
New Revision: 223272

URL: https://gcc.gnu.org/viewcvs?rev=223272&root=gcc&view=rev
Log:
PR target/66047
* i386.c (ix86_function_sseregparm): Only return -1 if local function
with implied regparm is called from -mno-sse function.
(init_cumulative_args): Output error if ix86_function_sseregparm
return -1 and SSE register would be needed.
(function_arg_advance_32): Likewise.
(function_arg_32): Likewise.
* i386.h (ix86_args): Add decl field.
* gcc.target/i386/pr66047.c: New testcase.

Added:
branches/gcc-5-branch/gcc/testsuite/gcc.target/i386/pr66047.c
Modified:
branches/gcc-5-branch/gcc/ChangeLog
branches/gcc-5-branch/gcc/config/i386/i386.c
branches/gcc-5-branch/gcc/config/i386/i386.h
branches/gcc-5-branch/gcc/testsuite/ChangeLog


[Bug target/66047] vlc compilation failure with target attribute

2015-05-17 Thread hubicka at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66047

Jan Hubicka  changed:

   What|Removed |Added

   Priority|P1  |P2
Summary|[5 Regression] vlc  |vlc compilation failure
   |compilation failure with|with target attribute
   |target attribute|

--- Comment #7 from Jan Hubicka  ---
No longer a regression, but it is still a bug about rejecting valid code that
may be quite common for 32bit builds.


[Bug libstdc++/65942] [5/6 Regression] [C++14] cannot use std::function as comparator in algorithms

2015-05-17 Thread harald at gigawatt dot nl
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65942

--- Comment #12 from Harald van Dijk  ---
(In reply to Harald van Dijk from comment #11)
> The programs in my comment here are accepted by G++ 4.5.4 (with -std=c++0x),
> and rejected by 4.6.4 and later.

But as G++ 4.5 recognises but simply ignores the constexpr keyword, it's not
really a regression. 4.6 is the first that actually implements constexpr
functions, and it was broken in that version already.


[Bug ipa/66181] [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread danglin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

John David Anglin  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2015-05-17
 CC||danglin at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #4 from John David Anglin  ---
Also seen on hppa-unknown-linux-gnu.


[Bug target/54236] [SH] Improve addc and subc insn utilization

2015-05-17 Thread olegendo at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54236

--- Comment #12 from Oleg Endo  ---
Author: olegendo
Date: Sun May 17 21:01:29 2015
New Revision: 223274

URL: https://gcc.gnu.org/viewcvs?rev=223274&root=gcc&view=rev
Log:
gcc/
PR target/54236
* config/sh/sh.md (*addc_2r_t): Use ashift instead of mult.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/sh/sh.md


[Bug middle-end/66148] [6 regression] build/genpreds: Internal error: abort in choose_enum_order, at genpreds.c:1006

2015-05-17 Thread danglin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66148

--- Comment #1 from John David Anglin  ---
Introduced in r223034:

2015-05-12  Thomas Preud'homme  

* combine.c i(set_nonzero_bits_and_sign_copies): Split code updating
rsp->sign_bit_copies and rsp->nonzero_bits into ...
(update_rsp_from_reg_equal): This.  Also use REG_EQUAL note on src if
present to get more accurate information about the number of sign bit
copies and non zero bits.


[Bug middle-end/66148] [6 regression] build/genpreds: Internal error: abort in choose_enum_order, at genpreds.c:1006

2015-05-17 Thread danglin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66148

--- Comment #2 from John David Anglin  ---
Created attachment 35559
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35559&action=edit
Preprocessed source


[Bug bootstrap/66038] [5 regression] (stage 2) build/genmatch segfaults in operand::gen_transform (gcc/hash-table.h:223)

2015-05-17 Thread dougmencken at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66038

--- Comment #9 from Douglas Mencken  ---
I decided to use git bisect to figure out.

Working genmatch@stage2:
  commit 852fa94e29ebd44814054f4657b7385788b0321b (2014-12-16)

$ prev-gcc/build/genmatch --gimple ../gcc-git/gcc/match.pd >../o1
$ gcc/build/genmatch --gimple ../gcc-git/gcc/match.pd >../o2
$ diff -u ../o1 ../o2
(nothing)

git bisect start

git bisect bad d5ad84b309d0d97d3955fb1f62a96fc262df2b76 #==gcc-5_1_0-release
git bisect good 852fa94e29ebd44814054f4657b7385788b0321b # [ unrelated to
genmatch ICE @stage2 ]
git bisect bad 6c13ec429c328b934e9f67d5cd6f5ab55e17ce73 # =%) genmatch issue
(%= @stage2

git bisect skip e2afa5c10fd41fe708959121f373fcb5435ef5d6 # ld issue @stage1
issue
#.# -=-= e2afa5c10fd41fe708959121f373fcb5435ef5d6 =-=-
#.# < @stage1 >
#.# ld: duplicate symbol char* std::__add_grouping(char*, char, char
const*, unsigned long, char const*, char const*) in
.libs/libstdc++.lax/libc++11convenience.a/cxx11-locale-inst.o and
.libs/libstdc++.lax/libc++98convenience.a/locale-inst.o

git bisect skip bedd686385875f1706b0bf60f5ba8bf2ebd0321e # likewise

git checkout 4e28babd199a81ced4eb07ef9b65c13c42e0d830 # fix duplicate symbol
errors in Darwin bootstrap (2014-12-20)

Building 4e28babd199a81ced4eb07ef9b65c13c42e0d830 now.


[Bug fortran/66079] [6 Regression] memory leak with source allocation in internal subprogram

2015-05-17 Thread damian at sourceryinstitute dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66079

--- Comment #3 from Damian Rouson  ---
Thanks for working on this.

Damian


[Bug ipa/66181] [6 Regression]: /usr/include/bits/types.h:134:16: ICE: verify_type failed

2015-05-17 Thread sandra at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66181

sandra at gcc dot gnu.org changed:

   What|Removed |Added

 CC||sandra at gcc dot gnu.org

--- Comment #5 from sandra at gcc dot gnu.org ---
Add nios2-linux-gnu to the list of failing targets as well.


[Bug middle-end/62103] Incorrect folding of bitfield in a union on big endian targets

2015-05-17 Thread thopre01 at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62103

Thomas Preud'homme  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #13 from Thomas Preud'homme  ---
Fixed in all maintained branches.


[Bug rtl-optimization/66168] [6 Regression] ICE at -O3 in elimination_costs_in_insn, at reload1.c:3677

2015-05-17 Thread thopre01 at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66168

Thomas Preud'homme  changed:

   What|Removed |Added

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

--- Comment #2 from Thomas Preud'homme  ---
I can reproduce. I start looking into it.


[Bug c++/66188] New: gcc crashed when compiling programs

2015-05-17 Thread zhangbiao2000 at yeah dot net
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66188

Bug ID: 66188
   Summary: gcc crashed when compiling programs
   Product: gcc
   Version: 4.9.2
Status: UNCONFIRMED
  Severity: critical
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: zhangbiao2000 at yeah dot net
  Target Milestone: ---

I built and installed gcc 4.9.2 on CentOS 6.5 with following steps:
../configure --enable-languages=c,c++ --disable-multilib
make -j4
make install

I build it with gcc 4.4.7 and it seems the installation is successful.

But when I use the new gcc build my program it crashed with the following
backtrace:

g++: internal compiler error: Killed (program cc1plus)
0x409edc execute
../../gcc/gcc.c:2854
0x40a2a4 do_spec_1
../../gcc/gcc.c:4658
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855
0x40b119 do_spec_1
../../gcc/gcc.c:5312
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855
0x40b119 do_spec_1
../../gcc/gcc.c:5312
0x40ae83 do_spec_1
../../gcc/gcc.c:5427
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855
0x40b119 do_spec_1
../../gcc/gcc.c:5312
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855
0x40b119 do_spec_1
../../gcc/gcc.c:5312
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855
0x40b119 do_spec_1
../../gcc/gcc.c:5312
0x40cb66 process_brace_body
../../gcc/gcc.c:5941
0x40cb66 handle_braces
../../gcc/gcc.c:5855


[Bug tree-optimization/14741] graphite with loop blocking and interchanging doesn't optimize a matrix multiplication loop

2015-05-17 Thread Joost.VandeVondele at mat dot ethz.ch
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14741

--- Comment #32 from Joost VandeVondele  
---
(In reply to Thomas Koenig from comment #31)
> If the middle end is not up to this, should we be looking at doing loop
> blocking in the Fortran front end, at least for the Matmul intrinsic?

I think this makes sense, fixing this issue in the middle end seems to be a
project on a different timescale. Ideally, matmul expands to something that
generates good code even at e.g. -O2 -march=native (which would require both
blocking and unrolling). At that point, the inlined code would be faster than
the runtime library...for all sizes.