Skip to content

[BUG] Default device memory allocation is too aggressive #1160

Description

@JerryHOTS

Software versions

Python      :  3.12.7 | packaged by conda-forge | (main, Oct  4 2024, 16:05:46) [GCC 13.3.0]
Platform    :  Linux-5.15.167.4-microsoft-standard-WSL2-x86_64-with-glibc2.39
Legion      :  24.11.1 (commit: ac6aae07cb18fa9de978b073766dd9e3def29dbb)
Legate      :  24.11.1
[0 - 7f06e35b3600]    0.000000 {5}{module_config}: Module numa can not detect resources.
[0 - 7f06e35b3600]    0.000000 {4}{openmp}: numa support not found (or not working)
[0 - 7f06e35b3600]    0.000000 {5}{gpu}: /tmp/conda-croot/legate/work/arch-conda/skbuild_core/_deps/legion-src/runtime/realm/cuda/cuda_module.cc(3985):CUDA_DRIVER_FNPTR(cuIpcGetMemHandle)(&alloc.ipc_handle, alloc.dev_ptr) = 2(CUDA_ERROR_OUT_OF_MEMORY): out of memory

(Following's the output for nvidia-smi btw)

+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 565.72                 Driver Version: 566.14         CUDA Version: 12.7     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4070 ...    On  |   00000000:01:00.0 Off |                  N/A |
| N/A   48C    P8              1W /  120W |    7825MiB /   8188MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      3830      C   /python3.12                                 N/A      |
+-----------------------------------------------------------------------------------------+

Jupyter notebook / Jupyter Lab version

No response

Expected behavior

No error

Observed behavior

When I run legate-issue or run import cupynumeric as np in python it raises the following error:

[0 - 7f06e35b3600]    0.000000 {5}{module_config}: Module numa can not detect resources.
[0 - 7f06e35b3600]    0.000000 {4}{openmp}: numa support not found (or not working)
[0 - 7f06e35b3600]    0.000000 {5}{gpu}: /tmp/conda-croot/legate/work/arch-conda/skbuild_core/_deps/legion-src/runtime/realm/cuda/cuda_module.cc(3985):CUDA_DRIVER_FNPTR(cuIpcGetMemHandle)(&alloc.ipc_handle, alloc.dev_ptr) = 2(CUDA_ERROR_OUT_OF_MEMORY): out of memory

Example code or instructions

legate-issue
import cupynumeric as np

Stack traceback or browser console output

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions