68c68
< * EXCEPT for globals! These are assumed to be bunched together,
---
> * EXCEPT for globals! These are assumed to be bunched together,
79,85c79,85
< * "isym" Index into the SYMbol table.
< * "ipd" Index into the Procedure Descriptor array.
< * "ifd" Index into the File Descriptor array.
< * "iss" Index into String Space.
< * "cb" Count of Bytes.
< * "rgPd" array whose domain is "0..ipdMax-1" and RanGe is PDR.
< * "rgFd" array whose domain is "0..ifdMax-1" and RanGe is FDR.
---
> * "isym" Index into the SYMbol table.
> * "ipd" Index into the Procedure Descriptor array.
> * "ifd" Index into the File Descriptor array.
> * "iss" Index into String Space.
> * "cb" Count of Bytes.
> * "rgPd" array whose domain is "0..ipdMax-1" and RanGe is PDR.
> * "rgFd" array whose domain is "0..ifdMax-1" and RanGe is FDR.
100,124c100,124
< coff_short magic; /* to verify validity of the table */
< coff_short vstamp; /* version stamp */
< coff_int ilineMax; /* number of line number entries */
< coff_int idnMax; /* max index into dense number table */
< coff_int ipdMax; /* number of procedures */
< coff_int isymMax; /* number of local symbols */
< coff_int ioptMax; /* max index into optimization symbol entries */
< coff_int iauxMax; /* number of auxillary symbol entries */
< coff_int issMax; /* max index into local strings */
< coff_int issExtMax; /* max index into external strings */
< coff_int ifdMax; /* number of file descriptor entries */
< coff_int crfd; /* number of relative file descriptor entries */
< coff_int iextMax; /* max index into external symbols */
< coff_addr cbLine; /* number of bytes for line number entries */
< coff_addr cbLineOffset; /* offset to start of line number entries*/
< coff_addr cbDnOffset; /* offset to start dense number table */
< coff_addr cbPdOffset; /* offset to procedure descriptor table */
< coff_addr cbSymOffset; /* offset to start of local symbols*/
< coff_addr cbOptOffset; /* offset to optimization symbol entries */
< coff_addr cbAuxOffset; /* offset to start of auxillary symbol entries*/
< coff_addr cbSsOffset; /* offset to start of local strings */
< coff_addr cbSsExtOffset; /* offset to start of external strings */
< coff_addr cbFdOffset; /* offset to file descriptor table */
< coff_addr cbRfdOffset; /* offset to relative file descriptor table */
< coff_addr cbExtOffset; /* offset to start of external symbol entries*/
---
> coff_short magic; /* to verify validity of the table */
> coff_short vstamp; /* version stamp */
> coff_int ilineMax; /* number of line number entries */
> coff_int idnMax; /* max index into dense number table */
> coff_int ipdMax; /* number of procedures */
> coff_int isymMax; /* number of local symbols */
> coff_int ioptMax; /* max index into optimization symbol entries */
> coff_int iauxMax; /* number of auxillary symbol entries */
> coff_int issMax; /* max index into local strings */
> coff_int issExtMax; /* max index into external strings */
> coff_int ifdMax; /* number of file descriptor entries */
> coff_int crfd; /* number of relative file descriptor entries */
> coff_int iextMax; /* max index into external symbols */
> coff_addr cbLine; /* number of bytes for line number entries */
> coff_addr cbLineOffset; /* offset to start of line number entries*/
> coff_addr cbDnOffset; /* offset to start dense number table */
> coff_addr cbPdOffset; /* offset to procedure descriptor table */
> coff_addr cbSymOffset; /* offset to start of local symbols*/
> coff_addr cbOptOffset; /* offset to optimization symbol entries */
> coff_addr cbAuxOffset; /* offset to start of auxillary symbol entries*/
> coff_addr cbSsOffset; /* offset to start of local strings */
> coff_addr cbSsExtOffset; /* offset to start of external strings */
> coff_addr cbFdOffset; /* offset to file descriptor table */
> coff_addr cbRfdOffset; /* offset to relative file descriptor table */
> coff_addr cbExtOffset; /* offset to start of external symbol entries*/
141c141
< * the path name given to the compiler. This allows the user
---
> * the path name given to the compiler. This allows the user
148,168c148,168
< coff_addr adr; /* memory address of beginning of file */
< coff_addr cbLineOffset; /* byte offset from header for this file ln's */
< coff_addr cbLine; /* size of lines for this file */
< coff_addr cbSs; /* number of bytes in the ss */
< coff_int rss; /* file name (of source, if known) */
< coff_int issBase; /* file's string space */
< coff_int isymBase; /* beginning of symbols */
< coff_int csym; /* count file's of symbols */
< coff_int ilineBase; /* file's line symbols */
< coff_int cline; /* count of file's line symbols */
< coff_int ioptBase; /* file's optimization entries */
< coff_int copt; /* count of file's optimization entries */
< coff_int ipdFirst; /* start of procedures for this file */
< coff_int cpd; /* count of procedures for this file */
< coff_int iauxBase; /* file's auxiliary entries */
< coff_int caux; /* count of file's auxiliary entries */
< coff_int rfdBase; /* index into the file indirect table */
< coff_int crfd; /* count file indirect entries */
< unsigned lang: 5; /* language for this file */
< unsigned fMerge : 1; /* whether this file can be merged */
< unsigned fReadin : 1; /* true if it was read in (not just created) */
---
> coff_addr adr; /* memory address of beginning of file */
> coff_addr cbLineOffset; /* byte offset from header for this file ln's */
> coff_addr cbLine; /* size of lines for this file */
> coff_addr cbSs; /* number of bytes in the ss */
> coff_int rss; /* file name (of source, if known) */
> coff_int issBase; /* file's string space */
> coff_int isymBase; /* beginning of symbols */
> coff_int csym; /* count file's of symbols */
> coff_int ilineBase; /* file's line symbols */
> coff_int cline; /* count of file's line symbols */
> coff_int ioptBase; /* file's optimization entries */
> coff_int copt; /* count of file's optimization entries */
> coff_int ipdFirst; /* start of procedures for this file */
> coff_int cpd; /* count of procedures for this file */
> coff_int iauxBase; /* file's auxiliary entries */
> coff_int caux; /* count of file's auxiliary entries */
> coff_int rfdBase; /* index into the file indirect table */
> coff_int crfd; /* count file indirect entries */
> unsigned lang: 5; /* language for this file */
> unsigned fMerge : 1; /* whether this file can be merged */
> unsigned fReadin : 1; /* true if it was read in (not just created) */
170,171c170,171
< /* aux's will be in compile host's sex */
< unsigned glevel : 2; /* level this file was compiled with */
---
> /* aux's will be in compile host's sex */
> unsigned glevel : 2; /* level this file was compiled with */
173c173
< coff_uint reserved2;
---
> coff_uint reserved2;
192,203c192,203
< coff_addr adr; /* memory address of start of procedure */
< coff_addr cbLineOffset; /* byte offset for this procedure from the fd base */
< coff_int isym; /* start of local symbol entries */
< coff_int iline; /* start of line number entries*/
< coff_uint regmask; /* save register mask */
< coff_int regoffset; /* save register offset */
< coff_int iopt; /* start of optimization symbol entries*/
< coff_uint fregmask; /* save floating point register mask */
< coff_int fregoffset; /* save floating point register offset */
< coff_int frameoffset; /* frame size */
< coff_int lnLow; /* lowest line in the procedure */
< coff_int lnHigh; /* highest line in the procedure */
---
> coff_addr adr; /* memory address of start of procedure */
> coff_addr cbLineOffset; /* byte offset for this procedure from the fd base */
> coff_int isym; /* start of local symbol entries */
> coff_int iline; /* start of line number entries*/
> coff_uint regmask; /* save register mask */
> coff_int regoffset; /* save register offset */
> coff_int iopt; /* start of optimization symbol entries*/
> coff_uint fregmask; /* save floating point register mask */
> coff_int fregoffset; /* save floating point register offset */
> coff_int frameoffset; /* frame size */
> coff_int lnLow; /* lowest line in the procedure */
> coff_int lnHigh; /* highest line in the procedure */
206,212c206,212
< unsigned gp_used : 1; /* true if the procedure uses GP */
< unsigned reg_frame : 1; /* true if register frame procedure */
< unsigned prof : 1; /* true if compiled with -pg */
< unsigned reserved : 13; /* reserved: must be zero */
< unsigned localoff : 8; /* offset of local variables from vfp */
< coff_short framereg; /* frame pointer register */
< coff_short pcreg; /* offset or reg of return pc */
---
> unsigned gp_used : 1; /* true if the procedure uses GP */
> unsigned reg_frame : 1; /* true if register frame procedure */
> unsigned prof : 1; /* true if compiled with -pg */
> unsigned reserved : 13; /* reserved: must be zero */
> unsigned localoff : 8; /* offset of local variables from vfp */
> coff_short framereg; /* frame pointer register */
> coff_short pcreg; /* offset or reg of return pc */
216c216
< #define ipdNil -1
---
> #define ipdNil -1
228,237c228,237
< coff_addr adr; /* memory address of start of procedure */
< coff_uint regmask; /* save register mask */
< coff_int regoffset; /* save register offset */
< coff_uint fregmask; /* save floating point register mask */
< coff_int fregoffset; /* save floating point register offset */
< coff_int frameoffset; /* frame size */
< coff_ushort framereg; /* frame pointer register */
< coff_ushort pcreg; /* offset or reg of return pc */
< coff_int irpss; /* index into the runtime string table */
< coff_uint reserved;
---
> coff_addr adr; /* memory address of start of procedure */
> coff_uint regmask; /* save register mask */
> coff_int regoffset; /* save register offset */
> coff_uint fregmask; /* save floating point register mask */
> coff_int fregoffset; /* save floating point register offset */
> coff_int frameoffset; /* frame size */
> coff_ushort framereg; /* frame pointer register */
> coff_ushort pcreg; /* offset or reg of return pc */
> coff_int irpss; /* index into the runtime string table */
> coff_uint reserved;
256c256
< typedef coff_int LINER, *pLINER;
---
> typedef coff_int LINER, *pLINER;
259c259
< #define ilineNil -1
---
> #define ilineNil -1
264c264
< * The Symbol Structure (GFW, to those who Know!)
---
> * The Symbol Structure (GFW, to those who Know!)
268,273c268,273
< coff_long value; /* value of symbol */
< coff_int iss; /* index into String Space of name */
< unsigned st : 6; /* symbol type */
< unsigned sc : 5; /* storage class - text, data, etc */
< unsigned reserved : 1; /* reserved */
< unsigned index : 20; /* index into sym/aux table */
---
> coff_long value; /* value of symbol */
> coff_int iss; /* index into String Space of name */
> unsigned st : 6; /* symbol type */
> unsigned sc : 5; /* storage class - text, data, etc */
> unsigned reserved : 1; /* reserved */
> unsigned index : 20; /* index into sym/aux table */
290,291c290,291
< * Same as the SYMR except it contains file context to determine where
< * the index is.
---
> * Same as the SYMR except it contains file context to determine where
> * the index is.
294,299c294,299
< SYMR asym; /* symbol for the external */
< unsigned jmptbl:1; /* symbol is a jump table entry for shlibs */
< unsigned cobol_main:1; /* symbol is a cobol main procedure */
< unsigned weakext:1; /* symbol is weak external */
< unsigned reserved:29; /* reserved for future use */
< coff_int ifd; /* where the iss and index fields point into */
---
> SYMR asym; /* symbol for the external */
> unsigned jmptbl:1; /* symbol is a jump table entry for shlibs */
> unsigned cobol_main:1; /* symbol is a cobol main procedure */
> unsigned weakext:1; /* symbol is weak external */
> unsigned reserved:29; /* reserved for future use */
> coff_int ifd; /* where the iss and index fields point into */
305c305
< /* A U X I L L A R Y T Y P E I N F O R M A T I O N */
---
> /* A U X I L L A R Y T Y P E I N F O R M A T I O N */
313c313
< unsigned bt : 6; /* basic type */
---
> unsigned bt : 6; /* basic type */
318c318
< unsigned tq1 : 4; /* 6 type qualifiers - tqPtr, etc. */
---
> unsigned tq1 : 4; /* 6 type qualifiers - tqPtr, etc. */
330c330
< * table.
---
> * table.
334,335c334,335
< unsigned rfd : 12; /* index into the file indirect table */
< unsigned index : 20; /* index int sym/aux/iss tables */
---
> unsigned rfd : 12; /* index into the file indirect table */
> unsigned index : 20; /* index int sym/aux/iss tables */
341c341
< * a rfd of 0xffffffff is an index into the global table.
---
> * a rfd of 0xffffffff is an index into the global table.
344,345c344,345
< coff_uint rfd; /* index into the file table */
< coff_uint index; /* index int sym/aux/iss tables */
---
> coff_uint rfd; /* index into the file table */
> coff_uint index; /* index int sym/aux/iss tables */
356,359c356,359
< isymMac used by stProc only
< TIR type info
< TIR additional TQ info (if first TIR was not enough)
< rndx if (bt == btStruct,btUnion,btEnum,btSet,btRange,
---
> isymMac used by stProc only
> TIR type info
> TIR additional TQ info (if first TIR was not enough)
> rndx if (bt == btStruct,btUnion,btEnum,btSet,btRange,
363,365c363,365
< dimLow btRange, btSet
< dimMac btRange, btSet
< rndx0 As many as there are tq arrays
---
> dimLow btRange, btSet
> dimMac btRange, btSet
> rndx0 As many as there are tq arrays
372c372
< width in bits if (bit field), width in bits.
---
> width in bits if (bit field), width in bits.
378,385c378,385
< TIR ti; /* type information record */
< RNDXR rndx; /* relative index into symbol table */
< coff_int dnLow; /* low dimension */
< coff_int dnHigh; /* high dimension */
< coff_int isym; /* symbol table index (end of proc) */
< coff_int iss; /* index into string space (not used) */
< coff_int width; /* width for non-default sized struc fields */
< coff_int count; /* count of ranges for variant arm */
---
> TIR ti; /* type information record */
> RNDXR rndx; /* relative index into symbol table */
> coff_int dnLow; /* low dimension */
> coff_int dnHigh; /* high dimension */
> coff_int isym; /* symbol table index (end of proc) */
> coff_int iss; /* index into string space (not used) */
> coff_int width; /* width for non-default sized struc fields */
> coff_int count; /* count of ranges for variant arm */
404,407c404,407
< unsigned ot: 8; /* optimization type */
< unsigned value: 24; /* address where we are moving it to */
< RNDXR rndx; /* points to a symbol or opt entry */
< coff_ulong offset; /* relative offset this occured */
---
> unsigned ot: 8; /* optimization type */
> unsigned value: 24; /* address where we are moving it to */
> RNDXR rndx; /* points to a symbol or opt entry */
> coff_ulong offset; /* relative offset this occured */
409c409
< #define optNil ((pOPTR) 0)
---
> #define optNil ((pOPTR) 0)
417,419c417,419
< * 1) use the file index to get the File indirect entry.
< * 2) use the file indirect entry to get the File descriptor.
< * 3) add the sym index to the base of that file's sym table
---
> * 1) use the file index to get the File indirect entry.
> * 2) use the file indirect entry to get the File descriptor.
> * 3) add the sym index to the base of that file's sym table
425c425
< #define rfdNil -1
---
> #define rfdNil -1
433,435c433,435
< #define cbFIT sizeof(FIT)
< #define ifiNil -1
< #define fiNil ((pFIT) 0)
---
> #define cbFIT sizeof(FIT)
> #define ifiNil -1
> #define fiNil ((pFIT) 0)
451c451
< #endif /* _LANGUAGE_PASCAL */
---
> #endif /* _LANGUAGE_PASCAL */
457,462c457,462
< * and globals, we use dense number so that they can be easily embeded
< * in intermediate code and the programs that process them can
< * use direct access tabls instead of hash table (which would be
< * necesary otherwise because of the sparse name space caused by
< * file index, symbol index pairs. Dense number are represented
< * by RNDXRs.
---
> * and globals, we use dense number so that they can be easily embeded
> * in intermediate code and the programs that process them can
> * use direct access tabls instead of hash table (which would be
> * necesary otherwise because of the sparse name space caused by
> * file index, symbol index pairs. Dense number are represented
> * by RNDXRs.
470c470
< * of enclosing a block of related information. This value is the
---
> * of enclosing a block of related information. This value is the
480,489c480,489
< ST SC VALUE INDEX
< -------- ------ -------- ------
< stFile scText address isymMac
< stLabel scText address ---
< stGlobal scD/B address iaux
< stStatic scD/B address iaux
< stParam scAbs offset iaux
< stLocal scAbs offset iaux
< stProc scText address iaux (isymMac is first AUX)
< stStaticProc scText address iaux (isymMac is first AUX)
---
> ST SC VALUE INDEX
> -------- ------ -------- ------
> stFile scText address isymMac
> stLabel scText address ---
> stGlobal scD/B address iaux
> stStatic scD/B address iaux
> stParam scAbs offset iaux
> stLocal scAbs offset iaux
> stProc scText address iaux (isymMac is first AUX)
> stStaticProc scText address iaux (isymMac is first AUX)
491c491
< stMember scNil ordinal --- (if member of enum)
---
> stMember scNil ordinal --- (if member of enum)
493,494c493,494
< stMember scNil byte offset iaux (if member of struct/union)
< stMember scBits bit offset iaux (bit field spec)
---
> stMember scNil byte offset iaux (if member of struct/union)
> stMember scBits bit offset iaux (bit field spec)
496c496
< stBlock scText address isymMac (text block)
---
> stBlock scText address isymMac (text block)
499,500c499,500
< stBlock scNil cb isymMac (struct/union member define)
< stBlock scNil cMembers isymMac (enum member define)
---
> stBlock scNil cb isymMac (struct/union member define)
> stBlock scNil cMembers isymMac (enum member define)
503,505c503,505
< stStruct scInfo cb isymMac (struct type define)
< stUnion scInfo cb isymMac (union type define)
< stEnum scInfo cMembers isymMac (enum type define)
---
> stStruct scInfo cb isymMac (struct type define)
> stUnion scInfo cb isymMac (union type define)
> stEnum scInfo cMembers isymMac (enum type define)
507,508c507,508
< stEnd scText address isymStart
< stEnd scNil ------- isymStart (struct/union/enum)
---
> stEnd scText address isymStart
> stEnd scNil ------- isymStart (struct/union/enum)
510,512c510,512
< stTypedef scNil ------- iaux
< stRegReloc sc??? value old register number
< stForward sc??? new address isym to original symbol
---
> stTypedef scNil ------- iaux
> stRegReloc sc??? value old register number
> stForward sc??? new address isym to original symbol
514,515c514,515
< stConstant scInfo value --- (scalar)
< stConstant scInfo iss --- (complex, e.g. string)
---
> stConstant scInfo value --- (scalar)
> stConstant scInfo iss --- (complex, e.g. string)