git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111172
91177308-0d34-0410-b5e6-
96231b3b80d8
private:
friend class MCContext;
MCSectionELF(StringRef Section, unsigned type, unsigned flags,
private:
friend class MCContext;
MCSectionELF(StringRef Section, unsigned type, unsigned flags,
- SectionKind K, bool isExplicit)
+ SectionKind K, bool isExplicit, unsigned entrySize)
: MCSection(SV_ELF, K), SectionName(Section), Type(type), Flags(flags),
: MCSection(SV_ELF, K), SectionName(Section), Type(type), Flags(flags),
- IsExplicit(isExplicit) {}
+ IsExplicit(isExplicit), EntrySize(entrySize) {}
StringRef getSectionName() const { return SectionName; }
unsigned getType() const { return Type; }
unsigned getFlags() const { return Flags; }
StringRef getSectionName() const { return SectionName; }
unsigned getType() const { return Type; }
unsigned getFlags() const { return Flags; }
+ unsigned getEntrySize() const { return EntrySize; }
void PrintSwitchToSection(const MCAsmInfo &MAI,
raw_ostream &OS) const;
void PrintSwitchToSection(const MCAsmInfo &MAI,
raw_ostream &OS) const;
MCCodeEmitter &CE, raw_ostream &OS,
bool RelaxAll = false);
MCCodeEmitter &CE, raw_ostream &OS,
bool RelaxAll = false);
+ /// createELFStreamer - Create a machine code streamer which will generate
+ /// ELF format object files.
+ MCStreamer *createELFStreamer(MCContext &Ctx, TargetAsmBackend &TAB,
+ raw_ostream &OS, MCCodeEmitter *CE,
+ bool RelaxAll = false);
+
/// createLoggingStreamer - Create a machine code streamer which just logs the
/// API calls and then dispatches to another streamer.
///
/// createLoggingStreamer - Create a machine code streamer which just logs the
/// API calls and then dispatches to another streamer.
///
+// The size (in bytes) of symbol table entries.
+enum {
+ SYMENTRY_SIZE32 = 16, // 32-bit symbol entry size
+ SYMENTRY_SIZE64 = 24 // 64-bit symbol entry size.
+};
+
// Symbol bindings.
enum {
STB_LOCAL = 0, // Local symbol, not visible outside obj file containing def
// Symbol bindings.
enum {
STB_LOCAL = 0, // Local symbol, not visible outside obj file containing def
MCAsmInfo.cpp
MCAsmInfoCOFF.cpp
MCAsmInfoDarwin.cpp
MCAsmInfo.cpp
MCAsmInfoCOFF.cpp
MCAsmInfoDarwin.cpp
MCCodeEmitter.cpp
MCContext.cpp
MCDisassembler.cpp
MCCodeEmitter.cpp
MCContext.cpp
MCDisassembler.cpp
MCExpr.cpp
MCInst.cpp
MCInstPrinter.cpp
MCExpr.cpp
MCInst.cpp
MCInstPrinter.cpp
const MCSection *MCContext::
getELFSection(StringRef Section, unsigned Type, unsigned Flags,
const MCSection *MCContext::
getELFSection(StringRef Section, unsigned Type, unsigned Flags,
- SectionKind Kind, bool IsExplicit) {
+ SectionKind Kind, bool IsExplicit, unsigned EntrySize) {
if (ELFUniquingMap == 0)
ELFUniquingMap = new ELFUniqueMapTy();
ELFUniqueMapTy &Map = *(ELFUniqueMapTy*)ELFUniquingMap;
if (ELFUniquingMap == 0)
ELFUniquingMap = new ELFUniqueMapTy();
ELFUniqueMapTy &Map = *(ELFUniqueMapTy*)ELFUniquingMap;
if (Entry.getValue()) return Entry.getValue();
MCSectionELF *Result = new (*this) MCSectionELF(Entry.getKey(), Type, Flags,
if (Entry.getValue()) return Entry.getValue();
MCSectionELF *Result = new (*this) MCSectionELF(Entry.getKey(), Type, Flags,
+ Kind, IsExplicit, EntrySize);
Entry.setValue(Result);
return Result;
}
Entry.setValue(Result);
return Result;
}