Bug 1698 - [MIPS] compiling optimized code using mips4 on R12000
Summary: [MIPS] compiling optimized code using mips4 on R12000
Status: RESOLVED INVALID
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: unknown
: P3 normal
Target Milestone: ---
Assignee: Eric Christopher
URL:
Keywords: wrong-code
Depends on:
Blocks:
 
Reported: 2001-01-18 15:36 UTC by mburnham
Modified: 2003-08-17 02:10 UTC (History)
2 users (show)

See Also:
Host: mips-sgi-irix6.5
Target: mips-sgi-irix6.5
Build: mips-sgi-irix6.5
Known to work:
Known to fail:
Last reconfirmed:


Attachments
test_loops.cxx (318 bytes, text/x-c )
2003-05-21 15:17 UTC, mburnham
Details

Note You need to log in before you can comment on or make changes to this bug.
Description mburnham 2001-01-18 15:36:01 UTC
Sample program is compiled with the -mips4 and -O2 flags.
When it is run, the condition of a while loop that tests 
an int against a double fails, but shouldn't.

The problem is only on machines with R12000 processors.
It works ok on a machine with R10000 processors.

Release:
unknown

Environment:
SGI Onyx, IRIX64 6.5, with IP27 Processors
CPU: MIPS R12000 Processor Chip Revision: 3.5
FPU: MIPS R12010 Floating Point Chip Revision: 0.0

How-To-Repeat:
1 - compile using:
    g++ -mips4 -O2 test_loops.cxx -o test_loops
2 - execute test_loops application
Comment 1 mburnham 2001-01-18 15:36:01 UTC
Fix:
compile using the -mips3 flag
Comment 2 Richard Henderson 2002-04-03 17:04:46 UTC
Responsible-Changed-From-To: unassigned->echristo
Responsible-Changed-Why: mips
Comment 3 Eric Christopher 2003-05-17 06:51:24 UTC
State-Changed-From-To: open->feedback
State-Changed-Why: Can you retest this with mainline. I don't have an r12000 machine and the code appears correct (and runs on an r10000 as you noticed).
Comment 4 Dara Hazeghi 2003-06-21 00:16:02 UTC
Just a reminder that this bug is waiting for feedback. Does the code still have problems, using gcc 
3.3? Thanks,

Dara
Comment 5 Andrew Pinski 2003-08-17 02:10:13 UTC
No feedback in 3 months.