From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22155 invoked by alias); 17 Jan 2006 06:59:57 -0000 Received: (qmail 22130 invoked by uid 48); 17 Jan 2006 06:59:53 -0000 Date: Tue, 17 Jan 2006 06:59:00 -0000 Message-ID: <20060117065953.22129.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug rtl-optimization/25791] -O2 execution fails, -O and -g work In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "ebotcazou at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-01/txt/msg01625.txt.bz2 List-Id: ------- Comment #6 from ebotcazou at gcc dot gnu dot org 2006-01-17 06:59 ------- > (gdb) run > Starting program: > /afs/ir.stanford.edu/users/g/u/guertin/wylsrc/wylbur.ge > > > Program received signal SIGILL, Illegal instruction. > 0x00297064 in hex_to_character () > (gdb) where > #0 0x00297064 in hex_to_character () > #1 0x00297068 in hex_to_character () > Previous frame identical to this frame (corrupt > stack?) Could you post an excerpt of the assembly code around 0x00297064? > As you can see, your suggested change did NOT fix the 'problem'. Well, it was not meant to, my wording was "and see what happens". > What is obvious to me is that -O2 is affecting address computations. What did you mean exactly? Sure, -O2 is expected to have a negative impact on debugging. > There shouldn't be any way to clobber the stack unless addresses are > mis-computed or not stored into variables when they > should. As far as I'm concerned, -O2 is a violation > of the ISO standards concerning Optimization. Well, if there is a code generation bug somewhere, things are expected to go badly at some point. That doesn't mean we should throw the baby with the bath water. > If you need the source code, I can bundle it into a tar.z > file and make it available for download over the web. No, we need a preprocessed testcase, preferably a runnable testcase but a compilable one is sufficient if you can pinpoint the miscompilation. That's explained at the URL I previously posted: http://gcc.gnu.org/bugs.html. Thanks in advance. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25791