Skip to content

Commit

Permalink
Better error message
Browse files Browse the repository at this point in the history
  • Loading branch information
chudur-budur committed Oct 27, 2023
1 parent 8fd6dbd commit 7baa79e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion numba_dpex/core/runtime/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ def _check_null_result(func):
@functools.wraps(func)
def wrap(self, builder, *args, **kwargs):
memptr = func(self, builder, *args, **kwargs)
msg = "USM allocation failed. Check the usm_type and queue."
msg = "In {0:s}.wrap(). USM allocation failed at {1:s}(). Check the usm_type and queue.".format(
self.__class__.__name__, func.__name__
)
cgutils.guard_memory_error(self._context, builder, memptr, msg=msg)
return memptr

Expand Down

0 comments on commit 7baa79e

Please sign in to comment.