[gnu.gcc.bug] Possible 386i GCC Problem

mccarty@aaet.csc.ti.com (Rick McCarty) (07/04/89)

Here's a gcc problem I encountered when building g++ on a Sun 386i.  As
it turns out, it appears that the real bug is in the Sun assembler -
and I'm going to make a local gcc fix to get around it.  You may want to
provide a similar fix in the next version of gcc.

Scenario:

	Building g++ 1.35 on Sun386i, OS version 4.0.1
	Using: 	gcc 1.35
		Sun assembler
	      	bison 1.01

This is the error reported to me when I make:
	
 make all
../gcc/gcc -B../gcc/ -c -g -DSOS -DESKIT -Iconfig -DPARSE_OUTPUT=\"/files/gnu/g++/cplus-parse.output\" cplus-parse.tab.c
Assembler: /tmp/cca02470.s
        aline 1 : .file name too long

Here's the offending line from that ".s" file:

	.file	"cplus-parse.tab.c"

Notes:

	-  If you keep the filename <= 14 chars, things work OK (Gee -
	   I thought I had bought a BERKELEY system, not some phone
	   company version!)

	-  I tried using Sun C instead on this particular module and got
	   no error.  (I guess he truncates that filename - I didn't
	   bother to check)

	-  The gcc fix, of course, is obvious.  During codegen, truncate
	   the name in the .file directive to 14 chars.  Kind of distasteful,
	   but hey . . .

Regards,

Rick McCarty
Texas Instruments Incorporated
mccarty@aaet.csc.ti.com