[PATCH] D113491: [HIP] Fix device stub name for Windows

Yaxun Liu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 9 13:35:06 PST 2021


yaxunl marked an inline comment as done.
yaxunl added inline comments.


================
Comment at: clang/lib/AST/MicrosoftMangle.cpp:975-976
+          llvm::SmallString<128> Buf;
+          mangleSourceName((llvm::Twine("__device_stub__") + II->getName())
+                               .toStringRef(Buf));
+        } else
----------------
tra wrote:
> Can we just use `(llvm::Twine("__device_stub__") + II->getName()).str()`? Or  `std::string("__device__stub") + II->getName().str()`  ?
> 
> `std::string` should be convertible to StringRef and using a temporary variable here is fine.
I will use (llvm::Twine("__device_stub__") + II->getName()).str()


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D113491/new/

https://reviews.llvm.org/D113491



More information about the cfe-commits mailing list