public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++
@ 2009-04-20 19:20 d dot g dot gorbachev at gmail dot com
2009-04-20 19:26 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: d dot g dot gorbachev at gmail dot com @ 2009-04-20 19:20 UTC (permalink / raw)
To: gcc-bugs
GCC 4.4.0 20090414 i686-pc-linux-gnu
Configure options:
--prefix=/usr/local --enable-languages=c,c++
--enable-version-specific-runtime-libs --with-host-libstdcxx='-lstdc++ -lm'
--disable-bootstrap --disable-shared --disable-nls
Libraries: GMP 4.3, MPFR 2.4.1-p5, PPL 0.10.2, CLooG-PPL 0.15.
In std::string::begin() (_ZNSs5beginEv):
movl 12(%ebp), %ebx
movl (%ebx), %eax
or:
mov 0xc(%ebp),%ebx
...
mov (%ebx),%edx // crash here
--
Summary: GCC 4.4.0 produces bad code for libstdc++
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: d dot g dot gorbachev at gmail dot com
GCC build triplet: i686-pc-linux-gnu
GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/39823] GCC 4.4.0 produces bad code for libstdc++
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
@ 2009-04-20 19:26 ` d dot g dot gorbachev at gmail dot com
2009-04-20 20:23 ` [Bug middle-end/39823] " pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: d dot g dot gorbachev at gmail dot com @ 2009-04-20 19:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from d dot g dot gorbachev at gmail dot com 2009-04-20 19:26 -------
Created an attachment (id=17657)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17657&action=view)
Preprocessed source
g++ -S -std=gnu++0x -O1 string-inst.cc
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug middle-end/39823] GCC 4.4.0 produces bad code for libstdc++
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
2009-04-20 19:26 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
@ 2009-04-20 20:23 ` pinskia at gcc dot gnu dot org
2009-04-20 21:24 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-04-20 20:23 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from pinskia at gcc dot gnu dot org 2009-04-20 20:23 -------
Do you have an example where this happens?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/39823] GCC 4.4.0 produces bad code for libstdc++
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
2009-04-20 19:26 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
2009-04-20 20:23 ` [Bug middle-end/39823] " pinskia at gcc dot gnu dot org
@ 2009-04-20 21:24 ` d dot g dot gorbachev at gmail dot com
2009-04-20 22:09 ` jakub at gcc dot gnu dot org
2009-04-21 12:24 ` d dot g dot gorbachev at gmail dot com
4 siblings, 0 replies; 6+ messages in thread
From: d dot g dot gorbachev at gmail dot com @ 2009-04-20 21:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from d dot g dot gorbachev at gmail dot com 2009-04-20 21:24 -------
For example, a ppl-0.10.2 test numberinput1 crashed because of this.
std::string::begin() is called at src/checked.cc:171
for (i = num.mantissa.begin(); ...
--
d dot g dot gorbachev at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|middle-end |c++
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/39823] GCC 4.4.0 produces bad code for libstdc++
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
` (2 preceding siblings ...)
2009-04-20 21:24 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
@ 2009-04-20 22:09 ` jakub at gcc dot gnu dot org
2009-04-21 12:24 ` d dot g dot gorbachev at gmail dot com
4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2009-04-20 22:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from jakub at gcc dot gnu dot org 2009-04-20 22:09 -------
What makes you think there is a problem on the _ZNSs5beginEv side?
0(%ebp) is saved %ebp, 4(%ebp) is caller IP, 8(%ebp) is address of return value
(returned by invisible reference), 12(%ebp) is this pointer. If there is a
crash on dereferencing the this pointer, it is a problem in the caller.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c++/39823] GCC 4.4.0 produces bad code for libstdc++
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
` (3 preceding siblings ...)
2009-04-20 22:09 ` jakub at gcc dot gnu dot org
@ 2009-04-21 12:24 ` d dot g dot gorbachev at gmail dot com
4 siblings, 0 replies; 6+ messages in thread
From: d dot g dot gorbachev at gmail dot com @ 2009-04-21 12:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from d dot g dot gorbachev at gmail dot com 2009-04-21 12:24 -------
(In reply to comment #4)
Sorry, my mistake. The problem indeed was in the caller because of different
compiler flags.
--
d dot g dot gorbachev at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39823
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-04-21 12:24 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-20 19:20 [Bug c++/39823] New: GCC 4.4.0 produces bad code for libstdc++ d dot g dot gorbachev at gmail dot com
2009-04-20 19:26 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
2009-04-20 20:23 ` [Bug middle-end/39823] " pinskia at gcc dot gnu dot org
2009-04-20 21:24 ` [Bug c++/39823] " d dot g dot gorbachev at gmail dot com
2009-04-20 22:09 ` jakub at gcc dot gnu dot org
2009-04-21 12:24 ` d dot g dot gorbachev 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).