18 using namespace llvm::codeview;
40 #define TYPE_RECORD(EnumName, EnumVal, Name) \
41 Error visitKnownRecord(CVType &CVR, Name##Record &Record) override;
42 #define TYPE_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName)
43 #define MEMBER_RECORD(EnumName, EnumVal, Name)
44 #include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
56 CurrentTypeIndex = Index;
64 Name =
"<field list>";
79 assert(Indices[
I] < CurrentTypeIndex);
81 Name.append(Types.getTypeName(Indices[
I]));
95 Name.append(Types.getTypeName(Indices[I]));
136 Name =
formatv(
"{0} {1}", Ret, Params).sstr<256>();
145 Name =
formatv(
"{0} {1}::{2}", Ret, Class, Params).sstr<256>();
169 Name.append(
"const ");
171 Name.append(
"volatile ");
173 Name.append(
"__unaligned ");
188 uint16_t Mods =
static_cast<uint16_t
>(Mod.
getModifiers());
192 Name.append(
"const ");
194 Name.append(
"volatile ");
196 Name.append(
"__unaligned ");
236 TypeNameComputer Computer(Types);
240 return "<unknown UDT>";
242 return Computer.name();
auto formatv(const char *Fmt, Ts &&...Vals) -> formatv_object< decltype(std::make_tuple(detail::build_format_adapter(std::forward< Ts >(Vals))...))>
TypeIndex getArgumentList() const
virtual CVType getType(TypeIndex Index)=0
ArrayRef< TypeIndex > getIndices() const
std::string computeTypeName(TypeCollection &Types, TypeIndex Index)
TypeIndex getClassType() const
StringRef getString() const
bool isPointerToMember() const
StringRef getName() const
TypeIndex getReturnType() const
TypeIndex getContainingType() const
static Error visitKnownRecord(CVSymbol &Record, SymbolVisitorCallbacks &Callbacks)
TypeIndex getReturnType() const
StringRef getName() const
constexpr char Args[]
Key for Kernel::Metadata::mArgs.
StringRef getName() const
Error visitTypeRecord(CVType &Record, TypeIndex Index, TypeVisitorCallbacks &Callbacks, VisitorDataSource Source=VDS_BytesPresent)
void consumeError(Error Err)
Consume a Error without doing anything.
uint32_t getEntryCount() const
ModifierOptions getModifiers() const
static ErrorSuccess success()
Create a success value.
PointerMode getMode() const
constexpr char Size[]
Key for Kernel::Arg::Metadata::mSize.
llvm_unreachable("Unknown RegBank!")
TypeIndex getModifiedType() const
ArrayRef< TypeIndex > getIndices() const
TypeIndex getArgumentList() const
StringRef getName() const
MemberPointerInfo getMemberInfo() const
constexpr char TypeName[]
Key for Kernel::Arg::Metadata::mTypeName.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
Lightweight error class with error context and mandatory checking.
StringRef - Represent a constant reference to a string, i.e.
TypeIndex getReferentType() const
StringRef getName() const
StringRef getName() const