You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
libcuopt.so currently has dynamic dependencies on several non-CUDA, non-RAPIDS shared libraries — libgrpc++.so, libgrpc.so, libgpr.so, libprotobuf.so, multiple libabsl_*.so, libtbb.so, libgomp.so. These get installed automatically when users use the conda channel, but they create friction for users who don't:
Java distribution (cuopt-java, PR java: cuopt-java initial release — LP/MILP/QP API + classifier JARs #1192): The classifier JAR can safely bundle RAPIDS libs (rmm, rapids_logger, mps_parser), CUDA toolkit is excluded per convention, but bundling gRPC/protobuf/abseil is unsafe due to global state and ABI instability conflicting with user-app native deps. So users have to install these via the system package manager or conda.
Standalone C/C++ users: Same friction — every consumer needs the full transitive dep set, not just libcuopt.
Container images: Each base image variant needs the full lib set installed.
Describe the solution you'd like
Have the C++ build static-link the following into libcuopt.so:
libgrpc++, libgrpc, libgpr (gRPC C++)
libprotobuf (protocol buffers C++)
libabsl_* (Abseil; gRPC dep)
libtbb (Intel TBB)
libgomp (OpenMP runtime)
What stays dynamic:
CUDA toolkit libs (libcublas, libcusparse, libcudss, libcublasLt, libcudart, libnvJitLink) — user-installed for licensing/size reasons
RAPIDS libs (librmm, librapids_logger) — bundled in JAR or conda-installed
libmps_parser — sibling library in this repo
C/C++ runtime (libstdc++, libgcc_s, libc, etc.) — system
Describe alternatives you've considered
Bundle in each downstream artifact (Java JAR, future Rust/Go crates) — risky for gRPC/protobuf/abseil because they have global registries; two copies of libprotobuf in one process can crash or corrupt data. TensorFlow has been bitten by this repeatedly.
Document the transitive deps as system prerequisites — current state. Works but adds friction for non-conda users.
Static linking is the standard fix used by TensorFlow's libtensorflow.so and ONNX Runtime's libonnxruntime.so, both of which static-link their gRPC/protobuf/abseil deps.
Is your feature request related to a problem? Please describe.
libcuopt.socurrently has dynamic dependencies on several non-CUDA, non-RAPIDS shared libraries —libgrpc++.so,libgrpc.so,libgpr.so,libprotobuf.so, multiplelibabsl_*.so,libtbb.so,libgomp.so. These get installed automatically when users use the conda channel, but they create friction for users who don't:Describe the solution you'd like
Have the C++ build static-link the following into
libcuopt.so:libgrpc++,libgrpc,libgpr(gRPC C++)libprotobuf(protocol buffers C++)libabsl_*(Abseil; gRPC dep)libtbb(Intel TBB)libgomp(OpenMP runtime)What stays dynamic:
libcublas,libcusparse,libcudss,libcublasLt,libcudart,libnvJitLink) — user-installed for licensing/size reasonslibrmm,librapids_logger) — bundled in JAR or conda-installedlibmps_parser— sibling library in this repolibstdc++,libgcc_s,libc, etc.) — systemDescribe alternatives you've considered
libprotobufin one process can crash or corrupt data. TensorFlow has been bitten by this repeatedly.Static linking is the standard fix used by TensorFlow's
libtensorflow.soand ONNX Runtime'slibonnxruntime.so, both of which static-link their gRPC/protobuf/abseil deps.Additional context
Confirmed dynamic deps via
ldd cpp/build/libcuopt.so:```
libtbb.so.12, libgrpc++.so.1.78, libgrpc.so.52, libgpr.so.52,
libprotobuf.so.33.5.0, libabsl_*.so.2601.0.0 (many),
libgomp.so.1
```
Related: #1202 (C API stats getters — separate concern), PR #1192 (cuopt-java, which prompted this).