[libc-commits] [libc] [libc] Remove more libc dependencies from the	RPC header (PR #116437)
    Joseph Huber via libc-commits 
    libc-commits at lists.llvm.org
       
    Fri Nov 15 16:02:18 PST 2024
    
    
  
================
@@ -10,20 +10,16 @@
 #define LLVM_LIBC_SRC___SUPPORT_RPC_RPC_UTIL_H
 
 #include "src/__support/CPP/type_traits.h"
-#include "src/__support/GPU/utils.h"
 #include "src/__support/macros/attributes.h"
 #include "src/__support/macros/config.h"
-#include "src/__support/macros/properties/architectures.h"
 #include "src/__support/threads/sleep.h"
-#include "src/string/memory_utils/generic/byte_per_byte.h"
-#include "src/string/memory_utils/inline_memcpy.h"
 
 namespace LIBC_NAMESPACE_DECL {
 namespace rpc {
 
 /// Conditional to indicate if this process is running on the GPU.
 LIBC_INLINE constexpr bool is_process_gpu() {
-#if defined(LIBC_TARGET_ARCH_IS_GPU)
+#if defined(__NVPTX__) || defined(__AMDGPU__)
----------------
jhuber6 wrote:
I think I'm going to cram all of this in `rpc_util.h`. Question is where I should put those two headers when I'm done such that they can be included by everyone.
https://github.com/llvm/llvm-project/pull/116437
    
    
More information about the libc-commits
mailing list