diff --git a/BurnOutSharp.Models/LinearExecutable/Executable.cs b/BurnOutSharp.Models/LinearExecutable/Executable.cs
index a3ff1327..c4141c92 100644
--- a/BurnOutSharp.Models/LinearExecutable/Executable.cs
+++ b/BurnOutSharp.Models/LinearExecutable/Executable.cs
@@ -37,17 +37,30 @@ namespace BurnOutSharp.Models.LinearExecutable
///
public ResourceTableEntry[] ResourceTable { get; set; }
- // TODO: Resident-names table
+ ///
+ /// Resident Name table
+ ///
+ public ResidentNameTableEntry[] ResidentNameTable { get; set; }
+
// TODO: Entry table
- // TODO: Module directives table
+ // TODO: Module format directives table
+ // TODO: Resident directives data
+ // TODO: Per-page checksum table
// TODO: Fix-up page table
// TODO: Fix-up record table
// TODO: Imported modules name table
// TODO: Imported procedures name table
- // TODO: Per-page checksum table
- // TODO: Code or Data Segment X
+ // TODO: Preload Pages
+ // TODO: Demand Load Pages
+ // TODO: Iterated Pages
- // TODO: Non-resident table
+ ///
+ /// Non-Resident Name table
+ ///
+ public NonResidentNameTableEntry[] NonResidentNameTable { get; set; }
+
+ // TODO: Non-resident directives data
+ // TODO: Debug Info
}
}
diff --git a/BurnOutSharp.Models/LinearExecutable/NonResidentNameTableEntry.cs b/BurnOutSharp.Models/LinearExecutable/NonResidentNameTableEntry.cs
new file mode 100644
index 00000000..10924d4b
--- /dev/null
+++ b/BurnOutSharp.Models/LinearExecutable/NonResidentNameTableEntry.cs
@@ -0,0 +1,64 @@
+using System.Runtime.InteropServices;
+
+namespace BurnOutSharp.Models.LinearExecutable
+{
+ ///
+ /// The resident and non-resident name tables define the ASCII names and ordinal
+ /// numbers for exported entries in the module. In addition the first entry in
+ /// the resident name table contains the module name. These tables are used to
+ /// translate a procedure name string into an ordinal number by searching for a
+ /// matching name string. The ordinal number is used to locate the entry point
+ /// information in the entry table.
+ ///
+ /// The resident name table is kept resident in system memory while the module is
+ /// loaded.It is intended to contain the exported entry point names that are
+ /// frequently dynamically linked to by name.Non-resident names are not kept in
+ /// memory and are read from the EXE file when a dynamic link reference is made.
+ /// Exported entry point names that are infrequently dynamically linked to by name
+ /// or are commonly referenced by ordinal number should be placed in the
+ /// non-resident name table.The trade off made for references by name is performance
+ /// vs memory usage.
+ ///
+ /// Import references by name require these tables to be searched to obtain the entry
+ /// point ordinal number.Import references by ordinal number provide the fastest
+ /// lookup since the search of these tables is not required.
+ ///
+ /// The strings are CASE SENSITIVE and are NOT NULL TERMINATED.
+ ///
+ ///
+ ///
+ [StructLayout(LayoutKind.Sequential)]
+ public class NonResidentNameTableEntry
+ {
+ ///
+ /// String Length.
+ ///
+ ///
+ /// This defines the length of the string in bytes. A zero length indicates there are
+ /// no more entries in table. The length of each ascii name string is limited to 127
+ /// characters.
+ ///
+ /// The high bit in the LEN field (bit 7) is defined as an Overload bit. This bit
+ /// signifies that additional information is contained in the linear EXE module and
+ /// will be used in the future for parameter type checking.
+ ///
+ public byte Length;
+
+ ///
+ /// ASCII String.
+ ///
+ ///
+ /// This is a variable length string with it's length defined in bytes by the LEN field.
+ /// The string is case case sensitive and is not null terminated.
+ ///
+ public byte[] Name;
+
+ ///
+ /// Ordinal number.
+ ///
+ ///
+ /// The ordinal number in an ordered index into the entry table for this entry point.
+ ///
+ public ushort OrdinalNumber;
+ }
+}
diff --git a/BurnOutSharp.Models/LinearExecutable/ResidentNameTableEntry.cs b/BurnOutSharp.Models/LinearExecutable/ResidentNameTableEntry.cs
new file mode 100644
index 00000000..e97f807e
--- /dev/null
+++ b/BurnOutSharp.Models/LinearExecutable/ResidentNameTableEntry.cs
@@ -0,0 +1,64 @@
+using System.Runtime.InteropServices;
+
+namespace BurnOutSharp.Models.LinearExecutable
+{
+ ///
+ /// The resident and non-resident name tables define the ASCII names and ordinal
+ /// numbers for exported entries in the module. In addition the first entry in
+ /// the resident name table contains the module name. These tables are used to
+ /// translate a procedure name string into an ordinal number by searching for a
+ /// matching name string. The ordinal number is used to locate the entry point
+ /// information in the entry table.
+ ///
+ /// The resident name table is kept resident in system memory while the module is
+ /// loaded.It is intended to contain the exported entry point names that are
+ /// frequently dynamically linked to by name.Non-resident names are not kept in
+ /// memory and are read from the EXE file when a dynamic link reference is made.
+ /// Exported entry point names that are infrequently dynamically linked to by name
+ /// or are commonly referenced by ordinal number should be placed in the
+ /// non-resident name table.The trade off made for references by name is performance
+ /// vs memory usage.
+ ///
+ /// Import references by name require these tables to be searched to obtain the entry
+ /// point ordinal number.Import references by ordinal number provide the fastest
+ /// lookup since the search of these tables is not required.
+ ///
+ /// The strings are CASE SENSITIVE and are NOT NULL TERMINATED.
+ ///
+ ///
+ ///
+ [StructLayout(LayoutKind.Sequential)]
+ public class ResidentNameTableEntry
+ {
+ ///
+ /// String Length.
+ ///
+ ///
+ /// This defines the length of the string in bytes. A zero length indicates there are
+ /// no more entries in table. The length of each ascii name string is limited to 127
+ /// characters.
+ ///
+ /// The high bit in the LEN field (bit 7) is defined as an Overload bit. This bit
+ /// signifies that additional information is contained in the linear EXE module and
+ /// will be used in the future for parameter type checking.
+ ///
+ public byte Length;
+
+ ///
+ /// ASCII String.
+ ///
+ ///
+ /// This is a variable length string with it's length defined in bytes by the LEN field.
+ /// The string is case case sensitive and is not null terminated.
+ ///
+ public byte[] Name;
+
+ ///
+ /// Ordinal number.
+ ///
+ ///
+ /// The ordinal number in an ordered index into the entry table for this entry point.
+ ///
+ public ushort OrdinalNumber;
+ }
+}