[Bug libstdc++/81064] [8 Regression] Inline namespace regression

2017-07-23 Thread fdumont at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81064

--- Comment #6 from François Dumont  ---
Author: fdumont
Date: Sun Jul 23 08:41:35 2017
New Revision: 250458

URL: https://gcc.gnu.org/viewcvs?rev=250458&root=gcc&view=rev
Log:
2017-07-23  François Dumont  

PR libstdc++/81064
* include/bits/algorithmfwd.h: Reorganize versioned namespace.
* include/bits/basic_string.h: Likewise.
* include/bits/c++config: Likewise.
* include/bits/deque.tcc: Likewise.
* include/bits/forward_list.h: Likewise.
* include/bits/forward_list.tcc: Likewise.
* include/bits/hashtable_policy.h: Likewise.
* include/bits/list.tcc: Likewise.
* include/bits/move.h: Likewise.
* include/bits/quoted_string.h: Likewise.
* include/bits/random.h: Likewise.
* include/bits/random.tcc: Likewise.
* include/bits/regex.h: Likewise.
* include/bits/regex.tcc: Likewise.
* include/bits/regex_automaton.h: Likewise.
* include/bits/regex_automaton.tcc: Likewise.
* include/bits/regex_compiler.h: Likewise.
* include/bits/regex_compiler.tcc: Likewise.
* include/bits/regex_constants.h: Likewise.
* include/bits/regex_error.h: Likewise.
* include/bits/regex_executor.h: Likewise.
* include/bits/regex_executor.tcc: Likewise.
* include/bits/regex_scanner.h: Likewise.
* include/bits/regex_scanner.tcc: Likewise.
* include/bits/specfun.h: Likewise.
* include/bits/stl_algo.h: Likewise.
* include/bits/stl_algobase.h: Likewise.
* include/bits/stl_bvector.h: Likewise.
* include/bits/stl_deque.h: Likewise.
* include/bits/stl_iterator.h: Likewise.
* include/bits/stl_iterator_base_funcs.h: Likewise.
* include/bits/stl_list.h: Likewise.
* include/bits/stl_map.h: Likewise.
* include/bits/stl_multimap.h: Likewise.
* include/bits/stl_multiset.h: Likewise.
* include/bits/stl_relops.h: Likewise.
* include/bits/stl_set.h: Likewise.
* include/bits/stl_vector.h: Likewise.
* include/bits/uniform_int_dist.h: Likewise.
* include/bits/unordered_map.h: Likewise.
* include/bits/unordered_set.h: Likewise.
* include/bits/vector.tcc: Likewise.
* include/c_global/cmath: Likewise.
* include/c_std/cmath: Likewise.
* include/decimal/decimal: Likewise.
* include/decimal/decimal.h: Likewise.
* include/experimental/algorithm: Likewise.
* include/experimental/any: Likewise.
* include/experimental/array: Likewise.
* include/experimental/bits/erase_if.h: Likewise.
* include/experimental/bits/fs_dir.h: Likewise.
* include/experimental/bits/fs_fwd.h: Likewise.
* include/experimental/bits/fs_ops.h: Likewise.
* include/experimental/bits/fs_path.h: Likewise.
* include/experimental/bits/lfts_config.h: Likewise.
* include/experimental/bits/shared_ptr.h: Likewise.
* include/experimental/bits/string_view.tcc: Likewise.
* include/experimental/chrono: Likewise.
* include/experimental/deque: Likewise.
* include/experimental/filesystem: Likewise.
* include/experimental/forward_list: Likewise.
* include/experimental/functional: Likewise.
* include/experimental/iterator: Likewise.
* include/experimental/list: Likewise.
* include/experimental/map: Likewise.
* include/experimental/memory: Likewise.
* include/experimental/memory_resource: Likewise.
* include/experimental/numeric: Likewise.
* include/experimental/optional: Likewise.
* include/experimental/propagate_const: Likewise.
* include/experimental/random: Likewise.
* include/experimental/ratio: Likewise.
* include/experimental/regex: Likewise.
* include/experimental/set: Likewise.
* include/experimental/source_location: Likewise.
* include/experimental/string: Likewise.
* include/experimental/string_view: Likewise.
* include/experimental/system_error: Likewise.
* include/experimental/tuple: Likewise.
* include/experimental/type_traits: Likewise.
* include/experimental/unordered_map: Likewise.
* include/experimental/unordered_set: Likewise.
* include/experimental/utility: Likewise.
* include/experimental/vector: Likewise.
* include/ext/bitmap_allocator.h: Likewise.
* include/ext/codecvt_specializations.h: Likewise.
* include/ext/rope: Likewise.
* include/ext/typelist.h: Likewise.
* include/std/chrono: Likewise.
* include/std/complex: Likewise.
* include/std/functional: Likewise.
* include/std/numeric: Likewise.
* include/std/string_view: Likewise.
* include/std/thread: Likewise.
* include/std/variant: Likewise.

[Bug bootstrap/81521] New: After [r250413] GCC 8.0 doesn't compile for Windows

2017-07-23 Thread mateuszb at poczta dot onet.pl
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81521

Bug ID: 81521
   Summary: After [r250413] GCC 8.0 doesn't compile for Windows
   Product: gcc
   Version: 8.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: bootstrap
  Assignee: unassigned at gcc dot gnu.org
  Reporter: mateuszb at poczta dot onet.pl
  Target Milestone: ---

In [r250413] there is a patch Remove TYPE_METHODS. It breaks compiling GCC 8.0
for Windows (mingw-w64).

The bug is:
/home/ma/m/source/gcc-8/gcc/config/i386/winnt-cxx.c: In function ‘void
i386_pe_adjust_class_at_definition(tree)’:
/home/ma/m/source/gcc-8/gcc/config/i386/winnt-cxx.c:123:36: error:
‘TYPE_METHODS’ was not declared in this scope
   for (member = TYPE_METHODS (t); member;  member = DECL_CHAIN (member))
^
/home/ma/m/source/gcc-8/gcc/config/i386/winnt-cxx.c:156:36: error:
‘TYPE_METHODS’ was not declared in this scope
   for (member = TYPE_METHODS (t); member;  member = DECL_CHAIN (member))
^
/home/ma/m/source/gcc-8/gcc/config/i386/t-cygming:32: recipe for target
'winnt-cxx.o' failed
make[1]: *** [winnt-cxx.o] Error 1

[Bug libstdc++/81064] [8 Regression] Inline namespace regression

2017-07-23 Thread fdumont at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81064

François Dumont  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #7 from François Dumont  ---
Versioned namespace simplified to be compatible with front end evolution.

[Bug libstdc++/81522] New: c++17/old-abi/cygwin empty stringstream invalid memory access

2017-07-23 Thread irfanadilovic at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81522

Bug ID: 81522
   Summary: c++17/old-abi/cygwin empty stringstream invalid memory
access
   Product: gcc
   Version: 7.1.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: libstdc++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: irfanadilovic at gmail dot com
  Target Milestone: ---
 Build: x86_64-pc-cygwin

This trivial program:

#include 
int main() {
std::stringstream os; // same with ("") or (std::string())
os.str();
return 0;
}

causes an invalid memory access with gcc 7.1.0 (compiled from source), but only
on Cygwin in c++17 mode with old ABI, and only if the stringstream is
constructed empty. Changing any of those parameters no longer causes the issue.

Thread 1 "string" received signal SIGABRT, Aborted.
0x0001004018a0 in __gnu_cxx::new_allocator::deallocate (this=0x6,
__p=0x3e803fc )
at /usr/local/gcc-7.1.0/include/c++/7.1.0/ext/new_allocator.h:125
125 ::operator delete(__p);
(gdb) bt
#0  0x0001004018a0 in __gnu_cxx::new_allocator::deallocate (this=0x6,
__p=0x3e803fc )
at /usr/local/gcc-7.1.0/include/c++/7.1.0/ext/new_allocator.h:125
#1  0x0001800b25d2 in CreateEventW () from /usr/bin/cygwin1.dll
#2  0x0130 in ?? ()

$ g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/local/gcc-7.1.0/libexec/gcc/x86_64-pc-cygwin/7.1.0/lto-wrapper.exe
Target: x86_64-pc-cygwin
Configured with: ../configure --prefix=/usr/local/gcc-7.1.0
--enable-threads=posix --enable-checking=release --enable-languages=c,c++
--build=x86_64-pc-cygwin --disable-multilib
--with-default-libstdcxx-abi=gcc4-compatible
Thread model: posix
gcc version 7.1.0 (GCC)

Sample program compiled with:

$ g++  -std=c++17 -D_GLIBCXX_USE_CXX11_ABI=0 -ggdb -O0   string.cc   -o string

[Bug target/80569] i686: "shrx" instruction generated in 16-bit mode

2017-07-23 Thread davmac at davmac dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80569

--- Comment #4 from Davin McCall  ---
(In reply to Uroš Bizjak from comment #3)
> Can you please test attached patch?

That seems to fix the problem, yes. Thanks.

[Bug target/80569] i686: "shrx" instruction generated in 16-bit mode

2017-07-23 Thread uros at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80569

--- Comment #5 from uros at gcc dot gnu.org ---
Author: uros
Date: Sun Jul 23 10:28:26 2017
New Revision: 250459

URL: https://gcc.gnu.org/viewcvs?rev=250459&root=gcc&view=rev
Log:
PR target/80569
* config/i386/i386.c (ix86_option_override_internal): Disable
BMI, BMI2 and TBM instructions for -m16.

testsuite/ChangeLog:

PR target/80569
* gcc.target/i386/pr80569.c: New test.


Added:
trunk/gcc/testsuite/gcc.target/i386/pr80569.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/i386/i386.c
trunk/gcc/testsuite/ChangeLog

[Bug target/80569] i686: "shrx" instruction generated in 16-bit mode

2017-07-23 Thread uros at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80569

--- Comment #6 from uros at gcc dot gnu.org ---
Author: uros
Date: Sun Jul 23 10:33:08 2017
New Revision: 250460

URL: https://gcc.gnu.org/viewcvs?rev=250460&root=gcc&view=rev
Log:
PR target/80569
* config/i386/i386.c (ix86_option_override_internal): Disable
BMI, BMI2 and TBM instructions for -m16.

testsuite/ChangeLog:

PR target/80569
* gcc.target/i386/pr80569.c: New test.


Added:
branches/gcc-7-branch/gcc/testsuite/gcc.target/i386/pr80569.c
Modified:
branches/gcc-7-branch/gcc/ChangeLog
branches/gcc-7-branch/gcc/config/i386/i386.c
branches/gcc-7-branch/gcc/testsuite/ChangeLog

[Bug web/3119] Broken gcc mailing list archives

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3119

Eric Gallager  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |WONTFIX

--- Comment #9 from Eric Gallager  ---
(In reply to c...@gcc.gnu.org from comment #8)
> Subject: Re:  Broken gcc mailing list archives
> 
> On Sat, Dec 10, 2005 at 05:30:21AM -, pinskia at gcc dot gnu dot org
> wrote:
> >
> >-- 
> >
> >pinskia at gcc dot gnu dot org changed:
> >
> >   What|Removed |Added
> >
> >   Last reconfirmed|2005-09-07 16:53:59 |2005-12-10 05:30:21
> >   date||
> >
> >
> >http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3119
> >
> >--- You are receiving this mail because: ---
> >You are the assignee for the bug, or are watching the assignee.
> 
> Given the age of these bugs should we just close them as "wontfix"?  I don't
> see anyone stepping up to fix them anytime soon.
> 
> cgf

OK, doing that.

[Bug web/33364] reporting bugs + minimizing testcases

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=33364

Eric Gallager  changed:

   What|Removed |Added

 CC||egallager at gcc dot gnu.org

--- Comment #4 from Eric Gallager  ---
(In reply to Manuel López-Ibáñez from comment #3)
> The bugzilla side is FIXED.
> 
> http://gcc.gnu.org/bugs.html needs a thorough rewriting.

Does this still apply?

[Bug web/36739] Proposal for clarifications in GCC Bugzilla

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=36739

Eric Gallager  changed:

   What|Removed |Added

 CC||egallager at gcc dot gnu.org

--- Comment #8 from Eric Gallager  ---
(In reply to Frédéric Buclin from comment #7)
> (In reply to comment #3)
> > We should really upgrade bugzilla to version 3.0
> 
> bug 43011. :)

...which has now been closed as FIXED. And everything seems hyperlinked to me
now. So is there anything left to do for this bug?

[Bug web/59449] Missing online documentation web pages

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59449

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |FIXED

--- Comment #3 from Eric Gallager  ---
(In reply to otmar.struwe from comment #0)
> The below pages are not available
> 
> http://gcc.gnu.org/onlinedocs/gcc-4.8.2/gcc/i386-and-x86-64-Options.
> html#i386-and-x86-64-Options
> 
> http://gcc.gnu.org/onlinedocs/gcc-4.8.2/gcc/IA-64-Options.html#IA-64-Options
> 
> http://gcc.gnu.org/onlinedocs/gcc-4.8.2/gcc/i386-and-x86-64-Windows-Options.
> html#i386-and-x86-64-Windows-Options

These links all seem to work for me; assuming it was fixed.

[Bug web/61992] git web interface handles some paths badly

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61992

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |WAITING
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #2 from Eric Gallager  ---
Seems like they display properly to me; does it still have issues for you?

[Bug web/64549] Add a 404 page

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64549

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Eric Gallager  ---
Confirmed.

[Bug web/78315] "Changes" don't explain what "LRA" is

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78315

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Eric Gallager  ---
(In reply to Erik Schnetter from comment #0)
> The page  points to the GCC wiki
> page  "LRA by default". However, this
> page never explains what "LRA" actually is. Since this wiki page is
> mentioned so prominently, it could spend a paragraph explaining the acronym.

Confirmed.

[Bug target/81516] Wrong code with -m32 -O2 on x86_64-linux-gnu

2017-07-23 Thread davmac at davmac dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81516

--- Comment #8 from Davin McCall  ---
This problem disappears when I apply the fix for #80706 (as applied to GCC 7
branch). Possibly this is a duplicate of that issue.

[Bug target/81504] [7/8 Regression] gcc-7 regression: vec_st in loop misoptimized

2017-07-23 Thread wschmidt at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81504

Bill Schmidt  changed:

   What|Removed |Added

   Assignee|unassigned at gcc dot gnu.org  |wschmidt at gcc dot 
gnu.org

--- Comment #3 from Bill Schmidt  ---
This is on my list to investigate, but I am about 5 bugs deep right now, so
please be patient and I should get to it relatively soon...

[Bug driver/81523] New: -static -pie behaves differently depending on if --enable-default-pie is used

2017-07-23 Thread hjl.tools at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81523

Bug ID: 81523
   Summary: -static -pie behaves differently depending on if
--enable-default-pie is used
   Product: gcc
   Version: 8.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: driver
  Assignee: unassigned at gcc dot gnu.org
  Reporter: hjl.tools at gmail dot com
Blocks: 81170, 81498
  Target Milestone: ---

[hjl@gnu-tools-1 tmp]$ cat x.c
#include 

int
main ()
{
  printf ("hello\n");
  return 0;
}
[hjl@gnu-tools-1 tmp]$ /mnt/test/usr/gcc-7.1.1-x32-pie/bin/gcc -static -pie
-fPIE x.c
[hjl@gnu-tools-1 tmp]$ /mnt/test/usr/gcc-7.1.1-x32/bin/gcc -static -pie -fPIE
x.c
/usr/local/bin/ld:
/mnt/test/usr/gcc-7.1.1-x32/bin/../lib/gcc/x86_64-pc-linux-gnu/7.1.1/crtbeginT.o:
relocation R_X86_64_32 against hidden symbol `__TMC_END__' can not be used when
making a shared object
/usr/local/bin/ld: /lib/../lib64/libc.a(libc-start.o): relocation R_X86_64_32
against symbol `_dl_starting_up' can not be used when making a shared object;
recompile with -fPIC
...

When gcc is configured with --enable-default-pie, -static completely overrides
-pie.  When gcc is configured without --enable-default-pie, -static partially
overrides -pie.


Referenced Bugs:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81170
[Bug 81170] powerpc*-linux --enable-default-pie chooses incorrect startup files
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81498
[Bug 81498] Support creating static PIE

[Bug c/81524] New: Bogus or missing warnings when dereferencing pointer to deallocated stack memory

2017-07-23 Thread fredrik.hederstie...@securitas-direct.com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81524

Bug ID: 81524
   Summary: Bogus or missing warnings when dereferencing pointer
to deallocated stack memory
   Product: gcc
   Version: 7.1.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
  Assignee: unassigned at gcc dot gnu.org
  Reporter: fredrik.hederstie...@securitas-direct.com
  Target Milestone: ---

Created attachment 41814
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=41814&action=edit
test_deref_ptr_to_dealloc_stack_mem.c

When dereferencing a pointer to deallocated stack memory sometimes warnings
messages are missing or gives bogus information.

See attached test example with 6 different cases.

Some cases does give confusing message I think and some are missing.

Tested with GCC 7.1 and flags:
-Wnull-dereference -Wreturn-local-addr -Wuninitialized

Could it be possible to differ between 'null' pointer and 'dangling' pointer?
In pointer-to analysis it might be possible to in flow to see if pointer will
point to deallocated stack frame memory and mark it as 'dangeling'? Now it
seems to if ref missing it assume NULL and give null-pointer warning in some
cases, which might be bogus?

[Bug target/80695] gratuitous use of stxvx to store multiple pointers

2017-07-23 Thread wschmidt at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80695

--- Comment #6 from Bill Schmidt  ---
Author: wschmidt
Date: Sun Jul 23 15:32:37 2017
New Revision: 250461

URL: https://gcc.gnu.org/viewcvs?rev=250461&root=gcc&view=rev
Log:
2017-07-23  Bill Schmidt  

PR target/80695
* config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
Reduce cost estimate for direct moves.


Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/rs6000/rs6000.c

[Bug c++/81525] New: [7 Regression] Invalid codegen with constexpr variable template

2017-07-23 Thread ldionne.2 at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81525

Bug ID: 81525
   Summary: [7 Regression] Invalid codegen with constexpr variable
template
   Product: gcc
   Version: 7.1.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: ldionne.2 at gmail dot com
  Target Milestone: ---

The following code prints

i = 0
N = 0

when it should print

i = 0
N = 1

This seems to be a regression since GCC 7, although I am not sure exactly
which minor version introduced it. The problem only triggers when 'N' is
constexpr, when it is assigned from a variable template, and when we go
through enough templates (randomly making functions not templates seems
to fix the issue). The code is (sorry, I reduced a lot but could not
reduce further):

#include 

template 
struct integral_constant {
  constexpr operator int() const { return i; }
};

template 
constexpr integral_constant int_{};

template 
void with_index(F f) {
  f(integral_constant<0>{});
}

template 
void print(Dummy) {
  constexpr auto N = ::int_<1>;
  (void)N; // otherwise we get [warning: variable 'N' set but not used]
   // this may be a hint that something is wrong

  auto f = [&](auto i) {
std::cout << "i = " << static_cast(i) << std::endl;
std::cout << "N = " << static_cast(N) << std::endl;
  };

  with_index(f);
}

int main() {
  ::print(0);
}


Live example with GCC 6.3.0: https://wandbox.org/permlink/lclToxN6mnRAS3ol
Live example with GCC 7.1.0: https://wandbox.org/permlink/AUqaHBYlsfwHLUrU
Live example with GCC trunk: https://wandbox.org/permlink/8wxi8MqrS03MbujE

This bug report was lifted from a failure in Boost.Hana's test suite [1],
with the relevant original code being [2]. This is quite worrisome as this
breaks mundane constexpr-utilizing code in a nasty way.

[1]: https://travis-ci.org/boostorg/hana/jobs/256518824#L7663
[2]:
https://github.com/boostorg/hana/blob/e50749/example/tutorial/tag_dispatching.cpp#L72-L85

[Bug target/81516] Wrong code with -m32 -O2 on x86_64-linux-gnu

2017-07-23 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81516

Andrew Pinski  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #9 from Andrew Pinski  ---
Dup of bug 80706 then.

*** This bug has been marked as a duplicate of bug 80706 ***

[Bug target/80706] [7/8 Regression] peephole2 uses uninitialized stack variables on i686

2017-07-23 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80706

Andrew Pinski  changed:

   What|Removed |Added

 CC||davmac at davmac dot org

--- Comment #18 from Andrew Pinski  ---
*** Bug 81516 has been marked as a duplicate of this bug. ***

[Bug target/81521] [8 Regression] After [r250413] GCC 8.0 doesn't compile for Windows

2017-07-23 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81521

Andrew Pinski  changed:

   What|Removed |Added

 Target||*-*-cgwin* *-*-mingw*
 Status|UNCONFIRMED |NEW
   Keywords||build
   Last reconfirmed||2017-07-23
  Component|bootstrap   |target
 Ever confirmed|0   |1
Summary|After [r250413] GCC 8.0 |[8 Regression] After
   |doesn't compile for Windows |[r250413] GCC 8.0 doesn't
   ||compile for Windows
   Target Milestone|--- |8.0

--- Comment #1 from Andrew Pinski  ---
.

[Bug libfortran/80365] undefined memcpy while writing zero length array on unformatted stream in unix.c

2017-07-23 Thread tkoenig at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80365

Thomas Koenig  changed:

   What|Removed |Added

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

--- Comment #5 from Thomas Koenig  ---
Looks straightforward... let's see.

[Bug objc++/23610] obj-c++.dg/bitfield-[14].mm, obj-c++.dg/layout-1.mm fails with the GNU runtime

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=23610

Eric Gallager  changed:

   What|Removed |Added

 Target|64bit targets   |
   Last reconfirmed|2008-02-08 05:59:26 |2017-7-23
 CC||egallager at gcc dot gnu.org
  Known to fail||8.0

--- Comment #10 from Eric Gallager  ---
With gcc 8.0.0 20170702 on i386-apple-darwin9.8.0 I get 3 excess warnings in
32-bit mode and 9 excess warnings in 64-bit mode when compiling the testcase
manually.

[Bug objc++/47261] ICE on @property declaration in the wrong place

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47261

Eric Gallager  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||egallager at gcc dot gnu.org
  Known to work||8.0
 Resolution|--- |FIXED
  Known to fail||4.6.0

--- Comment #2 from Eric Gallager  ---
When I try to compile it with trunk, it gives a sane error message:

$ /usr/local/bin/g++ -c 47261.mm
47261.mm:6:2: error: expected unqualified-id before ‘property’
  @property int x;
  ^
47261.mm:6:2: error: expected ‘;’ before ‘property’

Assuming this was fixed at some point.

[Bug objc++/49070] ObjC++ compiler fails to compile ObjC method invocations without keyword arguments

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49070

Eric Gallager  changed:

   What|Removed |Added

   Keywords||rejects-valid
 CC||egallager at gcc dot gnu.org
  Known to work||4.0.1, 4.1.2
  Known to fail||4.7.0, 8.0

--- Comment #2 from Eric Gallager  ---
Output with gcc trunk:

$ /usr/local/bin/g++ -c 49070.mm
49070.mm: In function ‘objc_object* function(A*)’:
49070.mm:10:21: error: found ‘:’ in nested-name-specifier, expected ‘::’
  return [x method:x :x];
 ^
 ::
49070.mm:10:19: warning: ‘A’ may not respond to ‘-method:’
  return [x method:x :x];
   ^
49070.mm:10:19: warning: (Messages without a matching method signature
49070.mm:10:19: warning: will be assumed to return ‘id’ and accept
49070.mm:10:19: warning: ‘...’ as arguments.)
49070.mm:10:12: error: expected ‘,’ before ‘method’
  return [x method:x :x];
^~
49070.mm:10:12: error: ‘method’ was not declared in this scope
49070.mm:10:18: error: expected ‘,’ before ‘:’ token
  return [x method:x :x];
  ^
49070.mm:10:18: error: expected identifier before ‘:’ token
49070.mm: In lambda function:
49070.mm:10:24: error: expected ‘{’ before ‘;’ token
  return [x method:x :x];
^
49070.mm: In function ‘objc_object* function(A*)’:
49070.mm:10:24: error: cannot convert ‘function(A*)::’ to
‘objc_object*’ in return


I also checked with an older version of g++ (Apple's 4.0.1) and can confirm
that the older version compiled it successfully.

[Bug objc++/56604] Missing obj-c++.srcman target

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56604

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Eric Gallager  ---
(In reply to Pierre Labastie from comment #0)
> According to the doc, there should be a obj-c++.srcman target in
> gcc/objcp/Make-lang.in, which is not presently true, and makes
> bootstrapping with --enable-languages=...,obj-c++,..
> --enable-generated-files-in-srcdir
> fail with:
> make[3]: *** No rule to make target `obj-c++.srcman', needed by
> `lang.srcman'.
> Correction is easy, just add a line:
> obj-c++.srcman:
> to gcc/objcp/Make-lang.in

Confirming that gcc/objcp/Make-lang.in is still missing the
obj-c++.srcman:
line.

[Bug objc++/59117] Is the default constructor generated by the compiler actually called?

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59117

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |INVALID

--- Comment #1 from Eric Gallager  ---
(In reply to Anna Koneva from comment #0)
> Dear sirs!
> I am Anna Koneva from Moscow, Russia. I have faced with some problem using
> XCode 4.6.3 and the LLVM GCC 4.2. I use the following code.
> 
> [snip]
> 
> If you switch to «LLVM GCC» from «Apple LLVM compiler» (selected by default
> after the creation of the project) a checkbox appears in the project
> settings (which is not available for Clang) «Call C++ Default Ctors / Dtors
> in Objective-C» (GCC_OBJC_CALL_CXX_CDTORS, -fobjc-call-cxx-cdtors).
> 

Neither of these are actually the GCC provided here; please report your bug to
Apple instead.

[Bug objc++/66504] ICE using C++ exceptions in Objective-C++

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66504

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1
  Known to fail||8.0

--- Comment #1 from Eric Gallager  ---
Confirmed; message I get now with trunk is:

$ /usr/local/bin/g++ -c 35756.mm
during GIMPLE pass: eh
35756.mm: In function ‘void Problem()’:
35756.mm:1:6: internal compiler error: in objc_eh_runtime_type, at
objc/objc-next-runtime-abi-01.c:2791
 void Problem()
  ^~~
libbacktrace could not find executable to open
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.

Attaching gdb to get a backtrace, I get:

Breakpoint 2, 0x00fb3c74 in internal_error ()
(gdb) bt
#0  0x00fb3c74 in internal_error ()
warning: .o file
"/private/var/root/gcc-git/my_oddly_named_builddir/./mpfr/src/.libs/libmpfr.a(mpfr-gmp.o)"
more recent than executable timestamp
#1  0x014e9561 in fancy_abort ()
#2  0x012db91c in objc_eh_runtime_type ()
#3  0x007b571b in add_type_for_runtime ()
#4  0x007b57ab in gen_eh_region_catch ()
#5  0x00c676c1 in lower_eh_constructs_1 ()
#6  0x00c68deb in (anonymous namespace)::pass_lower_eh::execute ()
#7  0x00af3550 in execute_one_pass ()
#8  0x00af3eb9 in execute_pass_list_1 ()
#9  0x00af3f0e in execute_pass_list ()
#10 0x006bed49 in cgraph_node::analyze ()
#11 0x006c1d3d in analyze_functions ()
#12 0x006c2c42 in symbol_table::finalize_compilation_unit ()
#13 0x00bee32a in compile_file ()
#14 0x01b02420 in toplev::main ()
#15 0x01b03a34 in main ()

I'll have to rebuild with debug info to get a better backtrace.

[Bug objc++/61759] [ICE] [objc] reaching gcc_unreachable in objc_eh_runtime_type at objc/objc-next-runtime-abi-01.c

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61759

Eric Gallager  changed:

   What|Removed |Added

 CC||egallager at gcc dot gnu.org

--- Comment #7 from Eric Gallager  ---
(In reply to Douglas Mencken from comment #6)
> Looks like I found the root of the issue ~
> GCC ICEs when it meets C++ exception handling (try+catch)
> 
> $ cat main.mm
> #include 
> #include 
> 
> int main (void)
> {
>   try {
>   throw 0;
>   } catch (int & e) {
>   std::cout << "caught" << std::endl;
>   }
> 
>   NSString *name = @"GNUstep !";
>   NSAutoreleasePool *pool;
>   pool = [NSAutoreleasePool new];
>   [pool drain];
> }
> 
> $ g++ main.mm -o test.out -framework Foundation -lobjc
> main.mm: In function 'int main()':
> main.mm:4:5: internal compiler error: in objc_eh_runtime_type, at
> objc/objc-next-runtime-abi-01.c:2804
>  int main (void)
>  ^
> libbacktrace could not find executable to open
> Please submit a full bug report,

This is similar to bug 35756 but since you have a different testcase I'll leave
this open as a separate bug. Anyways, I think I have bad headers on my system,
because my compiler chokes in that part:

$ /usr/local/bin/g++ 61759_main.mm -o test.out -framework Foundation -lobjc
In file included from
/System/Library/Frameworks/Security.framework/Headers/Security.h:57:0,
 from
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Headers/LSSharedFileList.h:32,
 from
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Headers/LaunchServices.h:37,
 from
/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:41,
 from
/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.h:20,
 from
/System/Library/Frameworks/Foundation.framework/Headers/NSAppleEventDescriptor.h:8,
 from
/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:107,
 from 61759_main.mm:1:
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:102:46:
error: shift expression ‘(1853123693 << 8)’ overflows [-fpermissive]
 kSecAuthenticationTypeNTLM = AUTH_TYPE_FIX_ ('ntlm'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:102:46:
error: enumerator value for ‘kSecAuthenticationTypeNTLM’ is not an integer
constant
 kSecAuthenticationTypeNTLM = AUTH_TYPE_FIX_ ('ntlm'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:103:46:
error: shift expression ‘(1836281441 << 8)’ overflows [-fpermissive]
 kSecAuthenticationTypeMSN  = AUTH_TYPE_FIX_ ('msna'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:103:46:
error: enumerator value for ‘kSecAuthenticationTypeMSN’ is not an integer
constant
 kSecAuthenticationTypeMSN  = AUTH_TYPE_FIX_ ('msna'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:104:46:
error: shift expression ‘(1685086561 << 8)’ overflows [-fpermissive]
 kSecAuthenticationTypeDPA  = AUTH_TYPE_FIX_ ('dpaa'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:104:46:
error: enumerator value for ‘kSecAuthenticationTypeDPA’ is not an integer
constant
 kSecAuthenticationTypeDPA  = AUTH_TYPE_FIX_ ('dpaa'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:105:46:
error: shift expression ‘(1919967585 << 8)’ overflows [-fpermissive]
 kSecAuthenticationTypeRPA  = AUTH_TYPE_FIX_ ('rpaa'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:105:46:
error: enumerator value for ‘kSecAuthenticationTypeRPA’ is not an integer
constant
 kSecAuthenticationTypeRPA  = AUTH_TYPE_FIX_ ('rpaa'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:106:46:
error: shift expression ‘(1752462448 << 8)’ overflows [-fpermissive]
 kSecAuthenticationTypeHTTPBasic= AUTH_TYPE_FIX_ ('http'),
  ^
/System/Library/Frameworks/Security.framework/Headers/SecKeychain.h:106:46:
error: enumerator value for ‘kSecAuthenticationTypeHTTPBasic’ is not an integer
constant
 kSecAuthenticationTypeHTTPBasic= AUTH_TYPE_FIX_ ('http'),
  ^
/System/Library/Frameworks/Security.framework/Head

[Bug web/61992] git web interface handles some paths badly

2017-07-23 Thread galtgendo at o2 dot pl
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61992

Rafał Mużyło  changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
 Resolution|--- |FIXED

--- Comment #3 from Rafał Mużyło  ---
Indeed, it seems the problem got fixed in the meanwhile.

[Bug libobjc/28565] building with --enable-objc-gc doesn't link with the gc convenience library

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=28565

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |INVALID

--- Comment #1 from Eric Gallager  ---
GCC no longer includes its own gc convenience library; libobjc_gc should be
linking against an external gc library instead.

[Bug libobjc/48626] --enable-objc-gc should be automatic

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48626

Eric Gallager  changed:

   What|Removed |Added

 CC||doko at ubuntu dot com,
   ||egallager at gcc dot gnu.org

--- Comment #1 from Eric Gallager  ---
I think --enable-objc-gc handling was changed recently; Matthias Klose was the
last one to touch it. cc-ing him to see if he thinks we need to leave this
open.

[Bug libobjc/54720] libobjc install-strip target not populated

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54720

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2017-07-23
 CC||egallager at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #5 from Eric Gallager  ---
(In reply to Keith Marshall from comment #4)
> Created attachment 41468 [details]
> Make install-strip work for libobjc
> 
> FWIW, I've applied the attached patch, for the MinGW.org binary distribution
> of GCC-6.3.0

Could you submit this patch to the gcc-patches mailing list please? Anyways,
I'm confirming that the install-strip target in libobjc/Makefile.in is still
unpopulated.

[Bug bootstrap/50229] [5/6/7/8 Regression] Can't cross compile for i686-apple-darwin10 from x86_64-redhat_linux

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50229

Eric Gallager  changed:

   What|Removed |Added

 CC||egallager at gcc dot gnu.org

--- Comment #27 from Eric Gallager  ---
(In reply to Iain Sandoe from comment #21)
> (In reply to Francois-Xavier Coudert from comment #20)
> > This PR appears to report two different issues:
> >   1. cross-compiler targeting Darwin
> 
> cross-compilers targeting Darwin <= 9 are possible using odcctools.
> 
> For "the future"
> I am working on a set of GCC patches and a GAS port that solves part of the
> problem for newer cases.  I intend to post these before stage#1 ends (but
> time is short - esp. with trunk trashed on darwin at the moment).
> 
> However the static linker remains an issue (I have a build of ld64-127.2
> which supports Darwin10, and ppc*) … however, this needs to be
> forward-ported to the latest published sources for ld64 before it will
> support "current" Darwin.  
> 
> In any event, it would be the User's responsibility to obtain a suitable SDK
> for the target - by downloading the appropriate Xcode and extracting the SDK
> as needed.
> 
> in short: "can't be expected to work until there's a set of Darwin
> 'binutils' supporting > darwin 9". (working on providing that).
> 
> >   2. cross-compiler hosted on Darwin
> 
> I do this all the time - it's possible to cross from x86_64-darwin12 ->
> powerpc-darwin9, for example (assuming one has the relevant cctools and
> ld64, and enough patience).
> 
> I have also built native-crosses [x86-64-darwin12=build powerpc-darwin8
> host/target] for the record.
> 
> Darwin works just fine as a host for cross-compilers to Linux.
> 
> (building your own sysroot - in particular GLIBC can be a trial, but if you
> make a sysroot from a standard distro, it's not hard).
> 
> in short (2) is very definitely "works for me"

So does this bug need to stay open then?

[Bug lto/78087] gcc 6.2.0 fails to link temacs from emacs-25.1 with -O0 -flto

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78087

Eric Gallager  changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |WONTFIX

--- Comment #4 from Eric Gallager  ---
(In reply to Richard Biener from comment #3)
> LTO exposes certain classes of coding bugs.  Ask firefox / libreoffice
> people.  So as a start I assume these are all temacs bugs.

I never got in touch with them; I guess we'll just assume this bug is actually
with temacs then...

[Bug target/70420] (Building GCC) mtune=native and internal compiler error at emit-rtl.c:1027

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70420

Eric Gallager  changed:

   What|Removed |Added

 Status|WAITING |NEW
 CC||egallager at gcc dot gnu.org

--- Comment #4 from Eric Gallager  ---
(In reply to Richard Biener from comment #1)
> Please provide preprocessed source of the file and the compiler command with
> -v
> appended so we can see what -mtune/-march expands to.

Reporter has since provided these.

(In reply to Seth Junot from comment #2)
> Created attachment 38124 [details]
> Preprocessed file during libquadmath compilation

Compiling this with trunk I get:

$ /usr/local/bin/gcc -DHAVE_CONFIG_H -I. -g -O2 -v -save-temps -march=native
-mtune=native -mfpmath=sse -m32 -MT math/rem_pio2q.lo -MD -MP -MF
math/.deps/rem_pio2q.Tpo -c rem_pio2q.i
Using built-in specs.
COLLECT_GCC=/usr/local/bin/gcc
Target: i386-apple-darwin9.8.0
Configured with: ../configure --disable-werror --disable-werror-always
--enable-languages=c,c++,lto,objc,obj-c++ --enable-stage1-checking=release,rtl
-C --with-system-libunwind --enable-secureplt --enable-frame-pointer
--enable-debug --with-isl --disable-host-shared --enable-maintainer-mode
--disable-default-pie --with-ld64 --without-pic --enable-target-optspace
CC=/usr/local/bin/gcc CXX=/usr/local/bin/g++ AUTOCONF=/usr/local/bin/autoconf
AUTOHEADER=/usr/local/bin/autoheader AUTORECONF=/usr/local/bin/autoreconf
AUTOM4TE=/usr/local/bin/autom4te AUTOSCAN=/usr/local/bin/autoscan
AUTOUPDATE=/usr/local/bin/autoupdate IFNAMES=/usr/local/bin/ifnames
Thread model: posix
gcc version 8.0.0 20170702 (experimental) (GCC) 
COLLECT_GCC_OPTIONS='-D' 'HAVE_CONFIG_H' '-I' '.' '-g' '-O2' '-v' '-save-temps'
'-march=native' '-mtune=native' '-mfpmath=sse' '-m32' '-MT' 'math/rem_pio2q.lo'
'-MD' '-MP' '-MF' 'math/.deps/rem_pio2q.Tpo' '-c' '-mmacosx-version-min=10.5.8'
'-asm_macosx_version_min=10.5'
 /usr/local/libexec/gcc/i386-apple-darwin9.8.0/8.0.0/cc1 -fpreprocessed
rem_pio2q.i -march=core2 -mmmx -mno-3dnow -msse -msse2 -msse3 -mssse3
-mno-sse4a -mcx16 -msahf -mno-movbe -mno-aes -mno-sha -mno-pclmul -mno-popcnt
-mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mno-bmi -mno-sgx -mno-bmi2
-mno-tbm -mno-avx -mno-avx2 -mno-sse4.2 -msse4.1 -mno-lzcnt -mno-rtm -mno-hle
-mno-rdrnd -mno-f16c -mno-fsgsbase -mno-rdseed -mno-prfchw -mno-adx -mfxsr
-mno-xsave -mno-xsaveopt -mno-avx512f -mno-avx512er -mno-avx512cd -mno-avx512pf
-mno-prefetchwt1 -mno-clflushopt -mno-xsavec -mno-xsaves -mno-avx512dq
-mno-avx512bw -mno-avx512vl -mno-avx512ifma -mno-avx512vbmi -mno-avx5124fmaps
-mno-avx5124vnniw -mno-clwb -mno-mwaitx -mno-clzero -mno-pku -mno-rdpid --param
l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=3072
-mtune=core2 -fPIC -feliminate-unused-debug-symbols -quiet -dumpbase
rem_pio2q.i -mfpmath=sse -m32 -mmacosx-version-min=10.5.8 -auxbase rem_pio2q -g
-O2 -version -o rem_pio2q.s
GNU C11 (GCC) version 8.0.0 20170702 (experimental) (i386-apple-darwin9.8.0)
compiled by GNU C version 8.0.0 20170702 (experimental), GMP version
6.1.0, MPFR version 3.1.4, MPC version 1.0.3, isl version isl-0.16.1-GMP

GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU C11 (GCC) version 8.0.0 20170702 (experimental) (i386-apple-darwin9.8.0)
compiled by GNU C version 8.0.0 20170702 (experimental), GMP version
6.1.0, MPFR version 3.1.4, MPC version 1.0.3, isl version isl-0.16.1-GMP

GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Compiler executable checksum: 5b4c68354b33780d2d34c743d42b6977
during RTL pass: split2
../../../libquadmath/math/rem_pio2q.c: In function ‘__quadmath_rem_pio2q’:
../../../libquadmath/math/rem_pio2q.c:587:1: internal compiler error: in
gen_reg_rtx, at emit-rtl.c:1026
libbacktrace could not find executable to open
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.

For a backtrace I get:


Breakpoint 3, 0x00e085f4 in internal_error ()
(gdb) bt
#0  0x00e085f4 in internal_error ()
warning: .o file
"/private/var/root/gcc-git/my_oddly_named_builddir/./mpfr/src/.libs/libmpfr.a(mpfr-gmp.o)"
more recent than executable timestamp
#1  0x014e4227 in fancy_abort ()
#2  0x013eb932 in __cold_sect_of___Z11gen_reg_rtx12machine_mode ()
#3  0x00305cd2 in gen_split_374 ()
#4  0x00435c11 in split_9 ()
#5  0x005fd4c6 in try_split ()
#6  0x00989990 in split_insn ()
#7  0x0098ed75 in split_all_insns ()
#8  0x0098ee2b in (anonymous namespace)::pass_split_after_reload::execute ()
#9  0x00946770 in execute_one_pass ()
#10 0x009470d9 in execute_pass_list_1 ()
#11 0x00947105 in execute_pass_list_1 ()
#12 0x00947105 in execute_pass_list_1 ()
#13 0x0094712e in execute_pass_list ()
#14 0x0051174a in cgraph_node::expand ()
#15 0x00512c5e in symbol_table::compile ()
#16 0x005151d8 in symbol_table::finalize_c

[Bug c++/81526] New: In structure defined inside template function, template arguments inside the structure are not accepted to have template members.

2017-07-23 Thread ramon.garcia.f+gcc at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81526

Bug ID: 81526
   Summary: In structure defined inside template function,
template arguments inside the structure are not
accepted to have template members.
   Product: gcc
   Version: 6.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: ramon.garcia.f+gcc at gmail dot com
  Target Milestone: ---

Created attachment 41815
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=41815&action=edit
Preprocessed source.

While building Microsoft Bond (http://github.com/Microsoft/bond) source
(release 0b22da6371098fefd921291bfb7c211a33191121 ), I had trouble with what
looks like a GCC bug. I posted a bug report at
https://github.com/Microsoft/bond/issues/538

The conflicting source is
https://github.com/Microsoft/bond/blob/5454d52ea0b55ee696e1bd2727d5492379abe06f/cpp/inc/bond/core/value.h

The issue happens with a template function DeserializeElement.

template 
typename boost::enable_if >::type
inline DeserializeElement(X& var, const I& item, const T& element)
{
struct Deserialize
{
Deserialize(const T& element)
: element(element)
{}

void operator()(typename element_type::type& e)
{
this->element.template Deserialize(e);
}

const T& element;
};

modify_element(var, item, Deserialize(element));
}

The error message is 

In file included from /bond/cpp/inc/bond/core/parser.h:8:0,
 from /bond/cpp/inc/bond/core/apply.h:9,
 from /bond/cpp/inc/bond/core/bond.h:7,
 from /bond/build/cpp/bond/core/bond_apply.h:16,
 from /bond/build/cpp/bond/core/bond_apply.cpp:13:
/bond/cpp/inc/bond/core/value.h: In member function ‘void
bond::DeserializeElement(X&, const I&, const
T&)::Deserialize::operator()(typename bond::element_type::type&)’:
/bond/cpp/inc/bond/core/value.h:644:57: error: non-template type ‘Deserialize’
used as a template
 this->element.template Deserialize(e);

GCC cannot figure out that element.template Deserialize is a template function.

The issue disappears completely if the structure Deserialize is moved out of
the local function.


I am posting preprocessed source of a slightly simplified (replaced
boost::enable_if with std::enable_if).

I also reproduced the problem with GCC 7.1 and 6.3.0 in my Debian GNU/Linux

[Bug c++/81526] In structure defined inside template function, template arguments inside the structure are not accepted to have template members.

2017-07-23 Thread ramon.garcia.f+gcc at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81526

--- Comment #1 from Ramon Garcia  ---
Later, I noticed that this is fixed in GCC development snapshot at
https://gcc.godbolt.org/

Anyway, I would appreciate if this is fixed in  GCC 7.

[Bug middle-end/81030] [8 Regression] ICE on valid code at -O1 (only) on x86_64-linux-gnu: verify_flow_info failed

2017-07-23 Thread asolokha at gmx dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81030

Arseny Solokha  changed:

   What|Removed |Added

 CC||asolokha at gmx dot com

--- Comment #11 from Arseny Solokha  ---
Should this PR be closed now?

[Bug rtl-optimization/81290] [8 Regression] ICE in update_br_prob_note

2017-07-23 Thread asolokha at gmx dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81290

--- Comment #9 from Arseny Solokha  ---
So given the issue is really fixed, should this PR be closed now?

[Bug other/16615] throughout gcc docu and code numerous "can not"'s appear

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=16615

Eric Gallager  changed:

   What|Removed |Added

   Keywords||documentation
   Last reconfirmed|2005-01-16 01:24:20 |2017-7-24
 CC||egallager at gcc dot gnu.org

--- Comment #4 from Eric Gallager  ---
(In reply to Georg Schwarz from comment #0)
> Throughout gcc documentation and code "cannot" is wrongly spelled as "can
> not". The following command executed in the source root reveals the affected
> files:
> find . -type f -print | xargs grep -i "can not"| awk -F: '{print $1}'|uniq
> 
> Please change the text into "cannot". Thanks.

Adding a 'wc -l' to the end of that pipeline shows that 375 are affected.

[Bug bootstrap/80047] fixincludes/fixincl.c: PVS-Studio: Improper Release of Memory Before Removing Last Reference (CWE-401)

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80047

--- Comment #5 from Eric Gallager  ---
(In reply to Andrew Pinski from comment #2)
> >char cwdbuf[MAXPATHLEN];
> 
> This is not a GNU style thing.  GNU style mentions against using arbitrary
> limits.

That's bug 21823 btw.

[Bug c++/81527] New: Missing inherited constructor by "using-declarations"

2017-07-23 Thread tuwwcn at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81527

Bug ID: 81527
   Summary: Missing inherited constructor by "using-declarations"
   Product: gcc
   Version: 6.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c++
  Assignee: unassigned at gcc dot gnu.org
  Reporter: tuwwcn at gmail dot com
  Target Milestone: ---

The below code is rejected by GCC 6.1.0(similar bug,
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70845), 6.3.0, 6.4.0, and 7.1.0,
but accepted by GCC 5.4.0.
I think the code is valid according to the language standard.

Building options: g++ test.cpp --std=c++14 (or g++ test.cpp --std=c++11)

test.cpp is as below:

/
#include 

struct A : public std::pair< int, int> {
using std::pair::pair;
};

int main() {
std::pair p{1, 2}; 
A a(p);
}
///

Error Message produced by GCC 6.4.0(Building Option: g++ test.cpp --std=c++14,
other rejected versions show similar error message):

test.cpp: In function ‘int main()’:
test.cpp:9:10: error: no matching function for call to ‘A::A(std::pair&)’
 A a(p);
  ^
test.cpp:4:32: note: candidate: template() &&
_ImplicitlyConvertiblePair<_U1, _U2>()), bool>::type  > constexpr
A::A(const int&, const int&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note: candidate: template() && (!
_ImplicitlyConvertiblePair<_U1, _U2>())), bool>::type  > constexpr
A::A(const int&, const int&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note: candidate: template::value) || (!
std::is_same::value)), int, int>::_ConstructiblePair<_U1, _U2>() &&
std::_PCC<((! std::is_same::value) || (! std::is_same::value)), int, int>::_ImplicitlyConvertiblePair<_U1, _U2>()), bool>::type
 > constexpr A::A(const std::pair<_T1, _T2>&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
In file included from
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/utility:70:0,
 from test.cpp:1:
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/bits/stl_pair.h:275:18: error:
no type named ‘type’ in ‘struct std::enable_if’
  bool>::type=true>
  ^~~~
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/bits/stl_pair.h:275:18: note:
invalid template non-type parameter
test.cpp:4:32: note: candidate: template::value) || (!
std::is_same::value)), int, int>::_ConstructiblePair<_U1, _U2>() &&
(! std::_PCC<((! std::is_same::value) || (! std::is_same::value)), int, int>::_ImplicitlyConvertiblePair<_U1, _U2>())), bool>::type
 > constexpr A::A(const std::pair<_T1, _T2>&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
In file included from
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/utility:70:0,
 from test.cpp:1:
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/bits/stl_pair.h:284:38: error:
no type named ‘type’ in ‘struct std::enable_if’
  bool>::type=false>
  ^
/home/tuweiwei/tools/gcc-6.4.0/include/c++/6.4.0/bits/stl_pair.h:284:38: note:
invalid template non-type parameter
test.cpp:4:32: note: candidate: template(), bool>::type  >
constexpr A::A(_U1&&, const int&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note: candidate: template(), bool>::type  >
constexpr A::A(_U1&&, const int&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note: candidate: template(), bool>::type  >
constexpr A::A(const int&, _U2&&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note: candidate: template(), bool>::type  >
A::A(const int&, _U2&&)
 using std::pair::pair;
^~~~
test.cpp:4:32: note:   template argument deduction/substitution failed:
test.cpp:9:10: note:   candidate expects 2 arguments, 1 provided
 A a(p);
  ^
test.cpp:4:32: note

[Bug other/28334] SSP always log to syslog()

2017-07-23 Thread egallager at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=28334

Eric Gallager  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 CC||egallager at gcc dot gnu.org
 Resolution|--- |WONTFIX

--- Comment #6 from Eric Gallager  ---
(In reply to John Richard Moser from comment #5)
> (In reply to comment #4)
> > See bug #28328 comment #5 on why this should be closed as WONTFIX/INVALID or
> > the likes.
> > 
> 
> Eh close it WONTFIX because it's not gcc's job.

OK.

[Bug go/81528] New: libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined type ‘SockFilter’

2017-07-23 Thread mfe at live dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81528

Bug ID: 81528
   Summary: libgo/go/syscall/lsf_linux.go:13:28: error: use of
undefined type ‘SockFilter’
   Product: gcc
   Version: 5.4.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: go
  Assignee: ian at airs dot com
  Reporter: mfe at live dot de
CC: cmang at google dot com
  Target Milestone: ---

the exact version of GCC:
gcc-7.1.0

the system type:
NetgearReadyNAS Duo (http://netgear.nas-central.org/wiki/Category:ReadyNasDUO)

the options given when GCC was configured/built:
../gcc-5.4.0/configure  CC=/opt/gcc-4.6/bin/gcc CXX=/opt/gcc-4.6/bin/g++
--enable-languages=c,c++,go --prefix=/opt/gcc-7.1  --with-cpu=v7
--with-mpc=/usr/local  --with-mpfr=/usr/local --with-gmp=/usr/local
--with-isl=/usr/local/ --disable-libstdcxx-pch  --disable-linux-futex
--enable-__cxa_atexit --with-system-zlib --enable-nls --enable-clocale=gnu
--enable-debug  --build=sparc-linux --host=sparc-linux --target=sparc-linux

the complete command line that triggers the bug;
/usr/local/bin/make

the compiler output (error messages, warnings, etc.);
[...]
ll/libcall_uname.go ../../../gcc-5.4.0/libgo/go/syscall/netlink_linux.go
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go
../../../gcc-5.4.0/libgo/go/syscall/libcall_linux_utimesnano.go
../../../gcc-5.4.0/libgo/go/syscall/libcall_linux.go libcalls.go sysinfo.go
syscall_arch.go  -fPIC -o .libs/syscall.o
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined
type ‘SockFilter’
 func LsfStmt(code, k int) *SockFilter {
^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined
type ‘SockFilter’
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:69:8: error: use of undefined
type ‘SockFprog’
  var p SockFprog
^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:70:3: error: reference to
field ‘Len’ in object which has no fields or methods
  p.Len = uint16(len(i))
   ^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:71:3: error: reference to
field ‘Filter’ in object which has no fields or methods
  p.Filter = (*SockFilter)(unsafe.Pointer(&i[0]))
   ^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:71:15: error: reference to
undefined name ‘SockFilter’
  p.Filter = (*SockFilter)(unsafe.Pointer(&i[0]))
   ^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:71:14: error: expected pointer
  p.Filter = (*SockFilter)(unsafe.Pointer(&i[0]))
  ^
../../../gcc-5.4.0/libgo/go/syscall/libcall_linux_utimesnano.go:17:18: error:
reference to undefined name ‘_AT_FDCWD’
  err = utimensat(_AT_FDCWD, path, (*[2]Timespec)(unsafe.Pointer(&ts[0])), 0)
  ^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined
type ‘SockFilter’
 func LsfStmt(code, k int) *SockFilter {
^
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined
type ‘SockFilter’
../../../gcc-5.4.0/libgo/go/syscall/lsf_linux.go:13:28: error: use of undefined
type ‘SockFilter’
make[4]: *** [Makefile:5857: syscall.lo] Error 1
make[4]: Leaving directory '/c/media/gcc-5.4.0-compiled/sparc-linux/libgo'
make[3]: *** [Makefile:4119: all-recursive] Error 1
make[3]: Leaving directory '/c/media/gcc-5.4.0-compiled/sparc-linux/libgo'
make[2]: *** [Makefile:2371: all] Error 2
make[2]: Leaving directory '/c/media/gcc-5.4.0-compiled/sparc-linux/libgo'
make[1]: *** [Makefile:17088: all-target-libgo] Error 2
make[1]: Leaving directory '/c/media/gcc-5.4.0-compiled'
make: *** [Makefile:903: all] Error 2