xref: /csrg-svn/old/pcc/ccom.tahoe/macdefs.h (revision 34581)
1*34581Sdonn /*	macdefs.h	1.7	88/05/31	*/
225833Ssam 
326074Ssam #ifndef _MACDEFS_
426074Ssam #define _MACDEFS_
525833Ssam 
626074Ssam #define makecc(val,i)	lastcon = (lastcon<<8)|((val<<24)>>24);
725833Ssam 
826074Ssam #define ARGINIT		SZINT
926074Ssam #define AUTOINIT	(13*SZINT)
1025833Ssam 
1126074Ssam /*
1226074Ssam  * Storage space requirements.
1326074Ssam  */
1426074Ssam #define SZCHAR		8
1526074Ssam #define SZINT		32
1626074Ssam #define SZFLOAT		32
1726074Ssam #define SZDOUBLE	64
1826074Ssam #define SZLONG		32
1926074Ssam #define SZSHORT		16
2026074Ssam #define SZPOINT		32
2125833Ssam 
2226074Ssam /*
2326074Ssam  * Alignment constraints
2426074Ssam  */
2526074Ssam #define ALCHAR		8
2626074Ssam #define ALINT		32
2726074Ssam #define ALFLOAT		32
2826074Ssam #define ALDOUBLE	32
2926074Ssam #define ALLONG		32
3026074Ssam #define ALSHORT		16
3126074Ssam #define ALPOINT		32
3226074Ssam #define ALSTRUCT	8
3326074Ssam #define ALSTACK		32
3425833Ssam 
3526074Ssam #define ACONFMT	"$0x%lx"	/* format for printing address constants */
3626074Ssam #define CONFMT	"%ld"		/* format for printing constants */
3726074Ssam #define LABFMT	"L%d"		/* format for printing labels */
3825833Ssam 
3926074Ssam typedef	long	CONSZ;		/* size in which constants are converted */
4034090Sbostic typedef	unsigned long	U_CONSZ;/* unsigned version of the above */
4126074Ssam typedef	long	OFFSZ;		/* size in which offsets are kept */
4225833Ssam 
4326074Ssam #define CCTRANS(x) x		/* character set macro */
4425833Ssam 
4526074Ssam /*
4626074Ssam  * Register cookie for stack pointer.
4726074Ssam  */
4826074Ssam #define STKREG	13		/* stack pointer */
4925833Ssam 
5026074Ssam /*
5126074Ssam  * Maximum and minimum register variables
5226074Ssam  */
5326074Ssam #define MINRVAR	6		/* use R6 thru ... */
5426074Ssam #define MAXRVAR	12		/* ... R12 */
5525833Ssam 
5626074Ssam #define BACKAUTO		/* stack grows negatively for automatics */
5726074Ssam #define BACKTEMP		/* stack grows negatively for temporaries */
5826074Ssam /*#define FIELDOPS	/* no hardware field support */
5926074Ssam /*#define RTOLBYTES	/* bytes are number from left to right */
6032891Sdonn #define ADDROREG		/* can unwind &o, where o is OREG */
6132891Sdonn 
6232891Sdonn #define ASSTRINGS		/* assembler handles string initializations */
6332891Sdonn #define STABDOT			/* assembler understands .stabd */
6432891Sdonn #define LCOMM			/* assembler supports .lcomm */
6532892Sdonn #define SPRECC			/* double only arithmetic not supported */
6632891Sdonn 
6726074Ssam #define ENUMSIZE(high,low) INT	/* enums are always stored in full int */
6825833Ssam 
6932891Sdonn #define FIXDEF(p)	if (!nerrors) outstab(p); else
7032891Sdonn #define FIXARG(p)	if (!nerrors) fixarg(p); else
7132891Sdonn #define FIXSTRUCT(p,q)	if (!nerrors) outstruct(p,q); else
7232891Sdonn 
7326074Ssam #ifndef ncopy
7426074Ssam #define	ncopy(q, p)	((q)->in = (p)->in)
7526074Ssam #endif
7625833Ssam 
7732891Sdonn #define aobeg()
7832891Sdonn #define aocode(p)
7932891Sdonn #define aoend()
8032891Sdonn 
8126074Ssam #define	PRTDCON			/* use machine-specific prtdcon routine */
8226074Ssam extern	prtdcon();
8325833Ssam #endif
84