mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-31 10:34:17 +00:00
This add a reset method for WinCOFFObjectWriter, like other MC* classes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217907 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a0b4148700
commit
ca7da16ca0
@ -113,6 +113,11 @@ public:
|
|||||||
StringTable();
|
StringTable();
|
||||||
size_t size() const;
|
size_t size() const;
|
||||||
size_t insert(StringRef String);
|
size_t insert(StringRef String);
|
||||||
|
void clear() {
|
||||||
|
Map.clear();
|
||||||
|
Data.resize(4);
|
||||||
|
update_length();
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
class WinCOFFObjectWriter : public MCObjectWriter {
|
class WinCOFFObjectWriter : public MCObjectWriter {
|
||||||
@ -139,6 +144,17 @@ public:
|
|||||||
bool UseBigObj;
|
bool UseBigObj;
|
||||||
|
|
||||||
WinCOFFObjectWriter(MCWinCOFFObjectTargetWriter *MOTW, raw_ostream &OS);
|
WinCOFFObjectWriter(MCWinCOFFObjectTargetWriter *MOTW, raw_ostream &OS);
|
||||||
|
|
||||||
|
void reset() override {
|
||||||
|
memset(&Header, 0, sizeof(Header));
|
||||||
|
Header.Machine = TargetObjectWriter->getMachine();
|
||||||
|
Sections.clear();
|
||||||
|
Symbols.clear();
|
||||||
|
Strings.clear();
|
||||||
|
SectionMap.clear();
|
||||||
|
SymbolMap.clear();
|
||||||
|
MCObjectWriter::reset();
|
||||||
|
}
|
||||||
|
|
||||||
COFFSymbol *createSymbol(StringRef Name);
|
COFFSymbol *createSymbol(StringRef Name);
|
||||||
COFFSymbol *GetOrCreateCOFFSymbol(const MCSymbol * Symbol);
|
COFFSymbol *GetOrCreateCOFFSymbol(const MCSymbol * Symbol);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user