decompiler
1.0.0
|
Contents of the <language> tag in a .ldefs file. More...
#include <sleigh_arch.hh>
Public Member Functions | |
LanguageDescription (void) | |
Constructor. | |
void | decode (Decoder &decoder) |
Parse this description from a stream. More... | |
const string & | getProcessor (void) const |
Get the name of the processor. | |
bool | isBigEndian (void) const |
Return true if the processor is big-endian. | |
int4 | getSize (void) const |
Get the size of the address bus. | |
const string & | getVariant (void) const |
Get the processor variant. | |
const string & | getVersion (void) const |
Get the processor version. | |
const string & | getSlaFile (void) const |
Get filename of the SLEIGH specification. | |
const string & | getProcessorSpec (void) const |
Get the filename of the processor specification. | |
const string & | getId (void) const |
Get the language id string associated with this processor. | |
const string & | getDescription (void) const |
Get a description of the processor. | |
bool | isDeprecated (void) const |
Return true if this specification is deprecated. | |
const CompilerTag & | getCompiler (const string &nm) const |
Get compiler specification of the given name. More... | |
int4 | numCompilers (void) const |
Get the number of compiler records. | |
const CompilerTag & | getCompiler (int4 i) const |
Get the i-th compiler record. | |
int4 | numTruncations (void) const |
Get the number of truncation records. | |
const TruncationTag & | getTruncation (int4 i) const |
Get the i-th truncation record. | |
Private Attributes | |
string | processor |
Name of processor. | |
bool | isbigendian |
Set to true if this processor is big-endian. | |
int4 | size |
Size of address bus in bits. | |
string | variant |
Name of processor variant or "default". | |
string | version |
Version of the specification. | |
string | slafile |
Name of .sla file for processor. | |
string | processorspec |
Name of .pspec file. | |
string | id |
Unique id for this language. | |
string | description |
Human readable description of this language. | |
bool | deprecated |
Set to true if the specification is considered deprecated. | |
vector< CompilerTag > | compilers |
List of compiler specifications compatible with this processor. | |
vector< TruncationTag > | truncations |
Address space truncations required by this processor. | |
Contents of the <language> tag in a .ldefs file.
This class contains meta-data describing a single processor and the set of files used to analyze it. Ghidra requires a compiled SLEIGH specification file (.sla), a processor specification file (.pspec), and a compiler specification file (.cspec) in order to support disassembly/decompilation of a processor. This class supports a single processor, as described by a single SLEIGH file and processor spec. Multiple compiler specifications can be given for the single processor.
void ghidra::LanguageDescription::decode | ( | Decoder & | decoder | ) |
Parse this description from a stream.
Parse an ldefs <language> element
decoder | is the stream decoder |
References ghidra::Decoder::closeElement(), ghidra::Decoder::closeElementSkipping(), ghidra::Decoder::getNextAttributeId(), ghidra::Decoder::openElement(), ghidra::Decoder::peekElement(), ghidra::Decoder::readBool(), ghidra::Decoder::readSignedInteger(), and ghidra::Decoder::readString().
const CompilerTag & ghidra::LanguageDescription::getCompiler | ( | const string & | nm | ) | const |
Get compiler specification of the given name.
Pick out the CompilerTag associated with the desired compiler id string
nm | is the desired id string |
References ghidra::CompilerTag::getId().
Referenced by ghidra::SleighArchitecture::buildSpecFile().