diff options
| author | Joseph Huber <huberjn@outlook.com> | 2024-03-29 12:49:16 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-29 12:49:16 -0500 |
| commit | a1a8bb1d3ae9a535526aba9514e87f76e2d040fa (patch) | |
| tree | b8ef82216dc13fce92135886bef9f4e0e469e197 /openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp | |
| parent | bdb60e6f0c8e89abf9bdf36411348db304ca65ba (diff) | |
[libc] Change RPC interface to not use device ids (#87087)
Summary:
The current implementation of RPC tied everything to device IDs and
forced us to do init / shutdown to manage some global state. This turned
out to be a bad idea in situations where we want to track multiple
hetergeneous devices that may report the same device ID in the same
process.
This patch changes the interface to instead create an opaque handle to
the internal device and simply allocates it via `new`. The user will
then take this device and store it to interface with the attached
device. This interface puts the burden of tracking the device identifier
to mapped d evices onto the user, but in return heavily simplifies the
implementation.
Diffstat (limited to 'openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp')
| -rw-r--r-- | openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp b/openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp index a4e6c9319215..55e2865d6aae 100644 --- a/openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp +++ b/openmp/libomptarget/plugins-nextgen/common/src/PluginInterface.cpp @@ -1492,7 +1492,7 @@ Error GenericPluginTy::init() { GlobalHandler = createGlobalHandler(); assert(GlobalHandler && "Invalid global handler"); - RPCServer = new RPCServerTy(NumDevices); + RPCServer = new RPCServerTy(); assert(RPCServer && "Invalid RPC server"); return Plugin::success(); |
