diff --git a/libc/docs/gpu/rpc.rst b/libc/docs/gpu/rpc.rst index 78ae778671881..fb738138568f6 100644 --- a/libc/docs/gpu/rpc.rst +++ b/libc/docs/gpu/rpc.rst @@ -104,7 +104,7 @@ Some operations are too divergent to provide generic implementations for, such as allocating device accessible memory. For these cases, we provide a callback registration scheme to add a custom handler for any given opcode through the port API. More information can be found in the installed header -``/include/gpu-none-llvm/rpc_server.h``. +``/include/llvmlibc_rpc_server.h``. Client Example -------------- @@ -194,7 +194,7 @@ but the following example shows how it can be used by a standard user. #include #include - #include + #include [[noreturn]] void handle_error(cudaError_t err) { fprintf(stderr, "CUDA error: %s\n", cudaGetErrorString(err)); diff --git a/libc/utils/gpu/loader/Loader.h b/libc/utils/gpu/loader/Loader.h index d2b2ee5baebed..e2aabb08c11da 100644 --- a/libc/utils/gpu/loader/Loader.h +++ b/libc/utils/gpu/loader/Loader.h @@ -9,7 +9,7 @@ #ifndef LLVM_LIBC_UTILS_GPU_LOADER_LOADER_H #define LLVM_LIBC_UTILS_GPU_LOADER_LOADER_H -#include "utils/gpu/server/rpc_server.h" +#include "utils/gpu/server/llvmlibc_rpc_server.h" #include "include/llvm-libc-types/test_rpc_opcodes_t.h" diff --git a/libc/utils/gpu/server/CMakeLists.txt b/libc/utils/gpu/server/CMakeLists.txt index 94cdfe5bf6521..745a248d9b63d 100644 --- a/libc/utils/gpu/server/CMakeLists.txt +++ b/libc/utils/gpu/server/CMakeLists.txt @@ -21,8 +21,8 @@ if(LLVM_RUNTIMES_TARGET OR LIBC_TARGET_TRIPLE) endif() # Install the server and associated header. -install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/rpc_server.h - DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/gpu-none-llvm/ +install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/llvmlibc_rpc_server.h + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} COMPONENT libc-headers) install(TARGETS llvmlibc_rpc_server ARCHIVE DESTINATION "lib${LLVM_LIBDIR_SUFFIX}" diff --git a/libc/utils/gpu/server/rpc_server.h b/libc/utils/gpu/server/llvmlibc_rpc_server.h similarity index 100% rename from libc/utils/gpu/server/rpc_server.h rename to libc/utils/gpu/server/llvmlibc_rpc_server.h diff --git a/libc/utils/gpu/server/rpc_server.cpp b/libc/utils/gpu/server/rpc_server.cpp index 4e535a294a19e..707807a5cbaf7 100644 --- a/libc/utils/gpu/server/rpc_server.cpp +++ b/libc/utils/gpu/server/rpc_server.cpp @@ -6,7 +6,7 @@ // //===----------------------------------------------------------------------===// -#include "rpc_server.h" +#include "llvmlibc_rpc_server.h" #include "src/__support/RPC/rpc.h" #include "src/stdio/gpu/file.h" diff --git a/openmp/libomptarget/plugins-nextgen/common/src/RPC.cpp b/openmp/libomptarget/plugins-nextgen/common/src/RPC.cpp index cb6a5086bc4dd..05ae5acb01ddf 100644 --- a/openmp/libomptarget/plugins-nextgen/common/src/RPC.cpp +++ b/openmp/libomptarget/plugins-nextgen/common/src/RPC.cpp @@ -12,14 +12,8 @@ #include "PluginInterface.h" -// This header file may be present in-tree or from an LLVM installation. The -// installed version lives alongside the GPU headers so we do not want to -// include it directly. -#if __has_include() -#include -#elif defined(LIBOMPTARGET_RPC_SUPPORT) -// Just pull this out of the source if available. -#include "rpc_server.h" +#if defined(LIBOMPTARGET_RPC_SUPPORT) +#include "llvmlibc_rpc_server.h" #endif using namespace llvm;