LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Macros | Functions | Variables
MCSectionMachO.cpp File Reference
#include "llvm/MC/MCSectionMachO.h"
#include "llvm/MC/MCContext.h"
#include "llvm/Support/raw_ostream.h"
#include <cctype>
Include dependency graph for MCSectionMachO.cpp:

Go to the source code of this file.

Macros

#define ENTRY(ASMNAME, ENUM)   { MCSectionMachO::ENUM, ASMNAME, #ENUM },
 
#define AttrFlagEnd   0xffffffff
 

Functions

static void StripSpaces (StringRef &Str)
 StripSpaces - This removes leading and trailing spaces from the StringRef. More...
 

Variables

struct {
   const char *   AssemblerName
 
   const char *   EnumName
 
SectionTypeDescriptors [MCSectionMachO::LAST_KNOWN_SECTION_TYPE+1]
 
struct {
   unsigned   AttrFlag
 
   const char *   AssemblerName
 
   const char *   EnumName
 
SectionAttrDescriptors []
 

Macro Definition Documentation

#define AttrFlagEnd   0xffffffff
#define ENTRY (   ASMNAME,
  ENUM 
)    { MCSectionMachO::ENUM, ASMNAME, #ENUM },

Function Documentation

static void StripSpaces ( StringRef Str)
static

StripSpaces - This removes leading and trailing spaces from the StringRef.

Definition at line 168 of file MCSectionMachO.cpp.

References llvm::StringRef::back(), llvm::StringRef::empty(), llvm::StringRef::size(), and llvm::StringRef::substr().

Referenced by llvm::MCSectionMachO::ParseSectionSpecifier().

Variable Documentation

const char* AssemblerName
unsigned AttrFlag
const char * EnumName

Definition at line 20 of file MCSectionMachO.cpp.

const { ... } SectionAttrDescriptors[]
Initial value:
= {
#define ENTRY(ASMNAME, ENUM)
{ 0, "none", 0 },
#define AttrFlagEnd
{ AttrFlagEnd, 0, 0 }
}
#define AttrFlagEnd

SectionAttrDescriptors - This is an array of descriptors for section attributes. Unlike the SectionTypeDescriptors, this is not directly indexed by attribute, instead it is searched. The last entry has an AttrFlagEnd AttrFlag value.

Referenced by llvm::MCSectionMachO::ParseSectionSpecifier(), and llvm::MCSectionMachO::PrintSwitchToSection().

const { ... } LAST_KNOWN_SECTION_TYPE+1]
Initial value:
= {
{ "regular", "S_REGULAR" },
{ 0, "S_ZEROFILL" },
{ "cstring_literals", "S_CSTRING_LITERALS" },
{ "4byte_literals", "S_4BYTE_LITERALS" },
{ "8byte_literals", "S_8BYTE_LITERALS" },
{ "literal_pointers", "S_LITERAL_POINTERS" },
{ "non_lazy_symbol_pointers", "S_NON_LAZY_SYMBOL_POINTERS" },
{ "lazy_symbol_pointers", "S_LAZY_SYMBOL_POINTERS" },
{ "symbol_stubs", "S_SYMBOL_STUBS" },
{ "mod_init_funcs", "S_MOD_INIT_FUNC_POINTERS" },
{ "mod_term_funcs", "S_MOD_TERM_FUNC_POINTERS" },
{ "coalesced", "S_COALESCED" },
{ 0, "S_GB_ZEROFILL" },
{ "interposing", "S_INTERPOSING" },
{ "16byte_literals", "S_16BYTE_LITERALS" },
{ 0, "S_DTRACE_DOF" },
{ 0, "S_LAZY_DYLIB_SYMBOL_POINTERS" },
{ "thread_local_regular", "S_THREAD_LOCAL_REGULAR" },
{ "thread_local_zerofill", "S_THREAD_LOCAL_ZEROFILL" },
{ "thread_local_variables", "S_THREAD_LOCAL_VARIABLES" },
{ "thread_local_variable_pointers",
"S_THREAD_LOCAL_VARIABLE_POINTERS" },
{ "thread_local_init_function_pointers",
"S_THREAD_LOCAL_INIT_FUNCTION_POINTERS"},
}

SectionTypeDescriptors - These are strings that describe the various section types. This must be kept in order with and stay synchronized with the section type list.

Referenced by llvm::MCSectionMachO::ParseSectionSpecifier(), and llvm::MCSectionMachO::PrintSwitchToSection().