[PATCH] D76627: Fix a warning building on my machine, NFC. warning: unused function 'compilePtxToCubinForTesting'

Chris Lattner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 23 11:28:37 PDT 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rG42d8f48ccfcd: Fix a warning building on my machine, NFC. warning: unused function… (authored by lattner).

Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D76627

Files:
  mlir/test/lib/Transforms/TestConvertGPUKernelToCubin.cpp


Index: mlir/test/lib/Transforms/TestConvertGPUKernelToCubin.cpp
===================================================================
--- mlir/test/lib/Transforms/TestConvertGPUKernelToCubin.cpp
+++ mlir/test/lib/Transforms/TestConvertGPUKernelToCubin.cpp
@@ -9,18 +9,15 @@
 #include "mlir/Conversion/GPUToCUDA/GPUToCUDAPass.h"
 #include "mlir/Pass/Pass.h"
 #include "mlir/Pass/PassManager.h"
-
 using namespace mlir;
 
-namespace {
+#if MLIR_CUDA_CONVERSIONS_ENABLED
 static OwnedCubin compilePtxToCubinForTesting(const std::string &, Location,
                                               StringRef) {
   const char data[] = "CUBIN";
   return std::make_unique<std::vector<char>>(data, data + sizeof(data) - 1);
 }
-} // end anonymous namespace
 
-#if MLIR_CUDA_CONVERSIONS_ENABLED
 namespace mlir {
 void registerTestConvertGPUKernelToCubinPass() {
   PassPipelineRegistration<>("test-kernel-to-cubin",


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76627.252104.patch
Type: text/x-patch
Size: 906 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200323/dc6ffee3/attachment.bin>


More information about the llvm-commits mailing list