[Mlir-commits] [mlir] 59c3be7 - Apply clang-tidy fixes for performance-move-const-arg in SerializeToHsaco.cpp (NFC)

Mehdi Amini llvmlistbot at llvm.org
Mon May 16 06:59:12 PDT 2022


Author: Mehdi Amini
Date: 2022-05-16T13:58:49Z
New Revision: 59c3be748f89d9084ac71b28784fd4e26322e181

URL: https://github.com/llvm/llvm-project/commit/59c3be748f89d9084ac71b28784fd4e26322e181
DIFF: https://github.com/llvm/llvm-project/commit/59c3be748f89d9084ac71b28784fd4e26322e181.diff

LOG: Apply clang-tidy fixes for performance-move-const-arg in SerializeToHsaco.cpp (NFC)

Added: 
    

Modified: 
    mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp b/mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp
index c881d458afb8f..15e1674a84d58 100644
--- a/mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp
+++ b/mlir/lib/Dialect/GPU/Transforms/SerializeToHsaco.cpp
@@ -274,7 +274,7 @@ SerializeToHsacoPass::translateToLLVMIR(llvm::LLVMContext &llvmContext) {
 
   Optional<SmallVector<std::unique_ptr<llvm::Module>, 3>> mbModules;
   std::string theRocmPath = getRocmPath();
-  llvm::SmallString<32> bitcodePath(std::move(theRocmPath));
+  llvm::SmallString<32> bitcodePath(theRocmPath);
   llvm::sys::path::append(bitcodePath, "amdgcn", "bitcode");
   mbModules = loadLibraries(bitcodePath, libraries, llvmContext);
 
@@ -433,7 +433,7 @@ SerializeToHsacoPass::createHsaco(const SmallVectorImpl<char> &isaBinary) {
   llvm::FileRemover cleanupHsaco(tempHsacoFilename);
 
   std::string theRocmPath = getRocmPath();
-  llvm::SmallString<32> lldPath(std::move(theRocmPath));
+  llvm::SmallString<32> lldPath(theRocmPath);
   llvm::sys::path::append(lldPath, "llvm", "bin", "ld.lld");
   int lldResult = llvm::sys::ExecuteAndWait(
       lldPath,


        


More information about the Mlir-commits mailing list