Skip to content

Commit 4b519a7

Browse files
steffenlarsenvmaksimo
authored andcommitted
[SYCL][libclc] Support BinaryFPType in Remangler tool
This patch fixes build on CUDA after LLORG changes.
1 parent 38bac16 commit 4b519a7

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

libclc/utils/libclc-remangler/LibclcRemangler.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -367,6 +367,20 @@ class Remangler {
367367
addSub(typeNode);
368368
break;
369369
}
370+
case Node::Kind::KBinaryFPType: {
371+
if (remangleSub(typeNode, S))
372+
return;
373+
374+
const BinaryFPType *BFPType = static_cast<const BinaryFPType *>(typeNode);
375+
assert(BFPType->getDimension()->getKind() == Node::Kind::KNameType);
376+
const NameType *dims =
377+
static_cast<const NameType *>(BFPType->getDimension());
378+
379+
S << "DF";
380+
S << dims->getName();
381+
S << '_';
382+
break;
383+
}
370384
case Node::Kind::KVendorExtQualType: {
371385
if (remangleSub(typeNode, S))
372386
return;

llvm/include/llvm/Demangle/ItaniumDemangle.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1104,6 +1104,8 @@ class BinaryFPType final : public Node {
11041104

11051105
template<typename Fn> void match(Fn F) const { F(Dimension); }
11061106

1107+
const Node *getDimension() const { return Dimension; }
1108+
11071109
void printLeft(OutputStream &S) const override {
11081110
S += "_Float";
11091111
Dimension->print(S);

0 commit comments

Comments
 (0)