LLVM  6.0.0svn
Classes | Namespaces | Macros | Functions
CodeViewYAMLTypes.cpp File Reference
#include "llvm/ObjectYAML/CodeViewYAMLTypes.h"
#include "llvm/ADT/APSInt.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/BinaryFormat/COFF.h"
#include "llvm/DebugInfo/CodeView/CVTypeVisitor.h"
#include "llvm/DebugInfo/CodeView/CodeView.h"
#include "llvm/DebugInfo/CodeView/CodeViewError.h"
#include "llvm/DebugInfo/CodeView/TypeDeserializer.h"
#include "llvm/DebugInfo/CodeView/TypeIndex.h"
#include "llvm/DebugInfo/CodeView/TypeTableBuilder.h"
#include "llvm/DebugInfo/CodeView/TypeVisitorCallbacks.h"
#include "llvm/Support/Allocator.h"
#include "llvm/Support/BinaryStreamReader.h"
#include "llvm/Support/BinaryStreamWriter.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/Error.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/YAMLTraits.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
#include <cassert>
#include <cstdint>
#include <vector>
#include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
Include dependency graph for CodeViewYAMLTypes.cpp:

Go to the source code of this file.

Classes

struct  llvm::CodeViewYAML::detail::LeafRecordBase
 
struct  llvm::CodeViewYAML::detail::LeafRecordImpl< T >
 
struct  llvm::CodeViewYAML::detail::LeafRecordImpl< FieldListRecord >
 
struct  llvm::CodeViewYAML::detail::MemberRecordBase
 
struct  llvm::CodeViewYAML::detail::MemberRecordImpl< T >
 
struct  llvm::yaml::MappingTraits< LeafRecordBase >
 
struct  llvm::yaml::MappingTraits< MemberRecordBase >
 

Namespaces

 llvm
 Compute iterated dominance frontiers using a linear time algorithm.
 
 llvm::CodeViewYAML
 
 llvm::CodeViewYAML::detail
 
 llvm::yaml
 

Macros

#define CV_TYPE(name, val)   io.enumCase(Value, #name, name);
 
#define TYPE_RECORD(EnumName, EnumVal, Name)
 
#define MEMBER_RECORD(EnumName, EnumVal, Name)
 
#define TYPE_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName)
 
#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName)
 
#define TYPE_RECORD(EnumName, EnumVal, ClassName)
 
#define TYPE_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)   TYPE_RECORD(EnumName, EnumVal, ClassName)
 
#define MEMBER_RECORD(EnumName, EnumVal, ClassName)
 
#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)
 
#define TYPE_RECORD(EnumName, EnumVal, ClassName)
 
#define TYPE_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)   TYPE_RECORD(EnumName, EnumVal, ClassName)
 
#define MEMBER_RECORD(EnumName, EnumVal, ClassName)
 
#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)
 
#define MEMBER_RECORD(EnumName, EnumVal, ClassName)
 
#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)   MEMBER_RECORD(EnumName, EnumVal, ClassName)
 
#define TYPE_RECORD(EnumName, EnumVal, ClassName)
 
#define TYPE_RECORD_ALIAS(EnumName, EnumVal, AliasName, ClassName)
 

Functions

template<typename T >
static Expected< LeafRecordfromCodeViewRecordImpl (CVType Type)
 
template<typename ConcreteType >
static void mapLeafRecordImpl (IO &IO, const char *Class, TypeLeafKind Kind, LeafRecord &Obj)
 
template<typename ConcreteType >
static void mapMemberRecordImpl (IO &IO, const char *Class, TypeLeafKind Kind, MemberRecord &Obj)
 

Macro Definition Documentation

◆ CV_TYPE

#define CV_TYPE (   name,
  val 
)    io.enumCase(Value, #name, name);

◆ MEMBER_RECORD [1/4]

#define MEMBER_RECORD (   EnumName,
  EnumVal,
  Name 
)
Value:
return visitKnownMemberImpl(Record); \
}
static Error visitKnownMember(CVMemberRecord &Record, TypeVisitorCallbacks &Callbacks)
Lightweight error class with error context and mandatory checking.
Definition: Error.h:156

Definition at line 465 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD [2/4]

#define MEMBER_RECORD (   EnumName,
  EnumVal,
  ClassName 
)

Definition at line 465 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD [3/4]

#define MEMBER_RECORD (   EnumName,
  EnumVal,
  ClassName 
)

Definition at line 465 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD [4/4]

#define MEMBER_RECORD (   EnumName,
  EnumVal,
  ClassName 
)
Value:
case EnumName: \
mapMemberRecordImpl<ClassName##Record>(IO, #ClassName, Kind, Obj); \
break;
StringLiteral EnumName
const unsigned Kind

Definition at line 465 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD_ALIAS [1/4]

#define MEMBER_RECORD_ALIAS (   EnumName,
  EnumVal,
  Name,
  AliasName 
)

Definition at line 470 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD_ALIAS [2/4]

#define MEMBER_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)

Definition at line 470 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD_ALIAS [3/4]

#define MEMBER_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)

Definition at line 470 of file CodeViewYAMLTypes.cpp.

◆ MEMBER_RECORD_ALIAS [4/4]

#define MEMBER_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)    MEMBER_RECORD(EnumName, EnumVal, ClassName)

Definition at line 470 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD [1/4]

#define TYPE_RECORD (   EnumName,
  EnumVal,
  Name 
)

Definition at line 464 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD [2/4]

#define TYPE_RECORD (   EnumName,
  EnumVal,
  ClassName 
)
Value:
case EnumName: \
return fromCodeViewRecordImpl<ClassName##Record>(Type);
StringLiteral EnumName

Definition at line 464 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD [3/4]

#define TYPE_RECORD (   EnumName,
  EnumVal,
  ClassName 
)
Value:
case EnumName: \
mapLeafRecordImpl<ClassName##Record>(IO, #ClassName, Kind, Obj); \
break;
StringLiteral EnumName
const unsigned Kind

Definition at line 464 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD [4/4]

#define TYPE_RECORD (   EnumName,
  EnumVal,
  ClassName 
)

Definition at line 464 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD_ALIAS [1/4]

#define TYPE_RECORD_ALIAS (   EnumName,
  EnumVal,
  Name,
  AliasName 
)

Definition at line 469 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD_ALIAS [2/4]

#define TYPE_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)    TYPE_RECORD(EnumName, EnumVal, ClassName)

Definition at line 469 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD_ALIAS [3/4]

#define TYPE_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)    TYPE_RECORD(EnumName, EnumVal, ClassName)

Definition at line 469 of file CodeViewYAMLTypes.cpp.

◆ TYPE_RECORD_ALIAS [4/4]

#define TYPE_RECORD_ALIAS (   EnumName,
  EnumVal,
  AliasName,
  ClassName 
)

Definition at line 469 of file CodeViewYAMLTypes.cpp.

Function Documentation

◆ fromCodeViewRecordImpl()

template<typename T >
static Expected<LeafRecord> fromCodeViewRecordImpl ( CVType  Type)
inlinestatic

◆ mapLeafRecordImpl()

template<typename ConcreteType >
static void mapLeafRecordImpl ( IO IO,
const char Class,
TypeLeafKind  Kind,
LeafRecord Obj 
)
static

◆ mapMemberRecordImpl()

template<typename ConcreteType >
static void mapMemberRecordImpl ( IO IO,
const char Class,
TypeLeafKind  Kind,
MemberRecord Obj 
)
static