public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/54080] New: g++ crashes when compiling the following file
@ 2012-07-24 10:55 m101010a at gmail dot com
2012-07-24 11:08 ` [Bug c++/54080] " daniel.kruegler at googlemail dot com
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: m101010a at gmail dot com @ 2012-07-24 10:55 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54080
Bug #: 54080
Summary: g++ crashes when compiling the following file
Classification: Unclassified
Product: gcc
Version: 4.7.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: m101010a@gmail.com
$ cat y.cpp
template <class T>
class vector
{
};
template <template <typename U> class Container,
typename Func
>
vector<int> foo(const Container<int>& input, const Func &func)
{
}
template <template <typename U> class OutType,
typename Func1,
typename FuncRest
>
auto foo(const vector<int> &input, const Func1 &func1, const FuncRest funcrest)
-> decltype(foo<vector>(foo(input, func1), funcrest))
{
return;
}
int main()
{
vector<int> v1;
foo<vector>(v1, 1, 1);
}
$ g++ -v -save-temps -std=c++11 y.cpp
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: /build/src/gcc-4.7-20120721/configure --prefix=/usr
--libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man
--infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/
--enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ --enable-shared
--enable-threads=posix --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch
--enable-libstdcxx-time --enable-gnu-unique-object --enable-linker-build-id
--with-ppl --enable-cloog-backend=isl --disable-ppl-version-check
--disable-cloog-version-check --enable-lto --enable-gold --enable-ld=default
--enable-plugin --with-plugin-ld=ld.gold --with-linker-hash-style=gnu
--enable-multilib --disable-libssp --disable-build-with-cxx
--disable-build-poststage1-with-cxx --enable-checking=release
Thread model: posix
gcc version 4.7.1 20120721 (prerelease) (GCC)
COLLECT_GCC_OPTIONS='-v' '-save-temps' '-std=c++11' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/cc1plus -E -quiet -v -D_GNU_SOURCE
y.cpp -mtune=generic -march=x86-64 -std=c++11 -fpch-preprocess -o y.ii
ignoring nonexistent directory
"/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/x86_64-unknown-linux-gnu
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/backward
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/include
/usr/local/include
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/include-fixed
/usr/include
End of search list.
COLLECT_GCC_OPTIONS='-v' '-save-temps' '-std=c++11' '-shared-libgcc'
'-mtune=generic' '-march=x86-64'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/cc1plus -fpreprocessed y.ii -quiet
-dumpbase y.cpp -mtune=generic -march=x86-64 -auxbase y -std=c++11 -version -o
y.s
GNU C++ (GCC) version 4.7.1 20120721 (prerelease) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.7.1 20120721 (prerelease), GMP version 5.0.5,
MPFR version 3.1.1, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
GNU C++ (GCC) version 4.7.1 20120721 (prerelease) (x86_64-unknown-linux-gnu)
compiled by GNU C version 4.7.1 20120721 (prerelease), GMP version 5.0.5,
MPFR version 3.1.1, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 9968e81036a8f762508137542633c004
‘
Internal compiler error: Error reporting routines re-entered.
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://bugs.archlinux.org/> for instructions.
$ cat y.ii
# 1 "y.cpp"
# 1 "<command-line>"
# 1 "y.cpp"
template <class T>
class vector
{
};
template <template <typename U> class Container,
typename Func
>
vector<int> foo(const Container<int>& input, const Func &func)
{
}
template <template <typename U> class OutType,
typename Func1,
typename FuncRest
>
auto foo(const vector<int> &input, const Func1 &func1, const FuncRest funcrest)
-> decltype(foo<vector>(foo(input, func1), funcrest))
{
return;
}
int main()
{
vector<int> v1;
foo<vector>(v1, 1, 1);
}
On a possibly unrelated note, changing the "return;" in foo to "return
vector<int>();" will cause the file to compile without a compiler crash.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/54080] g++ crashes when compiling the following file
2012-07-24 10:55 [Bug c++/54080] New: g++ crashes when compiling the following file m101010a at gmail dot com
@ 2012-07-24 11:08 ` daniel.kruegler at googlemail dot com
2012-10-10 20:05 ` [Bug c++/54080] [C++11] " paolo.carlini at oracle dot com
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: daniel.kruegler at googlemail dot com @ 2012-07-24 11:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54080
Daniel Krügler <daniel.kruegler at googlemail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |daniel.kruegler at
| |googlemail dot com
--- Comment #1 from Daniel Krügler <daniel.kruegler at googlemail dot com> 2012-07-24 11:07:53 UTC ---
The problem exists in gcc 4.8.0 20120722 (experimental) as well
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/54080] [C++11] g++ crashes when compiling the following file
2012-07-24 10:55 [Bug c++/54080] New: g++ crashes when compiling the following file m101010a at gmail dot com
2012-07-24 11:08 ` [Bug c++/54080] " daniel.kruegler at googlemail dot com
@ 2012-10-10 20:05 ` paolo.carlini at oracle dot com
2013-08-08 8:56 ` paolo.carlini at oracle dot com
2013-08-31 2:18 ` nightstrike at gmail dot com
3 siblings, 0 replies; 5+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-10-10 20:05 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54080
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-on-invalid-code
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-10-10
Ever Confirmed|0 |1
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/54080] [C++11] g++ crashes when compiling the following file
2012-07-24 10:55 [Bug c++/54080] New: g++ crashes when compiling the following file m101010a at gmail dot com
2012-07-24 11:08 ` [Bug c++/54080] " daniel.kruegler at googlemail dot com
2012-10-10 20:05 ` [Bug c++/54080] [C++11] " paolo.carlini at oracle dot com
@ 2013-08-08 8:56 ` paolo.carlini at oracle dot com
2013-08-31 2:18 ` nightstrike at gmail dot com
3 siblings, 0 replies; 5+ messages in thread
From: paolo.carlini at oracle dot com @ 2013-08-08 8:56 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54080
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |paolo.carlini at oracle dot com
--- Comment #2 from Paolo Carlini <paolo.carlini at oracle dot com> ---
On it.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/54080] [C++11] g++ crashes when compiling the following file
2012-07-24 10:55 [Bug c++/54080] New: g++ crashes when compiling the following file m101010a at gmail dot com
` (2 preceding siblings ...)
2013-08-08 8:56 ` paolo.carlini at oracle dot com
@ 2013-08-31 2:18 ` nightstrike at gmail dot com
3 siblings, 0 replies; 5+ messages in thread
From: nightstrike at gmail dot com @ 2013-08-31 2:18 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54080
nightstrike <nightstrike at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |nightstrike at gmail dot com
--- Comment #3 from nightstrike <nightstrike at gmail dot com> ---
I found this thread: http://gcc.gnu.org/ml/gcc-patches/2013-08/msg00564.html
But it seems to have died. Any way to get the fix in? Seems like it fixes a
few bugs.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-08-31 2:18 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-24 10:55 [Bug c++/54080] New: g++ crashes when compiling the following file m101010a at gmail dot com
2012-07-24 11:08 ` [Bug c++/54080] " daniel.kruegler at googlemail dot com
2012-10-10 20:05 ` [Bug c++/54080] [C++11] " paolo.carlini at oracle dot com
2013-08-08 8:56 ` paolo.carlini at oracle dot com
2013-08-31 2:18 ` nightstrike at gmail dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).