LLVM: include/llvm/MC/MCSectionELF.h Source File (original) (raw)

1

2

3

4

5

6

7

8

9

10

11

12

13#ifndef LLVM_MC_MCSECTIONELF_H

14#define LLVM_MC_MCSECTIONELF_H

15

22

23namespace llvm {

24

25

26

27class MCSectionELF final : public MCSection {

28

29 unsigned Type;

30

31

32 unsigned Flags;

33

34 unsigned UniqueID;

35

36

37

38

39 unsigned EntrySize;

40

41

42

44

45

46

48

49

52

53private:

56

57

58 MCSectionELF(StringRef Name, unsigned type, unsigned flags,

59 unsigned entrySize, const MCSymbolELF *group, bool IsComdat,

60 unsigned UniqueID, MCSymbol *Begin,

63 Begin),

64 Type(type), Flags(flags), UniqueID(UniqueID), EntrySize(entrySize),

65 Group(group, IsComdat), LinkedToSym(LinkedToSym) {

67 "Group section without signature!");

68 if (Group.getPointer())

69 Group.getPointer()->setIsSignature();

70 }

71

72public:

73 unsigned getType() const { return Type; }

74 unsigned getFlags() const { return Flags; }

78 bool isComdat() const { return Group.getInt(); }

79

82

84 return &LinkedToSym->getSection();

85 }

87

89 StartOffset = Start;

90 EndOffset = End;

91 }

92 std::pair<uint64_t, uint64_t> getOffsets() const {

93 return std::make_pair(StartOffset, EndOffset);

94 }

95};

96

97}

98

99#endif

assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")

This file defines the PointerIntPair class.

const MCSection * getLinkedToSection() const

Definition MCSectionELF.h:83

unsigned getFlags() const

Definition MCSectionELF.h:74

unsigned getUniqueID() const

Definition MCSectionELF.h:81

void setOffsets(uint64_t Start, uint64_t End)

Definition MCSectionELF.h:88

friend class MCAsmInfoELF

Definition MCSectionELF.h:55

void setFlags(unsigned F)

Definition MCSectionELF.h:76

const MCSymbol * getLinkedToSymbol() const

Definition MCSectionELF.h:86

friend class MCContext

Definition MCSectionELF.h:54

std::pair< uint64_t, uint64_t > getOffsets() const

Definition MCSectionELF.h:92

bool isUnique() const

Definition MCSectionELF.h:80

const MCSymbolELF * getGroup() const

Definition MCSectionELF.h:77

unsigned getType() const

Definition MCSectionELF.h:73

unsigned getEntrySize() const

Definition MCSectionELF.h:75

bool isComdat() const

Definition MCSectionELF.h:78

static constexpr unsigned NonUniqueID

MCSection(StringRef Name, bool IsText, bool IsBss, MCSymbol *Begin)

MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...

PointerIntPair - This class implements a pair of a pointer and small integer.

StringRef - Represent a constant reference to a string, i.e.

This is an optimization pass for GlobalISel generic memory operations.