[libc][obvious] Fix undefined variable after name change
authorJoseph Huber <jhuber6@vols.utk.edu>
Thu, 11 May 2023 13:38:27 +0000 (08:38 -0500)
committerJoseph Huber <jhuber6@vols.utk.edu>
Thu, 11 May 2023 14:00:08 +0000 (09:00 -0500)
I forgot that we still used these variables in the loaders.

Differential Revision: https://reviews.llvm.org/D150362

libc/startup/gpu/amdgpu/start.cpp
libc/startup/gpu/nvptx/start.cpp
libc/utils/gpu/loader/amdgpu/Loader.cpp
libc/utils/gpu/loader/nvptx/Loader.cpp

index b9f1df204b41136b8cdfb86bd4e663769cb4d4df..8d85fe1a4b03d4a5956a3a111f399ff68656287b 100644 (file)
@@ -41,7 +41,7 @@ extern "C" [[gnu::visibility("protected"), clang::amdgpu_kernel]] void
 _begin(int argc, char **argv, char **env, void *rpc_shared_buffer) {
   // We need to set up the RPC client first in case any of the constructors
   // require it.
-  __llvm_libc::rpc::client.reset(__llvm_libc::rpc::default_port_count,
+  __llvm_libc::rpc::client.reset(__llvm_libc::rpc::DEFAULT_PORT_COUNT,
                                  __llvm_libc::gpu::get_lane_size(),
                                  rpc_shared_buffer);
 
index 709a5936d82e985bf041a7e518d74bd0991d2eab..fdd3c439530e18db79f0cc7e32fd7ff87a5e087c 100644 (file)
@@ -45,7 +45,7 @@ extern "C" [[gnu::visibility("protected"), clang::nvptx_kernel]] void
 _begin(int argc, char **argv, char **env, void *rpc_shared_buffer) {
   // We need to set up the RPC client first in case any of the constructors
   // require it.
-  __llvm_libc::rpc::client.reset(__llvm_libc::rpc::default_port_count,
+  __llvm_libc::rpc::client.reset(__llvm_libc::rpc::DEFAULT_PORT_COUNT,
                                  __llvm_libc::gpu::get_lane_size(),
                                  rpc_shared_buffer);
 
index fac81a2057b59eb680806453ee18496063020cd2..eab3d6a0007945f218ecfadeb53743550327c717 100644 (file)
@@ -330,7 +330,7 @@ int load(int argc, char **argv, char **envp, void *image, size_t size,
   hsa_amd_memory_fill(dev_ret, 0, sizeof(int));
 
   // Allocate finegrained memory for the RPC server and client to share.
-  uint64_t port_size = __llvm_libc::rpc::default_port_count;
+  uint64_t port_size = __llvm_libc::rpc::DEFAULT_PORT_COUNT;
   uint32_t wavefront_size = 0;
   if (hsa_status_t err = hsa_agent_get_info(
           dev_agent, HSA_AGENT_INFO_WAVEFRONT_SIZE, &wavefront_size))
index c5c23604a1aa9df9abd64145fa810c2db119c0df..fc30274163dc3c588611987452a4cefe3c96a895 100644 (file)
@@ -246,7 +246,7 @@ int load(int argc, char **argv, char **envp, void *image, size_t size,
   if (CUresult err = cuMemsetD32(dev_ret, 0, 1))
     handle_error(err);
 
-  uint64_t port_size = __llvm_libc::rpc::default_port_count;
+  uint64_t port_size = __llvm_libc::rpc::DEFAULT_PORT_COUNT;
   uint32_t warp_size = 32;
 
   uint64_t rpc_shared_buffer_size =