bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Segmentation fault in as


From: Stefan Keller-Tuberg
Subject: Segmentation fault in as
Date: Tue, 24 Apr 2001 15:16:52 -0400

Hi,

I've been chasing a problem with "as" for several days and finally found the
lines of source code which cause it to crash with a segmentation fault.

I'd be happy to supply more information if there's insufficient details to help
you below.

Cheers,
Stefan

___________________________________________________________
The source code for as came straight from binutils-2.10.1, unchanged. I'm
running redhat 7.0 and tried three separate machines each with the same result.
One machine had redhat 7 installed straight out of the box, no patches or
configuration changes.

I compiled a cross assembler by issuing the following command in an adjacent
directory....
% ../binutils-2.10.1/configure --host=i586-linux --target=m68k-coff
--prefix=/usr/local --program-prefix=m68k- -v
% make all install

I use the following command to assemble:
% /usr/local/bin/m68k-as sys_test.s
Segmentation fault (core dumped)

Here are the source files which cause the crash reduced to a minimum....

sys_test.s contains:
        .include        "macros.i"
        rts

macros.i contains:
# 0

The problem is in the macros.i.

If you remove the white space between the # and the 0, the problem goes away (eg
#0).

The problem remains if you add additional white space between the # and the 0
(eg #    0).

If you change the white space between the # and the 0 into another non white
character, the segmentation fault remains (eg #w0).

If you add characters after the 0, the problem remains (eg # 0sdsf).

If you keep the white space and add a character before the 0, the problem goes
away (eg # w0).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]