19using namespace ms_demangle;
21#define OUTPUT_ENUM_CLASS_VALUE(Enum, Value, Desc) \
32 if (std::isalnum(
C) ||
C ==
'>')
69 size_t Pos1 = OB.getCurrentPosition();
73 size_t Pos2 = OB.getCurrentPosition();
74 if (SpaceAfter && Pos2 > Pos1)
82 case CallingConv::Cdecl:
85 case CallingConv::Fastcall:
88 case CallingConv::Pascal:
91 case CallingConv::Regcall:
94 case CallingConv::Stdcall:
97 case CallingConv::Thiscall:
100 case CallingConv::Eabi:
103 case CallingConv::Vectorcall:
104 OB <<
"__vectorcall";
106 case CallingConv::Clrcall:
110 OB <<
"__attribute__((__swiftcall__)) ";
112 case CallingConv::SwiftAsync:
113 OB <<
"__attribute__((__swiftasynccall__)) ";
122 this->output(OB, Flags);
123 std::string_view SV = OB;
124 std::string Owned(SV.begin(), SV.end());
125 std::free(OB.getBuffer());
161 std::string_view Separator)
const {
166 for (
size_t I = 1;
I <
Count; ++
I) {
233 OB <<
"`dynamic atexit destructor for ";
235 OB <<
"`dynamic initializer for ";
304 "`vector deleting dtor'");
306 "`default ctor closure'");
308 "`scalar deleting dtor'");
310 "`vector ctor iterator'");
312 "`vector dtor iterator'");
314 "`vector vbase ctor iterator'");
316 "`virtual displacement map'");
318 "`eh vector ctor iterator'");
320 "`eh vector dtor iterator'");
322 "`eh vector vbase ctor iterator'");
324 "`copy ctor closure'");
326 "`local vftable ctor closure'");
329 "operator delete[]");
331 "`managed vector ctor iterator'");
333 "`managed vector dtor iterator'");
335 "`EH vector copy ctor iterator'");
337 "`EH vector vbase copy ctor iterator'");
339 "`vector copy ctor iterator'");
341 "`vector vbase copy constructor iterator'");
343 "`managed vector vbase copy constructor iterator'");
345 "operator co_await");
357 OB <<
"`local static thread guard'";
359 OB <<
"`local static guard'";
381 OB <<
"operator \"\"" <<
Name;
405 OB <<
"extern \"C\" ";
427 if (OB.back() !=
'(')
441 OB <<
" __unaligned";
491 OB <<
"__unaligned ";
593 const char *AccessSpec =
nullptr;
594 bool IsStatic =
true;
597 AccessSpec =
"private";
600 AccessSpec =
"public";
603 AccessSpec =
"protected";
610 OB << AccessSpec <<
": ";
615 Type->outputPre(OB, Flags);
620 Type->outputPost(OB, Flags);
634 OB <<
"`RTTI Base Class Descriptor at (";
static void outputCallingConvention(OutputBuffer &OB, CallingConv CC)
#define OUTPUT_ENUM_CLASS_VALUE(Enum, Value, Desc)
static void outputSingleQualifier(OutputBuffer &OB, Qualifiers Q)
static bool outputQualifierIfPresent(OutputBuffer &OB, Qualifiers Q, Qualifiers Mask, bool NeedSpace)
static void outputQualifiers(OutputBuffer &OB, Qualifiers Q, bool SpaceBefore, bool SpaceAfter)
static void outputSpaceIfNecessary(OutputBuffer &OB)
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
This is a utility class that provides an abstraction for the common functionality between Instruction...
The instances of the Type class are immutable: once they are created, they are never changed.
@ Swift
Calling convention for Swift.
@ C
The default llvm calling convention, compatible with C.
@ ManVectorVbaseCopyCtorIter
@ EHVectorVbaseCopyCtorIter
@ LocalVftableCtorClosure
@ VectorVbaseCopyCtorIter
This is an optimization pass for GlobalISel generic memory operations.
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
void outputOneDimension(OutputBuffer &OB, OutputFlags Flags, Node *N) const
NodeArrayNode * Dimensions
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void outputDimensionsImpl(OutputBuffer &OB, OutputFlags Flags) const
void output(OutputBuffer &OB, OutputFlags Flags) const override
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
IdentifierNode * Identifier
void output(OutputBuffer &OB, OutputFlags Flags) const override
VariableSymbolNode * Variable
void output(OutputBuffer &OB, OutputFlags Flags) const override
std::string_view DecodedString
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
FunctionRefQualifier RefQualifier
CallingConv CallConvention
FunctionSignatureNode * Signature
void output(OutputBuffer &OB, OutputFlags Flags) const override
NodeArrayNode * TemplateParams
void outputTemplateParameters(OutputBuffer &OB, OutputFlags Flags) const
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
virtual void output(OutputBuffer &OB, OutputFlags Flags) const =0
QualifiedNameNode * ClassParent
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
NodeArrayNode * Components
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
QualifiedNameNode * TargetName
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
std::array< int64_t, 3 > ThunkOffsets
void outputPost(OutputBuffer &OB, OutputFlags Flags) const override
void outputPre(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override
virtual void outputPre(OutputBuffer &OB, OutputFlags Flags) const =0
virtual void outputPost(OutputBuffer &OB, OutputFlags Flags) const =0
void output(OutputBuffer &OB, OutputFlags Flags) const override
void output(OutputBuffer &OB, OutputFlags Flags) const override