Defines the object file and target independent interfaces used by the assembler backend to write native file format object files.
Synopsis
Declared in <llvm/MC/MCObjectWriter.h>
class MCObjectWriter;
Description
The object writer contains a few callbacks used by the assembler to allow the object writer to modify the assembler data structures at appropriate points. Once assembly is complete, the object writer is given the MCAssembler instance, which contains all the symbol and section data which should be emitted as part of writeObject().
Member Functions
Name |
Description |
|
Deleted copy constructor. |
|
Destroy the object writer. |
|
Deleted copy assignment operator. |
Record the given symbol in the address‐significance table to be written diring writeObject(). |
|
Append a declared input file name. |
|
Request emission of an address‐significance table. |
|
|
Perform any late binding of symbols (for example, to assign symbol indices for use when generating relocations). |
Return the symbols recorded for the address‐significance table. |
|
Return the call‐graph profile entries to emit. |
|
Get the MC context associated with the assembler. |
|
Return whether an address‐significance section will be emitted. |
|
Return the list of declared input file names. |
|
Return whether Mach‐O .subsections_via_symbols is enabled. |
|
Check whether the difference (A ‐ B) between two symbol references is fully resolved. |
|
|
Implementation hook for isSymbolRefDifferenceFullyResolved. |
|
Record a relocation entry. |
|
lifetime management |
|
Set the assembler that owns this object writer. |
Set the optional compiler version string (XCOFF). |
|
Enable or disable Mach‐O .subsections_via_symbols. |
|
|
Write the object file and returns the number of bytes written. |
Protected Types
Name |
Description |
One call‐graph profile edge with a from/to pair and edge weight. |
Protected Member Functions
Name |
Description |
|
Construct an object writer with default state. |
Protected Data Members
Name |
Description |
Symbols to record in the address‐significance table. |
|
Assembler that owns this object writer, or null if unset. |
|
Accumulated call‐graph profile edges to emit. |
|
Optional compiler version string (XCOFF‐specific). |
|
True if an address‐significance section should be emitted. |
|
List of declared file names |
|
True if Mach‐O .subsections_via_symbols is enabled. |
Non-Member Functions
Name |
Description |
Construct a new GOFF writer instance. |
|
Construct a new GOFF writer instance with a split‐DWARF stream. |
|
Construct a new SPIR‐V writer instance. |
|
Construct a new Wasm writer that emits split DWARF to a separate stream. |
|
Construct a new Wasm writer instance. |
|
Construct a new Win COFF writer instance with a split‐DWARF stream. |
|
Construct a new Win COFF writer instance. |
|
Construct a new XCOFF writer instance. |
Derived Classes
Name |
Description |
DXContainer object writer that emits DXContainer files from an MCAssembler. |
|
ELF object writer that emits ELF object files from an MCAssembler. |
|
GOFF object writer that emits GOFF object files from an MCAssembler. |
|
Mach‐O object writer that emits Mach‐O object files from an MCAssembler. |
|
SPIR‐V object writer that emits SPIR‐V object files from an MCAssembler. |
|
Win COFF object writer that emits COFF object files from an MCAssembler. |
|
XCOFF object writer that emits XCOFF object files from an MCAssembler. |
Created with MrDocs