This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Bug report on 2.91.66



I don't know if this has been addressed, but....
the middle case element below returns a bogus result.
This is the stock compiler for SuSE Linux 6.4.
I'll try updating my compiler tomorrow.  In any event,
if someone knows they fixed the cause of something like this,
I would like to know.

NOTE:  this is completely unoptimized code!!

>>>  ORIGINAL CODE  <<<

    for (;;) {
        switch (nextOption( pOpts, &optState )) {
        case FAILURE:
            goto optionsError;

        case PROBLEM:
            return SUCCESS; /* no more args */

        case SUCCESS:
            break;
        }

>>> PREPROCESSED CODE <<<

    for (;;) {
        switch (nextOption( pOpts, &optState )) {
        case ((tSuccess)-1) :
            goto optionsError;

        case ((tSuccess)1) :
            return ((tSuccess)0) ;  

        case ((tSuccess)0) :
            break;
        }

>>> INTERMIXED ASSEMBLY CODE <<<

	780			
	781			        case PROBLEM:
	782			            return SUCCESS; /* no more args */
    0x8049c70 <doImmediateOpts+320>:     movl   $0x1,%eax
    0x8049c75 <doImmediateOpts+325>:     jmp    0x8049d80
<doImmediateOpts+592>
    0x8049c7a <doImmediateOpts+330>:     leal   0x0(%esi),%esi
	783			

>>> COMPILER VERSION <<<

$ gcc --version
egcs-2.91.66

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]