4.2bsd C compiler generates incorrect code

Jim McKie jim at mcvax.UUCP
Wed Jan 16 08:32:34 AEST 1985


I am no compiler expert, but I looked at the difference in the
code template tables (pcc/table.c) between a version of the 4.2
compiler which works and one which doesn't. The broken compiler
did not have the NASL (share left register) for the 'convert float
to double for comparison' table entry below:

OPLOG,	FORCC,
	SAREG|AWD,	TFLOAT,
	SAREG|AWD,	TDOUBLE,
		NAREG|NASL,	RESCC,
		"	cvtfd	AL,A1\n	cmpd	A1,AR\nZP",

With the 'NASL', it seems to generate the correct code. Anyone care
to confirm who has more experience with the compiler?

--jim



More information about the Comp.bugs.4bsd.ucb-fixes mailing list