diff --git a/projects/clr/hipamd/src/Cuda2Hip.cpp b/projects/clr/hipamd/src/Cuda2Hip.cpp index 42d3ca836f..f27a1bc1e5 100644 --- a/projects/clr/hipamd/src/Cuda2Hip.cpp +++ b/projects/clr/hipamd/src/Cuda2Hip.cpp @@ -569,8 +569,10 @@ class Cuda2HipCallback : public MatchFinder::MatchCallback { if (const StringLiteral * stringLiteral = Result.Nodes.getNodeAs("stringLiteral")) { - StringRef s = stringLiteral->getString(); - processString(s, N, Replace, *SM, stringLiteral->getLocStart()); + if (stringLiteral->getCharByteWidth() == 1) { + StringRef s = stringLiteral->getString(); + processString(s, N, Replace, *SM, stringLiteral->getLocStart()); + } } if (const UnaryExprOrTypeTraitExpr * expr = Result.Nodes.getNodeAs("cudaStructSizeOf"))