public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc/devel/omp/gcc-12] 'include/cuda/cuda.h': Add parts necessary for nvptx-tools 'nvptx-run'
@ 2022-07-05 8:10 Tobias Burnus
0 siblings, 0 replies; only message in thread
From: Tobias Burnus @ 2022-07-05 8:10 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:d271533e520f9c652ba6baee6f1e522496c25d8c
commit d271533e520f9c652ba6baee6f1e522496c25d8c
Author: Thomas Schwinge <thomas@codesourcery.com>
Date: Tue Jul 5 08:46:17 2022 +0200
'include/cuda/cuda.h': Add parts necessary for nvptx-tools 'nvptx-run'
include/
* cuda/cuda.h (enum CUjit_option): Add
'CU_JIT_GENERATE_DEBUG_INFO', 'CU_JIT_GENERATE_LINE_INFO'.
(enum CUlimit): Add 'CU_LIMIT_STACK_SIZE',
'CU_LIMIT_MALLOC_HEAP_SIZE'.
(cuCtxSetLimit, cuGetErrorName): Add.
(cherry picked from commit 86f64400a5692499856d41462461327b93f82b8d)
Diff:
---
include/ChangeLog.omp | 11 +++++++++++
include/cuda/cuda.h | 11 ++++++++++-
2 files changed, 21 insertions(+), 1 deletion(-)
diff --git a/include/ChangeLog.omp b/include/ChangeLog.omp
index d97509dfc31..03d6574f0ea 100644
--- a/include/ChangeLog.omp
+++ b/include/ChangeLog.omp
@@ -1,3 +1,14 @@
+2022-07-05 Tobias Burnus <tobias@codesourcery.com>
+
+ Backport from mainline:
+ 2022-05-18 Thomas Schwinge <thomas@codesourcery.com>
+
+ * cuda/cuda.h (enum CUjit_option): Add
+ 'CU_JIT_GENERATE_DEBUG_INFO', 'CU_JIT_GENERATE_LINE_INFO'.
+ (enum CUlimit): Add 'CU_LIMIT_STACK_SIZE',
+ 'CU_LIMIT_MALLOC_HEAP_SIZE'.
+ (cuCtxSetLimit, cuGetErrorName): Add.
+
2022-07-05 Tobias Burnus <tobias@codesourcery.com>
Backport from mainline:
diff --git a/include/cuda/cuda.h b/include/cuda/cuda.h
index 1c3271ae77a..8135e7c9247 100644
--- a/include/cuda/cuda.h
+++ b/include/cuda/cuda.h
@@ -107,7 +107,9 @@ typedef enum {
CU_JIT_ERROR_LOG_BUFFER = 5,
CU_JIT_ERROR_LOG_BUFFER_SIZE_BYTES = 6,
CU_JIT_OPTIMIZATION_LEVEL = 7,
- CU_JIT_LOG_VERBOSE = 12
+ CU_JIT_GENERATE_DEBUG_INFO = 11,
+ CU_JIT_LOG_VERBOSE = 12,
+ CU_JIT_GENERATE_LINE_INFO = 13,
} CUjit_option;
typedef enum {
@@ -127,6 +129,11 @@ enum {
CU_STREAM_NON_BLOCKING = 1
};
+typedef enum {
+ CU_LIMIT_STACK_SIZE = 0x00,
+ CU_LIMIT_MALLOC_HEAP_SIZE = 0x02,
+} CUlimit;
+
#define cuCtxCreate cuCtxCreate_v2
CUresult cuCtxCreate (CUcontext *, unsigned, CUdevice);
#define cuCtxDestroy cuCtxDestroy_v2
@@ -138,6 +145,7 @@ CUresult cuCtxPopCurrent (CUcontext *);
#define cuCtxPushCurrent cuCtxPushCurrent_v2
CUresult cuCtxPushCurrent (CUcontext);
CUresult cuCtxSynchronize (void);
+CUresult cuCtxSetLimit (CUlimit, size_t);
CUresult cuDeviceGet (CUdevice *, int);
#define cuDeviceTotalMem cuDeviceTotalMem_v2
CUresult cuDeviceTotalMem (size_t *, CUdevice);
@@ -153,6 +161,7 @@ CUresult cuEventRecord (CUevent, CUstream);
CUresult cuEventSynchronize (CUevent);
CUresult cuFuncGetAttribute (int *, CUfunction_attribute, CUfunction);
CUresult cuGetErrorString (CUresult, const char **);
+CUresult cuGetErrorName (CUresult, const char **);
CUresult cuInit (unsigned);
CUresult cuDriverGetVersion (int *);
CUresult cuLaunchKernel (CUfunction, unsigned, unsigned, unsigned, unsigned,
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-07-05 8:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-05 8:10 [gcc/devel/omp/gcc-12] 'include/cuda/cuda.h': Add parts necessary for nvptx-tools 'nvptx-run' Tobias Burnus
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).