Difference between revisions of "Tagged Object Code"

From Ninerpedia
Jump to navigation Jump to search
(Created page with "Tagged object code is the output of the TI-99/4A assembler program. It can be loaded by the linking loader included in the Editor/Assembler cartridge or in the [[Extended Bas...")
 
Line 123: Line 123:
| Content, PSEG offset to be added
| Content, PSEG offset to be added
|-
|-
| 'D'
| class="unsupp" | 'D'
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
|
| class="unsupp" |  
| Load bias (address where to start loading, not supported)
| class="unsupp" | Load bias (address where to start loading)
|-
|-
| 'E'
| class="unsupp" | 'E'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
| REF offset (not supported)
| class="unsupp" | REF offset
|-
|-
| 'F'
| 'F'
Line 141: Line 141:
| end of record
| end of record
|-
|-
| 'G'
| class="unsupp" | 'G'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
|
| class="unsupp" |  
| Symbol table dump (not supported), PSEG
| class="unsupp" | Symbol table dump, PSEG
|-
|-
| 'H'
| class="unsupp" | 'H'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
|
| class="unsupp" |  
| Symbol table dump (not supported), AORG  
| class="unsupp" | Symbol table dump, AORG  
|-
|-
| 'I'
| 'I'
Line 159: Line 159:
| Program ID (for symbol table)
| Program ID (for symbol table)
|-  
|-  
| 'J'
| class="unsupp" | 'J'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
| int16
| class="unsupp" | int16
| Symbol table dump (not supported), CSEG, DSEG
| class="unsupp" | Symbol table dump, CSEG, DSEG
|-  
|-  
| 'K'
| class="unsupp" | 'K'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
|  
| class="unsupp" |  
| External macro reference (not supported)
| class="unsupp" | External macro reference
|-
|-
| 'M'
| class="unsupp" | 'M'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
| int16
| class="unsupp" | int16
| Segment declaration (length in bytes, $DATA for DSEG and $<name> for CSEG '<name>', id), id=0000 for DSEG, 0001 for CSEG<blank>, 0xxx for other CSEG
| class="unsupp" | Segment declaration (length in bytes, $DATA for DSEG and $<name> for CSEG '<name>', id), id=0000 for DSEG, 0001 for CSEG<blank>, 0xxx for other CSEG
|-
|-
| 'N'
| class="unsupp" | 'N'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|  
| class="unsupp" |  
| Common-relocatable content, CSEG offset to be added (value, id)
| class="unsupp" | Common-relocatable content, CSEG offset to be added (value, id)
|-
|-
| 'P'
| class="unsupp" | 'P'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|  
| class="unsupp" |  
| Common-relocatable location (value, cseg_id)
| class="unsupp" | Common-relocatable location (value, cseg_id)
|-
|-
| 'Q'
| class="unsupp" | 'Q'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
| COBOL segment reference
| class="unsupp" | COBOL segment reference
|-
|-
| 'R'
| class="unsupp" | 'R'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|  
| class="unsupp" |  
| Repeat count
| class="unsupp" | Repeat count
|-
|-
| 'S'
| class="unsupp" | 'S'
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
|
| class="unsupp" |  
| Data-relocatable location (value)
| class="unsupp" | Data-relocatable location (value)
|-
|-
| 'T'
| class="unsupp" | 'T'
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
|
| class="unsupp" |  
| Data-relocatable content, DSEG offset to be added
| class="unsupp" | Data-relocatable content, DSEG offset to be added
|-
|-
| 'U'
| class="unsupp" | 'U'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
|
| class="unsupp" |  
| Load symbol
| class="unsupp" | Load symbol
|-
|-
| 'V'
| class="unsupp" | 'V'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
|
| class="unsupp" |  
| Secondary reference, PSEG
| class="unsupp" | Secondary reference, PSEG
|-
|-
| 'W'
| class="unsupp" | 'W'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
| int16
| class="unsupp" | int16
| DEF in DSEG or CSEG (location, name, segment_id)
| class="unsupp" | DEF in DSEG or CSEG (location, name, segment_id)
|-
|-
| 'X'
| class="unsupp" | 'X'
| int16
| class="unsupp" | int16
| byte[6]
| class="unsupp" | byte[6]
| int16
| class="unsupp" | int16
| REF in DSEG or CSEG (location, name, segment_id)
| class="unsupp" | REF in DSEG or CSEG (location, name, segment_id)
|-
|-
| 'Y'
| class="unsupp" | 'Y'
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
|
| class="unsupp" |  
| SREF absolute
| class="unsupp" | SREF absolute
|-
|-
| 'Z'
| class="unsupp" | 'Z'
| int16
| class="unsupp" | int16
| int16
| class="unsupp" | int16
|
| class="unsupp" |  
| SREF data-relocatable, common-relocatable
| class="unsupp" | SREF data-relocatable, common-relocatable
|-
|-
| ':'
| ':'

Revision as of 22:12, 28 June 2013

Tagged object code is the output of the TI-99/4A assembler program. It can be loaded by the linking loader included in the Editor/Assembler cartridge or in the Extended Basic cartridge.

Files containing tagged object code are stored in DIS/FIX 80 format.

Tag Tag content Tag Tag content ... EOL tag
Tag Tag content Tag Tag content ... EOL tag
EOF tag

In tagged object code the tag content is almost always 2 bytes long (like addresses or memory contents). There are two formats for tagged object code:

  • readable code: Contents are encoded as hexadecimal bytes, so the file contents can be edited with a common text editor.
  • compressed code: Contents are stored between the tags by their byte values. This results in a considerably smaller output file (half as long) which can be loaded faster.

The Extended Basic loader only supports the readable code format.

Both loaders (Editor/Assembler and Extended Basic) only support a subset of the tags that can be produced by the TI Assembler. These tags are indicated in the following table by a gray background.

(Thanks to Thierry Nouspikel for the remaining codes!)

Tag Argument Argument Argument Meaning
0x01 int16 byte[8] Identifier, compressed object code
'0' int16 byte[8] Identifier, readable object code
'1' int16 Program entry ("END XXX"), absolute address
'2' int16 Program entry, relocatable address
'3' int16 byte[6] REF (relocatable address, symbol)
'4' int16 byte[6] REF (absolute address, symbol)
'5' int16 byte[6] DEF (relocatable address, symbol)
'6' int16 byte[6] DEF (absolute address, symbol)
'7' int16 Checksum (value)
'8' int16 Checksum (value, ignored)
'9' int16 Absolute location (location counter, from AORG)
'A' int16 Program-relocatable location (location counter, RORG, default)
'B' int16 Absolute contents
'C' int16 Content, PSEG offset to be added
'D' int16 Load bias (address where to start loading)
'E' int16 int16 REF offset
'F' end of record
'G' int16 byte[6] Symbol table dump, PSEG
'H' int16 byte[6] Symbol table dump, AORG
'I' byte[8] Program ID (for symbol table)
'J' int16 byte[6] int16 Symbol table dump, CSEG, DSEG
'K' int16 byte[6] External macro reference
'M' int16 byte[6] int16 Segment declaration (length in bytes, $DATA for DSEG and $<name> for CSEG '<name>', id), id=0000 for DSEG, 0001 for CSEG<blank>, 0xxx for other CSEG
'N' int16 int16 Common-relocatable content, CSEG offset to be added (value, id)
'P' int16 int16 Common-relocatable location (value, cseg_id)
'Q' int16 int16 COBOL segment reference
'R' int16 int16 Repeat count
'S' int16 Data-relocatable location (value)
'T' int16 Data-relocatable content, DSEG offset to be added
'U' int16 byte[6] Load symbol
'V' int16 byte[6] Secondary reference, PSEG
'W' int16 byte[6] int16 DEF in DSEG or CSEG (location, name, segment_id)
'X' int16 byte[6] int16 REF in DSEG or CSEG (location, name, segment_id)
'Y' int16 SREF absolute
'Z' int16 int16 SREF data-relocatable, common-relocatable
':' [string] End of file (with optional comment)