public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug optimization/13681] New: [tree-ssa] ICE in get_expr_operands with out-of-bounds access
@ 2004-01-14 15:37 bangerth at dealii dot org
  2004-01-14 22:38 ` [Bug optimization/13681] " pinskia at gcc dot gnu dot org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: bangerth at dealii dot org @ 2004-01-14 15:37 UTC (permalink / raw)
  To: gcc-bugs

Seems like tree-ssa is getting too good at optimizing :-) 
 
Here's an out-of-bounds access that ICEs tree-ssa: 
---------------------------- 
struct X { 
    double values[1]; 
 
    double & foo (const unsigned int index) 
      { return values[index]; } 
}; 
 
void foo() { 
  double d; 
  X h1; 
  h1.foo(1) = d; 
} 
------------------------- 
Note that if I call h1.foo(0), then everything is fine, since we 
stay inside the bounds of the values array. However, with the code 
as shown, we get 
 
deal.II/base> c++ -c -O2 x.cc 
x.cc: In function `void foo()': 
x.cc:8: internal compiler error: in get_expr_operands, at 
tree-ssa-operands.c:918 
Please submit a full bug report, 
with preprocessed source if appropriate. 
See <URL:http://gcc.gnu.org/bugs.html> for instructions. 
 
This is with yesterday's tree-ssa branch. I hope it will be reasonable 
simple to fix, since this is the last ICE I presently get with tree-ssa, 
and if it is fixed I'll switch on a nightly tester for tree-ssa that 
compiles our library. I can then also finally try to run the generated 
code and find all those code-gen bugs :-) 
 
Thanks 
  W.

-- 
           Summary: [tree-ssa] ICE in get_expr_operands with out-of-bounds
                    access
           Product: gcc
           Version: tree-ssa
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: critical
          Priority: P2
         Component: optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bangerth at dealii dot org
                CC: gcc-bugs at gcc dot gnu dot org


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


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

end of thread, other threads:[~2004-01-22  2:16 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-14 15:37 [Bug optimization/13681] New: [tree-ssa] ICE in get_expr_operands with out-of-bounds access bangerth at dealii dot org
2004-01-14 22:38 ` [Bug optimization/13681] " pinskia at gcc dot gnu dot org
2004-01-15 22:17 ` bangerth at dealii dot org
2004-01-16 10:06 ` steven at gcc dot gnu dot org
2004-01-16 12:13 ` steven at gcc dot gnu dot org
2004-01-16 12:48 ` steven at gcc dot gnu dot org
2004-01-21 22:17 ` rth at gcc dot gnu dot org
2004-01-21 22:37 ` bangerth at dealii dot org
2004-01-22  0:05 ` rth at redhat dot com
2004-01-22  0:10 ` bangerth at dealii dot org
2004-01-22  1:58 ` cvs-commit at gcc dot gnu dot org
2004-01-22  2:16 ` rth 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).