Bug 111427 - gcc-3.2.2-5 creates bad asm with -march=k6
Summary: gcc-3.2.2-5 creates bad asm with -march=k6
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: gcc
Version: 9
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: David Lawrence
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-12-03 16:11 UTC by Stephen Tweedie
Modified: 2007-04-18 16:59 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2003-12-03 16:27:54 UTC
Embargoed:


Attachments (Terms of Use)
gzipped preprocessed test case. (74.75 KB, application/octet-stream)
2003-12-03 16:12 UTC, Stephen Tweedie
no flags Details

Description Stephen Tweedie 2003-12-03 16:11:17 UTC
Description of problem:

gcc-3.2.2-5 creates bad asm with -march=k6: compiling the 2.6 kernel
for a K6 architecture, for example, is giving me the error:
{standard input}: Assembler messages:
{standard input}:614: Error: value of -135 too large for field of 1
bytes at 939

The problem appears to be a "loop" instruction being generated with a
1-byte branch offset, for a target at offset -135 bytes.

Version-Release number of selected component (if applicable):
gcc-3.2.2-5.i386

How reproducible:
Always

Steps to Reproduce:
Compile the attached preprocessed .i file with:

gcc -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing
-fno-common -Wno-unused -pipe -msoft-float
-mpreferred-stack-boundary=2 -march=k6 -fomit-frame-pointer -c -o
ide-dma.o ide-dma.i

Actual results:
The error shown above.

Comment 1 Stephen Tweedie 2003-12-03 16:12:33 UTC
Created attachment 96314 [details]
gzipped preprocessed test case.

Comment 2 Jakub Jelinek 2003-12-03 16:27:54 UTC
Cannot reproduce with gcc-3.2.3-6, gcc-3.2.3-14 nor gcc-3.3.2-2.
There were a few fixes for k6 on both the gcc-3_2-rhl8-branch
and gcc-3_3-rhl-branch, e.g. http://gcc.gnu.org/PR9888

Comment 3 Stephen Tweedie 2003-12-03 16:59:49 UTC
Looks like that could well be the culprit, removing the -Os makes the
symptoms disappear.



Note You need to log in before you can comment on or make changes to this bug.