public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase
@ 2004-06-29 20:39 rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:01 ` [Bug tree-optimization/16282] " rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2004-06-29 20:39 UTC (permalink / raw)
  To: gcc-bugs

The tramp3d-v3 testcase is miscompiled by -O2 -fno-exceptions compared to -O2.
http://www.tat.physik.uni-tuebingen.de/~rguenth/gcc/tramp3d-v3.cpp.gz

g++ (GCC) 3.5.0 20040629 (experimental)

The testcase segfaults like:

(gdb) run -n 1
Starting program:
/net/natasa/scratch/natasa/rguenth/gcc-obj-3.5/tramp3d-v3.leafify -n 1

Program received signal SIGSEGV, Segmentation fault.
KernelEvaluator<InlineKernelTag>::evaluate<Field<UniformRectilinearMesh<MeshTraits<3,
double, UniformRectilinearTag, CartesianTag, 3> >, Vector<3, double, Full>,
BrickView>, OpAssign, Array<3, Vector<3, double, Full>, ConstantFunction> >
(lhs=@0x60000fffffff8270, 
    op=@0x60000fffffffb658, rhs=@0x60000fffffff8300) at ../src/tramp3d-v3.cpp:4047
4047	    dom = DomainTraits<T>::getFirst(newdom);
(gdb) bt
#0 
KernelEvaluator<InlineKernelTag>::evaluate<Field<UniformRectilinearMesh<MeshTraits<3,
double, UniformRectilinearTag, CartesianTag, 3> >, Vector<3, double, Full>,
BrickView>, OpAssign, Array<3, Vector<3, double, Full>, ConstantFunction> >
(lhs=@0x60000fffffff8270, 
    op=@0x60000fffffffb658, rhs=@0x60000fffffff8300) at ../src/tramp3d-v3.cpp:4047
#1  0x4000000000120180 in assign<UniformRectilinearMesh<MeshTraits<3, double,
UniformRectilinearTag, CartesianTag, 3> >, Vector<3, double, Full>,
MultiPatchView<GridTag, Remote<Brick>, 3>, Vector<3, double, Full>, OpAssign>
(lhs=@0x60000fffffff8c90, 
    rhs=@0x60000fffffff8d20, op=@0x60000fffffffb658) at ../src/tramp3d-v3.cpp:27733
#2  0x4000000000019040 in main (argc=1, argv=0x1) at ../src/tramp3d-v3.cpp:48677

The math evaluator kernel that segfaults is only miscompiled if using the
leafify patch, but maybe "careful" tuning of some inlining parameters could
reveal the same failure.

I believe this is not a recent failure, as I remember this failing on tree-ssa, too.

-- 
           Summary: -fno-exception miscompiles POOMA testcase
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at tat dot physik dot uni-tuebingen dot de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: ia64-unknown-linux
  GCC host triplet: ia64-unknown-linux
GCC target triplet: ia64-unknown-linux


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug tree-optimization/16282] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
@ 2004-06-29 21:01 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:05 ` rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2004-06-29 21:01 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rguenth at tat dot physik dot uni-tuebingen dot de  2004-06-29 20:59 -------
Created an attachment (id=6654)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=6654&action=view)
failing function with -fexceptions


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug tree-optimization/16282] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:01 ` [Bug tree-optimization/16282] " rguenth at tat dot physik dot uni-tuebingen dot de
@ 2004-06-29 21:05 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:12 ` rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2004-06-29 21:05 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rguenth at tat dot physik dot uni-tuebingen dot de  2004-06-29 21:01 -------
Created an attachment (id=6655)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=6655&action=view)
failing function with -fno-exceptions

Attached two optimized tree-dumps for the (leafified) function the segfault
occours.  One with -fno-exceptions, one without.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug tree-optimization/16282] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:01 ` [Bug tree-optimization/16282] " rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:05 ` rguenth at tat dot physik dot uni-tuebingen dot de
@ 2004-06-29 21:12 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2004-06-29 21:21 ` [Bug tree-optimization/16282] [3.5 Regression] " belyshev at lubercy dot com
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2004-06-29 21:12 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rguenth at tat dot physik dot uni-tuebingen dot de  2004-06-29 21:12 -------
Failure happens on ia32, too, though there I cannot get a backtrace because gdb
segfaults at the segfault, too! :/

alwazn:tmp> gdb ./tramp
GNU gdb 5.3.0.90_2003-05-21-cvs
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...
(gdb) run -n 1
Starting program: /tmp/tramp -n 1
Segmentation fault
alwazn:tmp> echo $?
139


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug tree-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (2 preceding siblings ...)
  2004-06-29 21:12 ` rguenth at tat dot physik dot uni-tuebingen dot de
@ 2004-06-29 21:21 ` belyshev at lubercy dot com
  2004-06-29 21:35 ` pinskia at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: belyshev at lubercy dot com @ 2004-06-29 21:21 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From belyshev at lubercy dot com  2004-06-29 21:18 -------
>Failure happens on ia32, too, though there I cannot get a backtrace because gdb
>segfaults at the segfault, too! :/

>GNU gdb 5.3.0.90_2003-05-21-cvs

It is what supposed to happen. Use gdb 6.1


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
  GCC build triplet|ia64-unknown-linux          |
   GCC host triplet|ia64-unknown-linux          |
 GCC target triplet|ia64-unknown-linux          |
           Keywords|                            |wrong-code
            Summary|-fno-exception miscompiles  |[3.5 Regression] -fno-
                   |POOMA testcase              |exception miscompiles POOMA
                   |                            |testcase
   Target Milestone|---                         |3.5.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug tree-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (3 preceding siblings ...)
  2004-06-29 21:21 ` [Bug tree-optimization/16282] [3.5 Regression] " belyshev at lubercy dot com
@ 2004-06-29 21:35 ` pinskia at gcc dot gnu dot org
  2004-07-01  4:46 ` [Bug rtl-optimization/16282] " pinskia at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-06-29 21:35 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-06-29 21:28 -------
For debugging with 3.5 you need a newer gdb, 6.1 and later will work, this is documented.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug rtl-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (4 preceding siblings ...)
  2004-06-29 21:35 ` pinskia at gcc dot gnu dot org
@ 2004-07-01  4:46 ` pinskia at gcc dot gnu dot org
  2004-07-01 17:00 ` rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-01  4:46 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-01 04:46 -------
Well look into the tree dumps, there was no difference in the code gen for that, what happens if for the 
-fno-exceptions you supply -fno-strict-aliasing too would not fix the problem, if so there is two other 
bugs which describe the problem already.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|tree-optimization           |rtl-optimization


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug rtl-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (5 preceding siblings ...)
  2004-07-01  4:46 ` [Bug rtl-optimization/16282] " pinskia at gcc dot gnu dot org
@ 2004-07-01 17:00 ` rguenth at tat dot physik dot uni-tuebingen dot de
  2004-07-02  5:13 ` pinskia at gcc dot gnu dot org
  2004-07-10  1:25 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: rguenth at tat dot physik dot uni-tuebingen dot de @ 2004-07-01 17:00 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rguenth at tat dot physik dot uni-tuebingen dot de  2004-07-01 17:00 -------
Subject: Re:  [3.5 Regression] -fno-exception
 miscompiles POOMA testcase

pinskia at gcc dot gnu dot org wrote:
> ------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-01 04:46 -------
> Well look into the tree dumps, there was no difference in the code gen for that, what happens if for the 
> -fno-exceptions you supply -fno-strict-aliasing too would not fix the problem, if so there is two other 
> bugs which describe the problem already.

Indeed, that works around it.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug rtl-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (6 preceding siblings ...)
  2004-07-01 17:00 ` rguenth at tat dot physik dot uni-tuebingen dot de
@ 2004-07-02  5:13 ` pinskia at gcc dot gnu dot org
  2004-07-10  1:25 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-02  5:13 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-02 05:13 -------
This is most likely a dup of bug 15262 or PR 14029.  Also note this is a front-end issue if it is a dup of 
one of those two bugs.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [Bug rtl-optimization/16282] [3.5 Regression] -fno-exception miscompiles POOMA testcase
  2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
                   ` (7 preceding siblings ...)
  2004-07-02  5:13 ` pinskia at gcc dot gnu dot org
@ 2004-07-10  1:25 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-10  1:25 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-10 01:25 -------
This is a dup of bug 14029.

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

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16282


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2004-07-10  1:25 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-06-29 20:39 [Bug tree-optimization/16282] New: -fno-exception miscompiles POOMA testcase rguenth at tat dot physik dot uni-tuebingen dot de
2004-06-29 21:01 ` [Bug tree-optimization/16282] " rguenth at tat dot physik dot uni-tuebingen dot de
2004-06-29 21:05 ` rguenth at tat dot physik dot uni-tuebingen dot de
2004-06-29 21:12 ` rguenth at tat dot physik dot uni-tuebingen dot de
2004-06-29 21:21 ` [Bug tree-optimization/16282] [3.5 Regression] " belyshev at lubercy dot com
2004-06-29 21:35 ` pinskia at gcc dot gnu dot org
2004-07-01  4:46 ` [Bug rtl-optimization/16282] " pinskia at gcc dot gnu dot org
2004-07-01 17:00 ` rguenth at tat dot physik dot uni-tuebingen dot de
2004-07-02  5:13 ` pinskia at gcc dot gnu dot org
2004-07-10  1:25 ` pinskia at gcc dot gnu dot org

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).