A Compiler creates a Segment of Control Information in Record 0 of the CodeFile. This is commonly referred to as the CodeFile Segment Zero (SEG0).
The layout of the CodeFile Segment Zero is described in the MCP CompilerSupport Module at 73209305.
The Algol Compiler describes the Segment Zero layout at 10017700.
This section does not describe the Segment Zero layout for an MCP CodeFile.
These are the fields in the Level 4 Segment Zero.
CodeFile Segment Zero | ||||
---|---|---|---|---|
Word | Field | Name | Values | Description |
0 | S0ProgWordV | |||
[47:8] | S0LevelNumberF | 1 = Seg0_Level1 2 = Seg0_Level2 4 = Seg0_Level4 |
Indicates the version of the layout of Seg0. Note: An MCP CodeFile has a Level of 3, it being the CodeFile Tag of the 1st word of BootStrap Code, even though the code is no longer used. |
|
[35:8] | S0ProgReleaseF | Program Release. | ||
[27:12] | S0ProgCycleF | Program Cycle. | ||
[15:16] | S0ProgPatchF | Program Path ID. | ||
1 | S0LibWordV | |||
[43:4] | S0SharingSpecF | 0 = PrivateLibV 1 = SharedByAllV 2 = DontCareLibV 3 = SharedByRunUnitV |
Library Sharing | |
[39:16] | S0ExceptionPCWF | Offset to TADS Exception Handler PCW in D[2]. | ||
2 | S0EntryPointV | Segment Dictionary Index of the PCW for the Program EntryPoint. | ||
3 | S0RollOutV | The Number of Sectors stored in the CodeFile. | ||
4 | S0DateV | Time(15) | Data of Compilation | |
5 | S0TimeV | Time(11) | Time of Compilation | |
6 | S0ExecuteInfoV | |||
[47:1] | NonExecutableF | The CodeFile is not Executable. | ||
[46:1] | NotProgramF | This is a subprogram which can only be bound into a program | ||
[45:1] | UnSafeF | Contains UnSafe Code | ||
[26:1] | IsolatedUseF | The program uses ISOLATED Procedures. | ||
[25:1] | UpLevelF | The program has UpLevel Procedure References. | ||
[24:1] | COMSFlagF | |||
[17:1] | Cobol68FlagF | |||
[16:1] | Fortran66FlagF | |||
[15:8] | CodeGenLevelF | |||
[7:8] | ParamCountF | Number of Program Parameters. See DRIVER in Algol. | ||
7 | S0CoreEstimateV | |||
8 | S0CompileInfoV | See MCP at 15361340. | ||
[47:1] | IPCCapableF | |||
[46:1] | SortCapableF | |||
[45:1] | ControlProgramF | |||
[44:1] | DMSCapableF | |||
[43:1] | BNACapableF | May use BNA Libraries | ||
[42:1] | PrivilegedProgramF | |||
[41:1] | LibraryCapableF | Could FREEZE as a Library | ||
[40:1] | NoGlobalEquateF | |||
[39:1] | TransparentPrivF | |||
[38:1] | AutoSuppressF | |||
[37:1] | ResidentProgramF | |||
[36:1] | WFLRefParamsF | |||
[35:1] | ACRFlagF | AccessRoutines | ||
[34:1] | DynamicCapableF | |||
[33:1] | SDI_HaltF | |||
[32:1] | LockProgramF | |||
[31:8] | LanguageNoF | 0 = AlgolType 1 = CobolType 2 = FortranType 3 = XAlgolType (3.1) 4 = PLIType 5 = JovialType 6 = NewpType 7 = EspolType 8 = DCAlgolType 9 = BasicType 10 = WFLType 11..13 Unused 14 = PascalType 15 = RPGType 16 = Fortran77Type 17 = Cobol74Type 18 = SortType 19 = AdHocType 20 = CCType 21 = Module2Type 22 = Cobol85Type 23 = CPPType 24 =Pascal83Type 25 = JavaType |
See MCP at 15351780 | |
[23:8] | MarkLevelF | COMPILETIME(20) | ||
[15:1] | TaskingProgramF | |||
[14:1] | SecAdminProgramF | |||
[13:1] | SecAdminTransparentF | |||
[12:1] | TaskingTransparentF | |||
[11:1] | TransferCapF | |||
[9:10] | CycleF | COMPILETIME(21) | ||
9 | S0SelfArchiveV | |||
[46:1] | S0ArchiveFlagF | Set if this is a Metalogic Self Extracting Archive. | ||
[15:16] | S0ArchiveAreaF | Area Number of the Area where the Archive. | ||
10 | ||||
11 | ||||
12 | S0FPBV | |||
[40:1] | S0FPBTrustedBitF | TRUE if Myself.MYPPB used | ||
[39:20] | S0FPBLenF | Length | ||
[19:20] | S0FPBRecNumF | Record Number | ||
13 | ||||
14 | ||||
15 | S0StackSizeV | |||
16 | S0SepCompileInfoV | |||
[44:5] | S0BindInfoLvlF | 0 = BindInfo_Level_0 1 = BindInfo_Level_1 |
||
[39:20] | LengthF | The Number of Segments of BindInfo. | ||
[19:20] | AddressF | Segment Address of the BindInfo. | ||
17 | S0IntrinsicTableV | |||
18 | S0D1DescV | See STACKIMAGE in Algol | ||
[39:20] | NumberOfEntriesF | The number of Entries in the Segment Dictionary. Each entry is 8 bytes, a 2 byte (Flags and Tag) and a 6 Byte Word. | ||
[19:20] | SegNumF | The Sector Address of the Start of the Segment Dictionary. | ||
19 | S0LocalCountV | |||
20 | S0WFLRestartInfoV | |||
21 | S0WFLErrorV SoACRSpecDescV |
|||
22 | S0ExportDirectoryV | |||
23 | S0ExecutionCountV | |||
24 | S0D1WSAvrgV | |||
25 | S0RunWSAvrgV | |||
26 | S0LogStartV | |||
27 | S0SkelStackV | |||
28 | S0InstructionDopeV | |||
Program_Unit_Desc_V | Binder definition. Fields depend on Bit [46:1]. | |||
[46:1] | 0 = AddressF contains the address of the File Directory of program units compiled under the $LIBRARY card. | |||
[39:20] | SizeF | File Directory size in Words. | ||
[19:20] | AddressF | File Directory Segment address. | ||
Program_Unit_Desc_V | ||||
[46:1] | 1 = SEGDESCABOVE information. | |||
[39:20] | SizeF | SegDescAbove Base. | ||
[19:20] | AddressF | StackTop. | ||
29 | S0SymbolicDescV |
In MCP CodeFiles, Segment Zero contains the BootStrap. Embedded in the BootStrap is a reference to the Segment Zero Information.
0 [47:16]4"0300" Indicates an MCP CodeFile (It is also a Tag) 1..2 BootStrap Code with Tags 3 Disk Segment Address of Segment Zero Information 4..6 BootStrap Code with Tags 7 [39:20] D[0] Length 8..27 Bootstrap Code with Tags 28 IOCW