RetroLinker
Linker for several 8-bit, 16-bit and 32-bit formats
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
Apple::OMFFormat::Segment::IntersegmentRelocationRecord Class Reference

Represents an INTERSEG or cINTERSEG record, containing an intersegment relocation. More...

#include <gsos.h>

Inheritance diagram for Apple::OMFFormat::Segment::IntersegmentRelocationRecord:
Apple::OMFFormat::Segment::RelocationRecord Apple::OMFFormat::Segment::Record

Public Member Functions

 IntersegmentRelocationRecord (record_type type)
 
 IntersegmentRelocationRecord (record_type type, uint8_t size, uint8_t shift, offset_t source, uint16_t file_number, uint16_t segment_number, offset_t target)
 
offset_t GetLength (const Segment &segment) const override
 Returns the size of the record, as stored in the file.
 
void ReadFile (Segment &segment, Linker::Reader &rd) override
 
void WriteFile (const Segment &segment, Linker::Writer &wr) const override
 
void AddFields (Dumper::Dumper &dump, Dumper::Region &region, const OMFFormat &omf, const Segment &segment, unsigned index, offset_t file_offset, offset_t address) const override
 Adds any further fields to the file region that encompasses this record.
 
- Public Member Functions inherited from Apple::OMFFormat::Segment::RelocationRecord
 RelocationRecord (record_type type)
 
 RelocationRecord (record_type type, uint8_t size, int8_t shift, offset_t source, offset_t target)
 
offset_t GetLength (const Segment &segment) const override
 Returns the size of the record, as stored in the file.
 
void ReadFile (Segment &segment, Linker::Reader &rd) override
 
void WriteFile (const Segment &segment, Linker::Writer &wr) const override
 
void AddFields (Dumper::Dumper &dump, Dumper::Region &region, const OMFFormat &omf, const Segment &segment, unsigned index, offset_t file_offset, offset_t address) const override
 Adds any further fields to the file region that encompasses this record.
 
void AddSignals (Dumper::Block &block, offset_t current_segment_offset) const override
 If this is a relocation record, add the relocation signals to the block.
 
- Public Member Functions inherited from Apple::OMFFormat::Segment::Record
 Record (record_type type)
 
virtual offset_t GetMemoryLength (const Segment &segment, offset_t current_address) const
 Returns the amount of memory the record occupies when loaded into memory. Most records have a length of 0.
 
virtual void Dump (Dumper::Dumper &dump, const OMFFormat &omf, const Segment &segment, unsigned index, offset_t file_offset, offset_t address) const
 Displays information pertaining to this record.
 
virtual void ReadData (size_t bytes, offset_t offset, void *buffer) const
 Attempts to read data from the in-memory image, if possible, it can be assumed that offset + bytes <= GetMemoryLength()
 

Public Attributes

uint16_t file_number = 0
 
uint16_t segment_number = 0
 
- Public Attributes inherited from Apple::OMFFormat::Segment::RelocationRecord
uint8_t size = 0
 
int8_t shift = 0
 
offset_t source = 0
 
offset_t target = 0
 
- Public Attributes inherited from Apple::OMFFormat::Segment::Record
record_type type
 

Additional Inherited Members

- Public Types inherited from Apple::OMFFormat::Segment::Record
enum  record_type {
  OPC_END = 0x00 , OPC_CONST_BASE = 0x00 , OPC_CONST_FIRST = 0x01 , OPC_CONST_LAST = 0xDF ,
  OPC_ALIGN = 0xE0 , OPC_ORG = 0xE1 , OPC_RELOC = 0xE2 , OPC_INTERSEG = 0xE3 ,
  OPC_USING = 0xE4 , OPC_STRONG = 0xE5 , OPC_GLOBAL = 0xE6 , OPC_GEQU = 0xE7 ,
  OPC_MEM = 0xE8 , OPC_EXPR = 0xEB , OPC_ZEXPR = 0xEC , OPC_BEXPR = 0xED ,
  OPC_RELEXPR = 0xEE , OPC_LOCAL = 0xEF , OPC_EQU = 0xF0 , OPC_DS = 0xF1 ,
  OPC_LCONST = 0xF2 , OPC_LEXPR = 0xF3 , OPC_ENTRY = 0xF4 , OPC_C_RELOC = 0xF5 ,
  OPC_C_INTERSEG = 0xF6 , OPC_SUPER = 0xF7
}
 

Detailed Description

Represents an INTERSEG or cINTERSEG record, containing an intersegment relocation.

Member Function Documentation

◆ AddFields()

void OMFFormat::Segment::IntersegmentRelocationRecord::AddFields ( Dumper::Dumper & dump,
Dumper::Region & region,
const OMFFormat & omf,
const Segment & segment,
unsigned index,
offset_t file_offset,
offset_t address ) const
overridevirtual

Adds any further fields to the file region that encompasses this record.

Reimplemented from Apple::OMFFormat::Segment::Record.

◆ GetLength()

offset_t OMFFormat::Segment::IntersegmentRelocationRecord::GetLength ( const Segment & segment) const
overridevirtual

Returns the size of the record, as stored in the file.

Parameters
segmentThe segment the record is part of

Reimplemented from Apple::OMFFormat::Segment::Record.

◆ ReadFile()

void OMFFormat::Segment::IntersegmentRelocationRecord::ReadFile ( Segment & segment,
Linker::Reader & rd )
overridevirtual

Reimplemented from Apple::OMFFormat::Segment::Record.

◆ WriteFile()

void OMFFormat::Segment::IntersegmentRelocationRecord::WriteFile ( const Segment & segment,
Linker::Writer & wr ) const
overridevirtual

Reimplemented from Apple::OMFFormat::Segment::Record.


The documentation for this class was generated from the following files: