-/// SectionKind - This is a simple POD value that classifies the properties of
-/// a section. A global variable is classified into the deepest possible
-/// classification, and then the target maps them onto their sections based on
-/// what capabilities they have.
-///
-/// The comments below describe these as if they were an inheritance hierarchy
-/// in order to explain the predicates below.
-class SectionKind {
-public:
- enum Kind {
- /// Metadata - Debug info sections or other metadata.
- Metadata,
-
- /// Text - Text section, used for functions and other executable code.
- Text,
-
- /// ReadOnly - Data that is never written to at program runtime by the
- /// program or the dynamic linker. Things in the top-level readonly
- /// SectionKind are not mergeable.
- ReadOnly,
-
- /// MergeableCString - This is a special section for nul-terminated
- /// strings. The linker can unique the C strings, knowing their
- /// semantics. Because it uniques based on the nul terminators, the
- /// compiler can't put strings in this section that have embeded nuls
- /// in them.
- MergeableCString,
-
- /// MergeableConst - These are sections for merging fixed-length
- /// constants together. For example, this can be used to unique
- /// constant pool entries etc.
- MergeableConst,
-
- /// MergeableConst4 - This is a section used by 4-byte constants,
- /// for example, floats.
- MergeableConst4,
-
- /// MergeableConst8 - This is a section used by 8-byte constants,
- /// for example, doubles.
- MergeableConst8,
-
- /// MergeableConst16 - This is a section used by 16-byte constants,
- /// for example, vectors.
- MergeableConst16,
-
- /// Writeable - This is the base of all segments that need to be written
- /// to during program runtime.
-
- /// ThreadLocal - This is the base of all TLS segments. All TLS
- /// objects must be writeable, otherwise there is no reason for them to
- /// be thread local!
-
- /// ThreadBSS - Zero-initialized TLS data objects.
- ThreadBSS,
-
- /// ThreadData - Initialized TLS data objects.
- ThreadData,
-
- /// GlobalWriteableData - Writeable data that is global (not thread
- /// local).
-
- /// BSS - Zero initialized writeable data.
- BSS,
-
- /// DataRel - This is the most general form of data that is written
- /// to by the program, it can have random relocations to arbitrary
- /// globals.
- DataRel,
-
- /// DataRelLocal - This is writeable data that has a non-zero
- /// initializer and has relocations in it, but all of the
- /// relocations are known to be within the final linked image
- /// the global is linked into.
- DataRelLocal,