Bug 10262

Summary: [3.2 regression] cc1plus crashes with large generated code
Product: gcc Reporter: skavenr
Component: middle-endAssignee: Not yet assigned to anyone <unassigned>
Severity: normal CC: bangerth, ehrhardt, gcc-bugs, jbuck
Priority: P3 Keywords: ice-on-valid-code
Version: 3.2.2   
Target Milestone: ---   
Host: Target:
Build: Known to work:
Known to fail: Last reconfirmed:
Attachments: genhvmmain.ii.bz2

Description skavenr 2003-03-29 02:36:00 UTC
Reading specs from /usr/lib/gcc-lib/i386-slackware-linux/3.2.2/specs
Configured with: ../gcc-3.2.2/configure --prefix=/usr --enable-shared --enable-threads=posix --enable-__cxa_atexit --disable-checking --with-gnu-ld --verbose --target=i386-slackware-linux --host=i386-slackware-linux
Thread model: posix
gcc version 3.2.2
 /usr/lib/gcc-lib/i386-slackware-linux/3.2.2/cc1plus -fpreprocessed genhvmmain.ii -quiet -dumpbase genhvmmain.ii -version -o genhvmmain.s
GNU CPP version 3.2.2 (cpplib) (i386 Linux/ELF)
GNU C++ version 3.2.2 (i386-slackware-linux)
        compiled by GNU C version 3.2.2.
genhvmmain.cpp: In member function `bool Hush::HushVM::run(long int)':
genhvmmain.cpp:362: Internal compiler error in convert_regs_1, at reg-stack.c:
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.

gcc version 3.2.2

standard Slackware 9.0 (2.4.20) on Intel Celeron

gcc genhvmmain.ii
Comment 1 Christian Ehrhardt 2003-03-30 21:38:55 UTC
State-Changed-From-To: open->analyzed
State-Changed-Why: Confirmed on 3.2, appears to be fixed with 3.4. A reduced testcase
    is this:
    -------------------------- cut --------------------------
    static const char* ip;
    static unsigned long* sp;
    static const char** rs;
    run(long max_opcodes_to_do)
        void* me_ptr;
        goto *ip;
        *rs++ = (char*)&&l77m; l77m:
        *rs++ = (char*)&&l102m; l102m:
        ip = (char*)&&l155c; goto opcode_counter; l155c:
        *reinterpret_cast<float*>(sp) = (sp[0]);
        return false;
    -------------------------- cut --------------------------
       regards  Christian
Comment 2 Wolfgang Bangerth 2003-03-31 09:47:29 UTC
From: Wolfgang Bangerth <bangerth@ices.utexas.edu>
To: gcc-gnats@gcc.gnu.org
Subject: Re: middle-end/10262
Date: Mon, 31 Mar 2003 09:47:29 -0600 (CST)

 This is actually a regression in 3.2 w.r.t. 3.0. Present mainline and 3.3 
 are not affected.
 Wolfgang Bangerth             email:            bangerth@ticam.utexas.edu
                               www: http://www.ticam.utexas.edu/~bangerth/
Comment 3 Joe Buck 2003-04-25 21:27:42 UTC
State-Changed-From-To: analyzed->closed
State-Changed-Why: Fixed for 3.3.