Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions numba_dpex/core/runtime/_dbg_printer.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,15 @@
X; \
}
#endif

/*
* Debugging printf function used internally
*/
static inline void drt_debug_print(const char *fmt, ...)
{
va_list args;

va_start(args, fmt);
vfprintf(stderr, fmt, args);
va_end(args);
}
12 changes: 0 additions & 12 deletions numba_dpex/core/runtime/_dpexrt_python.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,18 +62,6 @@ static int DPEXRT_sycl_queue_from_python(PyObject *obj,
queuestruct_t *queue_struct);
static PyObject *DPEXRT_sycl_queue_to_python(queuestruct_t *queuestruct);

/*
* Debugging printf function used internally
*/
void drt_debug_print(const char *fmt, ...)
{
va_list args;

va_start(args, fmt);
vfprintf(stderr, fmt, args);
va_end(args);
}

/** An NRT_external_malloc_func implementation using DPCTLmalloc_device.
*
*/
Expand Down
2 changes: 2 additions & 0 deletions numba_dpex/core/runtime/_nrt_helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ typedef intptr_t atomic_size_t;
#include <stdatomic.h>
#endif

#include "_dbg_printer.h"

/*
* Global resources.
*/
Expand Down
1 change: 1 addition & 0 deletions numba_dpex/core/runtime/_nrt_python_helper.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#include "_nrt_python_helper.h"
#include "_dbg_printer.h"

static PyBufferProcs MemInfo_bufferProcs = {MemInfo_getbuffer, NULL};

Expand Down