/* Generated by Cython 0.29.24 */

/* BEGIN: Cython Metadata
{
    "distutils": {
        "depends": [
            "cuda"
        ],
        "extra_compile_args": [
            "-std=c++14"
        ],
        "include_dirs": [
            "./cuda",
            "cuda",
            "/home/user/mavaz/anaconda3/conda-bld/cuda-python_1633926143181/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place/include"
        ],
        "language": "c++",
        "library_dirs": [
            "/home/user/mavaz/anaconda3/conda-bld/cuda-python_1633926143181/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place/lib/python3.7/site-packages",
            "/home/user/mavaz/anaconda3/conda-bld/cuda-python_1633926143181/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place/lib"
        ],
        "name": "cuda.tests.test_ccuda",
        "sources": [
            "cuda/tests/test_ccuda.pyx"
        ]
    },
    "module_name": "cuda.tests.test_ccuda"
}
END: Cython Metadata */

#ifndef PY_SSIZE_T_CLEAN
#define PY_SSIZE_T_CLEAN
#endif /* PY_SSIZE_T_CLEAN */
#include "Python.h"
#ifndef Py_PYTHON_H
    #error Python headers needed to compile C extensions, please install development version of Python.
#elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
    #error Cython requires Python 2.6+ or Python 3.3+.
#else
#define CYTHON_ABI "0_29_24"
#define CYTHON_HEX_VERSION 0x001D18F0
#define CYTHON_FUTURE_DIVISION 1
#include <stddef.h>
#ifndef offsetof
  #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
#endif
#if !defined(WIN32) && !defined(MS_WINDOWS)
  #ifndef __stdcall
    #define __stdcall
  #endif
  #ifndef __cdecl
    #define __cdecl
  #endif
  #ifndef __fastcall
    #define __fastcall
  #endif
#endif
#ifndef DL_IMPORT
  #define DL_IMPORT(t) t
#endif
#ifndef DL_EXPORT
  #define DL_EXPORT(t) t
#endif
#define __PYX_COMMA ,
#ifndef HAVE_LONG_LONG
  #if PY_VERSION_HEX >= 0x02070000
    #define HAVE_LONG_LONG
  #endif
#endif
#ifndef PY_LONG_LONG
  #define PY_LONG_LONG LONG_LONG
#endif
#ifndef Py_HUGE_VAL
  #define Py_HUGE_VAL HUGE_VAL
#endif
#ifdef PYPY_VERSION
  #define CYTHON_COMPILING_IN_PYPY 1
  #define CYTHON_COMPILING_IN_PYSTON 0
  #define CYTHON_COMPILING_IN_CPYTHON 0
  #undef CYTHON_USE_TYPE_SLOTS
  #define CYTHON_USE_TYPE_SLOTS 0
  #undef CYTHON_USE_PYTYPE_LOOKUP
  #define CYTHON_USE_PYTYPE_LOOKUP 0
  #if PY_VERSION_HEX < 0x03050000
    #undef CYTHON_USE_ASYNC_SLOTS
    #define CYTHON_USE_ASYNC_SLOTS 0
  #elif !defined(CYTHON_USE_ASYNC_SLOTS)
    #define CYTHON_USE_ASYNC_SLOTS 1
  #endif
  #undef CYTHON_USE_PYLIST_INTERNALS
  #define CYTHON_USE_PYLIST_INTERNALS 0
  #undef CYTHON_USE_UNICODE_INTERNALS
  #define CYTHON_USE_UNICODE_INTERNALS 0
  #undef CYTHON_USE_UNICODE_WRITER
  #define CYTHON_USE_UNICODE_WRITER 0
  #undef CYTHON_USE_PYLONG_INTERNALS
  #define CYTHON_USE_PYLONG_INTERNALS 0
  #undef CYTHON_AVOID_BORROWED_REFS
  #define CYTHON_AVOID_BORROWED_REFS 1
  #undef CYTHON_ASSUME_SAFE_MACROS
  #define CYTHON_ASSUME_SAFE_MACROS 0
  #undef CYTHON_UNPACK_METHODS
  #define CYTHON_UNPACK_METHODS 0
  #undef CYTHON_FAST_THREAD_STATE
  #define CYTHON_FAST_THREAD_STATE 0
  #undef CYTHON_FAST_PYCALL
  #define CYTHON_FAST_PYCALL 0
  #undef CYTHON_PEP489_MULTI_PHASE_INIT
  #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  #undef CYTHON_USE_TP_FINALIZE
  #define CYTHON_USE_TP_FINALIZE 0
  #undef CYTHON_USE_DICT_VERSIONS
  #define CYTHON_USE_DICT_VERSIONS 0
  #undef CYTHON_USE_EXC_INFO_STACK
  #define CYTHON_USE_EXC_INFO_STACK 0
#elif defined(PYSTON_VERSION)
  #define CYTHON_COMPILING_IN_PYPY 0
  #define CYTHON_COMPILING_IN_PYSTON 1
  #define CYTHON_COMPILING_IN_CPYTHON 0
  #ifndef CYTHON_USE_TYPE_SLOTS
    #define CYTHON_USE_TYPE_SLOTS 1
  #endif
  #undef CYTHON_USE_PYTYPE_LOOKUP
  #define CYTHON_USE_PYTYPE_LOOKUP 0
  #undef CYTHON_USE_ASYNC_SLOTS
  #define CYTHON_USE_ASYNC_SLOTS 0
  #undef CYTHON_USE_PYLIST_INTERNALS
  #define CYTHON_USE_PYLIST_INTERNALS 0
  #ifndef CYTHON_USE_UNICODE_INTERNALS
    #define CYTHON_USE_UNICODE_INTERNALS 1
  #endif
  #undef CYTHON_USE_UNICODE_WRITER
  #define CYTHON_USE_UNICODE_WRITER 0
  #undef CYTHON_USE_PYLONG_INTERNALS
  #define CYTHON_USE_PYLONG_INTERNALS 0
  #ifndef CYTHON_AVOID_BORROWED_REFS
    #define CYTHON_AVOID_BORROWED_REFS 0
  #endif
  #ifndef CYTHON_ASSUME_SAFE_MACROS
    #define CYTHON_ASSUME_SAFE_MACROS 1
  #endif
  #ifndef CYTHON_UNPACK_METHODS
    #define CYTHON_UNPACK_METHODS 1
  #endif
  #undef CYTHON_FAST_THREAD_STATE
  #define CYTHON_FAST_THREAD_STATE 0
  #undef CYTHON_FAST_PYCALL
  #define CYTHON_FAST_PYCALL 0
  #undef CYTHON_PEP489_MULTI_PHASE_INIT
  #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  #undef CYTHON_USE_TP_FINALIZE
  #define CYTHON_USE_TP_FINALIZE 0
  #undef CYTHON_USE_DICT_VERSIONS
  #define CYTHON_USE_DICT_VERSIONS 0
  #undef CYTHON_USE_EXC_INFO_STACK
  #define CYTHON_USE_EXC_INFO_STACK 0
#else
  #define CYTHON_COMPILING_IN_PYPY 0
  #define CYTHON_COMPILING_IN_PYSTON 0
  #define CYTHON_COMPILING_IN_CPYTHON 1
  #ifndef CYTHON_USE_TYPE_SLOTS
    #define CYTHON_USE_TYPE_SLOTS 1
  #endif
  #if PY_VERSION_HEX < 0x02070000
    #undef CYTHON_USE_PYTYPE_LOOKUP
    #define CYTHON_USE_PYTYPE_LOOKUP 0
  #elif !defined(CYTHON_USE_PYTYPE_LOOKUP)
    #define CYTHON_USE_PYTYPE_LOOKUP 1
  #endif
  #if PY_MAJOR_VERSION < 3
    #undef CYTHON_USE_ASYNC_SLOTS
    #define CYTHON_USE_ASYNC_SLOTS 0
  #elif !defined(CYTHON_USE_ASYNC_SLOTS)
    #define CYTHON_USE_ASYNC_SLOTS 1
  #endif
  #if PY_VERSION_HEX < 0x02070000
    #undef CYTHON_USE_PYLONG_INTERNALS
    #define CYTHON_USE_PYLONG_INTERNALS 0
  #elif !defined(CYTHON_USE_PYLONG_INTERNALS)
    #define CYTHON_USE_PYLONG_INTERNALS 1
  #endif
  #ifndef CYTHON_USE_PYLIST_INTERNALS
    #define CYTHON_USE_PYLIST_INTERNALS 1
  #endif
  #ifndef CYTHON_USE_UNICODE_INTERNALS
    #define CYTHON_USE_UNICODE_INTERNALS 1
  #endif
  #if PY_VERSION_HEX < 0x030300F0
    #undef CYTHON_USE_UNICODE_WRITER
    #define CYTHON_USE_UNICODE_WRITER 0
  #elif !defined(CYTHON_USE_UNICODE_WRITER)
    #define CYTHON_USE_UNICODE_WRITER 1
  #endif
  #ifndef CYTHON_AVOID_BORROWED_REFS
    #define CYTHON_AVOID_BORROWED_REFS 0
  #endif
  #ifndef CYTHON_ASSUME_SAFE_MACROS
    #define CYTHON_ASSUME_SAFE_MACROS 1
  #endif
  #ifndef CYTHON_UNPACK_METHODS
    #define CYTHON_UNPACK_METHODS 1
  #endif
  #ifndef CYTHON_FAST_THREAD_STATE
    #define CYTHON_FAST_THREAD_STATE 1
  #endif
  #ifndef CYTHON_FAST_PYCALL
    #define CYTHON_FAST_PYCALL 1
  #endif
  #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
    #define CYTHON_PEP489_MULTI_PHASE_INIT (PY_VERSION_HEX >= 0x03050000)
  #endif
  #ifndef CYTHON_USE_TP_FINALIZE
    #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
  #endif
  #ifndef CYTHON_USE_DICT_VERSIONS
    #define CYTHON_USE_DICT_VERSIONS (PY_VERSION_HEX >= 0x030600B1)
  #endif
  #ifndef CYTHON_USE_EXC_INFO_STACK
    #define CYTHON_USE_EXC_INFO_STACK (PY_VERSION_HEX >= 0x030700A3)
  #endif
#endif
#if !defined(CYTHON_FAST_PYCCALL)
#define CYTHON_FAST_PYCCALL  (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
#endif
#if CYTHON_USE_PYLONG_INTERNALS
  #include "longintrepr.h"
  #undef SHIFT
  #undef BASE
  #undef MASK
  #ifdef SIZEOF_VOID_P
    enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P == sizeof(void*)) };
  #endif
#endif
#ifndef __has_attribute
  #define __has_attribute(x) 0
#endif
#ifndef __has_cpp_attribute
  #define __has_cpp_attribute(x) 0
#endif
#ifndef CYTHON_RESTRICT
  #if defined(__GNUC__)
    #define CYTHON_RESTRICT __restrict__
  #elif defined(_MSC_VER) && _MSC_VER >= 1400
    #define CYTHON_RESTRICT __restrict
  #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    #define CYTHON_RESTRICT restrict
  #else
    #define CYTHON_RESTRICT
  #endif
#endif
#ifndef CYTHON_UNUSED
# if defined(__GNUC__)
#   if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
#     define CYTHON_UNUSED __attribute__ ((__unused__))
#   else
#     define CYTHON_UNUSED
#   endif
# elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
#   define CYTHON_UNUSED __attribute__ ((__unused__))
# else
#   define CYTHON_UNUSED
# endif
#endif
#ifndef CYTHON_MAYBE_UNUSED_VAR
#  if defined(__cplusplus)
     template<class T> void CYTHON_MAYBE_UNUSED_VAR( const T& ) { }
#  else
#    define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
#  endif
#endif
#ifndef CYTHON_NCP_UNUSED
# if CYTHON_COMPILING_IN_CPYTHON
#  define CYTHON_NCP_UNUSED
# else
#  define CYTHON_NCP_UNUSED CYTHON_UNUSED
# endif
#endif
#define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
#ifdef _MSC_VER
    #ifndef _MSC_STDINT_H_
        #if _MSC_VER < 1300
           typedef unsigned char     uint8_t;
           typedef unsigned int      uint32_t;
        #else
           typedef unsigned __int8   uint8_t;
           typedef unsigned __int32  uint32_t;
        #endif
    #endif
#else
   #include <stdint.h>
#endif
#ifndef CYTHON_FALLTHROUGH
  #if defined(__cplusplus) && __cplusplus >= 201103L
    #if __has_cpp_attribute(fallthrough)
      #define CYTHON_FALLTHROUGH [[fallthrough]]
    #elif __has_cpp_attribute(clang::fallthrough)
      #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
    #elif __has_cpp_attribute(gnu::fallthrough)
      #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
    #endif
  #endif
  #ifndef CYTHON_FALLTHROUGH
    #if __has_attribute(fallthrough)
      #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
    #else
      #define CYTHON_FALLTHROUGH
    #endif
  #endif
  #if defined(__clang__ ) && defined(__apple_build_version__)
    #if __apple_build_version__ < 7000000
      #undef  CYTHON_FALLTHROUGH
      #define CYTHON_FALLTHROUGH
    #endif
  #endif
#endif

#ifndef __cplusplus
  #error "Cython files generated with the C++ option must be compiled with a C++ compiler."
#endif
#ifndef CYTHON_INLINE
  #if defined(__clang__)
    #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
  #else
    #define CYTHON_INLINE inline
  #endif
#endif
template<typename T>
void __Pyx_call_destructor(T& x) {
    x.~T();
}
template<typename T>
class __Pyx_FakeReference {
  public:
    __Pyx_FakeReference() : ptr(NULL) { }
    __Pyx_FakeReference(const T& ref) : ptr(const_cast<T*>(&ref)) { }
    T *operator->() { return ptr; }
    T *operator&() { return ptr; }
    operator T&() { return *ptr; }
    template<typename U> bool operator ==(U other) { return *ptr == other; }
    template<typename U> bool operator !=(U other) { return *ptr != other; }
  private:
    T *ptr;
};

#if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
  #define Py_OptimizeFlag 0
#endif
#define __PYX_BUILD_PY_SSIZE_T "n"
#define CYTHON_FORMAT_SSIZE_T "z"
#if PY_MAJOR_VERSION < 3
  #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
          PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
  #define __Pyx_DefaultClassType PyClass_Type
#else
  #define __Pyx_BUILTIN_MODULE_NAME "builtins"
#if PY_VERSION_HEX >= 0x030800A4 && PY_VERSION_HEX < 0x030800B2
  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
          PyCode_New(a, 0, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#else
  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
          PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#endif
  #define __Pyx_DefaultClassType PyType_Type
#endif
#ifndef Py_TPFLAGS_CHECKTYPES
  #define Py_TPFLAGS_CHECKTYPES 0
#endif
#ifndef Py_TPFLAGS_HAVE_INDEX
  #define Py_TPFLAGS_HAVE_INDEX 0
#endif
#ifndef Py_TPFLAGS_HAVE_NEWBUFFER
  #define Py_TPFLAGS_HAVE_NEWBUFFER 0
#endif
#ifndef Py_TPFLAGS_HAVE_FINALIZE
  #define Py_TPFLAGS_HAVE_FINALIZE 0
#endif
#ifndef METH_STACKLESS
  #define METH_STACKLESS 0
#endif
#if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
  #ifndef METH_FASTCALL
     #define METH_FASTCALL 0x80
  #endif
  typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *self, PyObject *const *args, Py_ssize_t nargs);
  typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *self, PyObject *const *args,
                                                          Py_ssize_t nargs, PyObject *kwnames);
#else
  #define __Pyx_PyCFunctionFast _PyCFunctionFast
  #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
#endif
#if CYTHON_FAST_PYCCALL
#define __Pyx_PyFastCFunction_Check(func)\
    ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)))))
#else
#define __Pyx_PyFastCFunction_Check(func) 0
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
  #define PyObject_Malloc(s)   PyMem_Malloc(s)
  #define PyObject_Free(p)     PyMem_Free(p)
  #define PyObject_Realloc(p)  PyMem_Realloc(p)
#endif
#if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030400A1
  #define PyMem_RawMalloc(n)           PyMem_Malloc(n)
  #define PyMem_RawRealloc(p, n)       PyMem_Realloc(p, n)
  #define PyMem_RawFree(p)             PyMem_Free(p)
#endif
#if CYTHON_COMPILING_IN_PYSTON
  #define __Pyx_PyCode_HasFreeVars(co)  PyCode_HasFreeVars(co)
  #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno)
#else
  #define __Pyx_PyCode_HasFreeVars(co)  (PyCode_GetNumFree(co) > 0)
  #define __Pyx_PyFrame_SetLineNumber(frame, lineno)  (frame)->f_lineno = (lineno)
#endif
#if !CYTHON_FAST_THREAD_STATE || PY_VERSION_HEX < 0x02070000
  #define __Pyx_PyThreadState_Current PyThreadState_GET()
#elif PY_VERSION_HEX >= 0x03060000
  #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
#elif PY_VERSION_HEX >= 0x03000000
  #define __Pyx_PyThreadState_Current PyThreadState_GET()
#else
  #define __Pyx_PyThreadState_Current _PyThreadState_Current
#endif
#if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
#include "pythread.h"
#define Py_tss_NEEDS_INIT 0
typedef int Py_tss_t;
static CYTHON_INLINE int PyThread_tss_create(Py_tss_t *key) {
  *key = PyThread_create_key();
  return 0;
}
static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(void) {
  Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(sizeof(Py_tss_t));
  *key = Py_tss_NEEDS_INIT;
  return key;
}
static CYTHON_INLINE void PyThread_tss_free(Py_tss_t *key) {
  PyObject_Free(key);
}
static CYTHON_INLINE int PyThread_tss_is_created(Py_tss_t *key) {
  return *key != Py_tss_NEEDS_INIT;
}
static CYTHON_INLINE void PyThread_tss_delete(Py_tss_t *key) {
  PyThread_delete_key(*key);
  *key = Py_tss_NEEDS_INIT;
}
static CYTHON_INLINE int PyThread_tss_set(Py_tss_t *key, void *value) {
  return PyThread_set_key_value(*key, value);
}
static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
  return PyThread_get_key_value(*key);
}
#endif
#if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
#define __Pyx_PyDict_NewPresized(n)  ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
#else
#define __Pyx_PyDict_NewPresized(n)  PyDict_New()
#endif
#if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
  #define __Pyx_PyNumber_Divide(x,y)         PyNumber_TrueDivide(x,y)
  #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceTrueDivide(x,y)
#else
  #define __Pyx_PyNumber_Divide(x,y)         PyNumber_Divide(x,y)
  #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceDivide(x,y)
#endif
#if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && CYTHON_USE_UNICODE_INTERNALS
#define __Pyx_PyDict_GetItemStr(dict, name)  _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
#else
#define __Pyx_PyDict_GetItemStr(dict, name)  PyDict_GetItem(dict, name)
#endif
#if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
  #define CYTHON_PEP393_ENABLED 1
  #if defined(PyUnicode_IS_READY)
  #define __Pyx_PyUnicode_READY(op)       (likely(PyUnicode_IS_READY(op)) ?\
                                              0 : _PyUnicode_Ready((PyObject *)(op)))
  #else
  #define __Pyx_PyUnicode_READY(op)       (0)
  #endif
  #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_LENGTH(u)
  #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
  #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u)   PyUnicode_MAX_CHAR_VALUE(u)
  #define __Pyx_PyUnicode_KIND(u)         PyUnicode_KIND(u)
  #define __Pyx_PyUnicode_DATA(u)         PyUnicode_DATA(u)
  #define __Pyx_PyUnicode_READ(k, d, i)   PyUnicode_READ(k, d, i)
  #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  PyUnicode_WRITE(k, d, i, ch)
  #if defined(PyUnicode_IS_READY) && defined(PyUnicode_GET_SIZE)
  #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x03090000
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : ((PyCompactUnicodeObject *)(u))->wstr_length))
  #else
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
  #endif
  #else
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GET_LENGTH(u))
  #endif
#else
  #define CYTHON_PEP393_ENABLED 0
  #define PyUnicode_1BYTE_KIND  1
  #define PyUnicode_2BYTE_KIND  2
  #define PyUnicode_4BYTE_KIND  4
  #define __Pyx_PyUnicode_READY(op)       (0)
  #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_SIZE(u)
  #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
  #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u)   ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111)
  #define __Pyx_PyUnicode_KIND(u)         (sizeof(Py_UNICODE))
  #define __Pyx_PyUnicode_DATA(u)         ((void*)PyUnicode_AS_UNICODE(u))
  #define __Pyx_PyUnicode_READ(k, d, i)   ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
  #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  (((void)(k)), ((Py_UNICODE*)d)[i] = ch)
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GET_SIZE(u))
#endif
#if CYTHON_COMPILING_IN_PYPY
  #define __Pyx_PyUnicode_Concat(a, b)      PyNumber_Add(a, b)
  #define __Pyx_PyUnicode_ConcatSafe(a, b)  PyNumber_Add(a, b)
#else
  #define __Pyx_PyUnicode_Concat(a, b)      PyUnicode_Concat(a, b)
  #define __Pyx_PyUnicode_ConcatSafe(a, b)  ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
      PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
  #define PyUnicode_Contains(u, s)  PySequence_Contains(u, s)
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
  #define PyByteArray_Check(obj)  PyObject_TypeCheck(obj, &PyByteArray_Type)
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
  #define PyObject_Format(obj, fmt)  PyObject_CallMethod(obj, "__format__", "O", fmt)
#endif
#define __Pyx_PyString_FormatSafe(a, b)   ((unlikely((a) == Py_None || (PyString_Check(b) && !PyString_CheckExact(b)))) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
#define __Pyx_PyUnicode_FormatSafe(a, b)  ((unlikely((a) == Py_None || (PyUnicode_Check(b) && !PyUnicode_CheckExact(b)))) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyString_Format(a, b)  PyUnicode_Format(a, b)
#else
  #define __Pyx_PyString_Format(a, b)  PyString_Format(a, b)
#endif
#if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
  #define PyObject_ASCII(o)            PyObject_Repr(o)
#endif
#if PY_MAJOR_VERSION >= 3
  #define PyBaseString_Type            PyUnicode_Type
  #define PyStringObject               PyUnicodeObject
  #define PyString_Type                PyUnicode_Type
  #define PyString_Check               PyUnicode_Check
  #define PyString_CheckExact          PyUnicode_CheckExact
#ifndef PyObject_Unicode
  #define PyObject_Unicode             PyObject_Str
#endif
#endif
#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
  #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
#else
  #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
  #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
#endif
#ifndef PySet_CheckExact
  #define PySet_CheckExact(obj)        (Py_TYPE(obj) == &PySet_Type)
#endif
#if PY_VERSION_HEX >= 0x030900A4
  #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj, refcnt)
  #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj, size)
#else
  #define __Pyx_SET_REFCNT(obj, refcnt) Py_REFCNT(obj) = (refcnt)
  #define __Pyx_SET_SIZE(obj, size) Py_SIZE(obj) = (size)
#endif
#if CYTHON_ASSUME_SAFE_MACROS
  #define __Pyx_PySequence_SIZE(seq)  Py_SIZE(seq)
#else
  #define __Pyx_PySequence_SIZE(seq)  PySequence_Size(seq)
#endif
#if PY_MAJOR_VERSION >= 3
  #define PyIntObject                  PyLongObject
  #define PyInt_Type                   PyLong_Type
  #define PyInt_Check(op)              PyLong_Check(op)
  #define PyInt_CheckExact(op)         PyLong_CheckExact(op)
  #define PyInt_FromString             PyLong_FromString
  #define PyInt_FromUnicode            PyLong_FromUnicode
  #define PyInt_FromLong               PyLong_FromLong
  #define PyInt_FromSize_t             PyLong_FromSize_t
  #define PyInt_FromSsize_t            PyLong_FromSsize_t
  #define PyInt_AsLong                 PyLong_AsLong
  #define PyInt_AS_LONG                PyLong_AS_LONG
  #define PyInt_AsSsize_t              PyLong_AsSsize_t
  #define PyInt_AsUnsignedLongMask     PyLong_AsUnsignedLongMask
  #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
  #define PyNumber_Int                 PyNumber_Long
#endif
#if PY_MAJOR_VERSION >= 3
  #define PyBoolObject                 PyLongObject
#endif
#if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
  #ifndef PyUnicode_InternFromString
    #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
  #endif
#endif
#if PY_VERSION_HEX < 0x030200A4
  typedef long Py_hash_t;
  #define __Pyx_PyInt_FromHash_t PyInt_FromLong
  #define __Pyx_PyInt_AsHash_t   PyInt_AsLong
#else
  #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
  #define __Pyx_PyInt_AsHash_t   PyInt_AsSsize_t
#endif
#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyMethod_New(func, self, klass) ((self) ? ((void)(klass), PyMethod_New(func, self)) : __Pyx_NewRef(func))
#else
  #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
#endif
#if CYTHON_USE_ASYNC_SLOTS
  #if PY_VERSION_HEX >= 0x030500B1
    #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
    #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
  #else
    #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
  #endif
#else
  #define __Pyx_PyType_AsAsync(obj) NULL
#endif
#ifndef __Pyx_PyAsyncMethodsStruct
    typedef struct {
        unaryfunc am_await;
        unaryfunc am_aiter;
        unaryfunc am_anext;
    } __Pyx_PyAsyncMethodsStruct;
#endif

#if defined(WIN32) || defined(MS_WINDOWS)
  #define _USE_MATH_DEFINES
#endif
#include <math.h>
#ifdef NAN
#define __PYX_NAN() ((float) NAN)
#else
static CYTHON_INLINE float __PYX_NAN() {
  float value;
  memset(&value, 0xFF, sizeof(value));
  return value;
}
#endif
#if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
#define __Pyx_truncl trunc
#else
#define __Pyx_truncl truncl
#endif

#define __PYX_MARK_ERR_POS(f_index, lineno) \
    { __pyx_filename = __pyx_f[f_index]; (void)__pyx_filename; __pyx_lineno = lineno; (void)__pyx_lineno; __pyx_clineno = __LINE__; (void)__pyx_clineno; }
#define __PYX_ERR(f_index, lineno, Ln_error) \
    { __PYX_MARK_ERR_POS(f_index, lineno) goto Ln_error; }

#ifndef __PYX_EXTERN_C
  #ifdef __cplusplus
    #define __PYX_EXTERN_C extern "C"
  #else
    #define __PYX_EXTERN_C extern
  #endif
#endif

#define __PYX_HAVE__cuda__tests__test_ccuda
#define __PYX_HAVE_API__cuda__tests__test_ccuda
/* Early includes */
#include <string.h>
#include <stdint.h>
#ifdef _OPENMP
#include <omp.h>
#endif /* _OPENMP */

#if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
#define CYTHON_WITHOUT_ASSERTIONS
#endif

typedef struct {PyObject **p; const char *s; const Py_ssize_t n; const char* encoding;
                const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry;

#define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
#define __PYX_DEFAULT_STRING_ENCODING_IS_UTF8 0
#define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT (PY_MAJOR_VERSION >= 3 && __PYX_DEFAULT_STRING_ENCODING_IS_UTF8)
#define __PYX_DEFAULT_STRING_ENCODING ""
#define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
#define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
#define __Pyx_uchar_cast(c) ((unsigned char)c)
#define __Pyx_long_cast(x) ((long)x)
#define __Pyx_fits_Py_ssize_t(v, type, is_signed)  (\
    (sizeof(type) < sizeof(Py_ssize_t))  ||\
    (sizeof(type) > sizeof(Py_ssize_t) &&\
          likely(v < (type)PY_SSIZE_T_MAX ||\
                 v == (type)PY_SSIZE_T_MAX)  &&\
          (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
                                v == (type)PY_SSIZE_T_MIN)))  ||\
    (sizeof(type) == sizeof(Py_ssize_t) &&\
          (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
                               v == (type)PY_SSIZE_T_MAX)))  )
static CYTHON_INLINE int __Pyx_is_valid_index(Py_ssize_t i, Py_ssize_t limit) {
    return (size_t) i < (size_t) limit;
}
#if defined (__cplusplus) && __cplusplus >= 201103L
    #include <cstdlib>
    #define __Pyx_sst_abs(value) std::abs(value)
#elif SIZEOF_INT >= SIZEOF_SIZE_T
    #define __Pyx_sst_abs(value) abs(value)
#elif SIZEOF_LONG >= SIZEOF_SIZE_T
    #define __Pyx_sst_abs(value) labs(value)
#elif defined (_MSC_VER)
    #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
#elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    #define __Pyx_sst_abs(value) llabs(value)
#elif defined (__GNUC__)
    #define __Pyx_sst_abs(value) __builtin_llabs(value)
#else
    #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
#endif
static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject*);
static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
#define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
#define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
#define __Pyx_PyBytes_FromString        PyBytes_FromString
#define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*);
#if PY_MAJOR_VERSION < 3
    #define __Pyx_PyStr_FromString        __Pyx_PyBytes_FromString
    #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
#else
    #define __Pyx_PyStr_FromString        __Pyx_PyUnicode_FromString
    #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
#endif
#define __Pyx_PyBytes_AsWritableString(s)     ((char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsWritableSString(s)    ((signed char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsWritableUString(s)    ((unsigned char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsString(s)     ((const char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsSString(s)    ((const signed char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsUString(s)    ((const unsigned char*) PyBytes_AS_STRING(s))
#define __Pyx_PyObject_AsWritableString(s)    ((char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsWritableSString(s)    ((signed char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsWritableUString(s)    ((unsigned char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsSString(s)    ((const signed char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsUString(s)    ((const unsigned char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_FromCString(s)  __Pyx_PyObject_FromString((const char*)s)
#define __Pyx_PyBytes_FromCString(s)   __Pyx_PyBytes_FromString((const char*)s)
#define __Pyx_PyByteArray_FromCString(s)   __Pyx_PyByteArray_FromString((const char*)s)
#define __Pyx_PyStr_FromCString(s)     __Pyx_PyStr_FromString((const char*)s)
#define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u) {
    const Py_UNICODE *u_end = u;
    while (*u_end++) ;
    return (size_t)(u_end - u - 1);
}
#define __Pyx_PyUnicode_FromUnicode(u)       PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
#define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
#define __Pyx_PyUnicode_AsUnicode            PyUnicode_AsUnicode
#define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
#define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b);
static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject*);
static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
#define __Pyx_PySequence_Tuple(obj)\
    (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
#if CYTHON_ASSUME_SAFE_MACROS
#define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
#else
#define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
#endif
#define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
#if PY_MAJOR_VERSION >= 3
#define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
#else
#define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
#endif
#define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x))
#if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
static int __Pyx_sys_getdefaultencoding_not_ascii;
static int __Pyx_init_sys_getdefaultencoding_params(void) {
    PyObject* sys;
    PyObject* default_encoding = NULL;
    PyObject* ascii_chars_u = NULL;
    PyObject* ascii_chars_b = NULL;
    const char* default_encoding_c;
    sys = PyImport_ImportModule("sys");
    if (!sys) goto bad;
    default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
    Py_DECREF(sys);
    if (!default_encoding) goto bad;
    default_encoding_c = PyBytes_AsString(default_encoding);
    if (!default_encoding_c) goto bad;
    if (strcmp(default_encoding_c, "ascii") == 0) {
        __Pyx_sys_getdefaultencoding_not_ascii = 0;
    } else {
        char ascii_chars[128];
        int c;
        for (c = 0; c < 128; c++) {
            ascii_chars[c] = c;
        }
        __Pyx_sys_getdefaultencoding_not_ascii = 1;
        ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
        if (!ascii_chars_u) goto bad;
        ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
        if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
            PyErr_Format(
                PyExc_ValueError,
                "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
                default_encoding_c);
            goto bad;
        }
        Py_DECREF(ascii_chars_u);
        Py_DECREF(ascii_chars_b);
    }
    Py_DECREF(default_encoding);
    return 0;
bad:
    Py_XDECREF(default_encoding);
    Py_XDECREF(ascii_chars_u);
    Py_XDECREF(ascii_chars_b);
    return -1;
}
#endif
#if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
#define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
#else
#define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
#if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
static char* __PYX_DEFAULT_STRING_ENCODING;
static int __Pyx_init_sys_getdefaultencoding_params(void) {
    PyObject* sys;
    PyObject* default_encoding = NULL;
    char* default_encoding_c;
    sys = PyImport_ImportModule("sys");
    if (!sys) goto bad;
    default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
    Py_DECREF(sys);
    if (!default_encoding) goto bad;
    default_encoding_c = PyBytes_AsString(default_encoding);
    if (!default_encoding_c) goto bad;
    __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c) + 1);
    if (!__PYX_DEFAULT_STRING_ENCODING) goto bad;
    strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
    Py_DECREF(default_encoding);
    return 0;
bad:
    Py_XDECREF(default_encoding);
    return -1;
}
#endif
#endif


/* Test for GCC > 2.95 */
#if defined(__GNUC__)     && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
  #define likely(x)   __builtin_expect(!!(x), 1)
  #define unlikely(x) __builtin_expect(!!(x), 0)
#else /* !__GNUC__ or GCC < 2.95 */
  #define likely(x)   (x)
  #define unlikely(x) (x)
#endif /* __GNUC__ */
static CYTHON_INLINE void __Pyx_pretend_to_initialize(void* ptr) { (void)ptr; }

static PyObject *__pyx_m = NULL;
static PyObject *__pyx_d;
static PyObject *__pyx_b;
static PyObject *__pyx_cython_runtime = NULL;
static PyObject *__pyx_empty_tuple;
static PyObject *__pyx_empty_bytes;
static PyObject *__pyx_empty_unicode;
static int __pyx_lineno;
static int __pyx_clineno = 0;
static const char * __pyx_cfilenm= __FILE__;
static const char *__pyx_filename;


static const char *__pyx_f[] = {
  "cuda/tests/test_ccuda.pyx",
};

/* "cuda/ccuda.pxd":11
 * 
 * 
 * ctypedef uint32_t cuuint32_t             # <<<<<<<<<<<<<<
 * 
 * ctypedef uint64_t cuuint64_t
 */
typedef uint32_t __pyx_t_4cuda_5ccuda_cuuint32_t;

/* "cuda/ccuda.pxd":13
 * ctypedef uint32_t cuuint32_t
 * 
 * ctypedef uint64_t cuuint64_t             # <<<<<<<<<<<<<<
 * 
 * ctypedef unsigned long long CUdeviceptr_v2
 */
typedef uint64_t __pyx_t_4cuda_5ccuda_cuuint64_t;

/* "cuda/ccuda.pxd":15
 * ctypedef uint64_t cuuint64_t
 * 
 * ctypedef unsigned long long CUdeviceptr_v2             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUdeviceptr_v2 CUdeviceptr
 */
typedef unsigned PY_LONG_LONG __pyx_t_4cuda_5ccuda_CUdeviceptr_v2;

/* "cuda/ccuda.pxd":17
 * ctypedef unsigned long long CUdeviceptr_v2
 * 
 * ctypedef CUdeviceptr_v2 CUdeviceptr             # <<<<<<<<<<<<<<
 * 
 * ctypedef int CUdevice_v1
 */
typedef __pyx_t_4cuda_5ccuda_CUdeviceptr_v2 __pyx_t_4cuda_5ccuda_CUdeviceptr;

/* "cuda/ccuda.pxd":19
 * ctypedef CUdeviceptr_v2 CUdeviceptr
 * 
 * ctypedef int CUdevice_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUdevice_v1 CUdevice
 */
typedef int __pyx_t_4cuda_5ccuda_CUdevice_v1;

/* "cuda/ccuda.pxd":21
 * ctypedef int CUdevice_v1
 * 
 * ctypedef CUdevice_v1 CUdevice             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef __pyx_t_4cuda_5ccuda_CUdevice_v1 __pyx_t_4cuda_5ccuda_CUdevice;

/* "cuda/ccuda.pxd":73
 * ctypedef CUgraphicsResource_st* CUgraphicsResource
 * 
 * ctypedef unsigned long long CUtexObject_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUtexObject_v1 CUtexObject
 */
typedef unsigned PY_LONG_LONG __pyx_t_4cuda_5ccuda_CUtexObject_v1;

/* "cuda/ccuda.pxd":75
 * ctypedef unsigned long long CUtexObject_v1
 * 
 * ctypedef CUtexObject_v1 CUtexObject             # <<<<<<<<<<<<<<
 * 
 * ctypedef unsigned long long CUsurfObject_v1
 */
typedef __pyx_t_4cuda_5ccuda_CUtexObject_v1 __pyx_t_4cuda_5ccuda_CUtexObject;

/* "cuda/ccuda.pxd":77
 * ctypedef CUtexObject_v1 CUtexObject
 * 
 * ctypedef unsigned long long CUsurfObject_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUsurfObject_v1 CUsurfObject
 */
typedef unsigned PY_LONG_LONG __pyx_t_4cuda_5ccuda_CUsurfObject_v1;

/* "cuda/ccuda.pxd":79
 * ctypedef unsigned long long CUsurfObject_v1
 * 
 * ctypedef CUsurfObject_v1 CUsurfObject             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef __pyx_t_4cuda_5ccuda_CUsurfObject_v1 __pyx_t_4cuda_5ccuda_CUsurfObject;

/* "cuda/ccuda.pxd":1340
 * ctypedef CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1 CUDA_EXT_SEM_WAIT_NODE_PARAMS
 * 
 * ctypedef unsigned long long CUmemGenericAllocationHandle_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemGenericAllocationHandle_v1 CUmemGenericAllocationHandle
 */
typedef unsigned PY_LONG_LONG __pyx_t_4cuda_5ccuda_CUmemGenericAllocationHandle_v1;

/* "cuda/ccuda.pxd":1342
 * ctypedef unsigned long long CUmemGenericAllocationHandle_v1
 * 
 * ctypedef CUmemGenericAllocationHandle_v1 CUmemGenericAllocationHandle             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAllocationHandleType_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemGenericAllocationHandle_v1 __pyx_t_4cuda_5ccuda_CUmemGenericAllocationHandle;

/*--- Type declarations ---*/
struct __pyx_t_4cuda_5ccuda_CUuuid_st;
struct __pyx_t_4cuda_5ccuda_CUipcEventHandle_st;
struct __pyx_t_4cuda_5ccuda_CUipcMemHandle_st;
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWaitValueParams_st;
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWriteValueParams_st;
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpFlushRemoteWritesParams_st;
union __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams_union;
struct __pyx_t_4cuda_5ccuda_CUdevprop_st;
struct __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow_st;
struct __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS_st;
struct __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS_st;
struct __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS_st;
union __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue_union;
union __pyx_t_4cuda_5ccuda_CUstreamAttrValue_union;
struct __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount_st;
union __pyx_t_4cuda_5ccuda__CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u;
struct __pyx_t_4cuda_5ccuda_CUexecAffinityParam_st;
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D_st;
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_st;
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER_st;
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR_st;
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR_st;
struct __pyx_t_4cuda_5ccuda__CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s;
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES_st;
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s;
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_mipmap_s;
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_linear_s;
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_pitch2D_s;
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_reserved_s;
union __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_u;
struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC_st;
struct __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC_st;
struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC_st;
struct __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st;
struct __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS_st;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s;
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_u;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s;
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_u;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s;
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_nvSciSync_u;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_keyedMutex_s;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_s;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s;
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_nvSciSync_u;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_keyedMutex_s;
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_s;
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st;
struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st;
struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS_st;
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u;
struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_sparseLevel_s;
struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s;
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_u;
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_memHandle_u;
struct __pyx_t_4cuda_5ccuda_CUarrayMapInfo_st;
struct __pyx_t_4cuda_5ccuda_CUmemLocation_st;
struct __pyx_t_4cuda_5ccuda__CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s;
struct __pyx_t_4cuda_5ccuda_CUmemAllocationProp_st;
struct __pyx_t_4cuda_5ccuda_CUmemAccessDesc_st;
struct __pyx_t_4cuda_5ccuda_CUmemPoolProps_st;
struct __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData_st;
struct __pyx_t_4cuda_5ccuda_CUDA_MEM_ALLOC_NODE_PARAMS_st;

/* "cuda/ccuda.pxd":135
 * ctypedef CUipcMemHandle_v1 CUipcMemHandle
 * 
 * cdef enum CUipcMem_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_IPC_MEM_LAZY_ENABLE_PEER_ACCESS = 0x1
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUipcMem_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_IPC_MEM_LAZY_ENABLE_PEER_ACCESS = 0x1
};

/* "cuda/ccuda.pxd":140
 * ctypedef CUipcMem_flags_enum CUipcMem_flags
 * 
 * cdef enum CUmemAttach_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ATTACH_GLOBAL = 0x1
 *     CU_MEM_ATTACH_HOST = 0x2
 */
enum __pyx_t_4cuda_5ccuda_CUmemAttach_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ATTACH_GLOBAL = 0x1,
  __pyx_e_4cuda_5ccuda_CU_MEM_ATTACH_HOST = 0x2,
  __pyx_e_4cuda_5ccuda_CU_MEM_ATTACH_SINGLE = 0x4
};

/* "cuda/ccuda.pxd":147
 * ctypedef CUmemAttach_flags_enum CUmemAttach_flags
 * 
 * cdef enum CUctx_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_CTX_SCHED_AUTO = 0x00
 *     CU_CTX_SCHED_SPIN = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUctx_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_CTX_SCHED_AUTO = 0x00,
  __pyx_e_4cuda_5ccuda_CU_CTX_SCHED_SPIN = 0x01,
  __pyx_e_4cuda_5ccuda_CU_CTX_SCHED_YIELD = 0x02,
  __pyx_e_4cuda_5ccuda_CU_CTX_SCHED_BLOCKING_SYNC = 0x04,
  __pyx_e_4cuda_5ccuda_CU_CTX_BLOCKING_SYNC = 0x04,
  __pyx_e_4cuda_5ccuda_CU_CTX_SCHED_MASK = 0x07,
  __pyx_e_4cuda_5ccuda_CU_CTX_MAP_HOST = 0x08,
  __pyx_e_4cuda_5ccuda_CU_CTX_LMEM_RESIZE_TO_MAX = 0x10,
  __pyx_e_4cuda_5ccuda_CU_CTX_FLAGS_MASK = 0x1f
};

/* "cuda/ccuda.pxd":160
 * ctypedef CUctx_flags_enum CUctx_flags
 * 
 * cdef enum CUstream_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_DEFAULT = 0x0
 *     CU_STREAM_NON_BLOCKING = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUstream_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_NON_BLOCKING = 0x1
};

/* "cuda/ccuda.pxd":166
 * ctypedef CUstream_flags_enum CUstream_flags
 * 
 * cdef enum CUevent_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_EVENT_DEFAULT = 0x0
 *     CU_EVENT_BLOCKING_SYNC = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUevent_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_EVENT_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_EVENT_BLOCKING_SYNC = 0x1,
  __pyx_e_4cuda_5ccuda_CU_EVENT_DISABLE_TIMING = 0x2,
  __pyx_e_4cuda_5ccuda_CU_EVENT_INTERPROCESS = 0x4
};

/* "cuda/ccuda.pxd":174
 * ctypedef CUevent_flags_enum CUevent_flags
 * 
 * cdef enum CUevent_record_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_EVENT_RECORD_DEFAULT = 0x0
 *     CU_EVENT_RECORD_EXTERNAL = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUevent_record_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_EVENT_RECORD_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_EVENT_RECORD_EXTERNAL = 0x1
};

/* "cuda/ccuda.pxd":180
 * ctypedef CUevent_record_flags_enum CUevent_record_flags
 * 
 * cdef enum CUevent_wait_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_EVENT_WAIT_DEFAULT = 0x0
 *     CU_EVENT_WAIT_EXTERNAL = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUevent_wait_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_EVENT_WAIT_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_EVENT_WAIT_EXTERNAL = 0x1
};

/* "cuda/ccuda.pxd":186
 * ctypedef CUevent_wait_flags_enum CUevent_wait_flags
 * 
 * cdef enum CUstreamWaitValue_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_WAIT_VALUE_GEQ = 0x0
 *     CU_STREAM_WAIT_VALUE_EQ = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUstreamWaitValue_flags_enum {

  /* "cuda/ccuda.pxd":191
 *     CU_STREAM_WAIT_VALUE_AND = 0x2
 *     CU_STREAM_WAIT_VALUE_NOR = 0x3
 *     CU_STREAM_WAIT_VALUE_FLUSH = 1<<30             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUstreamWaitValue_flags_enum CUstreamWaitValue_flags
 */
  __pyx_e_4cuda_5ccuda_CU_STREAM_WAIT_VALUE_GEQ = 0x0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_WAIT_VALUE_EQ = 0x1,
  __pyx_e_4cuda_5ccuda_CU_STREAM_WAIT_VALUE_AND = 0x2,
  __pyx_e_4cuda_5ccuda_CU_STREAM_WAIT_VALUE_NOR = 0x3,
  __pyx_e_4cuda_5ccuda_CU_STREAM_WAIT_VALUE_FLUSH = (1 << 30)
};

/* "cuda/ccuda.pxd":195
 * ctypedef CUstreamWaitValue_flags_enum CUstreamWaitValue_flags
 * 
 * cdef enum CUstreamWriteValue_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_WRITE_VALUE_DEFAULT = 0x0
 *     CU_STREAM_WRITE_VALUE_NO_MEMORY_BARRIER = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUstreamWriteValue_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_WRITE_VALUE_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_WRITE_VALUE_NO_MEMORY_BARRIER = 0x1
};

/* "cuda/ccuda.pxd":201
 * ctypedef CUstreamWriteValue_flags_enum CUstreamWriteValue_flags
 * 
 * cdef enum CUstreamBatchMemOpType_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_MEM_OP_WAIT_VALUE_32 = 1
 *     CU_STREAM_MEM_OP_WRITE_VALUE_32 = 2
 */
enum __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_MEM_OP_WAIT_VALUE_32 = 1,
  __pyx_e_4cuda_5ccuda_CU_STREAM_MEM_OP_WRITE_VALUE_32 = 2,
  __pyx_e_4cuda_5ccuda_CU_STREAM_MEM_OP_WAIT_VALUE_64 = 4,
  __pyx_e_4cuda_5ccuda_CU_STREAM_MEM_OP_WRITE_VALUE_64 = 5,
  __pyx_e_4cuda_5ccuda_CU_STREAM_MEM_OP_FLUSH_REMOTE_WRITES = 3
};

/* "cuda/ccuda.pxd":239
 * ctypedef CUstreamBatchMemOpParams_v1 CUstreamBatchMemOpParams
 * 
 * cdef enum CUoccupancy_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_OCCUPANCY_DEFAULT = 0x0
 *     CU_OCCUPANCY_DISABLE_CACHING_OVERRIDE = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUoccupancy_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_OCCUPANCY_DEFAULT = 0x0,
  __pyx_e_4cuda_5ccuda_CU_OCCUPANCY_DISABLE_CACHING_OVERRIDE = 0x1
};

/* "cuda/ccuda.pxd":245
 * ctypedef CUoccupancy_flags_enum CUoccupancy_flags
 * 
 * cdef enum CUstreamUpdateCaptureDependencies_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_ADD_CAPTURE_DEPENDENCIES = 0x0
 *     CU_STREAM_SET_CAPTURE_DEPENDENCIES = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUstreamUpdateCaptureDependencies_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_ADD_CAPTURE_DEPENDENCIES = 0x0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_SET_CAPTURE_DEPENDENCIES = 0x1
};

/* "cuda/ccuda.pxd":251
 * ctypedef CUstreamUpdateCaptureDependencies_flags_enum CUstreamUpdateCaptureDependencies_flags
 * 
 * cdef enum CUarray_format_enum:             # <<<<<<<<<<<<<<
 *     CU_AD_FORMAT_UNSIGNED_INT8 = 0x01
 *     CU_AD_FORMAT_UNSIGNED_INT16 = 0x02
 */
enum __pyx_t_4cuda_5ccuda_CUarray_format_enum {
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNSIGNED_INT8 = 0x01,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNSIGNED_INT16 = 0x02,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNSIGNED_INT32 = 0x03,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SIGNED_INT8 = 0x08,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SIGNED_INT16 = 0x09,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SIGNED_INT32 = 0x0a,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_HALF = 0x10,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_FLOAT = 0x20,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_NV12 = 0xb0,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT8X1 = 0xc0,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT8X2 = 0xc1,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT8X4 = 0xc2,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT16X1 = 0xc3,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT16X2 = 0xc4,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_UNORM_INT16X4 = 0xc5,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT8X1 = 0xc6,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT8X2 = 0xc7,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT8X4 = 0xc8,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT16X1 = 0xc9,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT16X2 = 0xca,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_SNORM_INT16X4 = 0xcb,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC1_UNORM = 0x91,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC1_UNORM_SRGB = 0x92,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC2_UNORM = 0x93,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC2_UNORM_SRGB = 0x94,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC3_UNORM = 0x95,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC3_UNORM_SRGB = 0x96,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC4_UNORM = 0x97,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC4_SNORM = 0x98,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC5_UNORM = 0x99,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC5_SNORM = 0x9a,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC6H_UF16 = 0x9b,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC6H_SF16 = 0x9c,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC7_UNORM = 0x9d,
  __pyx_e_4cuda_5ccuda_CU_AD_FORMAT_BC7_UNORM_SRGB = 0x9e
};

/* "cuda/ccuda.pxd":290
 * ctypedef CUarray_format_enum CUarray_format
 * 
 * cdef enum CUaddress_mode_enum:             # <<<<<<<<<<<<<<
 *     CU_TR_ADDRESS_MODE_WRAP = 0
 *     CU_TR_ADDRESS_MODE_CLAMP = 1
 */
enum __pyx_t_4cuda_5ccuda_CUaddress_mode_enum {
  __pyx_e_4cuda_5ccuda_CU_TR_ADDRESS_MODE_WRAP = 0,
  __pyx_e_4cuda_5ccuda_CU_TR_ADDRESS_MODE_CLAMP = 1,
  __pyx_e_4cuda_5ccuda_CU_TR_ADDRESS_MODE_MIRROR = 2,
  __pyx_e_4cuda_5ccuda_CU_TR_ADDRESS_MODE_BORDER = 3
};

/* "cuda/ccuda.pxd":298
 * ctypedef CUaddress_mode_enum CUaddress_mode
 * 
 * cdef enum CUfilter_mode_enum:             # <<<<<<<<<<<<<<
 *     CU_TR_FILTER_MODE_POINT = 0
 *     CU_TR_FILTER_MODE_LINEAR = 1
 */
enum __pyx_t_4cuda_5ccuda_CUfilter_mode_enum {
  __pyx_e_4cuda_5ccuda_CU_TR_FILTER_MODE_POINT = 0,
  __pyx_e_4cuda_5ccuda_CU_TR_FILTER_MODE_LINEAR = 1
};

/* "cuda/ccuda.pxd":304
 * ctypedef CUfilter_mode_enum CUfilter_mode
 * 
 * cdef enum CUdevice_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_BLOCK = 1
 *     CU_DEVICE_ATTRIBUTE_MAX_BLOCK_DIM_X = 2
 */
enum __pyx_t_4cuda_5ccuda_CUdevice_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_BLOCK = 1,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_BLOCK_DIM_X = 2,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_BLOCK_DIM_Y = 3,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_BLOCK_DIM_Z = 4,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_GRID_DIM_X = 5,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_GRID_DIM_Y = 6,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_GRID_DIM_Z = 7,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_SHARED_MEMORY_PER_BLOCK = 8,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_SHARED_MEMORY_PER_BLOCK = 8,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_TOTAL_CONSTANT_MEMORY = 9,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_WARP_SIZE = 10,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_PITCH = 11,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_REGISTERS_PER_BLOCK = 12,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_REGISTERS_PER_BLOCK = 12,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CLOCK_RATE = 13,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_TEXTURE_ALIGNMENT = 14,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GPU_OVERLAP = 15,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MULTIPROCESSOR_COUNT = 16,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_KERNEL_EXEC_TIMEOUT = 17,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_INTEGRATED = 18,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_MAP_HOST_MEMORY = 19,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COMPUTE_MODE = 20,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE1D_WIDTH = 21,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_WIDTH = 22,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_HEIGHT = 23,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_WIDTH = 24,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_HEIGHT = 25,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_DEPTH = 26,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LAYERED_WIDTH = 27,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LAYERED_HEIGHT = 28,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LAYERED_LAYERS = 29,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_ARRAY_WIDTH = 27,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_ARRAY_HEIGHT = 28,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_ARRAY_NUMSLICES = 29,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_SURFACE_ALIGNMENT = 30,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CONCURRENT_KERNELS = 31,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_ECC_ENABLED = 32,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_PCI_BUS_ID = 33,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_PCI_DEVICE_ID = 34,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_TCC_DRIVER = 35,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MEMORY_CLOCK_RATE = 36,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GLOBAL_MEMORY_BUS_WIDTH = 37,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_L2_CACHE_SIZE = 38,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_THREADS_PER_MULTIPROCESSOR = 39,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_ASYNC_ENGINE_COUNT = 40,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_UNIFIED_ADDRESSING = 41,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE1D_LAYERED_WIDTH = 42,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE1D_LAYERED_LAYERS = 43,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_TEX2D_GATHER = 44,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_GATHER_WIDTH = 45,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_GATHER_HEIGHT = 46,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_WIDTH_ALTERNATE = 47,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_HEIGHT_ALTERNATE = 48,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE3D_DEPTH_ALTERNATE = 49,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_PCI_DOMAIN_ID = 50,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_TEXTURE_PITCH_ALIGNMENT = 51,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURECUBEMAP_WIDTH = 52,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURECUBEMAP_LAYERED_WIDTH = 53,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURECUBEMAP_LAYERED_LAYERS = 54,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE1D_WIDTH = 55,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE2D_WIDTH = 56,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE2D_HEIGHT = 57,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE3D_WIDTH = 58,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE3D_HEIGHT = 59,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE3D_DEPTH = 60,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE1D_LAYERED_WIDTH = 61,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE1D_LAYERED_LAYERS = 62,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE2D_LAYERED_WIDTH = 63,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE2D_LAYERED_HEIGHT = 64,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACE2D_LAYERED_LAYERS = 65,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACECUBEMAP_WIDTH = 66,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACECUBEMAP_LAYERED_WIDTH = 67,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_SURFACECUBEMAP_LAYERED_LAYERS = 68,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE1D_LINEAR_WIDTH = 69,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LINEAR_WIDTH = 70,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LINEAR_HEIGHT = 71,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_LINEAR_PITCH = 72,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_MIPMAPPED_WIDTH = 73,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE2D_MIPMAPPED_HEIGHT = 74,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COMPUTE_CAPABILITY_MAJOR = 75,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COMPUTE_CAPABILITY_MINOR = 76,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAXIMUM_TEXTURE1D_MIPMAPPED_WIDTH = 77,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_STREAM_PRIORITIES_SUPPORTED = 78,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GLOBAL_L1_CACHE_SUPPORTED = 79,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_LOCAL_L1_CACHE_SUPPORTED = 80,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_SHARED_MEMORY_PER_MULTIPROCESSOR = 81,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_REGISTERS_PER_MULTIPROCESSOR = 82,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MANAGED_MEMORY = 83,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MULTI_GPU_BOARD = 84,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MULTI_GPU_BOARD_GROUP_ID = 85,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_HOST_NATIVE_ATOMIC_SUPPORTED = 86,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_SINGLE_TO_DOUBLE_PRECISION_PERF_RATIO = 87,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS = 88,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS = 89,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COMPUTE_PREEMPTION_SUPPORTED = 90,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_USE_HOST_POINTER_FOR_REGISTERED_MEM = 91,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_USE_STREAM_MEM_OPS = 92,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_USE_64_BIT_STREAM_MEM_OPS = 93,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_USE_STREAM_WAIT_VALUE_NOR = 94,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COOPERATIVE_LAUNCH = 95,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_COOPERATIVE_MULTI_DEVICE_LAUNCH = 96,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_SHARED_MEMORY_PER_BLOCK_OPTIN = 97,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_CAN_FLUSH_REMOTE_WRITES = 98,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_HOST_REGISTER_SUPPORTED = 99,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS_USES_HOST_PAGE_TABLES = 0x64,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_DIRECT_MANAGED_MEM_ACCESS_FROM_HOST = 0x65,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_VIRTUAL_ADDRESS_MANAGEMENT_SUPPORTED = 0x66,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_VIRTUAL_MEMORY_MANAGEMENT_SUPPORTED = 0x66,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_HANDLE_TYPE_POSIX_FILE_DESCRIPTOR_SUPPORTED = 0x67,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_HANDLE_TYPE_WIN32_HANDLE_SUPPORTED = 0x68,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_HANDLE_TYPE_WIN32_KMT_HANDLE_SUPPORTED = 0x69,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_BLOCKS_PER_MULTIPROCESSOR = 0x6A,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GENERIC_COMPRESSION_SUPPORTED = 0x6B,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_PERSISTING_L2_CACHE_SIZE = 0x6C,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX_ACCESS_POLICY_WINDOW_SIZE = 0x6D,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GPU_DIRECT_RDMA_WITH_CUDA_VMM_SUPPORTED = 0x6E,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_RESERVED_SHARED_MEMORY_PER_BLOCK = 0x6F,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_SPARSE_CUDA_ARRAY_SUPPORTED = 0x70,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_READ_ONLY_HOST_REGISTER_SUPPORTED = 0x71,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_TIMELINE_SEMAPHORE_INTEROP_SUPPORTED = 0x72,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MEMORY_POOLS_SUPPORTED = 0x73,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GPU_DIRECT_RDMA_SUPPORTED = 0x74,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GPU_DIRECT_RDMA_FLUSH_WRITES_OPTIONS = 0x75,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_GPU_DIRECT_RDMA_WRITES_ORDERING = 0x76,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MEMPOOL_SUPPORTED_HANDLE_TYPES = 0x77,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_ATTRIBUTE_MAX
};

/* "cuda/ccuda.pxd":450
 * ctypedef CUdevprop_v1 CUdevprop
 * 
 * cdef enum CUpointer_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_POINTER_ATTRIBUTE_CONTEXT = 1
 *     CU_POINTER_ATTRIBUTE_MEMORY_TYPE = 2
 */
enum __pyx_t_4cuda_5ccuda_CUpointer_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_CONTEXT = 1,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_MEMORY_TYPE = 2,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_DEVICE_POINTER = 3,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_HOST_POINTER = 4,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_P2P_TOKENS = 5,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_SYNC_MEMOPS = 6,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_BUFFER_ID = 7,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_IS_MANAGED = 8,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_DEVICE_ORDINAL = 9,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_IS_LEGACY_CUDA_IPC_CAPABLE = 10,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_RANGE_START_ADDR = 11,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_RANGE_SIZE = 12,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_MAPPED = 13,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_ALLOWED_HANDLE_TYPES = 14,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_IS_GPU_DIRECT_RDMA_CAPABLE = 15,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_ACCESS_FLAGS = 16,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_MEMPOOL_HANDLE = 17
};

/* "cuda/ccuda.pxd":471
 * ctypedef CUpointer_attribute_enum CUpointer_attribute
 * 
 * cdef enum CUfunction_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_FUNC_ATTRIBUTE_MAX_THREADS_PER_BLOCK = 0
 *     CU_FUNC_ATTRIBUTE_SHARED_SIZE_BYTES = 1
 */
enum __pyx_t_4cuda_5ccuda_CUfunction_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_MAX_THREADS_PER_BLOCK = 0,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_SHARED_SIZE_BYTES = 1,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_CONST_SIZE_BYTES = 2,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_LOCAL_SIZE_BYTES = 3,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_NUM_REGS = 4,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_PTX_VERSION = 5,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_BINARY_VERSION = 6,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_CACHE_MODE_CA = 7,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_MAX_DYNAMIC_SHARED_SIZE_BYTES = 8,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_PREFERRED_SHARED_MEMORY_CARVEOUT = 9,
  __pyx_e_4cuda_5ccuda_CU_FUNC_ATTRIBUTE_MAX
};

/* "cuda/ccuda.pxd":486
 * ctypedef CUfunction_attribute_enum CUfunction_attribute
 * 
 * cdef enum CUfunc_cache_enum:             # <<<<<<<<<<<<<<
 *     CU_FUNC_CACHE_PREFER_NONE = 0x00
 *     CU_FUNC_CACHE_PREFER_SHARED = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUfunc_cache_enum {
  __pyx_e_4cuda_5ccuda_CU_FUNC_CACHE_PREFER_NONE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_FUNC_CACHE_PREFER_SHARED = 0x01,
  __pyx_e_4cuda_5ccuda_CU_FUNC_CACHE_PREFER_L1 = 0x02,
  __pyx_e_4cuda_5ccuda_CU_FUNC_CACHE_PREFER_EQUAL = 0x03
};

/* "cuda/ccuda.pxd":494
 * ctypedef CUfunc_cache_enum CUfunc_cache
 * 
 * cdef enum CUsharedconfig_enum:             # <<<<<<<<<<<<<<
 *     CU_SHARED_MEM_CONFIG_DEFAULT_BANK_SIZE = 0x00
 *     CU_SHARED_MEM_CONFIG_FOUR_BYTE_BANK_SIZE = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUsharedconfig_enum {
  __pyx_e_4cuda_5ccuda_CU_SHARED_MEM_CONFIG_DEFAULT_BANK_SIZE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_SHARED_MEM_CONFIG_FOUR_BYTE_BANK_SIZE = 0x01,
  __pyx_e_4cuda_5ccuda_CU_SHARED_MEM_CONFIG_EIGHT_BYTE_BANK_SIZE = 0x02
};

/* "cuda/ccuda.pxd":501
 * ctypedef CUsharedconfig_enum CUsharedconfig
 * 
 * cdef enum CUshared_carveout_enum:             # <<<<<<<<<<<<<<
 *     CU_SHAREDMEM_CARVEOUT_DEFAULT = -1
 *     CU_SHAREDMEM_CARVEOUT_MAX_SHARED = 100
 */
enum __pyx_t_4cuda_5ccuda_CUshared_carveout_enum {
  __pyx_e_4cuda_5ccuda_CU_SHAREDMEM_CARVEOUT_DEFAULT = -1L,
  __pyx_e_4cuda_5ccuda_CU_SHAREDMEM_CARVEOUT_MAX_SHARED = 0x64,
  __pyx_e_4cuda_5ccuda_CU_SHAREDMEM_CARVEOUT_MAX_L1 = 0
};

/* "cuda/ccuda.pxd":508
 * ctypedef CUshared_carveout_enum CUshared_carveout
 * 
 * cdef enum CUmemorytype_enum:             # <<<<<<<<<<<<<<
 *     CU_MEMORYTYPE_HOST = 0x01
 *     CU_MEMORYTYPE_DEVICE = 0x02
 */
enum __pyx_t_4cuda_5ccuda_CUmemorytype_enum {
  __pyx_e_4cuda_5ccuda_CU_MEMORYTYPE_HOST = 0x01,
  __pyx_e_4cuda_5ccuda_CU_MEMORYTYPE_DEVICE = 0x02,
  __pyx_e_4cuda_5ccuda_CU_MEMORYTYPE_ARRAY = 0x03,
  __pyx_e_4cuda_5ccuda_CU_MEMORYTYPE_UNIFIED = 0x04
};

/* "cuda/ccuda.pxd":516
 * ctypedef CUmemorytype_enum CUmemorytype
 * 
 * cdef enum CUcomputemode_enum:             # <<<<<<<<<<<<<<
 *     CU_COMPUTEMODE_DEFAULT = 0
 *     CU_COMPUTEMODE_PROHIBITED = 2
 */
enum __pyx_t_4cuda_5ccuda_CUcomputemode_enum {
  __pyx_e_4cuda_5ccuda_CU_COMPUTEMODE_DEFAULT = 0,
  __pyx_e_4cuda_5ccuda_CU_COMPUTEMODE_PROHIBITED = 2,
  __pyx_e_4cuda_5ccuda_CU_COMPUTEMODE_EXCLUSIVE_PROCESS = 3
};

/* "cuda/ccuda.pxd":523
 * ctypedef CUcomputemode_enum CUcomputemode
 * 
 * cdef enum CUmem_advise_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ADVISE_SET_READ_MOSTLY = 1
 *     CU_MEM_ADVISE_UNSET_READ_MOSTLY = 2
 */
enum __pyx_t_4cuda_5ccuda_CUmem_advise_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_SET_READ_MOSTLY = 1,
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_UNSET_READ_MOSTLY = 2,
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_SET_PREFERRED_LOCATION = 3,
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_UNSET_PREFERRED_LOCATION = 4,
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_SET_ACCESSED_BY = 5,
  __pyx_e_4cuda_5ccuda_CU_MEM_ADVISE_UNSET_ACCESSED_BY = 6
};

/* "cuda/ccuda.pxd":533
 * ctypedef CUmem_advise_enum CUmem_advise
 * 
 * cdef enum CUmem_range_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_RANGE_ATTRIBUTE_READ_MOSTLY = 1
 *     CU_MEM_RANGE_ATTRIBUTE_PREFERRED_LOCATION = 2
 */
enum __pyx_t_4cuda_5ccuda_CUmem_range_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_RANGE_ATTRIBUTE_READ_MOSTLY = 1,
  __pyx_e_4cuda_5ccuda_CU_MEM_RANGE_ATTRIBUTE_PREFERRED_LOCATION = 2,
  __pyx_e_4cuda_5ccuda_CU_MEM_RANGE_ATTRIBUTE_ACCESSED_BY = 3,
  __pyx_e_4cuda_5ccuda_CU_MEM_RANGE_ATTRIBUTE_LAST_PREFETCH_LOCATION = 4
};

/* "cuda/ccuda.pxd":541
 * ctypedef CUmem_range_attribute_enum CUmem_range_attribute
 * 
 * cdef enum CUjit_option_enum:             # <<<<<<<<<<<<<<
 *     CU_JIT_MAX_REGISTERS = 0
 *     CU_JIT_THREADS_PER_BLOCK
 */
enum __pyx_t_4cuda_5ccuda_CUjit_option_enum {
  __pyx_e_4cuda_5ccuda_CU_JIT_MAX_REGISTERS = 0,
  __pyx_e_4cuda_5ccuda_CU_JIT_THREADS_PER_BLOCK,
  __pyx_e_4cuda_5ccuda_CU_JIT_WALL_TIME,
  __pyx_e_4cuda_5ccuda_CU_JIT_INFO_LOG_BUFFER,
  __pyx_e_4cuda_5ccuda_CU_JIT_INFO_LOG_BUFFER_SIZE_BYTES,
  __pyx_e_4cuda_5ccuda_CU_JIT_ERROR_LOG_BUFFER,
  __pyx_e_4cuda_5ccuda_CU_JIT_ERROR_LOG_BUFFER_SIZE_BYTES,
  __pyx_e_4cuda_5ccuda_CU_JIT_OPTIMIZATION_LEVEL,
  __pyx_e_4cuda_5ccuda_CU_JIT_TARGET_FROM_CUCONTEXT,
  __pyx_e_4cuda_5ccuda_CU_JIT_TARGET,
  __pyx_e_4cuda_5ccuda_CU_JIT_FALLBACK_STRATEGY,
  __pyx_e_4cuda_5ccuda_CU_JIT_GENERATE_DEBUG_INFO,
  __pyx_e_4cuda_5ccuda_CU_JIT_LOG_VERBOSE,
  __pyx_e_4cuda_5ccuda_CU_JIT_GENERATE_LINE_INFO,
  __pyx_e_4cuda_5ccuda_CU_JIT_CACHE_MODE,
  __pyx_e_4cuda_5ccuda_CU_JIT_NEW_SM3X_OPT,
  __pyx_e_4cuda_5ccuda_CU_JIT_FAST_COMPILE,
  __pyx_e_4cuda_5ccuda_CU_JIT_GLOBAL_SYMBOL_NAMES,
  __pyx_e_4cuda_5ccuda_CU_JIT_GLOBAL_SYMBOL_ADDRESSES,
  __pyx_e_4cuda_5ccuda_CU_JIT_GLOBAL_SYMBOL_COUNT,
  __pyx_e_4cuda_5ccuda_CU_JIT_LTO,
  __pyx_e_4cuda_5ccuda_CU_JIT_FTZ,
  __pyx_e_4cuda_5ccuda_CU_JIT_PREC_DIV,
  __pyx_e_4cuda_5ccuda_CU_JIT_PREC_SQRT,
  __pyx_e_4cuda_5ccuda_CU_JIT_FMA,
  __pyx_e_4cuda_5ccuda_CU_JIT_NUM_OPTIONS
};

/* "cuda/ccuda.pxd":571
 * ctypedef CUjit_option_enum CUjit_option
 * 
 * cdef enum CUjit_target_enum:             # <<<<<<<<<<<<<<
 *     CU_TARGET_COMPUTE_20 = 20
 *     CU_TARGET_COMPUTE_21 = 21
 */
enum __pyx_t_4cuda_5ccuda_CUjit_target_enum {
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_20 = 20,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_21 = 21,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_30 = 30,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_32 = 32,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_35 = 35,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_37 = 37,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_50 = 50,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_52 = 52,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_53 = 53,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_60 = 60,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_61 = 61,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_62 = 62,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_70 = 70,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_72 = 72,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_75 = 75,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_80 = 80,
  __pyx_e_4cuda_5ccuda_CU_TARGET_COMPUTE_86 = 86
};

/* "cuda/ccuda.pxd":592
 * ctypedef CUjit_target_enum CUjit_target
 * 
 * cdef enum CUjit_fallback_enum:             # <<<<<<<<<<<<<<
 *     CU_PREFER_PTX = 0
 *     CU_PREFER_BINARY
 */
enum __pyx_t_4cuda_5ccuda_CUjit_fallback_enum {
  __pyx_e_4cuda_5ccuda_CU_PREFER_PTX = 0,
  __pyx_e_4cuda_5ccuda_CU_PREFER_BINARY
};

/* "cuda/ccuda.pxd":598
 * ctypedef CUjit_fallback_enum CUjit_fallback
 * 
 * cdef enum CUjit_cacheMode_enum:             # <<<<<<<<<<<<<<
 *     CU_JIT_CACHE_OPTION_NONE = 0
 *     CU_JIT_CACHE_OPTION_CG
 */
enum __pyx_t_4cuda_5ccuda_CUjit_cacheMode_enum {
  __pyx_e_4cuda_5ccuda_CU_JIT_CACHE_OPTION_NONE = 0,
  __pyx_e_4cuda_5ccuda_CU_JIT_CACHE_OPTION_CG,
  __pyx_e_4cuda_5ccuda_CU_JIT_CACHE_OPTION_CA
};

/* "cuda/ccuda.pxd":605
 * ctypedef CUjit_cacheMode_enum CUjit_cacheMode
 * 
 * cdef enum CUjitInputType_enum:             # <<<<<<<<<<<<<<
 *     CU_JIT_INPUT_CUBIN = 0
 *     CU_JIT_INPUT_PTX
 */
enum __pyx_t_4cuda_5ccuda_CUjitInputType_enum {
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_CUBIN = 0,
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_PTX,
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_FATBINARY,
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_OBJECT,
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_LIBRARY,
  __pyx_e_4cuda_5ccuda_CU_JIT_INPUT_NVVM,
  __pyx_e_4cuda_5ccuda_CU_JIT_NUM_INPUT_TYPES
};

/* "cuda/ccuda.pxd":621
 * ctypedef CUlinkState_st* CUlinkState
 * 
 * cdef enum CUgraphicsRegisterFlags_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPHICS_REGISTER_FLAGS_NONE = 0x00
 *     CU_GRAPHICS_REGISTER_FLAGS_READ_ONLY = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUgraphicsRegisterFlags_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_REGISTER_FLAGS_NONE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_REGISTER_FLAGS_READ_ONLY = 0x01,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_REGISTER_FLAGS_WRITE_DISCARD = 0x02,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_REGISTER_FLAGS_SURFACE_LDST = 0x04,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_REGISTER_FLAGS_TEXTURE_GATHER = 0x08
};

/* "cuda/ccuda.pxd":630
 * ctypedef CUgraphicsRegisterFlags_enum CUgraphicsRegisterFlags
 * 
 * cdef enum CUgraphicsMapResourceFlags_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPHICS_MAP_RESOURCE_FLAGS_NONE = 0x00
 *     CU_GRAPHICS_MAP_RESOURCE_FLAGS_READ_ONLY = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUgraphicsMapResourceFlags_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_MAP_RESOURCE_FLAGS_NONE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_MAP_RESOURCE_FLAGS_READ_ONLY = 0x01,
  __pyx_e_4cuda_5ccuda_CU_GRAPHICS_MAP_RESOURCE_FLAGS_WRITE_DISCARD = 0x02
};

/* "cuda/ccuda.pxd":637
 * ctypedef CUgraphicsMapResourceFlags_enum CUgraphicsMapResourceFlags
 * 
 * cdef enum CUarray_cubemap_face_enum:             # <<<<<<<<<<<<<<
 *     CU_CUBEMAP_FACE_POSITIVE_X = 0x00
 *     CU_CUBEMAP_FACE_NEGATIVE_X = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUarray_cubemap_face_enum {
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_POSITIVE_X = 0x00,
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_NEGATIVE_X = 0x01,
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_POSITIVE_Y = 0x02,
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_NEGATIVE_Y = 0x03,
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_POSITIVE_Z = 0x04,
  __pyx_e_4cuda_5ccuda_CU_CUBEMAP_FACE_NEGATIVE_Z = 0x05
};

/* "cuda/ccuda.pxd":647
 * ctypedef CUarray_cubemap_face_enum CUarray_cubemap_face
 * 
 * cdef enum CUlimit_enum:             # <<<<<<<<<<<<<<
 *     CU_LIMIT_STACK_SIZE = 0x00
 *     CU_LIMIT_PRINTF_FIFO_SIZE = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUlimit_enum {
  __pyx_e_4cuda_5ccuda_CU_LIMIT_STACK_SIZE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_PRINTF_FIFO_SIZE = 0x01,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_MALLOC_HEAP_SIZE = 0x02,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_DEV_RUNTIME_SYNC_DEPTH = 0x03,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_DEV_RUNTIME_PENDING_LAUNCH_COUNT = 0x04,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_MAX_L2_FETCH_GRANULARITY = 0x05,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_PERSISTING_L2_CACHE_SIZE = 0x06,
  __pyx_e_4cuda_5ccuda_CU_LIMIT_MAX
};

/* "cuda/ccuda.pxd":659
 * ctypedef CUlimit_enum CUlimit
 * 
 * cdef enum CUresourcetype_enum:             # <<<<<<<<<<<<<<
 *     CU_RESOURCE_TYPE_ARRAY = 0x00
 *     CU_RESOURCE_TYPE_MIPMAPPED_ARRAY = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUresourcetype_enum {
  __pyx_e_4cuda_5ccuda_CU_RESOURCE_TYPE_ARRAY = 0x00,
  __pyx_e_4cuda_5ccuda_CU_RESOURCE_TYPE_MIPMAPPED_ARRAY = 0x01,
  __pyx_e_4cuda_5ccuda_CU_RESOURCE_TYPE_LINEAR = 0x02,
  __pyx_e_4cuda_5ccuda_CU_RESOURCE_TYPE_PITCH2D = 0x03
};

/* "cuda/ccuda.pxd":669
 * ctypedef void (*CUhostFn)(void* userData)
 * 
 * cdef enum CUaccessProperty_enum:             # <<<<<<<<<<<<<<
 *     CU_ACCESS_PROPERTY_NORMAL = 0
 *     CU_ACCESS_PROPERTY_STREAMING = 1
 */
enum __pyx_t_4cuda_5ccuda_CUaccessProperty_enum {
  __pyx_e_4cuda_5ccuda_CU_ACCESS_PROPERTY_NORMAL = 0,
  __pyx_e_4cuda_5ccuda_CU_ACCESS_PROPERTY_STREAMING = 1,
  __pyx_e_4cuda_5ccuda_CU_ACCESS_PROPERTY_PERSISTING = 2
};

/* "cuda/ccuda.pxd":723
 * ctypedef CUDA_HOST_NODE_PARAMS_v1 CUDA_HOST_NODE_PARAMS
 * 
 * cdef enum CUgraphNodeType_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPH_NODE_TYPE_KERNEL = 0
 *     CU_GRAPH_NODE_TYPE_MEMCPY = 1
 */
enum __pyx_t_4cuda_5ccuda_CUgraphNodeType_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_KERNEL = 0,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_MEMCPY = 1,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_MEMSET = 2,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_HOST = 3,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_GRAPH = 4,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_EMPTY = 5,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_WAIT_EVENT = 6,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_EVENT_RECORD = 7,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_EXT_SEMAS_SIGNAL = 8,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_EXT_SEMAS_WAIT = 9,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_MEM_ALLOC = 10,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_NODE_TYPE_MEM_FREE = 11
};

/* "cuda/ccuda.pxd":739
 * ctypedef CUgraphNodeType_enum CUgraphNodeType
 * 
 * cdef enum CUsynchronizationPolicy_enum:             # <<<<<<<<<<<<<<
 *     CU_SYNC_POLICY_AUTO = 1
 *     CU_SYNC_POLICY_SPIN = 2
 */
enum __pyx_t_4cuda_5ccuda_CUsynchronizationPolicy_enum {
  __pyx_e_4cuda_5ccuda_CU_SYNC_POLICY_AUTO = 1,
  __pyx_e_4cuda_5ccuda_CU_SYNC_POLICY_SPIN = 2,
  __pyx_e_4cuda_5ccuda_CU_SYNC_POLICY_YIELD = 3,
  __pyx_e_4cuda_5ccuda_CU_SYNC_POLICY_BLOCKING_SYNC = 4
};

/* "cuda/ccuda.pxd":747
 * ctypedef CUsynchronizationPolicy_enum CUsynchronizationPolicy
 * 
 * cdef enum CUkernelNodeAttrID_enum:             # <<<<<<<<<<<<<<
 *     CU_KERNEL_NODE_ATTRIBUTE_ACCESS_POLICY_WINDOW = 1
 *     CU_KERNEL_NODE_ATTRIBUTE_COOPERATIVE = 2
 */
enum __pyx_t_4cuda_5ccuda_CUkernelNodeAttrID_enum {
  __pyx_e_4cuda_5ccuda_CU_KERNEL_NODE_ATTRIBUTE_ACCESS_POLICY_WINDOW = 1,
  __pyx_e_4cuda_5ccuda_CU_KERNEL_NODE_ATTRIBUTE_COOPERATIVE = 2
};

/* "cuda/ccuda.pxd":761
 * ctypedef CUkernelNodeAttrValue_v1 CUkernelNodeAttrValue
 * 
 * cdef enum CUstreamCaptureStatus_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_CAPTURE_STATUS_NONE = 0
 *     CU_STREAM_CAPTURE_STATUS_ACTIVE = 1
 */
enum __pyx_t_4cuda_5ccuda_CUstreamCaptureStatus_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_STATUS_NONE = 0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_STATUS_ACTIVE = 1,
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_STATUS_INVALIDATED = 2
};

/* "cuda/ccuda.pxd":768
 * ctypedef CUstreamCaptureStatus_enum CUstreamCaptureStatus
 * 
 * cdef enum CUstreamCaptureMode_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_CAPTURE_MODE_GLOBAL = 0
 *     CU_STREAM_CAPTURE_MODE_THREAD_LOCAL = 1
 */
enum __pyx_t_4cuda_5ccuda_CUstreamCaptureMode_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_MODE_GLOBAL = 0,
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_MODE_THREAD_LOCAL = 1,
  __pyx_e_4cuda_5ccuda_CU_STREAM_CAPTURE_MODE_RELAXED = 2
};

/* "cuda/ccuda.pxd":775
 * ctypedef CUstreamCaptureMode_enum CUstreamCaptureMode
 * 
 * cdef enum CUstreamAttrID_enum:             # <<<<<<<<<<<<<<
 *     CU_STREAM_ATTRIBUTE_ACCESS_POLICY_WINDOW = 1
 *     CU_STREAM_ATTRIBUTE_SYNCHRONIZATION_POLICY = 3
 */
enum __pyx_t_4cuda_5ccuda_CUstreamAttrID_enum {
  __pyx_e_4cuda_5ccuda_CU_STREAM_ATTRIBUTE_ACCESS_POLICY_WINDOW = 1,
  __pyx_e_4cuda_5ccuda_CU_STREAM_ATTRIBUTE_SYNCHRONIZATION_POLICY = 3
};

/* "cuda/ccuda.pxd":789
 * ctypedef CUstreamAttrValue_v1 CUstreamAttrValue
 * 
 * cdef enum CUdriverProcAddress_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_GET_PROC_ADDRESS_DEFAULT = 0
 *     CU_GET_PROC_ADDRESS_LEGACY_STREAM = 1 << 0
 */
enum __pyx_t_4cuda_5ccuda_CUdriverProcAddress_flags_enum {

  /* "cuda/ccuda.pxd":792
 *     CU_GET_PROC_ADDRESS_DEFAULT = 0
 *     CU_GET_PROC_ADDRESS_LEGACY_STREAM = 1 << 0
 *     CU_GET_PROC_ADDRESS_PER_THREAD_DEFAULT_STREAM = 1 << 1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUdriverProcAddress_flags_enum CUdriverProcAddress_flags
 */
  __pyx_e_4cuda_5ccuda_CU_GET_PROC_ADDRESS_DEFAULT = 0,
  __pyx_e_4cuda_5ccuda_CU_GET_PROC_ADDRESS_LEGACY_STREAM = (1 << 0),
  __pyx_e_4cuda_5ccuda_CU_GET_PROC_ADDRESS_PER_THREAD_DEFAULT_STREAM = (1 << 1)
};

/* "cuda/ccuda.pxd":796
 * ctypedef CUdriverProcAddress_flags_enum CUdriverProcAddress_flags
 * 
 * cdef enum CUexecAffinityType_enum:             # <<<<<<<<<<<<<<
 *     CU_EXEC_AFFINITY_TYPE_SM_COUNT = 0
 *     CU_EXEC_AFFINITY_TYPE_MAX
 */
enum __pyx_t_4cuda_5ccuda_CUexecAffinityType_enum {
  __pyx_e_4cuda_5ccuda_CU_EXEC_AFFINITY_TYPE_SM_COUNT = 0,
  __pyx_e_4cuda_5ccuda_CU_EXEC_AFFINITY_TYPE_MAX
};

/* "cuda/ccuda.pxd":820
 * ctypedef CUexecAffinityParam_v1 CUexecAffinityParam
 * 
 * cdef enum cudaError_enum:             # <<<<<<<<<<<<<<
 *     CUDA_SUCCESS = 0
 *     CUDA_ERROR_INVALID_VALUE = 1
 */
enum __pyx_t_4cuda_5ccuda_cudaError_enum {
  __pyx_e_4cuda_5ccuda_CUDA_SUCCESS = 0,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_VALUE = 1,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_OUT_OF_MEMORY = 2,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_INITIALIZED = 3,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_DEINITIALIZED = 4,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PROFILER_DISABLED = 5,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PROFILER_NOT_INITIALIZED = 6,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PROFILER_ALREADY_STARTED = 7,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PROFILER_ALREADY_STOPPED = 8,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STUB_LIBRARY = 34,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NO_DEVICE = 0x64,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_DEVICE = 0x65,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_DEVICE_NOT_LICENSED = 0x66,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_IMAGE = 0xC8,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_CONTEXT = 0xC9,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_CONTEXT_ALREADY_CURRENT = 0xCA,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MAP_FAILED = 0xCD,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_UNMAP_FAILED = 0xCE,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ARRAY_IS_MAPPED = 0xCF,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ALREADY_MAPPED = 0xD0,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NO_BINARY_FOR_GPU = 0xD1,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ALREADY_ACQUIRED = 0xD2,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_MAPPED = 0xD3,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_MAPPED_AS_ARRAY = 0xD4,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_MAPPED_AS_POINTER = 0xD5,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ECC_UNCORRECTABLE = 0xD6,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_UNSUPPORTED_LIMIT = 0xD7,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_CONTEXT_ALREADY_IN_USE = 0xD8,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PEER_ACCESS_UNSUPPORTED = 0xD9,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_PTX = 0xDA,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_GRAPHICS_CONTEXT = 0xDB,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NVLINK_UNCORRECTABLE = 0xDC,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_JIT_COMPILER_NOT_FOUND = 0xDD,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_UNSUPPORTED_PTX_VERSION = 0xDE,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_JIT_COMPILATION_DISABLED = 0xDF,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_UNSUPPORTED_EXEC_AFFINITY = 0xE0,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_SOURCE = 0x12C,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_FILE_NOT_FOUND = 0x12D,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_SHARED_OBJECT_SYMBOL_NOT_FOUND = 0x12E,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_SHARED_OBJECT_INIT_FAILED = 0x12F,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_OPERATING_SYSTEM = 0x130,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_HANDLE = 0x190,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ILLEGAL_STATE = 0x191,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND = 0x1F4,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_READY = 0x258,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ILLEGAL_ADDRESS = 0x2BC,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_LAUNCH_OUT_OF_RESOURCES = 0x2BD,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_LAUNCH_TIMEOUT = 0x2BE,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_LAUNCH_INCOMPATIBLE_TEXTURING = 0x2BF,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PEER_ACCESS_ALREADY_ENABLED = 0x2C0,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PEER_ACCESS_NOT_ENABLED = 0x2C1,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_PRIMARY_CONTEXT_ACTIVE = 0x2C4,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_CONTEXT_IS_DESTROYED = 0x2C5,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ASSERT = 0x2C6,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_TOO_MANY_PEERS = 0x2C7,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_HOST_MEMORY_ALREADY_REGISTERED = 0x2C8,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_HOST_MEMORY_NOT_REGISTERED = 0x2C9,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_HARDWARE_STACK_ERROR = 0x2CA,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_ILLEGAL_INSTRUCTION = 0x2CB,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MISALIGNED_ADDRESS = 0x2CC,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_ADDRESS_SPACE = 0x2CD,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_INVALID_PC = 0x2CE,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_LAUNCH_FAILED = 0x2CF,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_COOPERATIVE_LAUNCH_TOO_LARGE = 0x2D0,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_PERMITTED = 0x320,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_SUPPORTED = 0x321,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_SYSTEM_NOT_READY = 0x322,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_SYSTEM_DRIVER_MISMATCH = 0x323,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_COMPAT_NOT_SUPPORTED_ON_DEVICE = 0x324,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MPS_CONNECTION_FAILED = 0x325,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MPS_RPC_FAILURE = 0x326,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MPS_SERVER_NOT_READY = 0x327,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MPS_MAX_CLIENTS_REACHED = 0x328,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_MPS_MAX_CONNECTIONS_REACHED = 0x329,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_UNSUPPORTED = 0x384,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_INVALIDATED = 0x385,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_MERGE = 0x386,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_UNMATCHED = 0x387,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_UNJOINED = 0x388,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_ISOLATION = 0x389,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_IMPLICIT = 0x38A,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_CAPTURED_EVENT = 0x38B,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_STREAM_CAPTURE_WRONG_THREAD = 0x38C,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_TIMEOUT = 0x38D,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_GRAPH_EXEC_UPDATE_FAILURE = 0x38E,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_EXTERNAL_DEVICE = 0x38F,
  __pyx_e_4cuda_5ccuda_CUDA_ERROR_UNKNOWN = 0x3E7
};

/* "cuda/ccuda.pxd":911
 * ctypedef cudaError_enum CUresult
 * 
 * cdef enum CUdevice_P2PAttribute_enum:             # <<<<<<<<<<<<<<
 *     CU_DEVICE_P2P_ATTRIBUTE_PERFORMANCE_RANK = 0x01
 *     CU_DEVICE_P2P_ATTRIBUTE_ACCESS_SUPPORTED = 0x02
 */
enum __pyx_t_4cuda_5ccuda_CUdevice_P2PAttribute_enum {
  __pyx_e_4cuda_5ccuda_CU_DEVICE_P2P_ATTRIBUTE_PERFORMANCE_RANK = 0x01,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_P2P_ATTRIBUTE_ACCESS_SUPPORTED = 0x02,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_P2P_ATTRIBUTE_NATIVE_ATOMIC_SUPPORTED = 0x03,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_P2P_ATTRIBUTE_ACCESS_ACCESS_SUPPORTED = 0x04,
  __pyx_e_4cuda_5ccuda_CU_DEVICE_P2P_ATTRIBUTE_CUDA_ARRAY_ACCESS_SUPPORTED = 0x04
};

/* "cuda/ccuda.pxd":1101
 * ctypedef CUDA_TEXTURE_DESC_v1 CUDA_TEXTURE_DESC
 * 
 * cdef enum CUresourceViewFormat_enum:             # <<<<<<<<<<<<<<
 *     CU_RES_VIEW_FORMAT_NONE = 0x00
 *     CU_RES_VIEW_FORMAT_UINT_1X8 = 0x01
 */
enum __pyx_t_4cuda_5ccuda_CUresourceViewFormat_enum {
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_NONE = 0x00,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_1X8 = 0x01,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_2X8 = 0x02,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_4X8 = 0x03,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_1X8 = 0x04,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_2X8 = 0x05,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_4X8 = 0x06,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_1X16 = 0x07,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_2X16 = 0x08,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_4X16 = 0x09,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_1X16 = 0x0a,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_2X16 = 0x0b,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_4X16 = 0x0c,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_1X32 = 0x0d,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_2X32 = 0x0e,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UINT_4X32 = 0x0f,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_1X32 = 0x10,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_2X32 = 0x11,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SINT_4X32 = 0x12,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_1X16 = 0x13,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_2X16 = 0x14,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_4X16 = 0x15,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_1X32 = 0x16,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_2X32 = 0x17,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_FLOAT_4X32 = 0x18,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC1 = 0x19,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC2 = 0x1a,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC3 = 0x1b,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC4 = 0x1c,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SIGNED_BC4 = 0x1d,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC5 = 0x1e,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SIGNED_BC5 = 0x1f,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC6H = 0x20,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_SIGNED_BC6H = 0x21,
  __pyx_e_4cuda_5ccuda_CU_RES_VIEW_FORMAT_UNSIGNED_BC7 = 0x22
};

/* "cuda/ccuda.pxd":1163
 * ctypedef CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1 CUDA_POINTER_ATTRIBUTE_P2P_TOKENS
 * 
 * cdef enum CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum:             # <<<<<<<<<<<<<<
 *     CU_POINTER_ATTRIBUTE_ACCESS_FLAG_NONE = 0x0
 *     CU_POINTER_ATTRIBUTE_ACCESS_FLAG_READ = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum {
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_ACCESS_FLAG_NONE = 0x0,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_ACCESS_FLAG_READ = 0x1,
  __pyx_e_4cuda_5ccuda_CU_POINTER_ATTRIBUTE_ACCESS_FLAG_READWRITE = 0x3
};

/* "cuda/ccuda.pxd":1186
 * ctypedef CUDA_LAUNCH_PARAMS_v1 CUDA_LAUNCH_PARAMS
 * 
 * cdef enum CUexternalMemoryHandleType_enum:             # <<<<<<<<<<<<<<
 *     CU_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD = 1
 *     CU_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32 = 2
 */
enum __pyx_t_4cuda_5ccuda_CUexternalMemoryHandleType_enum {
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD = 1,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32 = 2,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_KMT = 3,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_D3D12_HEAP = 4,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_D3D12_RESOURCE = 5,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_D3D11_RESOURCE = 6,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_D3D11_RESOURCE_KMT = 7,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_MEMORY_HANDLE_TYPE_NVSCIBUF = 8
};

/* "cuda/ccuda.pxd":1238
 * ctypedef CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1 CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC
 * 
 * cdef enum CUexternalSemaphoreHandleType_enum:             # <<<<<<<<<<<<<<
 *     CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_FD = 1
 *     CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_WIN32 = 2
 */
enum __pyx_t_4cuda_5ccuda_CUexternalSemaphoreHandleType_enum {
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_FD = 1,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_WIN32 = 2,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_WIN32_KMT = 3,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_D3D12_FENCE = 4,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_D3D11_FENCE = 5,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_NVSCISYNC = 6,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_D3D11_KEYED_MUTEX = 7,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_D3D11_KEYED_MUTEX_KMT = 8,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_TIMELINE_SEMAPHORE_FD = 9,
  __pyx_e_4cuda_5ccuda_CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_TIMELINE_SEMAPHORE_WIN32 = 10
};

/* "cuda/ccuda.pxd":1344
 * ctypedef CUmemGenericAllocationHandle_v1 CUmemGenericAllocationHandle
 * 
 * cdef enum CUmemAllocationHandleType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_HANDLE_TYPE_NONE = 0x0
 *     CU_MEM_HANDLE_TYPE_POSIX_FILE_DESCRIPTOR = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemAllocationHandleType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_NONE = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_POSIX_FILE_DESCRIPTOR = 0x1,
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_WIN32 = 0x2,
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_WIN32_KMT = 0x4,
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_MAX = 0x7FFFFFFF
};

/* "cuda/ccuda.pxd":1353
 * ctypedef CUmemAllocationHandleType_enum CUmemAllocationHandleType
 * 
 * cdef enum CUmemAccess_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ACCESS_FLAGS_PROT_NONE = 0x0
 *     CU_MEM_ACCESS_FLAGS_PROT_READ = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemAccess_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ACCESS_FLAGS_PROT_NONE = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_ACCESS_FLAGS_PROT_READ = 0x1,
  __pyx_e_4cuda_5ccuda_CU_MEM_ACCESS_FLAGS_PROT_READWRITE = 0x3,
  __pyx_e_4cuda_5ccuda_CU_MEM_ACCESS_FLAGS_PROT_MAX = 0x7FFFFFFF
};

/* "cuda/ccuda.pxd":1361
 * ctypedef CUmemAccess_flags_enum CUmemAccess_flags
 * 
 * cdef enum CUmemLocationType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_LOCATION_TYPE_INVALID = 0x0
 *     CU_MEM_LOCATION_TYPE_DEVICE = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemLocationType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_LOCATION_TYPE_INVALID = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_LOCATION_TYPE_DEVICE = 0x1,
  __pyx_e_4cuda_5ccuda_CU_MEM_LOCATION_TYPE_MAX = 0x7FFFFFFF
};

/* "cuda/ccuda.pxd":1368
 * ctypedef CUmemLocationType_enum CUmemLocationType
 * 
 * cdef enum CUmemAllocationType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ALLOCATION_TYPE_INVALID = 0x0
 *     CU_MEM_ALLOCATION_TYPE_PINNED = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemAllocationType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOCATION_TYPE_INVALID = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOCATION_TYPE_PINNED = 0x1,
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOCATION_TYPE_MAX = 0x7FFFFFFF
};

/* "cuda/ccuda.pxd":1375
 * ctypedef CUmemAllocationType_enum CUmemAllocationType
 * 
 * cdef enum CUmemAllocationGranularity_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ALLOC_GRANULARITY_MINIMUM = 0x0
 *     CU_MEM_ALLOC_GRANULARITY_RECOMMENDED = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemAllocationGranularity_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOC_GRANULARITY_MINIMUM = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOC_GRANULARITY_RECOMMENDED = 0x1
};

/* "cuda/ccuda.pxd":1381
 * ctypedef CUmemAllocationGranularity_flags_enum CUmemAllocationGranularity_flags
 * 
 * cdef enum CUarraySparseSubresourceType_enum:             # <<<<<<<<<<<<<<
 *     CU_ARRAY_SPARSE_SUBRESOURCE_TYPE_SPARSE_LEVEL = 0
 *     CU_ARRAY_SPARSE_SUBRESOURCE_TYPE_MIPTAIL = 1
 */
enum __pyx_t_4cuda_5ccuda_CUarraySparseSubresourceType_enum {
  __pyx_e_4cuda_5ccuda_CU_ARRAY_SPARSE_SUBRESOURCE_TYPE_SPARSE_LEVEL = 0,
  __pyx_e_4cuda_5ccuda_CU_ARRAY_SPARSE_SUBRESOURCE_TYPE_MIPTAIL = 1
};

/* "cuda/ccuda.pxd":1387
 * ctypedef CUarraySparseSubresourceType_enum CUarraySparseSubresourceType
 * 
 * cdef enum CUmemOperationType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_OPERATION_TYPE_MAP = 1
 *     CU_MEM_OPERATION_TYPE_UNMAP = 2
 */
enum __pyx_t_4cuda_5ccuda_CUmemOperationType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_OPERATION_TYPE_MAP = 1,
  __pyx_e_4cuda_5ccuda_CU_MEM_OPERATION_TYPE_UNMAP = 2
};

/* "cuda/ccuda.pxd":1393
 * ctypedef CUmemOperationType_enum CUmemOperationType
 * 
 * cdef enum CUmemHandleType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_HANDLE_TYPE_GENERIC = 0
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUmemHandleType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_HANDLE_TYPE_GENERIC = 0
};

/* "cuda/ccuda.pxd":1449
 * ctypedef CUmemLocation_v1 CUmemLocation
 * 
 * cdef enum CUmemAllocationCompType_enum:             # <<<<<<<<<<<<<<
 *     CU_MEM_ALLOCATION_COMP_NONE = 0x0
 *     CU_MEM_ALLOCATION_COMP_GENERIC = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUmemAllocationCompType_enum {
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOCATION_COMP_NONE = 0x0,
  __pyx_e_4cuda_5ccuda_CU_MEM_ALLOCATION_COMP_GENERIC = 0x1
};

/* "cuda/ccuda.pxd":1480
 * ctypedef CUmemAccessDesc_v1 CUmemAccessDesc
 * 
 * cdef enum CUgraphExecUpdateResult_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPH_EXEC_UPDATE_SUCCESS = 0x0
 *     CU_GRAPH_EXEC_UPDATE_ERROR = 0x1
 */
enum __pyx_t_4cuda_5ccuda_CUgraphExecUpdateResult_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_SUCCESS = 0x0,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR = 0x1,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_TOPOLOGY_CHANGED = 0x2,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_NODE_TYPE_CHANGED = 0x3,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_FUNCTION_CHANGED = 0x4,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_PARAMETERS_CHANGED = 0x5,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_NOT_SUPPORTED = 0x6,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_EXEC_UPDATE_ERROR_UNSUPPORTED_FUNCTION_CHANGE = 0x7
};

/* "cuda/ccuda.pxd":1492
 * ctypedef CUgraphExecUpdateResult_enum CUgraphExecUpdateResult
 * 
 * cdef enum CUmemPool_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_MEMPOOL_ATTR_REUSE_FOLLOW_EVENT_DEPENDENCIES = 1
 *     CU_MEMPOOL_ATTR_REUSE_ALLOW_OPPORTUNISTIC
 */
enum __pyx_t_4cuda_5ccuda_CUmemPool_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_REUSE_FOLLOW_EVENT_DEPENDENCIES = 1,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_REUSE_ALLOW_OPPORTUNISTIC,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_REUSE_ALLOW_INTERNAL_DEPENDENCIES,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_RELEASE_THRESHOLD,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_RESERVED_MEM_CURRENT,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_RESERVED_MEM_HIGH,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_USED_MEM_CURRENT,
  __pyx_e_4cuda_5ccuda_CU_MEMPOOL_ATTR_USED_MEM_HIGH
};

/* "cuda/ccuda.pxd":1531
 * ctypedef CUDA_MEM_ALLOC_NODE_PARAMS_st CUDA_MEM_ALLOC_NODE_PARAMS
 * 
 * cdef enum CUgraphMem_attribute_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPH_MEM_ATTR_USED_MEM_CURRENT
 *     CU_GRAPH_MEM_ATTR_USED_MEM_HIGH
 */
enum __pyx_t_4cuda_5ccuda_CUgraphMem_attribute_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPH_MEM_ATTR_USED_MEM_CURRENT,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_MEM_ATTR_USED_MEM_HIGH,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_MEM_ATTR_RESERVED_MEM_CURRENT,
  __pyx_e_4cuda_5ccuda_CU_GRAPH_MEM_ATTR_RESERVED_MEM_HIGH
};

/* "cuda/ccuda.pxd":1539
 * ctypedef CUgraphMem_attribute_enum CUgraphMem_attribute
 * 
 * cdef enum CUflushGPUDirectRDMAWritesOptions_enum:             # <<<<<<<<<<<<<<
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_HOST = 1<<0
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_MEMOPS = 1<<1
 */
enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesOptions_enum {

  /* "cuda/ccuda.pxd":1541
 * cdef enum CUflushGPUDirectRDMAWritesOptions_enum:
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_HOST = 1<<0
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_MEMOPS = 1<<1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUflushGPUDirectRDMAWritesOptions_enum CUflushGPUDirectRDMAWritesOptions
 */
  __pyx_e_4cuda_5ccuda_CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_HOST = (1 << 0),
  __pyx_e_4cuda_5ccuda_CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_MEMOPS = (1 << 1)
};

/* "cuda/ccuda.pxd":1545
 * ctypedef CUflushGPUDirectRDMAWritesOptions_enum CUflushGPUDirectRDMAWritesOptions
 * 
 * cdef enum CUGPUDirectRDMAWritesOrdering_enum:             # <<<<<<<<<<<<<<
 *     CU_GPU_DIRECT_RDMA_WRITES_ORDERING_NONE = 0
 *     CU_GPU_DIRECT_RDMA_WRITES_ORDERING_OWNER = 100
 */
enum __pyx_t_4cuda_5ccuda_CUGPUDirectRDMAWritesOrdering_enum {
  __pyx_e_4cuda_5ccuda_CU_GPU_DIRECT_RDMA_WRITES_ORDERING_NONE = 0,
  __pyx_e_4cuda_5ccuda_CU_GPU_DIRECT_RDMA_WRITES_ORDERING_OWNER = 0x64,
  __pyx_e_4cuda_5ccuda_CU_GPU_DIRECT_RDMA_WRITES_ORDERING_ALL_DEVICES = 0xC8
};

/* "cuda/ccuda.pxd":1552
 * ctypedef CUGPUDirectRDMAWritesOrdering_enum CUGPUDirectRDMAWritesOrdering
 * 
 * cdef enum CUflushGPUDirectRDMAWritesScope_enum:             # <<<<<<<<<<<<<<
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TO_OWNER = 100
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TO_ALL_DEVICES = 200
 */
enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesScope_enum {
  __pyx_e_4cuda_5ccuda_CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TO_OWNER = 0x64,
  __pyx_e_4cuda_5ccuda_CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TO_ALL_DEVICES = 0xC8
};

/* "cuda/ccuda.pxd":1558
 * ctypedef CUflushGPUDirectRDMAWritesScope_enum CUflushGPUDirectRDMAWritesScope
 * 
 * cdef enum CUflushGPUDirectRDMAWritesTarget_enum:             # <<<<<<<<<<<<<<
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TARGET_CURRENT_CTX = 0
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesTarget_enum {
  __pyx_e_4cuda_5ccuda_CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TARGET_CURRENT_CTX = 0
};

/* "cuda/ccuda.pxd":1563
 * ctypedef CUflushGPUDirectRDMAWritesTarget_enum CUflushGPUDirectRDMAWritesTarget
 * 
 * cdef enum CUgraphDebugDot_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPH_DEBUG_DOT_FLAGS_VERBOSE = 1<<0
 *     CU_GRAPH_DEBUG_DOT_FLAGS_RUNTIME_TYPES = 1<<1
 */
enum __pyx_t_4cuda_5ccuda_CUgraphDebugDot_flags_enum {

  /* "cuda/ccuda.pxd":1576
 *     CU_GRAPH_DEBUG_DOT_FLAGS_HANDLES = 1<<10
 *     CU_GRAPH_DEBUG_DOT_FLAGS_MEM_ALLOC_NODE_PARAMS = 1<<11
 *     CU_GRAPH_DEBUG_DOT_FLAGS_MEM_FREE_NODE_PARAMS = 1<<12             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUgraphDebugDot_flags_enum CUgraphDebugDot_flags
 */
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_VERBOSE = (1 << 0),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_RUNTIME_TYPES = (1 << 1),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_KERNEL_NODE_PARAMS = (1 << 2),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_MEMCPY_NODE_PARAMS = (1 << 3),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_MEMSET_NODE_PARAMS = (1 << 4),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_HOST_NODE_PARAMS = (1 << 5),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_EVENT_NODE_PARAMS = (1 << 6),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_EXT_SEMAS_SIGNAL_NODE_PARAMS = (1 << 7),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_EXT_SEMAS_WAIT_NODE_PARAMS = (1 << 8),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_KERNEL_NODE_ATTRIBUTES = (1 << 9),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_HANDLES = (1 << 10),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_MEM_ALLOC_NODE_PARAMS = (1 << 11),
  __pyx_e_4cuda_5ccuda_CU_GRAPH_DEBUG_DOT_FLAGS_MEM_FREE_NODE_PARAMS = (1 << 12)
};

/* "cuda/ccuda.pxd":1580
 * ctypedef CUgraphDebugDot_flags_enum CUgraphDebugDot_flags
 * 
 * cdef enum CUuserObject_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_USER_OBJECT_NO_DESTRUCTOR_SYNC = 1
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUuserObject_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_USER_OBJECT_NO_DESTRUCTOR_SYNC = 1
};

/* "cuda/ccuda.pxd":1585
 * ctypedef CUuserObject_flags_enum CUuserObject_flags
 * 
 * cdef enum CUuserObjectRetain_flags_enum:             # <<<<<<<<<<<<<<
 *     CU_GRAPH_USER_OBJECT_MOVE = 1
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUuserObjectRetain_flags_enum {
  __pyx_e_4cuda_5ccuda_CU_GRAPH_USER_OBJECT_MOVE = 1
};

/* "cuda/ccuda.pxd":1590
 * ctypedef CUuserObjectRetain_flags_enum CUuserObjectRetain_flags
 * 
 * cdef enum CUgraphInstantiate_flags_enum:             # <<<<<<<<<<<<<<
 *     CUDA_GRAPH_INSTANTIATE_FLAG_AUTO_FREE_ON_LAUNCH = 1
 * 
 */
enum __pyx_t_4cuda_5ccuda_CUgraphInstantiate_flags_enum {
  __pyx_e_4cuda_5ccuda_CUDA_GRAPH_INSTANTIATE_FLAG_AUTO_FREE_ON_LAUNCH = 1
};

/* "cuda/ccuda.pxd":2295
 * cdef CUresult cuGetExportTable(const void** ppExportTable, const CUuuid* pExportTableId) nogil except ?CUDA_ERROR_NOT_FOUND
 * 
 * cdef enum: CUDA_VERSION = 11050             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_IPC_HANDLE_SIZE = 64
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_VERSION = 0x2B2A
};

/* "cuda/ccuda.pxd":2297
 * cdef enum: CUDA_VERSION = 11050
 * 
 * cdef enum: CU_IPC_HANDLE_SIZE = 64             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_STREAM_LEGACY = 0x1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_IPC_HANDLE_SIZE = 64
};

/* "cuda/ccuda.pxd":2299
 * cdef enum: CU_IPC_HANDLE_SIZE = 64
 * 
 * cdef enum: CU_STREAM_LEGACY = 0x1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_STREAM_PER_THREAD = 0x2
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_STREAM_LEGACY = 0x1
};

/* "cuda/ccuda.pxd":2301
 * cdef enum: CU_STREAM_LEGACY = 0x1
 * 
 * cdef enum: CU_STREAM_PER_THREAD = 0x2             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTALLOC_PORTABLE = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_STREAM_PER_THREAD = 0x2
};

/* "cuda/ccuda.pxd":2303
 * cdef enum: CU_STREAM_PER_THREAD = 0x2
 * 
 * cdef enum: CU_MEMHOSTALLOC_PORTABLE = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTALLOC_DEVICEMAP = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTALLOC_PORTABLE = 0x01
};

/* "cuda/ccuda.pxd":2305
 * cdef enum: CU_MEMHOSTALLOC_PORTABLE = 0x01
 * 
 * cdef enum: CU_MEMHOSTALLOC_DEVICEMAP = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTALLOC_WRITECOMBINED = 0x04
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTALLOC_DEVICEMAP = 0x02
};

/* "cuda/ccuda.pxd":2307
 * cdef enum: CU_MEMHOSTALLOC_DEVICEMAP = 0x02
 * 
 * cdef enum: CU_MEMHOSTALLOC_WRITECOMBINED = 0x04             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTREGISTER_PORTABLE = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTALLOC_WRITECOMBINED = 0x04
};

/* "cuda/ccuda.pxd":2309
 * cdef enum: CU_MEMHOSTALLOC_WRITECOMBINED = 0x04
 * 
 * cdef enum: CU_MEMHOSTREGISTER_PORTABLE = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTREGISTER_DEVICEMAP = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTREGISTER_PORTABLE = 0x01
};

/* "cuda/ccuda.pxd":2311
 * cdef enum: CU_MEMHOSTREGISTER_PORTABLE = 0x01
 * 
 * cdef enum: CU_MEMHOSTREGISTER_DEVICEMAP = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTREGISTER_IOMEMORY = 0x04
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTREGISTER_DEVICEMAP = 0x02
};

/* "cuda/ccuda.pxd":2313
 * cdef enum: CU_MEMHOSTREGISTER_DEVICEMAP = 0x02
 * 
 * cdef enum: CU_MEMHOSTREGISTER_IOMEMORY = 0x04             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEMHOSTREGISTER_READ_ONLY = 0x08
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTREGISTER_IOMEMORY = 0x04
};

/* "cuda/ccuda.pxd":2315
 * cdef enum: CU_MEMHOSTREGISTER_IOMEMORY = 0x04
 * 
 * cdef enum: CU_MEMHOSTREGISTER_READ_ONLY = 0x08             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_ARRAY_SPARSE_PROPERTIES_SINGLE_MIPTAIL = 0x1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEMHOSTREGISTER_READ_ONLY = 0x08
};

/* "cuda/ccuda.pxd":2317
 * cdef enum: CU_MEMHOSTREGISTER_READ_ONLY = 0x08
 * 
 * cdef enum: CU_ARRAY_SPARSE_PROPERTIES_SINGLE_MIPTAIL = 0x1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_EXTERNAL_MEMORY_DEDICATED = 0x1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_ARRAY_SPARSE_PROPERTIES_SINGLE_MIPTAIL = 0x1
};

/* "cuda/ccuda.pxd":2319
 * cdef enum: CU_ARRAY_SPARSE_PROPERTIES_SINGLE_MIPTAIL = 0x1
 * 
 * cdef enum: CUDA_EXTERNAL_MEMORY_DEDICATED = 0x1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_SIGNAL_SKIP_NVSCIBUF_MEMSYNC = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_DEDICATED = 0x1
};

/* "cuda/ccuda.pxd":2321
 * cdef enum: CUDA_EXTERNAL_MEMORY_DEDICATED = 0x1
 * 
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_SIGNAL_SKIP_NVSCIBUF_MEMSYNC = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_WAIT_SKIP_NVSCIBUF_MEMSYNC = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_SKIP_NVSCIBUF_MEMSYNC = 0x01
};

/* "cuda/ccuda.pxd":2323
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_SIGNAL_SKIP_NVSCIBUF_MEMSYNC = 0x01
 * 
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_WAIT_SKIP_NVSCIBUF_MEMSYNC = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_NVSCISYNC_ATTR_SIGNAL = 0x1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_SKIP_NVSCIBUF_MEMSYNC = 0x02
};

/* "cuda/ccuda.pxd":2325
 * cdef enum: CUDA_EXTERNAL_SEMAPHORE_WAIT_SKIP_NVSCIBUF_MEMSYNC = 0x02
 * 
 * cdef enum: CUDA_NVSCISYNC_ATTR_SIGNAL = 0x1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_NVSCISYNC_ATTR_WAIT = 0x2
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_NVSCISYNC_ATTR_SIGNAL = 0x1
};

/* "cuda/ccuda.pxd":2327
 * cdef enum: CUDA_NVSCISYNC_ATTR_SIGNAL = 0x1
 * 
 * cdef enum: CUDA_NVSCISYNC_ATTR_WAIT = 0x2             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_MEM_CREATE_USAGE_TILE_POOL = 0x1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_NVSCISYNC_ATTR_WAIT = 0x2
};

/* "cuda/ccuda.pxd":2329
 * cdef enum: CUDA_NVSCISYNC_ATTR_WAIT = 0x2
 * 
 * cdef enum: CU_MEM_CREATE_USAGE_TILE_POOL = 0x1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_PRE_LAUNCH_SYNC = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_MEM_CREATE_USAGE_TILE_POOL = 0x1
};

/* "cuda/ccuda.pxd":2331
 * cdef enum: CU_MEM_CREATE_USAGE_TILE_POOL = 0x1
 * 
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_PRE_LAUNCH_SYNC = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_POST_LAUNCH_SYNC = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_PRE_LAUNCH_SYNC = 0x01
};

/* "cuda/ccuda.pxd":2333
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_PRE_LAUNCH_SYNC = 0x01
 * 
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_POST_LAUNCH_SYNC = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_LAYERED = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_POST_LAUNCH_SYNC = 0x02
};

/* "cuda/ccuda.pxd":2335
 * cdef enum: CUDA_COOPERATIVE_LAUNCH_MULTI_DEVICE_NO_POST_LAUNCH_SYNC = 0x02
 * 
 * cdef enum: CUDA_ARRAY3D_LAYERED = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_2DARRAY = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_LAYERED = 0x01
};

/* "cuda/ccuda.pxd":2337
 * cdef enum: CUDA_ARRAY3D_LAYERED = 0x01
 * 
 * cdef enum: CUDA_ARRAY3D_2DARRAY = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_SURFACE_LDST = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_2DARRAY = 0x01
};

/* "cuda/ccuda.pxd":2339
 * cdef enum: CUDA_ARRAY3D_2DARRAY = 0x01
 * 
 * cdef enum: CUDA_ARRAY3D_SURFACE_LDST = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_CUBEMAP = 0x04
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_SURFACE_LDST = 0x02
};

/* "cuda/ccuda.pxd":2341
 * cdef enum: CUDA_ARRAY3D_SURFACE_LDST = 0x02
 * 
 * cdef enum: CUDA_ARRAY3D_CUBEMAP = 0x04             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_TEXTURE_GATHER = 0x08
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_CUBEMAP = 0x04
};

/* "cuda/ccuda.pxd":2343
 * cdef enum: CUDA_ARRAY3D_CUBEMAP = 0x04
 * 
 * cdef enum: CUDA_ARRAY3D_TEXTURE_GATHER = 0x08             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_DEPTH_TEXTURE = 0x10
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_TEXTURE_GATHER = 0x08
};

/* "cuda/ccuda.pxd":2345
 * cdef enum: CUDA_ARRAY3D_TEXTURE_GATHER = 0x08
 * 
 * cdef enum: CUDA_ARRAY3D_DEPTH_TEXTURE = 0x10             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_COLOR_ATTACHMENT = 0x20
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_DEPTH_TEXTURE = 0x10
};

/* "cuda/ccuda.pxd":2347
 * cdef enum: CUDA_ARRAY3D_DEPTH_TEXTURE = 0x10
 * 
 * cdef enum: CUDA_ARRAY3D_COLOR_ATTACHMENT = 0x20             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CUDA_ARRAY3D_SPARSE = 0x40
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_COLOR_ATTACHMENT = 0x20
};

/* "cuda/ccuda.pxd":2349
 * cdef enum: CUDA_ARRAY3D_COLOR_ATTACHMENT = 0x20
 * 
 * cdef enum: CUDA_ARRAY3D_SPARSE = 0x40             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_TRSA_OVERRIDE_FORMAT = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CUDA_ARRAY3D_SPARSE = 0x40
};

/* "cuda/ccuda.pxd":2351
 * cdef enum: CUDA_ARRAY3D_SPARSE = 0x40
 * 
 * cdef enum: CU_TRSA_OVERRIDE_FORMAT = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_TRSF_READ_AS_INTEGER = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_TRSA_OVERRIDE_FORMAT = 0x01
};

/* "cuda/ccuda.pxd":2353
 * cdef enum: CU_TRSA_OVERRIDE_FORMAT = 0x01
 * 
 * cdef enum: CU_TRSF_READ_AS_INTEGER = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_TRSF_NORMALIZED_COORDINATES = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_TRSF_READ_AS_INTEGER = 0x01
};

/* "cuda/ccuda.pxd":2355
 * cdef enum: CU_TRSF_READ_AS_INTEGER = 0x01
 * 
 * cdef enum: CU_TRSF_NORMALIZED_COORDINATES = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_TRSF_SRGB = 0x10
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_TRSF_NORMALIZED_COORDINATES = 0x02
};

/* "cuda/ccuda.pxd":2357
 * cdef enum: CU_TRSF_NORMALIZED_COORDINATES = 0x02
 * 
 * cdef enum: CU_TRSF_SRGB = 0x10             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_TRSF_DISABLE_TRILINEAR_OPTIMIZATION = 0x20
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_TRSF_SRGB = 0x10
};

/* "cuda/ccuda.pxd":2359
 * cdef enum: CU_TRSF_SRGB = 0x10
 * 
 * cdef enum: CU_TRSF_DISABLE_TRILINEAR_OPTIMIZATION = 0x20             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_LAUNCH_PARAM_END = 0x00
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_TRSF_DISABLE_TRILINEAR_OPTIMIZATION = 0x20
};

/* "cuda/ccuda.pxd":2361
 * cdef enum: CU_TRSF_DISABLE_TRILINEAR_OPTIMIZATION = 0x20
 * 
 * cdef enum: CU_LAUNCH_PARAM_END = 0x00             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_POINTER = 0x01
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_LAUNCH_PARAM_END = 0x00
};

/* "cuda/ccuda.pxd":2363
 * cdef enum: CU_LAUNCH_PARAM_END = 0x00
 * 
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_POINTER = 0x01             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_SIZE = 0x02
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_LAUNCH_PARAM_BUFFER_POINTER = 0x01
};

/* "cuda/ccuda.pxd":2365
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_POINTER = 0x01
 * 
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_SIZE = 0x02             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_PARAM_TR_DEFAULT = -1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_LAUNCH_PARAM_BUFFER_SIZE = 0x02
};

/* "cuda/ccuda.pxd":2367
 * cdef enum: CU_LAUNCH_PARAM_BUFFER_SIZE = 0x02
 * 
 * cdef enum: CU_PARAM_TR_DEFAULT = -1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_DEVICE_CPU = -1
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_PARAM_TR_DEFAULT = -1L
};

/* "cuda/ccuda.pxd":2369
 * cdef enum: CU_PARAM_TR_DEFAULT = -1
 * 
 * cdef enum: CU_DEVICE_CPU = -1             # <<<<<<<<<<<<<<
 * 
 * cdef enum: CU_DEVICE_INVALID = -2
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_DEVICE_CPU = -1L
};

/* "cuda/ccuda.pxd":2371
 * cdef enum: CU_DEVICE_CPU = -1
 * 
 * cdef enum: CU_DEVICE_INVALID = -2             # <<<<<<<<<<<<<<
 */
enum  {
  __pyx_e_4cuda_5ccuda_CU_DEVICE_INVALID = -2L
};

/* "cuda/ccuda.pxd":26
 *     cdef struct CUctx_st:
 *         pass
 * ctypedef CUctx_st* CUcontext             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUctx_st *__pyx_t_4cuda_5ccuda_CUcontext;

/* "cuda/ccuda.pxd":31
 *     cdef struct CUmod_st:
 *         pass
 * ctypedef CUmod_st* CUmodule             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUmod_st *__pyx_t_4cuda_5ccuda_CUmodule;

/* "cuda/ccuda.pxd":36
 *     cdef struct CUfunc_st:
 *         pass
 * ctypedef CUfunc_st* CUfunction             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUfunc_st *__pyx_t_4cuda_5ccuda_CUfunction;

/* "cuda/ccuda.pxd":41
 *     cdef struct CUarray_st:
 *         pass
 * ctypedef CUarray_st* CUarray             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUarray_st *__pyx_t_4cuda_5ccuda_CUarray;

/* "cuda/ccuda.pxd":46
 *     cdef struct CUmipmappedArray_st:
 *         pass
 * ctypedef CUmipmappedArray_st* CUmipmappedArray             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUmipmappedArray_st *__pyx_t_4cuda_5ccuda_CUmipmappedArray;

/* "cuda/ccuda.pxd":51
 *     cdef struct CUtexref_st:
 *         pass
 * ctypedef CUtexref_st* CUtexref             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUtexref_st *__pyx_t_4cuda_5ccuda_CUtexref;

/* "cuda/ccuda.pxd":56
 *     cdef struct CUsurfref_st:
 *         pass
 * ctypedef CUsurfref_st* CUsurfref             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUsurfref_st *__pyx_t_4cuda_5ccuda_CUsurfref;

/* "cuda/ccuda.pxd":61
 *     cdef struct CUevent_st:
 *         pass
 * ctypedef CUevent_st* CUevent             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUevent_st *__pyx_t_4cuda_5ccuda_CUevent;

/* "cuda/ccuda.pxd":66
 *     cdef struct CUstream_st:
 *         pass
 * ctypedef CUstream_st* CUstream             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUstream_st *__pyx_t_4cuda_5ccuda_CUstream;

/* "cuda/ccuda.pxd":71
 *     cdef struct CUgraphicsResource_st:
 *         pass
 * ctypedef CUgraphicsResource_st* CUgraphicsResource             # <<<<<<<<<<<<<<
 * 
 * ctypedef unsigned long long CUtexObject_v1
 */
typedef struct CUgraphicsResource_st *__pyx_t_4cuda_5ccuda_CUgraphicsResource;

/* "cuda/ccuda.pxd":84
 *     cdef struct CUextMemory_st:
 *         pass
 * ctypedef CUextMemory_st* CUexternalMemory             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUextMemory_st *__pyx_t_4cuda_5ccuda_CUexternalMemory;

/* "cuda/ccuda.pxd":89
 *     cdef struct CUextSemaphore_st:
 *         pass
 * ctypedef CUextSemaphore_st* CUexternalSemaphore             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUextSemaphore_st *__pyx_t_4cuda_5ccuda_CUexternalSemaphore;

/* "cuda/ccuda.pxd":94
 *     cdef struct CUgraph_st:
 *         pass
 * ctypedef CUgraph_st* CUgraph             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUgraph_st *__pyx_t_4cuda_5ccuda_CUgraph;

/* "cuda/ccuda.pxd":99
 *     cdef struct CUgraphNode_st:
 *         pass
 * ctypedef CUgraphNode_st* CUgraphNode             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUgraphNode_st *__pyx_t_4cuda_5ccuda_CUgraphNode;

/* "cuda/ccuda.pxd":104
 *     cdef struct CUgraphExec_st:
 *         pass
 * ctypedef CUgraphExec_st* CUgraphExec             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUgraphExec_st *__pyx_t_4cuda_5ccuda_CUgraphExec;

/* "cuda/ccuda.pxd":109
 *     cdef struct CUmemPoolHandle_st:
 *         pass
 * ctypedef CUmemPoolHandle_st* CUmemoryPool             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef struct CUmemPoolHandle_st *__pyx_t_4cuda_5ccuda_CUmemoryPool;

/* "cuda/ccuda.pxd":114
 *     cdef struct CUuserObject_st:
 *         pass
 * ctypedef CUuserObject_st* CUuserObject             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUuuid_st:
 */
typedef struct CUuserObject_st *__pyx_t_4cuda_5ccuda_CUuserObject;

/* "cuda/ccuda.pxd":116
 * ctypedef CUuserObject_st* CUuserObject
 * 
 * cdef struct CUuuid_st:             # <<<<<<<<<<<<<<
 *     char bytes[16]
 * 
 */
struct __pyx_t_4cuda_5ccuda_CUuuid_st {
  char bytes[16];
};

/* "cuda/ccuda.pxd":119
 *     char bytes[16]
 * 
 * ctypedef CUuuid_st CUuuid             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUipcEventHandle_st:
 */
typedef struct __pyx_t_4cuda_5ccuda_CUuuid_st __pyx_t_4cuda_5ccuda_CUuuid;

/* "cuda/ccuda.pxd":121
 * ctypedef CUuuid_st CUuuid
 * 
 * cdef struct CUipcEventHandle_st:             # <<<<<<<<<<<<<<
 *     char reserved[64]
 * 
 */
struct __pyx_t_4cuda_5ccuda_CUipcEventHandle_st {
  char reserved[64];
};

/* "cuda/ccuda.pxd":124
 *     char reserved[64]
 * 
 * ctypedef CUipcEventHandle_st CUipcEventHandle_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUipcEventHandle_v1 CUipcEventHandle
 */
typedef struct __pyx_t_4cuda_5ccuda_CUipcEventHandle_st __pyx_t_4cuda_5ccuda_CUipcEventHandle_v1;

/* "cuda/ccuda.pxd":126
 * ctypedef CUipcEventHandle_st CUipcEventHandle_v1
 * 
 * ctypedef CUipcEventHandle_v1 CUipcEventHandle             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUipcMemHandle_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUipcEventHandle_v1 __pyx_t_4cuda_5ccuda_CUipcEventHandle;

/* "cuda/ccuda.pxd":128
 * ctypedef CUipcEventHandle_v1 CUipcEventHandle
 * 
 * cdef struct CUipcMemHandle_st:             # <<<<<<<<<<<<<<
 *     char reserved[64]
 * 
 */
struct __pyx_t_4cuda_5ccuda_CUipcMemHandle_st {
  char reserved[64];
};

/* "cuda/ccuda.pxd":131
 *     char reserved[64]
 * 
 * ctypedef CUipcMemHandle_st CUipcMemHandle_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUipcMemHandle_v1 CUipcMemHandle
 */
typedef struct __pyx_t_4cuda_5ccuda_CUipcMemHandle_st __pyx_t_4cuda_5ccuda_CUipcMemHandle_v1;

/* "cuda/ccuda.pxd":133
 * ctypedef CUipcMemHandle_st CUipcMemHandle_v1
 * 
 * ctypedef CUipcMemHandle_v1 CUipcMemHandle             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUipcMem_flags_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUipcMemHandle_v1 __pyx_t_4cuda_5ccuda_CUipcMemHandle;

/* "cuda/ccuda.pxd":138
 *     CU_IPC_MEM_LAZY_ENABLE_PEER_ACCESS = 0x1
 * 
 * ctypedef CUipcMem_flags_enum CUipcMem_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAttach_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUipcMem_flags_enum __pyx_t_4cuda_5ccuda_CUipcMem_flags;

/* "cuda/ccuda.pxd":145
 *     CU_MEM_ATTACH_SINGLE = 0x4
 * 
 * ctypedef CUmemAttach_flags_enum CUmemAttach_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUctx_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAttach_flags_enum __pyx_t_4cuda_5ccuda_CUmemAttach_flags;

/* "cuda/ccuda.pxd":158
 *     CU_CTX_FLAGS_MASK = 0x1f
 * 
 * ctypedef CUctx_flags_enum CUctx_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstream_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUctx_flags_enum __pyx_t_4cuda_5ccuda_CUctx_flags;

/* "cuda/ccuda.pxd":164
 *     CU_STREAM_NON_BLOCKING = 0x1
 * 
 * ctypedef CUstream_flags_enum CUstream_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUevent_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstream_flags_enum __pyx_t_4cuda_5ccuda_CUstream_flags;

/* "cuda/ccuda.pxd":172
 *     CU_EVENT_INTERPROCESS = 0x4
 * 
 * ctypedef CUevent_flags_enum CUevent_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUevent_record_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUevent_flags_enum __pyx_t_4cuda_5ccuda_CUevent_flags;

/* "cuda/ccuda.pxd":178
 *     CU_EVENT_RECORD_EXTERNAL = 0x1
 * 
 * ctypedef CUevent_record_flags_enum CUevent_record_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUevent_wait_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUevent_record_flags_enum __pyx_t_4cuda_5ccuda_CUevent_record_flags;

/* "cuda/ccuda.pxd":184
 *     CU_EVENT_WAIT_EXTERNAL = 0x1
 * 
 * ctypedef CUevent_wait_flags_enum CUevent_wait_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamWaitValue_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUevent_wait_flags_enum __pyx_t_4cuda_5ccuda_CUevent_wait_flags;

/* "cuda/ccuda.pxd":193
 *     CU_STREAM_WAIT_VALUE_FLUSH = 1<<30
 * 
 * ctypedef CUstreamWaitValue_flags_enum CUstreamWaitValue_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamWriteValue_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamWaitValue_flags_enum __pyx_t_4cuda_5ccuda_CUstreamWaitValue_flags;

/* "cuda/ccuda.pxd":199
 *     CU_STREAM_WRITE_VALUE_NO_MEMORY_BARRIER = 0x1
 * 
 * ctypedef CUstreamWriteValue_flags_enum CUstreamWriteValue_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamBatchMemOpType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamWriteValue_flags_enum __pyx_t_4cuda_5ccuda_CUstreamWriteValue_flags;

/* "cuda/ccuda.pxd":208
 *     CU_STREAM_MEM_OP_FLUSH_REMOTE_WRITES = 3
 * 
 * ctypedef CUstreamBatchMemOpType_enum CUstreamBatchMemOpType             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUstreamMemOpWaitValueParams_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType_enum __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType;

/* "cuda/ccuda.pxd":210
 * ctypedef CUstreamBatchMemOpType_enum CUstreamBatchMemOpType
 * 
 * cdef struct CUstreamMemOpWaitValueParams_st:             # <<<<<<<<<<<<<<
 *     CUstreamBatchMemOpType operation
 *     CUdeviceptr address
 */
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWaitValueParams_st {
  __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType operation;
  __pyx_t_4cuda_5ccuda_CUdeviceptr address;
  __pyx_t_4cuda_5ccuda_cuuint64_t value64;
  unsigned int flags;
  __pyx_t_4cuda_5ccuda_CUdeviceptr alias;
};

/* "cuda/ccuda.pxd":217
 *     CUdeviceptr alias
 * 
 * cdef struct CUstreamMemOpWriteValueParams_st:             # <<<<<<<<<<<<<<
 *     CUstreamBatchMemOpType operation
 *     CUdeviceptr address
 */
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWriteValueParams_st {
  __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType operation;
  __pyx_t_4cuda_5ccuda_CUdeviceptr address;
  __pyx_t_4cuda_5ccuda_cuuint64_t value64;
  unsigned int flags;
  __pyx_t_4cuda_5ccuda_CUdeviceptr alias;
};

/* "cuda/ccuda.pxd":224
 *     CUdeviceptr alias
 * 
 * cdef struct CUstreamMemOpFlushRemoteWritesParams_st:             # <<<<<<<<<<<<<<
 *     CUstreamBatchMemOpType operation
 *     unsigned int flags
 */
struct __pyx_t_4cuda_5ccuda_CUstreamMemOpFlushRemoteWritesParams_st {
  __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType operation;
  unsigned int flags;
};

/* "cuda/ccuda.pxd":228
 *     unsigned int flags
 * 
 * cdef union CUstreamBatchMemOpParams_union:             # <<<<<<<<<<<<<<
 *     CUstreamBatchMemOpType operation
 *     CUstreamMemOpWaitValueParams_st waitValue
 */
union __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams_union {
  __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpType operation;
  struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWaitValueParams_st waitValue;
  struct __pyx_t_4cuda_5ccuda_CUstreamMemOpWriteValueParams_st writeValue;
  struct __pyx_t_4cuda_5ccuda_CUstreamMemOpFlushRemoteWritesParams_st flushRemoteWrites;
  __pyx_t_4cuda_5ccuda_cuuint64_t pad[6];
};

/* "cuda/ccuda.pxd":235
 *     cuuint64_t pad[6]
 * 
 * ctypedef CUstreamBatchMemOpParams_union CUstreamBatchMemOpParams_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUstreamBatchMemOpParams_v1 CUstreamBatchMemOpParams
 */
typedef union __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams_union __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams_v1;

/* "cuda/ccuda.pxd":237
 * ctypedef CUstreamBatchMemOpParams_union CUstreamBatchMemOpParams_v1
 * 
 * ctypedef CUstreamBatchMemOpParams_v1 CUstreamBatchMemOpParams             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUoccupancy_flags_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams_v1 __pyx_t_4cuda_5ccuda_CUstreamBatchMemOpParams;

/* "cuda/ccuda.pxd":243
 *     CU_OCCUPANCY_DISABLE_CACHING_OVERRIDE = 0x1
 * 
 * ctypedef CUoccupancy_flags_enum CUoccupancy_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamUpdateCaptureDependencies_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUoccupancy_flags_enum __pyx_t_4cuda_5ccuda_CUoccupancy_flags;

/* "cuda/ccuda.pxd":249
 *     CU_STREAM_SET_CAPTURE_DEPENDENCIES = 0x1
 * 
 * ctypedef CUstreamUpdateCaptureDependencies_flags_enum CUstreamUpdateCaptureDependencies_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUarray_format_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamUpdateCaptureDependencies_flags_enum __pyx_t_4cuda_5ccuda_CUstreamUpdateCaptureDependencies_flags;

/* "cuda/ccuda.pxd":288
 *     CU_AD_FORMAT_BC7_UNORM_SRGB = 0x9e
 * 
 * ctypedef CUarray_format_enum CUarray_format             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUaddress_mode_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUarray_format_enum __pyx_t_4cuda_5ccuda_CUarray_format;

/* "cuda/ccuda.pxd":296
 *     CU_TR_ADDRESS_MODE_BORDER = 3
 * 
 * ctypedef CUaddress_mode_enum CUaddress_mode             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUfilter_mode_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUaddress_mode_enum __pyx_t_4cuda_5ccuda_CUaddress_mode;

/* "cuda/ccuda.pxd":302
 *     CU_TR_FILTER_MODE_LINEAR = 1
 * 
 * ctypedef CUfilter_mode_enum CUfilter_mode             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUdevice_attribute_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUfilter_mode_enum __pyx_t_4cuda_5ccuda_CUfilter_mode;

/* "cuda/ccuda.pxd":432
 *     CU_DEVICE_ATTRIBUTE_MAX
 * 
 * ctypedef CUdevice_attribute_enum CUdevice_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUdevprop_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUdevice_attribute_enum __pyx_t_4cuda_5ccuda_CUdevice_attribute;

/* "cuda/ccuda.pxd":434
 * ctypedef CUdevice_attribute_enum CUdevice_attribute
 * 
 * cdef struct CUdevprop_st:             # <<<<<<<<<<<<<<
 *     int maxThreadsPerBlock
 *     int maxThreadsDim[3]
 */
struct __pyx_t_4cuda_5ccuda_CUdevprop_st {
  int maxThreadsPerBlock;
  int maxThreadsDim[3];
  int maxGridSize[3];
  int sharedMemPerBlock;
  int totalConstantMemory;
  int SIMDWidth;
  int memPitch;
  int regsPerBlock;
  int clockRate;
  int textureAlign;
};

/* "cuda/ccuda.pxd":446
 *     int textureAlign
 * 
 * ctypedef CUdevprop_st CUdevprop_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUdevprop_v1 CUdevprop
 */
typedef struct __pyx_t_4cuda_5ccuda_CUdevprop_st __pyx_t_4cuda_5ccuda_CUdevprop_v1;

/* "cuda/ccuda.pxd":448
 * ctypedef CUdevprop_st CUdevprop_v1
 * 
 * ctypedef CUdevprop_v1 CUdevprop             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUpointer_attribute_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUdevprop_v1 __pyx_t_4cuda_5ccuda_CUdevprop;

/* "cuda/ccuda.pxd":469
 *     CU_POINTER_ATTRIBUTE_MEMPOOL_HANDLE = 17
 * 
 * ctypedef CUpointer_attribute_enum CUpointer_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUfunction_attribute_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUpointer_attribute_enum __pyx_t_4cuda_5ccuda_CUpointer_attribute;

/* "cuda/ccuda.pxd":484
 *     CU_FUNC_ATTRIBUTE_MAX
 * 
 * ctypedef CUfunction_attribute_enum CUfunction_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUfunc_cache_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUfunction_attribute_enum __pyx_t_4cuda_5ccuda_CUfunction_attribute;

/* "cuda/ccuda.pxd":492
 *     CU_FUNC_CACHE_PREFER_EQUAL = 0x03
 * 
 * ctypedef CUfunc_cache_enum CUfunc_cache             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUsharedconfig_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUfunc_cache_enum __pyx_t_4cuda_5ccuda_CUfunc_cache;

/* "cuda/ccuda.pxd":499
 *     CU_SHARED_MEM_CONFIG_EIGHT_BYTE_BANK_SIZE = 0x02
 * 
 * ctypedef CUsharedconfig_enum CUsharedconfig             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUshared_carveout_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUsharedconfig_enum __pyx_t_4cuda_5ccuda_CUsharedconfig;

/* "cuda/ccuda.pxd":506
 *     CU_SHAREDMEM_CARVEOUT_MAX_L1 = 0
 * 
 * ctypedef CUshared_carveout_enum CUshared_carveout             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemorytype_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUshared_carveout_enum __pyx_t_4cuda_5ccuda_CUshared_carveout;

/* "cuda/ccuda.pxd":514
 *     CU_MEMORYTYPE_UNIFIED = 0x04
 * 
 * ctypedef CUmemorytype_enum CUmemorytype             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUcomputemode_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemorytype_enum __pyx_t_4cuda_5ccuda_CUmemorytype;

/* "cuda/ccuda.pxd":521
 *     CU_COMPUTEMODE_EXCLUSIVE_PROCESS = 3
 * 
 * ctypedef CUcomputemode_enum CUcomputemode             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmem_advise_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUcomputemode_enum __pyx_t_4cuda_5ccuda_CUcomputemode;

/* "cuda/ccuda.pxd":531
 *     CU_MEM_ADVISE_UNSET_ACCESSED_BY = 6
 * 
 * ctypedef CUmem_advise_enum CUmem_advise             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmem_range_attribute_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmem_advise_enum __pyx_t_4cuda_5ccuda_CUmem_advise;

/* "cuda/ccuda.pxd":539
 *     CU_MEM_RANGE_ATTRIBUTE_LAST_PREFETCH_LOCATION = 4
 * 
 * ctypedef CUmem_range_attribute_enum CUmem_range_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUjit_option_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmem_range_attribute_enum __pyx_t_4cuda_5ccuda_CUmem_range_attribute;

/* "cuda/ccuda.pxd":569
 *     CU_JIT_NUM_OPTIONS
 * 
 * ctypedef CUjit_option_enum CUjit_option             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUjit_target_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUjit_option_enum __pyx_t_4cuda_5ccuda_CUjit_option;

/* "cuda/ccuda.pxd":590
 *     CU_TARGET_COMPUTE_86 = 86
 * 
 * ctypedef CUjit_target_enum CUjit_target             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUjit_fallback_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUjit_target_enum __pyx_t_4cuda_5ccuda_CUjit_target;

/* "cuda/ccuda.pxd":596
 *     CU_PREFER_BINARY
 * 
 * ctypedef CUjit_fallback_enum CUjit_fallback             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUjit_cacheMode_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUjit_fallback_enum __pyx_t_4cuda_5ccuda_CUjit_fallback;

/* "cuda/ccuda.pxd":603
 *     CU_JIT_CACHE_OPTION_CA
 * 
 * ctypedef CUjit_cacheMode_enum CUjit_cacheMode             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUjitInputType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUjit_cacheMode_enum __pyx_t_4cuda_5ccuda_CUjit_cacheMode;

/* "cuda/ccuda.pxd":614
 *     CU_JIT_NUM_INPUT_TYPES
 * 
 * ctypedef CUjitInputType_enum CUjitInputType             # <<<<<<<<<<<<<<
 * 
 * cdef extern from "":
 */
typedef enum __pyx_t_4cuda_5ccuda_CUjitInputType_enum __pyx_t_4cuda_5ccuda_CUjitInputType;

/* "cuda/ccuda.pxd":619
 *     cdef struct CUlinkState_st:
 *         pass
 * ctypedef CUlinkState_st* CUlinkState             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphicsRegisterFlags_enum:
 */
typedef struct CUlinkState_st *__pyx_t_4cuda_5ccuda_CUlinkState;

/* "cuda/ccuda.pxd":628
 *     CU_GRAPHICS_REGISTER_FLAGS_TEXTURE_GATHER = 0x08
 * 
 * ctypedef CUgraphicsRegisterFlags_enum CUgraphicsRegisterFlags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphicsMapResourceFlags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphicsRegisterFlags_enum __pyx_t_4cuda_5ccuda_CUgraphicsRegisterFlags;

/* "cuda/ccuda.pxd":635
 *     CU_GRAPHICS_MAP_RESOURCE_FLAGS_WRITE_DISCARD = 0x02
 * 
 * ctypedef CUgraphicsMapResourceFlags_enum CUgraphicsMapResourceFlags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUarray_cubemap_face_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphicsMapResourceFlags_enum __pyx_t_4cuda_5ccuda_CUgraphicsMapResourceFlags;

/* "cuda/ccuda.pxd":645
 *     CU_CUBEMAP_FACE_NEGATIVE_Z = 0x05
 * 
 * ctypedef CUarray_cubemap_face_enum CUarray_cubemap_face             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUlimit_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUarray_cubemap_face_enum __pyx_t_4cuda_5ccuda_CUarray_cubemap_face;

/* "cuda/ccuda.pxd":657
 *     CU_LIMIT_MAX
 * 
 * ctypedef CUlimit_enum CUlimit             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUresourcetype_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUlimit_enum __pyx_t_4cuda_5ccuda_CUlimit;

/* "cuda/ccuda.pxd":665
 *     CU_RESOURCE_TYPE_PITCH2D = 0x03
 * 
 * ctypedef CUresourcetype_enum CUresourcetype             # <<<<<<<<<<<<<<
 * 
 * ctypedef void (*CUhostFn)(void* userData)
 */
typedef enum __pyx_t_4cuda_5ccuda_CUresourcetype_enum __pyx_t_4cuda_5ccuda_CUresourcetype;

/* "cuda/ccuda.pxd":667
 * ctypedef CUresourcetype_enum CUresourcetype
 * 
 * ctypedef void (*CUhostFn)(void* userData)             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUaccessProperty_enum:
 */
typedef void (*__pyx_t_4cuda_5ccuda_CUhostFn)(void *);

/* "cuda/ccuda.pxd":674
 *     CU_ACCESS_PROPERTY_PERSISTING = 2
 * 
 * ctypedef CUaccessProperty_enum CUaccessProperty             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUaccessPolicyWindow_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUaccessProperty_enum __pyx_t_4cuda_5ccuda_CUaccessProperty;

/* "cuda/ccuda.pxd":676
 * ctypedef CUaccessProperty_enum CUaccessProperty
 * 
 * cdef struct CUaccessPolicyWindow_st:             # <<<<<<<<<<<<<<
 *     void* base_ptr
 *     size_t num_bytes
 */
struct __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow_st {
  void *base_ptr;
  size_t num_bytes;
  float hitRatio;
  __pyx_t_4cuda_5ccuda_CUaccessProperty hitProp;
  __pyx_t_4cuda_5ccuda_CUaccessProperty missProp;
};

/* "cuda/ccuda.pxd":683
 *     CUaccessProperty missProp
 * 
 * ctypedef CUaccessPolicyWindow_st CUaccessPolicyWindow_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUaccessPolicyWindow_v1 CUaccessPolicyWindow
 */
typedef struct __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow_st __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow_v1;

/* "cuda/ccuda.pxd":685
 * ctypedef CUaccessPolicyWindow_st CUaccessPolicyWindow_v1
 * 
 * ctypedef CUaccessPolicyWindow_v1 CUaccessPolicyWindow             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_KERNEL_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow_v1 __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow;

/* "cuda/ccuda.pxd":687
 * ctypedef CUaccessPolicyWindow_v1 CUaccessPolicyWindow
 * 
 * cdef struct CUDA_KERNEL_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUfunction func
 *     unsigned int gridDimX
 */
struct __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUfunction func;
  unsigned int gridDimX;
  unsigned int gridDimY;
  unsigned int gridDimZ;
  unsigned int blockDimX;
  unsigned int blockDimY;
  unsigned int blockDimZ;
  unsigned int sharedMemBytes;
  void **kernelParams;
  void **extra;
};

/* "cuda/ccuda.pxd":699
 *     void** extra
 * 
 * ctypedef CUDA_KERNEL_NODE_PARAMS_st CUDA_KERNEL_NODE_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_KERNEL_NODE_PARAMS_v1 CUDA_KERNEL_NODE_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS_v1;

/* "cuda/ccuda.pxd":701
 * ctypedef CUDA_KERNEL_NODE_PARAMS_st CUDA_KERNEL_NODE_PARAMS_v1
 * 
 * ctypedef CUDA_KERNEL_NODE_PARAMS_v1 CUDA_KERNEL_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_MEMSET_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_KERNEL_NODE_PARAMS;

/* "cuda/ccuda.pxd":703
 * ctypedef CUDA_KERNEL_NODE_PARAMS_v1 CUDA_KERNEL_NODE_PARAMS
 * 
 * cdef struct CUDA_MEMSET_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUdeviceptr dst
 *     size_t pitch
 */
struct __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUdeviceptr dst;
  size_t pitch;
  unsigned int value;
  unsigned int elementSize;
  size_t width;
  size_t height;
};

/* "cuda/ccuda.pxd":711
 *     size_t height
 * 
 * ctypedef CUDA_MEMSET_NODE_PARAMS_st CUDA_MEMSET_NODE_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_MEMSET_NODE_PARAMS_v1 CUDA_MEMSET_NODE_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS_v1;

/* "cuda/ccuda.pxd":713
 * ctypedef CUDA_MEMSET_NODE_PARAMS_st CUDA_MEMSET_NODE_PARAMS_v1
 * 
 * ctypedef CUDA_MEMSET_NODE_PARAMS_v1 CUDA_MEMSET_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_HOST_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_MEMSET_NODE_PARAMS;

/* "cuda/ccuda.pxd":715
 * ctypedef CUDA_MEMSET_NODE_PARAMS_v1 CUDA_MEMSET_NODE_PARAMS
 * 
 * cdef struct CUDA_HOST_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUhostFn fn
 *     void* userData
 */
struct __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUhostFn fn;
  void *userData;
};

/* "cuda/ccuda.pxd":719
 *     void* userData
 * 
 * ctypedef CUDA_HOST_NODE_PARAMS_st CUDA_HOST_NODE_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_HOST_NODE_PARAMS_v1 CUDA_HOST_NODE_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS_v1;

/* "cuda/ccuda.pxd":721
 * ctypedef CUDA_HOST_NODE_PARAMS_st CUDA_HOST_NODE_PARAMS_v1
 * 
 * ctypedef CUDA_HOST_NODE_PARAMS_v1 CUDA_HOST_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphNodeType_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_HOST_NODE_PARAMS;

/* "cuda/ccuda.pxd":737
 *     CU_GRAPH_NODE_TYPE_MEM_FREE = 11
 * 
 * ctypedef CUgraphNodeType_enum CUgraphNodeType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUsynchronizationPolicy_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphNodeType_enum __pyx_t_4cuda_5ccuda_CUgraphNodeType;

/* "cuda/ccuda.pxd":745
 *     CU_SYNC_POLICY_BLOCKING_SYNC = 4
 * 
 * ctypedef CUsynchronizationPolicy_enum CUsynchronizationPolicy             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUkernelNodeAttrID_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUsynchronizationPolicy_enum __pyx_t_4cuda_5ccuda_CUsynchronizationPolicy;

/* "cuda/ccuda.pxd":751
 *     CU_KERNEL_NODE_ATTRIBUTE_COOPERATIVE = 2
 * 
 * ctypedef CUkernelNodeAttrID_enum CUkernelNodeAttrID             # <<<<<<<<<<<<<<
 * 
 * cdef union CUkernelNodeAttrValue_union:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUkernelNodeAttrID_enum __pyx_t_4cuda_5ccuda_CUkernelNodeAttrID;

/* "cuda/ccuda.pxd":753
 * ctypedef CUkernelNodeAttrID_enum CUkernelNodeAttrID
 * 
 * cdef union CUkernelNodeAttrValue_union:             # <<<<<<<<<<<<<<
 *     CUaccessPolicyWindow accessPolicyWindow
 *     int cooperative
 */
union __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue_union {
  __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow accessPolicyWindow;
  int cooperative;
};

/* "cuda/ccuda.pxd":757
 *     int cooperative
 * 
 * ctypedef CUkernelNodeAttrValue_union CUkernelNodeAttrValue_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUkernelNodeAttrValue_v1 CUkernelNodeAttrValue
 */
typedef union __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue_union __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue_v1;

/* "cuda/ccuda.pxd":759
 * ctypedef CUkernelNodeAttrValue_union CUkernelNodeAttrValue_v1
 * 
 * ctypedef CUkernelNodeAttrValue_v1 CUkernelNodeAttrValue             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamCaptureStatus_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue_v1 __pyx_t_4cuda_5ccuda_CUkernelNodeAttrValue;

/* "cuda/ccuda.pxd":766
 *     CU_STREAM_CAPTURE_STATUS_INVALIDATED = 2
 * 
 * ctypedef CUstreamCaptureStatus_enum CUstreamCaptureStatus             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamCaptureMode_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamCaptureStatus_enum __pyx_t_4cuda_5ccuda_CUstreamCaptureStatus;

/* "cuda/ccuda.pxd":773
 *     CU_STREAM_CAPTURE_MODE_RELAXED = 2
 * 
 * ctypedef CUstreamCaptureMode_enum CUstreamCaptureMode             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUstreamAttrID_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamCaptureMode_enum __pyx_t_4cuda_5ccuda_CUstreamCaptureMode;

/* "cuda/ccuda.pxd":779
 *     CU_STREAM_ATTRIBUTE_SYNCHRONIZATION_POLICY = 3
 * 
 * ctypedef CUstreamAttrID_enum CUstreamAttrID             # <<<<<<<<<<<<<<
 * 
 * cdef union CUstreamAttrValue_union:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUstreamAttrID_enum __pyx_t_4cuda_5ccuda_CUstreamAttrID;

/* "cuda/ccuda.pxd":781
 * ctypedef CUstreamAttrID_enum CUstreamAttrID
 * 
 * cdef union CUstreamAttrValue_union:             # <<<<<<<<<<<<<<
 *     CUaccessPolicyWindow accessPolicyWindow
 *     CUsynchronizationPolicy syncPolicy
 */
union __pyx_t_4cuda_5ccuda_CUstreamAttrValue_union {
  __pyx_t_4cuda_5ccuda_CUaccessPolicyWindow accessPolicyWindow;
  __pyx_t_4cuda_5ccuda_CUsynchronizationPolicy syncPolicy;
};

/* "cuda/ccuda.pxd":785
 *     CUsynchronizationPolicy syncPolicy
 * 
 * ctypedef CUstreamAttrValue_union CUstreamAttrValue_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUstreamAttrValue_v1 CUstreamAttrValue
 */
typedef union __pyx_t_4cuda_5ccuda_CUstreamAttrValue_union __pyx_t_4cuda_5ccuda_CUstreamAttrValue_v1;

/* "cuda/ccuda.pxd":787
 * ctypedef CUstreamAttrValue_union CUstreamAttrValue_v1
 * 
 * ctypedef CUstreamAttrValue_v1 CUstreamAttrValue             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUdriverProcAddress_flags_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUstreamAttrValue_v1 __pyx_t_4cuda_5ccuda_CUstreamAttrValue;

/* "cuda/ccuda.pxd":794
 *     CU_GET_PROC_ADDRESS_PER_THREAD_DEFAULT_STREAM = 1 << 1
 * 
 * ctypedef CUdriverProcAddress_flags_enum CUdriverProcAddress_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUexecAffinityType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUdriverProcAddress_flags_enum __pyx_t_4cuda_5ccuda_CUdriverProcAddress_flags;

/* "cuda/ccuda.pxd":800
 *     CU_EXEC_AFFINITY_TYPE_MAX
 * 
 * ctypedef CUexecAffinityType_enum CUexecAffinityType             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUexecAffinitySmCount_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUexecAffinityType_enum __pyx_t_4cuda_5ccuda_CUexecAffinityType;

/* "cuda/ccuda.pxd":802
 * ctypedef CUexecAffinityType_enum CUexecAffinityType
 * 
 * cdef struct CUexecAffinitySmCount_st:             # <<<<<<<<<<<<<<
 *     unsigned int val
 * 
 */
struct __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount_st {
  unsigned int val;
};

/* "cuda/ccuda.pxd":805
 *     unsigned int val
 * 
 * ctypedef CUexecAffinitySmCount_st CUexecAffinitySmCount_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUexecAffinitySmCount_v1 CUexecAffinitySmCount
 */
typedef struct __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount_st __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount_v1;

/* "cuda/ccuda.pxd":807
 * ctypedef CUexecAffinitySmCount_st CUexecAffinitySmCount_v1
 * 
 * ctypedef CUexecAffinitySmCount_v1 CUexecAffinitySmCount             # <<<<<<<<<<<<<<
 * 
 * cdef union _CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u:
 */
typedef __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount_v1 __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount;

/* "cuda/ccuda.pxd":809
 * ctypedef CUexecAffinitySmCount_v1 CUexecAffinitySmCount
 * 
 * cdef union _CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u:             # <<<<<<<<<<<<<<
 *     CUexecAffinitySmCount smCount
 * 
 */
union __pyx_t_4cuda_5ccuda__CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u {
  __pyx_t_4cuda_5ccuda_CUexecAffinitySmCount smCount;
};

/* "cuda/ccuda.pxd":812
 *     CUexecAffinitySmCount smCount
 * 
 * cdef struct CUexecAffinityParam_st:             # <<<<<<<<<<<<<<
 *     CUexecAffinityType type
 *     _CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u param
 */
struct __pyx_t_4cuda_5ccuda_CUexecAffinityParam_st {
  __pyx_t_4cuda_5ccuda_CUexecAffinityType type;
  union __pyx_t_4cuda_5ccuda__CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u param;
};

/* "cuda/ccuda.pxd":816
 *     _CUexecAffinityParam_v1_CUexecAffinityParam_v1_CUexecAffinityParam_st_param_u param
 * 
 * ctypedef CUexecAffinityParam_st CUexecAffinityParam_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUexecAffinityParam_v1 CUexecAffinityParam
 */
typedef struct __pyx_t_4cuda_5ccuda_CUexecAffinityParam_st __pyx_t_4cuda_5ccuda_CUexecAffinityParam_v1;

/* "cuda/ccuda.pxd":818
 * ctypedef CUexecAffinityParam_st CUexecAffinityParam_v1
 * 
 * ctypedef CUexecAffinityParam_v1 CUexecAffinityParam             # <<<<<<<<<<<<<<
 * 
 * cdef enum cudaError_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUexecAffinityParam_v1 __pyx_t_4cuda_5ccuda_CUexecAffinityParam;

/* "cuda/ccuda.pxd":909
 *     CUDA_ERROR_UNKNOWN = 999
 * 
 * ctypedef cudaError_enum CUresult             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUdevice_P2PAttribute_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_cudaError_enum __pyx_t_4cuda_5ccuda_CUresult;

/* "cuda/ccuda.pxd":918
 *     CU_DEVICE_P2P_ATTRIBUTE_CUDA_ARRAY_ACCESS_SUPPORTED = 0x04
 * 
 * ctypedef CUdevice_P2PAttribute_enum CUdevice_P2PAttribute             # <<<<<<<<<<<<<<
 * 
 * ctypedef void (*CUstreamCallback)(CUstream hStream, CUresult status, void* userData)
 */
typedef enum __pyx_t_4cuda_5ccuda_CUdevice_P2PAttribute_enum __pyx_t_4cuda_5ccuda_CUdevice_P2PAttribute;

/* "cuda/ccuda.pxd":920
 * ctypedef CUdevice_P2PAttribute_enum CUdevice_P2PAttribute
 * 
 * ctypedef void (*CUstreamCallback)(CUstream hStream, CUresult status, void* userData)             # <<<<<<<<<<<<<<
 * 
 * ctypedef size_t (*CUoccupancyB2DSize)(int blockSize)
 */
typedef void (*__pyx_t_4cuda_5ccuda_CUstreamCallback)(__pyx_t_4cuda_5ccuda_CUstream, __pyx_t_4cuda_5ccuda_CUresult, void *);

/* "cuda/ccuda.pxd":922
 * ctypedef void (*CUstreamCallback)(CUstream hStream, CUresult status, void* userData)
 * 
 * ctypedef size_t (*CUoccupancyB2DSize)(int blockSize)             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_MEMCPY2D_st:
 */
typedef size_t (*__pyx_t_4cuda_5ccuda_CUoccupancyB2DSize)(int);

/* "cuda/ccuda.pxd":924
 * ctypedef size_t (*CUoccupancyB2DSize)(int blockSize)
 * 
 * cdef struct CUDA_MEMCPY2D_st:             # <<<<<<<<<<<<<<
 *     size_t srcXInBytes
 *     size_t srcY
 */
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D_st {
  size_t srcXInBytes;
  size_t srcY;
  __pyx_t_4cuda_5ccuda_CUmemorytype srcMemoryType;
  void const *srcHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr srcDevice;
  __pyx_t_4cuda_5ccuda_CUarray srcArray;
  size_t srcPitch;
  size_t dstXInBytes;
  size_t dstY;
  __pyx_t_4cuda_5ccuda_CUmemorytype dstMemoryType;
  void *dstHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr dstDevice;
  __pyx_t_4cuda_5ccuda_CUarray dstArray;
  size_t dstPitch;
  size_t WidthInBytes;
  size_t Height;
};

/* "cuda/ccuda.pxd":942
 *     size_t Height
 * 
 * ctypedef CUDA_MEMCPY2D_st CUDA_MEMCPY2D_v2             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_MEMCPY2D_v2 CUDA_MEMCPY2D
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D_st __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D_v2;

/* "cuda/ccuda.pxd":944
 * ctypedef CUDA_MEMCPY2D_st CUDA_MEMCPY2D_v2
 * 
 * ctypedef CUDA_MEMCPY2D_v2 CUDA_MEMCPY2D             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_MEMCPY3D_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D_v2 __pyx_t_4cuda_5ccuda_CUDA_MEMCPY2D;

/* "cuda/ccuda.pxd":946
 * ctypedef CUDA_MEMCPY2D_v2 CUDA_MEMCPY2D
 * 
 * cdef struct CUDA_MEMCPY3D_st:             # <<<<<<<<<<<<<<
 *     size_t srcXInBytes
 *     size_t srcY
 */
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_st {
  size_t srcXInBytes;
  size_t srcY;
  size_t srcZ;
  size_t srcLOD;
  __pyx_t_4cuda_5ccuda_CUmemorytype srcMemoryType;
  void const *srcHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr srcDevice;
  __pyx_t_4cuda_5ccuda_CUarray srcArray;
  void *reserved0;
  size_t srcPitch;
  size_t srcHeight;
  size_t dstXInBytes;
  size_t dstY;
  size_t dstZ;
  size_t dstLOD;
  __pyx_t_4cuda_5ccuda_CUmemorytype dstMemoryType;
  void *dstHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr dstDevice;
  __pyx_t_4cuda_5ccuda_CUarray dstArray;
  void *reserved1;
  size_t dstPitch;
  size_t dstHeight;
  size_t WidthInBytes;
  size_t Height;
  size_t Depth;
};

/* "cuda/ccuda.pxd":973
 *     size_t Depth
 * 
 * ctypedef CUDA_MEMCPY3D_st CUDA_MEMCPY3D_v2             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_MEMCPY3D_v2 CUDA_MEMCPY3D
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_st __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_v2;

/* "cuda/ccuda.pxd":975
 * ctypedef CUDA_MEMCPY3D_st CUDA_MEMCPY3D_v2
 * 
 * ctypedef CUDA_MEMCPY3D_v2 CUDA_MEMCPY3D             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_MEMCPY3D_PEER_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_v2 __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D;

/* "cuda/ccuda.pxd":977
 * ctypedef CUDA_MEMCPY3D_v2 CUDA_MEMCPY3D
 * 
 * cdef struct CUDA_MEMCPY3D_PEER_st:             # <<<<<<<<<<<<<<
 *     size_t srcXInBytes
 *     size_t srcY
 */
struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER_st {
  size_t srcXInBytes;
  size_t srcY;
  size_t srcZ;
  size_t srcLOD;
  __pyx_t_4cuda_5ccuda_CUmemorytype srcMemoryType;
  void const *srcHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr srcDevice;
  __pyx_t_4cuda_5ccuda_CUarray srcArray;
  __pyx_t_4cuda_5ccuda_CUcontext srcContext;
  size_t srcPitch;
  size_t srcHeight;
  size_t dstXInBytes;
  size_t dstY;
  size_t dstZ;
  size_t dstLOD;
  __pyx_t_4cuda_5ccuda_CUmemorytype dstMemoryType;
  void *dstHost;
  __pyx_t_4cuda_5ccuda_CUdeviceptr dstDevice;
  __pyx_t_4cuda_5ccuda_CUarray dstArray;
  __pyx_t_4cuda_5ccuda_CUcontext dstContext;
  size_t dstPitch;
  size_t dstHeight;
  size_t WidthInBytes;
  size_t Height;
  size_t Depth;
};

/* "cuda/ccuda.pxd":1004
 *     size_t Depth
 * 
 * ctypedef CUDA_MEMCPY3D_PEER_st CUDA_MEMCPY3D_PEER_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_MEMCPY3D_PEER_v1 CUDA_MEMCPY3D_PEER
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER_st __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER_v1;

/* "cuda/ccuda.pxd":1006
 * ctypedef CUDA_MEMCPY3D_PEER_st CUDA_MEMCPY3D_PEER_v1
 * 
 * ctypedef CUDA_MEMCPY3D_PEER_v1 CUDA_MEMCPY3D_PEER             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_ARRAY_DESCRIPTOR_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER_v1 __pyx_t_4cuda_5ccuda_CUDA_MEMCPY3D_PEER;

/* "cuda/ccuda.pxd":1008
 * ctypedef CUDA_MEMCPY3D_PEER_v1 CUDA_MEMCPY3D_PEER
 * 
 * cdef struct CUDA_ARRAY_DESCRIPTOR_st:             # <<<<<<<<<<<<<<
 *     size_t Width
 *     size_t Height
 */
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR_st {
  size_t Width;
  size_t Height;
  __pyx_t_4cuda_5ccuda_CUarray_format Format;
  unsigned int NumChannels;
};

/* "cuda/ccuda.pxd":1014
 *     unsigned int NumChannels
 * 
 * ctypedef CUDA_ARRAY_DESCRIPTOR_st CUDA_ARRAY_DESCRIPTOR_v2             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_ARRAY_DESCRIPTOR_v2 CUDA_ARRAY_DESCRIPTOR
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR_st __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR_v2;

/* "cuda/ccuda.pxd":1016
 * ctypedef CUDA_ARRAY_DESCRIPTOR_st CUDA_ARRAY_DESCRIPTOR_v2
 * 
 * ctypedef CUDA_ARRAY_DESCRIPTOR_v2 CUDA_ARRAY_DESCRIPTOR             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_ARRAY3D_DESCRIPTOR_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR_v2 __pyx_t_4cuda_5ccuda_CUDA_ARRAY_DESCRIPTOR;

/* "cuda/ccuda.pxd":1018
 * ctypedef CUDA_ARRAY_DESCRIPTOR_v2 CUDA_ARRAY_DESCRIPTOR
 * 
 * cdef struct CUDA_ARRAY3D_DESCRIPTOR_st:             # <<<<<<<<<<<<<<
 *     size_t Width
 *     size_t Height
 */
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR_st {
  size_t Width;
  size_t Height;
  size_t Depth;
  __pyx_t_4cuda_5ccuda_CUarray_format Format;
  unsigned int NumChannels;
  unsigned int Flags;
};

/* "cuda/ccuda.pxd":1026
 *     unsigned int Flags
 * 
 * ctypedef CUDA_ARRAY3D_DESCRIPTOR_st CUDA_ARRAY3D_DESCRIPTOR_v2             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_ARRAY3D_DESCRIPTOR_v2 CUDA_ARRAY3D_DESCRIPTOR
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR_st __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR_v2;

/* "cuda/ccuda.pxd":1028
 * ctypedef CUDA_ARRAY3D_DESCRIPTOR_st CUDA_ARRAY3D_DESCRIPTOR_v2
 * 
 * ctypedef CUDA_ARRAY3D_DESCRIPTOR_v2 CUDA_ARRAY3D_DESCRIPTOR             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR_v2 __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR;

/* "cuda/ccuda.pxd":1030
 * ctypedef CUDA_ARRAY3D_DESCRIPTOR_v2 CUDA_ARRAY3D_DESCRIPTOR
 * 
 * cdef struct _CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s:             # <<<<<<<<<<<<<<
 *     unsigned int width
 *     unsigned int height
 */
struct __pyx_t_4cuda_5ccuda__CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s {
  unsigned int width;
  unsigned int height;
  unsigned int depth;
};

/* "cuda/ccuda.pxd":1035
 *     unsigned int depth
 * 
 * cdef struct CUDA_ARRAY_SPARSE_PROPERTIES_st:             # <<<<<<<<<<<<<<
 *     _CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s tileExtent
 *     unsigned int miptailFirstLevel
 */
struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES_st {
  struct __pyx_t_4cuda_5ccuda__CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_v1_CUDA_ARRAY_SPARSE_PROPERTIES_st_tileExtent_s tileExtent;
  unsigned int miptailFirstLevel;
  unsigned PY_LONG_LONG miptailSize;
  unsigned int flags;
  unsigned int reserved[4];
};

/* "cuda/ccuda.pxd":1042
 *     unsigned int reserved[4]
 * 
 * ctypedef CUDA_ARRAY_SPARSE_PROPERTIES_st CUDA_ARRAY_SPARSE_PROPERTIES_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_ARRAY_SPARSE_PROPERTIES_v1 CUDA_ARRAY_SPARSE_PROPERTIES
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES_st __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES_v1;

/* "cuda/ccuda.pxd":1044
 * ctypedef CUDA_ARRAY_SPARSE_PROPERTIES_st CUDA_ARRAY_SPARSE_PROPERTIES_v1
 * 
 * ctypedef CUDA_ARRAY_SPARSE_PROPERTIES_v1 CUDA_ARRAY_SPARSE_PROPERTIES             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES_v1 __pyx_t_4cuda_5ccuda_CUDA_ARRAY_SPARSE_PROPERTIES;

/* "cuda/ccuda.pxd":1046
 * ctypedef CUDA_ARRAY_SPARSE_PROPERTIES_v1 CUDA_ARRAY_SPARSE_PROPERTIES
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s:             # <<<<<<<<<<<<<<
 *     CUarray hArray
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s {
  __pyx_t_4cuda_5ccuda_CUarray hArray;
};

/* "cuda/ccuda.pxd":1049
 *     CUarray hArray
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_mipmap_s:             # <<<<<<<<<<<<<<
 *     CUmipmappedArray hMipmappedArray
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_mipmap_s {
  __pyx_t_4cuda_5ccuda_CUmipmappedArray hMipmappedArray;
};

/* "cuda/ccuda.pxd":1052
 *     CUmipmappedArray hMipmappedArray
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_linear_s:             # <<<<<<<<<<<<<<
 *     CUdeviceptr devPtr
 *     CUarray_format format
 */
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_linear_s {
  __pyx_t_4cuda_5ccuda_CUdeviceptr devPtr;
  __pyx_t_4cuda_5ccuda_CUarray_format format;
  unsigned int numChannels;
  size_t sizeInBytes;
};

/* "cuda/ccuda.pxd":1058
 *     size_t sizeInBytes
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_pitch2D_s:             # <<<<<<<<<<<<<<
 *     CUdeviceptr devPtr
 *     CUarray_format format
 */
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_pitch2D_s {
  __pyx_t_4cuda_5ccuda_CUdeviceptr devPtr;
  __pyx_t_4cuda_5ccuda_CUarray_format format;
  unsigned int numChannels;
  size_t width;
  size_t height;
  size_t pitchInBytes;
};

/* "cuda/ccuda.pxd":1066
 *     size_t pitchInBytes
 * 
 * cdef struct _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_reserved_s:             # <<<<<<<<<<<<<<
 *     int reserved[32]
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_reserved_s {
  int reserved[32];
};

/* "cuda/ccuda.pxd":1069
 *     int reserved[32]
 * 
 * cdef union _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_u:             # <<<<<<<<<<<<<<
 *     _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s array
 *     _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_mipmap_s mipmap
 */
union __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_u {
  struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_array_s array;
  struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_mipmap_s mipmap;
  struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_linear_s linear;
  struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_pitch2D_s pitch2D;
  struct __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_reserved_s reserved;
};

/* "cuda/ccuda.pxd":1076
 *     _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_res_reserved_s reserved
 * 
 * cdef struct CUDA_RESOURCE_DESC_st:             # <<<<<<<<<<<<<<
 *     CUresourcetype resType
 *     _CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_u res
 */
struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC_st {
  __pyx_t_4cuda_5ccuda_CUresourcetype resType;
  union __pyx_t_4cuda_5ccuda__CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_v1_CUDA_RESOURCE_DESC_st_res_u res;
  unsigned int flags;
};

/* "cuda/ccuda.pxd":1081
 *     unsigned int flags
 * 
 * ctypedef CUDA_RESOURCE_DESC_st CUDA_RESOURCE_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_RESOURCE_DESC_v1 CUDA_RESOURCE_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC_st __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC_v1;

/* "cuda/ccuda.pxd":1083
 * ctypedef CUDA_RESOURCE_DESC_st CUDA_RESOURCE_DESC_v1
 * 
 * ctypedef CUDA_RESOURCE_DESC_v1 CUDA_RESOURCE_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_TEXTURE_DESC_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_DESC;

/* "cuda/ccuda.pxd":1085
 * ctypedef CUDA_RESOURCE_DESC_v1 CUDA_RESOURCE_DESC
 * 
 * cdef struct CUDA_TEXTURE_DESC_st:             # <<<<<<<<<<<<<<
 *     CUaddress_mode addressMode[3]
 *     CUfilter_mode filterMode
 */
struct __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC_st {
  __pyx_t_4cuda_5ccuda_CUaddress_mode addressMode[3];
  __pyx_t_4cuda_5ccuda_CUfilter_mode filterMode;
  unsigned int flags;
  unsigned int maxAnisotropy;
  __pyx_t_4cuda_5ccuda_CUfilter_mode mipmapFilterMode;
  float mipmapLevelBias;
  float minMipmapLevelClamp;
  float maxMipmapLevelClamp;
  float borderColor[4];
  int reserved[12];
};

/* "cuda/ccuda.pxd":1097
 *     int reserved[12]
 * 
 * ctypedef CUDA_TEXTURE_DESC_st CUDA_TEXTURE_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_TEXTURE_DESC_v1 CUDA_TEXTURE_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC_st __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC_v1;

/* "cuda/ccuda.pxd":1099
 * ctypedef CUDA_TEXTURE_DESC_st CUDA_TEXTURE_DESC_v1
 * 
 * ctypedef CUDA_TEXTURE_DESC_v1 CUDA_TEXTURE_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUresourceViewFormat_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_TEXTURE_DESC;

/* "cuda/ccuda.pxd":1138
 *     CU_RES_VIEW_FORMAT_UNSIGNED_BC7 = 0x22
 * 
 * ctypedef CUresourceViewFormat_enum CUresourceViewFormat             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_RESOURCE_VIEW_DESC_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUresourceViewFormat_enum __pyx_t_4cuda_5ccuda_CUresourceViewFormat;

/* "cuda/ccuda.pxd":1140
 * ctypedef CUresourceViewFormat_enum CUresourceViewFormat
 * 
 * cdef struct CUDA_RESOURCE_VIEW_DESC_st:             # <<<<<<<<<<<<<<
 *     CUresourceViewFormat format
 *     size_t width
 */
struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC_st {
  __pyx_t_4cuda_5ccuda_CUresourceViewFormat format;
  size_t width;
  size_t height;
  size_t depth;
  unsigned int firstMipmapLevel;
  unsigned int lastMipmapLevel;
  unsigned int firstLayer;
  unsigned int lastLayer;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1151
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_RESOURCE_VIEW_DESC_st CUDA_RESOURCE_VIEW_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_RESOURCE_VIEW_DESC_v1 CUDA_RESOURCE_VIEW_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC_st __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC_v1;

/* "cuda/ccuda.pxd":1153
 * ctypedef CUDA_RESOURCE_VIEW_DESC_st CUDA_RESOURCE_VIEW_DESC_v1
 * 
 * ctypedef CUDA_RESOURCE_VIEW_DESC_v1 CUDA_RESOURCE_VIEW_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_RESOURCE_VIEW_DESC;

/* "cuda/ccuda.pxd":1155
 * ctypedef CUDA_RESOURCE_VIEW_DESC_v1 CUDA_RESOURCE_VIEW_DESC
 * 
 * cdef struct CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st:             # <<<<<<<<<<<<<<
 *     unsigned long long p2pToken
 *     unsigned int vaSpaceToken
 */
struct __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st {
  unsigned PY_LONG_LONG p2pToken;
  unsigned int vaSpaceToken;
};

/* "cuda/ccuda.pxd":1159
 *     unsigned int vaSpaceToken
 * 
 * ctypedef CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1 CUDA_POINTER_ATTRIBUTE_P2P_TOKENS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1;

/* "cuda/ccuda.pxd":1161
 * ctypedef CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_st CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1
 * 
 * ctypedef CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1 CUDA_POINTER_ATTRIBUTE_P2P_TOKENS             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS_v1 __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_P2P_TOKENS;

/* "cuda/ccuda.pxd":1168
 *     CU_POINTER_ATTRIBUTE_ACCESS_FLAG_READWRITE = 0x3
 * 
 * ctypedef CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_LAUNCH_PARAMS_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum __pyx_t_4cuda_5ccuda_CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS;

/* "cuda/ccuda.pxd":1170
 * ctypedef CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS_enum CUDA_POINTER_ATTRIBUTE_ACCESS_FLAGS
 * 
 * cdef struct CUDA_LAUNCH_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUfunction function
 *     unsigned int gridDimX
 */
struct __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUfunction function;
  unsigned int gridDimX;
  unsigned int gridDimY;
  unsigned int gridDimZ;
  unsigned int blockDimX;
  unsigned int blockDimY;
  unsigned int blockDimZ;
  unsigned int sharedMemBytes;
  __pyx_t_4cuda_5ccuda_CUstream hStream;
  void **kernelParams;
};

/* "cuda/ccuda.pxd":1182
 *     void** kernelParams
 * 
 * ctypedef CUDA_LAUNCH_PARAMS_st CUDA_LAUNCH_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_LAUNCH_PARAMS_v1 CUDA_LAUNCH_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS_v1;

/* "cuda/ccuda.pxd":1184
 * ctypedef CUDA_LAUNCH_PARAMS_st CUDA_LAUNCH_PARAMS_v1
 * 
 * ctypedef CUDA_LAUNCH_PARAMS_v1 CUDA_LAUNCH_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUexternalMemoryHandleType_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_LAUNCH_PARAMS;

/* "cuda/ccuda.pxd":1196
 *     CU_EXTERNAL_MEMORY_HANDLE_TYPE_NVSCIBUF = 8
 * 
 * ctypedef CUexternalMemoryHandleType_enum CUexternalMemoryHandleType             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUexternalMemoryHandleType_enum __pyx_t_4cuda_5ccuda_CUexternalMemoryHandleType;

/* "cuda/ccuda.pxd":1198
 * ctypedef CUexternalMemoryHandleType_enum CUexternalMemoryHandleType
 * 
 * cdef struct _CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s:             # <<<<<<<<<<<<<<
 *     void* handle
 *     void* name
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s {
  void *handle;
  void *name;
};

/* "cuda/ccuda.pxd":1202
 *     void* name
 * 
 * cdef union _CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_u:             # <<<<<<<<<<<<<<
 *     int fd
 *     _CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s win32
 */
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_u {
  int fd;
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_handle_win32_s win32;
  void *nvSciBufObject;
};

/* "cuda/ccuda.pxd":1207
 *     void* nvSciBufObject
 * 
 * cdef struct CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st:             # <<<<<<<<<<<<<<
 *     CUexternalMemoryHandleType type
 *     _CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_u handle
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st {
  __pyx_t_4cuda_5ccuda_CUexternalMemoryHandleType type;
  union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st_handle_u handle;
  unsigned PY_LONG_LONG size;
  unsigned int flags;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1214
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1 CUDA_EXTERNAL_MEMORY_HANDLE_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1;

/* "cuda/ccuda.pxd":1216
 * ctypedef CUDA_EXTERNAL_MEMORY_HANDLE_DESC_st CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1 CUDA_EXTERNAL_MEMORY_HANDLE_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_HANDLE_DESC;

/* "cuda/ccuda.pxd":1218
 * ctypedef CUDA_EXTERNAL_MEMORY_HANDLE_DESC_v1 CUDA_EXTERNAL_MEMORY_HANDLE_DESC
 * 
 * cdef struct CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st:             # <<<<<<<<<<<<<<
 *     unsigned long long offset
 *     unsigned long long size
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st {
  unsigned PY_LONG_LONG offset;
  unsigned PY_LONG_LONG size;
  unsigned int flags;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1224
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1 CUDA_EXTERNAL_MEMORY_BUFFER_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1;

/* "cuda/ccuda.pxd":1226
 * ctypedef CUDA_EXTERNAL_MEMORY_BUFFER_DESC_st CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1 CUDA_EXTERNAL_MEMORY_BUFFER_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_BUFFER_DESC;

/* "cuda/ccuda.pxd":1228
 * ctypedef CUDA_EXTERNAL_MEMORY_BUFFER_DESC_v1 CUDA_EXTERNAL_MEMORY_BUFFER_DESC
 * 
 * cdef struct CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st:             # <<<<<<<<<<<<<<
 *     unsigned long long offset
 *     CUDA_ARRAY3D_DESCRIPTOR arrayDesc
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st {
  unsigned PY_LONG_LONG offset;
  __pyx_t_4cuda_5ccuda_CUDA_ARRAY3D_DESCRIPTOR arrayDesc;
  unsigned int numLevels;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1234
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1 CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1;

/* "cuda/ccuda.pxd":1236
 * ctypedef CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_st CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1
 * 
 * ctypedef CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1 CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUexternalSemaphoreHandleType_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC;

/* "cuda/ccuda.pxd":1250
 *     CU_EXTERNAL_SEMAPHORE_HANDLE_TYPE_TIMELINE_SEMAPHORE_WIN32 = 10
 * 
 * ctypedef CUexternalSemaphoreHandleType_enum CUexternalSemaphoreHandleType             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUexternalSemaphoreHandleType_enum __pyx_t_4cuda_5ccuda_CUexternalSemaphoreHandleType;

/* "cuda/ccuda.pxd":1252
 * ctypedef CUexternalSemaphoreHandleType_enum CUexternalSemaphoreHandleType
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s:             # <<<<<<<<<<<<<<
 *     void* handle
 *     void* name
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s {
  void *handle;
  void *name;
};

/* "cuda/ccuda.pxd":1256
 *     void* name
 * 
 * cdef union _CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_u:             # <<<<<<<<<<<<<<
 *     int fd
 *     _CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s win32
 */
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_u {
  int fd;
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_handle_win32_s win32;
  void *nvSciSyncObj;
};

/* "cuda/ccuda.pxd":1261
 *     void* nvSciSyncObj
 * 
 * cdef struct CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st:             # <<<<<<<<<<<<<<
 *     CUexternalSemaphoreHandleType type
 *     _CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_u handle
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st {
  __pyx_t_4cuda_5ccuda_CUexternalSemaphoreHandleType type;
  union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st_handle_u handle;
  unsigned int flags;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1267
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1 CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1;

/* "cuda/ccuda.pxd":1269
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_st CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1 CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC;

/* "cuda/ccuda.pxd":1271
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC_v1 CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s:             # <<<<<<<<<<<<<<
 *     unsigned long long value
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s {
  unsigned PY_LONG_LONG value;
};

/* "cuda/ccuda.pxd":1274
 *     unsigned long long value
 * 
 * cdef union _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_nvSciSync_u:             # <<<<<<<<<<<<<<
 *     void* fence
 *     unsigned long long reserved
 */
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_nvSciSync_u {
  void *fence;
  unsigned PY_LONG_LONG reserved;
};

/* "cuda/ccuda.pxd":1278
 *     unsigned long long reserved
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_keyedMutex_s:             # <<<<<<<<<<<<<<
 *     unsigned long long key
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_keyedMutex_s {
  unsigned PY_LONG_LONG key;
};

/* "cuda/ccuda.pxd":1281
 *     unsigned long long key
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_s:             # <<<<<<<<<<<<<<
 *     _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s fence
 *     _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_nvSciSync_u nvSciSync
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_s {
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_fence_s fence;
  union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_nvSciSync_u nvSciSync;
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_params_keyedMutex_s keyedMutex;
  unsigned int reserved[12];
};

/* "cuda/ccuda.pxd":1287
 *     unsigned int reserved[12]
 * 
 * cdef struct CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st:             # <<<<<<<<<<<<<<
 *     _CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_s params
 *     unsigned int flags
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st {
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st_params_s params;
  unsigned int flags;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1292
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1;

/* "cuda/ccuda.pxd":1294
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_st CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS;

/* "cuda/ccuda.pxd":1296
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s:             # <<<<<<<<<<<<<<
 *     unsigned long long value
 * 
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s {
  unsigned PY_LONG_LONG value;
};

/* "cuda/ccuda.pxd":1299
 *     unsigned long long value
 * 
 * cdef union _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_nvSciSync_u:             # <<<<<<<<<<<<<<
 *     void* fence
 *     unsigned long long reserved
 */
union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_nvSciSync_u {
  void *fence;
  unsigned PY_LONG_LONG reserved;
};

/* "cuda/ccuda.pxd":1303
 *     unsigned long long reserved
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_keyedMutex_s:             # <<<<<<<<<<<<<<
 *     unsigned long long key
 *     unsigned int timeoutMs
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_keyedMutex_s {
  unsigned PY_LONG_LONG key;
  unsigned int timeoutMs;
};

/* "cuda/ccuda.pxd":1307
 *     unsigned int timeoutMs
 * 
 * cdef struct _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_s:             # <<<<<<<<<<<<<<
 *     _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s fence
 *     _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_nvSciSync_u nvSciSync
 */
struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_s {
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_fence_s fence;
  union __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_nvSciSync_u nvSciSync;
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_params_keyedMutex_s keyedMutex;
  unsigned int reserved[10];
};

/* "cuda/ccuda.pxd":1313
 *     unsigned int reserved[10]
 * 
 * cdef struct CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st:             # <<<<<<<<<<<<<<
 *     _CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_s params
 *     unsigned int flags
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st {
  struct __pyx_t_4cuda_5ccuda__CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st_params_s params;
  unsigned int flags;
  unsigned int reserved[16];
};

/* "cuda/ccuda.pxd":1318
 *     unsigned int reserved[16]
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1;

/* "cuda/ccuda.pxd":1320
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_st CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1
 * 
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS;

/* "cuda/ccuda.pxd":1322
 * ctypedef CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS_v1 CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS
 * 
 * cdef struct CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUexternalSemaphore* extSemArray
 *     const CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS* paramsArray
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUexternalSemaphore *extSemArray;
  __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS const *paramsArray;
  unsigned int numExtSems;
};

/* "cuda/ccuda.pxd":1327
 *     unsigned int numExtSems
 * 
 * ctypedef CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1 CUDA_EXT_SEM_SIGNAL_NODE_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1;

/* "cuda/ccuda.pxd":1329
 * ctypedef CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_st CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1
 * 
 * ctypedef CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1 CUDA_EXT_SEM_SIGNAL_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_EXT_SEM_WAIT_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_SIGNAL_NODE_PARAMS;

/* "cuda/ccuda.pxd":1331
 * ctypedef CUDA_EXT_SEM_SIGNAL_NODE_PARAMS_v1 CUDA_EXT_SEM_SIGNAL_NODE_PARAMS
 * 
 * cdef struct CUDA_EXT_SEM_WAIT_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUexternalSemaphore* extSemArray
 *     const CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS* paramsArray
 */
struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUexternalSemaphore *extSemArray;
  __pyx_t_4cuda_5ccuda_CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS const *paramsArray;
  unsigned int numExtSems;
};

/* "cuda/ccuda.pxd":1336
 *     unsigned int numExtSems
 * 
 * ctypedef CUDA_EXT_SEM_WAIT_NODE_PARAMS_st CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1 CUDA_EXT_SEM_WAIT_NODE_PARAMS
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1;

/* "cuda/ccuda.pxd":1338
 * ctypedef CUDA_EXT_SEM_WAIT_NODE_PARAMS_st CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1
 * 
 * ctypedef CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1 CUDA_EXT_SEM_WAIT_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * ctypedef unsigned long long CUmemGenericAllocationHandle_v1
 */
typedef __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS_v1 __pyx_t_4cuda_5ccuda_CUDA_EXT_SEM_WAIT_NODE_PARAMS;

/* "cuda/ccuda.pxd":1351
 *     CU_MEM_HANDLE_TYPE_MAX = 0x7FFFFFFF
 * 
 * ctypedef CUmemAllocationHandleType_enum CUmemAllocationHandleType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAccess_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAllocationHandleType_enum __pyx_t_4cuda_5ccuda_CUmemAllocationHandleType;

/* "cuda/ccuda.pxd":1359
 *     CU_MEM_ACCESS_FLAGS_PROT_MAX = 0x7FFFFFFF
 * 
 * ctypedef CUmemAccess_flags_enum CUmemAccess_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemLocationType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAccess_flags_enum __pyx_t_4cuda_5ccuda_CUmemAccess_flags;

/* "cuda/ccuda.pxd":1366
 *     CU_MEM_LOCATION_TYPE_MAX = 0x7FFFFFFF
 * 
 * ctypedef CUmemLocationType_enum CUmemLocationType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAllocationType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemLocationType_enum __pyx_t_4cuda_5ccuda_CUmemLocationType;

/* "cuda/ccuda.pxd":1373
 *     CU_MEM_ALLOCATION_TYPE_MAX = 0x7FFFFFFF
 * 
 * ctypedef CUmemAllocationType_enum CUmemAllocationType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAllocationGranularity_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAllocationType_enum __pyx_t_4cuda_5ccuda_CUmemAllocationType;

/* "cuda/ccuda.pxd":1379
 *     CU_MEM_ALLOC_GRANULARITY_RECOMMENDED = 0x1
 * 
 * ctypedef CUmemAllocationGranularity_flags_enum CUmemAllocationGranularity_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUarraySparseSubresourceType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAllocationGranularity_flags_enum __pyx_t_4cuda_5ccuda_CUmemAllocationGranularity_flags;

/* "cuda/ccuda.pxd":1385
 *     CU_ARRAY_SPARSE_SUBRESOURCE_TYPE_MIPTAIL = 1
 * 
 * ctypedef CUarraySparseSubresourceType_enum CUarraySparseSubresourceType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemOperationType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUarraySparseSubresourceType_enum __pyx_t_4cuda_5ccuda_CUarraySparseSubresourceType;

/* "cuda/ccuda.pxd":1391
 *     CU_MEM_OPERATION_TYPE_UNMAP = 2
 * 
 * ctypedef CUmemOperationType_enum CUmemOperationType             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemHandleType_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemOperationType_enum __pyx_t_4cuda_5ccuda_CUmemOperationType;

/* "cuda/ccuda.pxd":1396
 *     CU_MEM_HANDLE_TYPE_GENERIC = 0
 * 
 * ctypedef CUmemHandleType_enum CUmemHandleType             # <<<<<<<<<<<<<<
 * 
 * cdef union _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemHandleType_enum __pyx_t_4cuda_5ccuda_CUmemHandleType;

/* "cuda/ccuda.pxd":1398
 * ctypedef CUmemHandleType_enum CUmemHandleType
 * 
 * cdef union _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u:             # <<<<<<<<<<<<<<
 *     CUmipmappedArray mipmap
 *     CUarray array
 */
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u {
  __pyx_t_4cuda_5ccuda_CUmipmappedArray mipmap;
  __pyx_t_4cuda_5ccuda_CUarray array;
};

/* "cuda/ccuda.pxd":1402
 *     CUarray array
 * 
 * cdef struct _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_sparseLevel_s:             # <<<<<<<<<<<<<<
 *     unsigned int level
 *     unsigned int layer
 */
struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_sparseLevel_s {
  unsigned int level;
  unsigned int layer;
  unsigned int offsetX;
  unsigned int offsetY;
  unsigned int offsetZ;
  unsigned int extentWidth;
  unsigned int extentHeight;
  unsigned int extentDepth;
};

/* "cuda/ccuda.pxd":1412
 *     unsigned int extentDepth
 * 
 * cdef struct _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s:             # <<<<<<<<<<<<<<
 *     unsigned int layer
 *     unsigned long long offset
 */
struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s {
  unsigned int layer;
  unsigned PY_LONG_LONG offset;
  unsigned PY_LONG_LONG size;
};

/* "cuda/ccuda.pxd":1417
 *     unsigned long long size
 * 
 * cdef union _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_u:             # <<<<<<<<<<<<<<
 *     _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_sparseLevel_s sparseLevel
 *     _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s miptail
 */
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_u {
  struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_sparseLevel_s sparseLevel;
  struct __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s miptail;
};

/* "cuda/ccuda.pxd":1421
 *     _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_subresource_miptail_s miptail
 * 
 * cdef union _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_memHandle_u:             # <<<<<<<<<<<<<<
 *     CUmemGenericAllocationHandle memHandle
 * 
 */
union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_memHandle_u {
  __pyx_t_4cuda_5ccuda_CUmemGenericAllocationHandle memHandle;
};

/* "cuda/ccuda.pxd":1424
 *     CUmemGenericAllocationHandle memHandle
 * 
 * cdef struct CUarrayMapInfo_st:             # <<<<<<<<<<<<<<
 *     CUresourcetype resourceType
 *     _CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u resource
 */
struct __pyx_t_4cuda_5ccuda_CUarrayMapInfo_st {
  __pyx_t_4cuda_5ccuda_CUresourcetype resourceType;
  union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_resource_u resource;
  __pyx_t_4cuda_5ccuda_CUarraySparseSubresourceType subresourceType;
  union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_subresource_u subresource;
  __pyx_t_4cuda_5ccuda_CUmemOperationType memOperationType;
  __pyx_t_4cuda_5ccuda_CUmemHandleType memHandleType;
  union __pyx_t_4cuda_5ccuda__CUarrayMapInfo_v1_CUarrayMapInfo_v1_CUarrayMapInfo_st_memHandle_u memHandle;
  unsigned PY_LONG_LONG offset;
  unsigned int deviceBitMask;
  unsigned int flags;
  unsigned int reserved[2];
};

/* "cuda/ccuda.pxd":1437
 *     unsigned int reserved[2]
 * 
 * ctypedef CUarrayMapInfo_st CUarrayMapInfo_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUarrayMapInfo_v1 CUarrayMapInfo
 */
typedef struct __pyx_t_4cuda_5ccuda_CUarrayMapInfo_st __pyx_t_4cuda_5ccuda_CUarrayMapInfo_v1;

/* "cuda/ccuda.pxd":1439
 * ctypedef CUarrayMapInfo_st CUarrayMapInfo_v1
 * 
 * ctypedef CUarrayMapInfo_v1 CUarrayMapInfo             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUmemLocation_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUarrayMapInfo_v1 __pyx_t_4cuda_5ccuda_CUarrayMapInfo;

/* "cuda/ccuda.pxd":1441
 * ctypedef CUarrayMapInfo_v1 CUarrayMapInfo
 * 
 * cdef struct CUmemLocation_st:             # <<<<<<<<<<<<<<
 *     CUmemLocationType type
 *     int id
 */
struct __pyx_t_4cuda_5ccuda_CUmemLocation_st {
  __pyx_t_4cuda_5ccuda_CUmemLocationType type;
  int id;
};

/* "cuda/ccuda.pxd":1445
 *     int id
 * 
 * ctypedef CUmemLocation_st CUmemLocation_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemLocation_v1 CUmemLocation
 */
typedef struct __pyx_t_4cuda_5ccuda_CUmemLocation_st __pyx_t_4cuda_5ccuda_CUmemLocation_v1;

/* "cuda/ccuda.pxd":1447
 * ctypedef CUmemLocation_st CUmemLocation_v1
 * 
 * ctypedef CUmemLocation_v1 CUmemLocation             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemAllocationCompType_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemLocation_v1 __pyx_t_4cuda_5ccuda_CUmemLocation;

/* "cuda/ccuda.pxd":1453
 *     CU_MEM_ALLOCATION_COMP_GENERIC = 0x1
 * 
 * ctypedef CUmemAllocationCompType_enum CUmemAllocationCompType             # <<<<<<<<<<<<<<
 * 
 * cdef struct _CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemAllocationCompType_enum __pyx_t_4cuda_5ccuda_CUmemAllocationCompType;

/* "cuda/ccuda.pxd":1455
 * ctypedef CUmemAllocationCompType_enum CUmemAllocationCompType
 * 
 * cdef struct _CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s:             # <<<<<<<<<<<<<<
 *     unsigned char compressionType
 *     unsigned char gpuDirectRDMACapable
 */
struct __pyx_t_4cuda_5ccuda__CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s {
  unsigned char compressionType;
  unsigned char gpuDirectRDMACapable;
  unsigned short usage;
  unsigned char reserved[4];
};

/* "cuda/ccuda.pxd":1461
 *     unsigned char reserved[4]
 * 
 * cdef struct CUmemAllocationProp_st:             # <<<<<<<<<<<<<<
 *     CUmemAllocationType type
 *     CUmemAllocationHandleType requestedHandleTypes
 */
struct __pyx_t_4cuda_5ccuda_CUmemAllocationProp_st {
  __pyx_t_4cuda_5ccuda_CUmemAllocationType type;
  __pyx_t_4cuda_5ccuda_CUmemAllocationHandleType requestedHandleTypes;
  __pyx_t_4cuda_5ccuda_CUmemLocation location;
  void *win32HandleMetaData;
  struct __pyx_t_4cuda_5ccuda__CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s allocFlags;
};

/* "cuda/ccuda.pxd":1468
 *     _CUmemAllocationProp_v1_CUmemAllocationProp_v1_CUmemAllocationProp_st_allocFlags_s allocFlags
 * 
 * ctypedef CUmemAllocationProp_st CUmemAllocationProp_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemAllocationProp_v1 CUmemAllocationProp
 */
typedef struct __pyx_t_4cuda_5ccuda_CUmemAllocationProp_st __pyx_t_4cuda_5ccuda_CUmemAllocationProp_v1;

/* "cuda/ccuda.pxd":1470
 * ctypedef CUmemAllocationProp_st CUmemAllocationProp_v1
 * 
 * ctypedef CUmemAllocationProp_v1 CUmemAllocationProp             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUmemAccessDesc_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemAllocationProp_v1 __pyx_t_4cuda_5ccuda_CUmemAllocationProp;

/* "cuda/ccuda.pxd":1472
 * ctypedef CUmemAllocationProp_v1 CUmemAllocationProp
 * 
 * cdef struct CUmemAccessDesc_st:             # <<<<<<<<<<<<<<
 *     CUmemLocation location
 *     CUmemAccess_flags flags
 */
struct __pyx_t_4cuda_5ccuda_CUmemAccessDesc_st {
  __pyx_t_4cuda_5ccuda_CUmemLocation location;
  __pyx_t_4cuda_5ccuda_CUmemAccess_flags flags;
};

/* "cuda/ccuda.pxd":1476
 *     CUmemAccess_flags flags
 * 
 * ctypedef CUmemAccessDesc_st CUmemAccessDesc_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemAccessDesc_v1 CUmemAccessDesc
 */
typedef struct __pyx_t_4cuda_5ccuda_CUmemAccessDesc_st __pyx_t_4cuda_5ccuda_CUmemAccessDesc_v1;

/* "cuda/ccuda.pxd":1478
 * ctypedef CUmemAccessDesc_st CUmemAccessDesc_v1
 * 
 * ctypedef CUmemAccessDesc_v1 CUmemAccessDesc             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphExecUpdateResult_enum:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemAccessDesc_v1 __pyx_t_4cuda_5ccuda_CUmemAccessDesc;

/* "cuda/ccuda.pxd":1490
 *     CU_GRAPH_EXEC_UPDATE_ERROR_UNSUPPORTED_FUNCTION_CHANGE = 0x7
 * 
 * ctypedef CUgraphExecUpdateResult_enum CUgraphExecUpdateResult             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUmemPool_attribute_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphExecUpdateResult_enum __pyx_t_4cuda_5ccuda_CUgraphExecUpdateResult;

/* "cuda/ccuda.pxd":1502
 *     CU_MEMPOOL_ATTR_USED_MEM_HIGH
 * 
 * ctypedef CUmemPool_attribute_enum CUmemPool_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUmemPoolProps_st:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUmemPool_attribute_enum __pyx_t_4cuda_5ccuda_CUmemPool_attribute;

/* "cuda/ccuda.pxd":1504
 * ctypedef CUmemPool_attribute_enum CUmemPool_attribute
 * 
 * cdef struct CUmemPoolProps_st:             # <<<<<<<<<<<<<<
 *     CUmemAllocationType allocType
 *     CUmemAllocationHandleType handleTypes
 */
struct __pyx_t_4cuda_5ccuda_CUmemPoolProps_st {
  __pyx_t_4cuda_5ccuda_CUmemAllocationType allocType;
  __pyx_t_4cuda_5ccuda_CUmemAllocationHandleType handleTypes;
  __pyx_t_4cuda_5ccuda_CUmemLocation location;
  void *win32SecurityAttributes;
  unsigned char reserved[64];
};

/* "cuda/ccuda.pxd":1511
 *     unsigned char reserved[64]
 * 
 * ctypedef CUmemPoolProps_st CUmemPoolProps_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemPoolProps_v1 CUmemPoolProps
 */
typedef struct __pyx_t_4cuda_5ccuda_CUmemPoolProps_st __pyx_t_4cuda_5ccuda_CUmemPoolProps_v1;

/* "cuda/ccuda.pxd":1513
 * ctypedef CUmemPoolProps_st CUmemPoolProps_v1
 * 
 * ctypedef CUmemPoolProps_v1 CUmemPoolProps             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUmemPoolPtrExportData_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemPoolProps_v1 __pyx_t_4cuda_5ccuda_CUmemPoolProps;

/* "cuda/ccuda.pxd":1515
 * ctypedef CUmemPoolProps_v1 CUmemPoolProps
 * 
 * cdef struct CUmemPoolPtrExportData_st:             # <<<<<<<<<<<<<<
 *     unsigned char reserved[64]
 * 
 */
struct __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData_st {
  unsigned char reserved[64];
};

/* "cuda/ccuda.pxd":1518
 *     unsigned char reserved[64]
 * 
 * ctypedef CUmemPoolPtrExportData_st CUmemPoolPtrExportData_v1             # <<<<<<<<<<<<<<
 * 
 * ctypedef CUmemPoolPtrExportData_v1 CUmemPoolPtrExportData
 */
typedef struct __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData_st __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData_v1;

/* "cuda/ccuda.pxd":1520
 * ctypedef CUmemPoolPtrExportData_st CUmemPoolPtrExportData_v1
 * 
 * ctypedef CUmemPoolPtrExportData_v1 CUmemPoolPtrExportData             # <<<<<<<<<<<<<<
 * 
 * cdef struct CUDA_MEM_ALLOC_NODE_PARAMS_st:
 */
typedef __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData_v1 __pyx_t_4cuda_5ccuda_CUmemPoolPtrExportData;

/* "cuda/ccuda.pxd":1522
 * ctypedef CUmemPoolPtrExportData_v1 CUmemPoolPtrExportData
 * 
 * cdef struct CUDA_MEM_ALLOC_NODE_PARAMS_st:             # <<<<<<<<<<<<<<
 *     CUmemPoolProps poolProps
 *     const CUmemAccessDesc* accessDescs
 */
struct __pyx_t_4cuda_5ccuda_CUDA_MEM_ALLOC_NODE_PARAMS_st {
  __pyx_t_4cuda_5ccuda_CUmemPoolProps poolProps;
  __pyx_t_4cuda_5ccuda_CUmemAccessDesc const *accessDescs;
  size_t accessDescCount;
  size_t bytesize;
  __pyx_t_4cuda_5ccuda_CUdeviceptr dptr;
};

/* "cuda/ccuda.pxd":1529
 *     CUdeviceptr dptr
 * 
 * ctypedef CUDA_MEM_ALLOC_NODE_PARAMS_st CUDA_MEM_ALLOC_NODE_PARAMS             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphMem_attribute_enum:
 */
typedef struct __pyx_t_4cuda_5ccuda_CUDA_MEM_ALLOC_NODE_PARAMS_st __pyx_t_4cuda_5ccuda_CUDA_MEM_ALLOC_NODE_PARAMS;

/* "cuda/ccuda.pxd":1537
 *     CU_GRAPH_MEM_ATTR_RESERVED_MEM_HIGH
 * 
 * ctypedef CUgraphMem_attribute_enum CUgraphMem_attribute             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUflushGPUDirectRDMAWritesOptions_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphMem_attribute_enum __pyx_t_4cuda_5ccuda_CUgraphMem_attribute;

/* "cuda/ccuda.pxd":1543
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_OPTION_MEMOPS = 1<<1
 * 
 * ctypedef CUflushGPUDirectRDMAWritesOptions_enum CUflushGPUDirectRDMAWritesOptions             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUGPUDirectRDMAWritesOrdering_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesOptions_enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesOptions;

/* "cuda/ccuda.pxd":1550
 *     CU_GPU_DIRECT_RDMA_WRITES_ORDERING_ALL_DEVICES = 200
 * 
 * ctypedef CUGPUDirectRDMAWritesOrdering_enum CUGPUDirectRDMAWritesOrdering             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUflushGPUDirectRDMAWritesScope_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUGPUDirectRDMAWritesOrdering_enum __pyx_t_4cuda_5ccuda_CUGPUDirectRDMAWritesOrdering;

/* "cuda/ccuda.pxd":1556
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TO_ALL_DEVICES = 200
 * 
 * ctypedef CUflushGPUDirectRDMAWritesScope_enum CUflushGPUDirectRDMAWritesScope             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUflushGPUDirectRDMAWritesTarget_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesScope_enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesScope;

/* "cuda/ccuda.pxd":1561
 *     CU_FLUSH_GPU_DIRECT_RDMA_WRITES_TARGET_CURRENT_CTX = 0
 * 
 * ctypedef CUflushGPUDirectRDMAWritesTarget_enum CUflushGPUDirectRDMAWritesTarget             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphDebugDot_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesTarget_enum __pyx_t_4cuda_5ccuda_CUflushGPUDirectRDMAWritesTarget;

/* "cuda/ccuda.pxd":1578
 *     CU_GRAPH_DEBUG_DOT_FLAGS_MEM_FREE_NODE_PARAMS = 1<<12
 * 
 * ctypedef CUgraphDebugDot_flags_enum CUgraphDebugDot_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUuserObject_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphDebugDot_flags_enum __pyx_t_4cuda_5ccuda_CUgraphDebugDot_flags;

/* "cuda/ccuda.pxd":1583
 *     CU_USER_OBJECT_NO_DESTRUCTOR_SYNC = 1
 * 
 * ctypedef CUuserObject_flags_enum CUuserObject_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUuserObjectRetain_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUuserObject_flags_enum __pyx_t_4cuda_5ccuda_CUuserObject_flags;

/* "cuda/ccuda.pxd":1588
 *     CU_GRAPH_USER_OBJECT_MOVE = 1
 * 
 * ctypedef CUuserObjectRetain_flags_enum CUuserObjectRetain_flags             # <<<<<<<<<<<<<<
 * 
 * cdef enum CUgraphInstantiate_flags_enum:
 */
typedef enum __pyx_t_4cuda_5ccuda_CUuserObjectRetain_flags_enum __pyx_t_4cuda_5ccuda_CUuserObjectRetain_flags;

/* "cuda/ccuda.pxd":1593
 *     CUDA_GRAPH_INSTANTIATE_FLAG_AUTO_FREE_ON_LAUNCH = 1
 * 
 * ctypedef CUgraphInstantiate_flags_enum CUgraphInstantiate_flags             # <<<<<<<<<<<<<<
 * 
 * cdef CUresult cuGetErrorString(CUresult error, const char** pStr) nogil except ?CUDA_ERROR_NOT_FOUND
 */
typedef enum __pyx_t_4cuda_5ccuda_CUgraphInstantiate_flags_enum __pyx_t_4cuda_5ccuda_CUgraphInstantiate_flags;

/* --- Runtime support code (head) --- */
/* Refnanny.proto */
#ifndef CYTHON_REFNANNY
  #define CYTHON_REFNANNY 0
#endif
#if CYTHON_REFNANNY
  typedef struct {
    void (*INCREF)(void*, PyObject*, int);
    void (*DECREF)(void*, PyObject*, int);
    void (*GOTREF)(void*, PyObject*, int);
    void (*GIVEREF)(void*, PyObject*, int);
    void* (*SetupContext)(const char*, int, const char*);
    void (*FinishContext)(void**);
  } __Pyx_RefNannyAPIStruct;
  static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
  static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname);
  #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
#ifdef WITH_THREAD
  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
          if (acquire_gil) {\
              PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
              __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
              PyGILState_Release(__pyx_gilstate_save);\
          } else {\
              __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
          }
#else
  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
          __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
#endif
  #define __Pyx_RefNannyFinishContext()\
          __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
  #define __Pyx_INCREF(r)  __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_DECREF(r)  __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_GOTREF(r)  __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_XINCREF(r)  do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
  #define __Pyx_XDECREF(r)  do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
  #define __Pyx_XGOTREF(r)  do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
  #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
#else
  #define __Pyx_RefNannyDeclarations
  #define __Pyx_RefNannySetupContext(name, acquire_gil)
  #define __Pyx_RefNannyFinishContext()
  #define __Pyx_INCREF(r) Py_INCREF(r)
  #define __Pyx_DECREF(r) Py_DECREF(r)
  #define __Pyx_GOTREF(r)
  #define __Pyx_GIVEREF(r)
  #define __Pyx_XINCREF(r) Py_XINCREF(r)
  #define __Pyx_XDECREF(r) Py_XDECREF(r)
  #define __Pyx_XGOTREF(r)
  #define __Pyx_XGIVEREF(r)
#endif
#define __Pyx_XDECREF_SET(r, v) do {\
        PyObject *tmp = (PyObject *) r;\
        r = v; __Pyx_XDECREF(tmp);\
    } while (0)
#define __Pyx_DECREF_SET(r, v) do {\
        PyObject *tmp = (PyObject *) r;\
        r = v; __Pyx_DECREF(tmp);\
    } while (0)
#define __Pyx_CLEAR(r)    do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
#define __Pyx_XCLEAR(r)   do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)

/* PyThreadStateGet.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_PyThreadState_declare  PyThreadState *__pyx_tstate;
#define __Pyx_PyThreadState_assign  __pyx_tstate = __Pyx_PyThreadState_Current;
#define __Pyx_PyErr_Occurred()  __pyx_tstate->curexc_type
#else
#define __Pyx_PyThreadState_declare
#define __Pyx_PyThreadState_assign
#define __Pyx_PyErr_Occurred()  PyErr_Occurred()
#endif

/* PyErrFetchRestore.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
#define __Pyx_ErrRestoreWithState(type, value, tb)  __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
#define __Pyx_ErrFetchWithState(type, value, tb)    __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
#define __Pyx_ErrRestore(type, value, tb)  __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
#define __Pyx_ErrFetch(type, value, tb)    __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
#if CYTHON_COMPILING_IN_CPYTHON
#define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
#else
#define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
#endif
#else
#define __Pyx_PyErr_Clear() PyErr_Clear()
#define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
#define __Pyx_ErrRestoreWithState(type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetchWithState(type, value, tb)  PyErr_Fetch(type, value, tb)
#define __Pyx_ErrRestoreInState(tstate, type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetchInState(tstate, type, value, tb)  PyErr_Fetch(type, value, tb)
#define __Pyx_ErrRestore(type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetch(type, value, tb)  PyErr_Fetch(type, value, tb)
#endif

/* Profile.proto */
#ifndef CYTHON_PROFILE
#if CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_PYSTON
  #define CYTHON_PROFILE 0
#else
  #define CYTHON_PROFILE 1
#endif
#endif
#ifndef CYTHON_TRACE_NOGIL
  #define CYTHON_TRACE_NOGIL 0
#else
  #if CYTHON_TRACE_NOGIL && !defined(CYTHON_TRACE)
    #define CYTHON_TRACE 1
  #endif
#endif
#ifndef CYTHON_TRACE
  #define CYTHON_TRACE 0
#endif
#if CYTHON_TRACE
  #undef CYTHON_PROFILE_REUSE_FRAME
#endif
#ifndef CYTHON_PROFILE_REUSE_FRAME
  #define CYTHON_PROFILE_REUSE_FRAME 0
#endif
#if CYTHON_PROFILE || CYTHON_TRACE
  #include "compile.h"
  #include "frameobject.h"
  #include "traceback.h"
  #if CYTHON_PROFILE_REUSE_FRAME
    #define CYTHON_FRAME_MODIFIER static
    #define CYTHON_FRAME_DEL(frame)
  #else
    #define CYTHON_FRAME_MODIFIER
    #define CYTHON_FRAME_DEL(frame) Py_CLEAR(frame)
  #endif
  #define __Pyx_TraceDeclarations\
      static PyCodeObject *__pyx_frame_code = NULL;\
      CYTHON_FRAME_MODIFIER PyFrameObject *__pyx_frame = NULL;\
      int __Pyx_use_tracing = 0;
  #define __Pyx_TraceFrameInit(codeobj)\
      if (codeobj) __pyx_frame_code = (PyCodeObject*) codeobj;
#if PY_VERSION_HEX >= 0x030a00b1
  #define __Pyx_IsTracing(tstate, check_tracing, check_funcs)\
     (unlikely((tstate)->cframe->use_tracing) &&\
         (!(check_tracing) || !(tstate)->tracing) &&\
         (!(check_funcs) || (tstate)->c_profilefunc || (CYTHON_TRACE && (tstate)->c_tracefunc)))
  #define __Pyx_SetTracing(tstate, enable)\
      (tstate)->cframe->use_tracing = (enable)
#else
  #define __Pyx_IsTracing(tstate, check_tracing, check_funcs)\
     (unlikely((tstate)->use_tracing) &&\
         (!(check_tracing) || !(tstate)->tracing) &&\
         (!(check_funcs) || (tstate)->c_profilefunc || (CYTHON_TRACE && (tstate)->c_tracefunc)))
  #define __Pyx_SetTracing(tstate, enable)\
      (tstate)->use_tracing = (enable)
#endif
  #ifdef WITH_THREAD
  #define __Pyx_TraceCall(funcname, srcfile, firstlineno, nogil, goto_error)\
  if (nogil) {\
      if (CYTHON_TRACE_NOGIL) {\
          PyThreadState *tstate;\
          PyGILState_STATE state = PyGILState_Ensure();\
          tstate = __Pyx_PyThreadState_Current;\
          if (__Pyx_IsTracing(tstate, 1, 1)) {\
              __Pyx_use_tracing = __Pyx_TraceSetupAndCall(&__pyx_frame_code, &__pyx_frame, tstate, funcname, srcfile, firstlineno);\
          }\
          PyGILState_Release(state);\
          if (unlikely(__Pyx_use_tracing < 0)) goto_error;\
      }\
  } else {\
      PyThreadState* tstate = PyThreadState_GET();\
      if (__Pyx_IsTracing(tstate, 1, 1)) {\
          __Pyx_use_tracing = __Pyx_TraceSetupAndCall(&__pyx_frame_code, &__pyx_frame, tstate, funcname, srcfile, firstlineno);\
          if (unlikely(__Pyx_use_tracing < 0)) goto_error;\
      }\
  }
  #else
  #define __Pyx_TraceCall(funcname, srcfile, firstlineno, nogil, goto_error)\
  {   PyThreadState* tstate = PyThreadState_GET();\
      if (__Pyx_IsTracing(tstate, 1, 1)) {\
          __Pyx_use_tracing = __Pyx_TraceSetupAndCall(&__pyx_frame_code, &__pyx_frame, tstate, funcname, srcfile, firstlineno);\
          if (unlikely(__Pyx_use_tracing < 0)) goto_error;\
      }\
  }
  #endif
  #define __Pyx_TraceException()\
  if (likely(!__Pyx_use_tracing)); else {\
      PyThreadState* tstate = __Pyx_PyThreadState_Current;\
      if (__Pyx_IsTracing(tstate, 0, 1)) {\
          tstate->tracing++;\
          __Pyx_SetTracing(tstate, 0);\
          PyObject *exc_info = __Pyx_GetExceptionTuple(tstate);\
          if (exc_info) {\
              if (CYTHON_TRACE && tstate->c_tracefunc)\
                  tstate->c_tracefunc(\
                      tstate->c_traceobj, __pyx_frame, PyTrace_EXCEPTION, exc_info);\
              tstate->c_profilefunc(\
                  tstate->c_profileobj, __pyx_frame, PyTrace_EXCEPTION, exc_info);\
              Py_DECREF(exc_info);\
          }\
          __Pyx_SetTracing(tstate, 1);\
          tstate->tracing--;\
      }\
  }
  static void __Pyx_call_return_trace_func(PyThreadState *tstate, PyFrameObject *frame, PyObject *result) {
      PyObject *type, *value, *traceback;
      __Pyx_ErrFetchInState(tstate, &type, &value, &traceback);
      tstate->tracing++;
      __Pyx_SetTracing(tstate, 0);
      if (CYTHON_TRACE && tstate->c_tracefunc)
          tstate->c_tracefunc(tstate->c_traceobj, frame, PyTrace_RETURN, result);
      if (tstate->c_profilefunc)
          tstate->c_profilefunc(tstate->c_profileobj, frame, PyTrace_RETURN, result);
      CYTHON_FRAME_DEL(frame);
      __Pyx_SetTracing(tstate, 1);
      tstate->tracing--;
      __Pyx_ErrRestoreInState(tstate, type, value, traceback);
  }
  #ifdef WITH_THREAD
  #define __Pyx_TraceReturn(result, nogil)\
  if (likely(!__Pyx_use_tracing)); else {\
      if (nogil) {\
          if (CYTHON_TRACE_NOGIL) {\
              PyThreadState *tstate;\
              PyGILState_STATE state = PyGILState_Ensure();\
              tstate = __Pyx_PyThreadState_Current;\
              if (__Pyx_IsTracing(tstate, 0, 0)) {\
                  __Pyx_call_return_trace_func(tstate, __pyx_frame, (PyObject*)result);\
              }\
              PyGILState_Release(state);\
          }\
      } else {\
          PyThreadState* tstate = __Pyx_PyThreadState_Current;\
          if (__Pyx_IsTracing(tstate, 0, 0)) {\
              __Pyx_call_return_trace_func(tstate, __pyx_frame, (PyObject*)result);\
          }\
      }\
  }
  #else
  #define __Pyx_TraceReturn(result, nogil)\
  if (likely(!__Pyx_use_tracing)); else {\
      PyThreadState* tstate = __Pyx_PyThreadState_Current;\
      if (__Pyx_IsTracing(tstate, 0, 0)) {\
          __Pyx_call_return_trace_func(tstate, __pyx_frame, (PyObject*)result);\
      }\
  }
  #endif
  static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const char *srcfile, int firstlineno);
  static int __Pyx_TraceSetupAndCall(PyCodeObject** code, PyFrameObject** frame, PyThreadState* tstate, const char *funcname, const char *srcfile, int firstlineno);
#else
  #define __Pyx_TraceDeclarations
  #define __Pyx_TraceFrameInit(codeobj)
  #define __Pyx_TraceCall(funcname, srcfile, firstlineno, nogil, goto_error)   if ((1)); else goto_error;
  #define __Pyx_TraceException()
  #define __Pyx_TraceReturn(result, nogil)
#endif
#if CYTHON_TRACE
  static int __Pyx_call_line_trace_func(PyThreadState *tstate, PyFrameObject *frame, int lineno) {
      int ret;
      PyObject *type, *value, *traceback;
      __Pyx_ErrFetchInState(tstate, &type, &value, &traceback);
      __Pyx_PyFrame_SetLineNumber(frame, lineno);
      tstate->tracing++;
      __Pyx_SetTracing(tstate, 0);
      ret = tstate->c_tracefunc(tstate->c_traceobj, frame, PyTrace_LINE, NULL);
      __Pyx_SetTracing(tstate, 1);
      tstate->tracing--;
      if (likely(!ret)) {
          __Pyx_ErrRestoreInState(tstate, type, value, traceback);
      } else {
          Py_XDECREF(type);
          Py_XDECREF(value);
          Py_XDECREF(traceback);
      }
      return ret;
  }
  #ifdef WITH_THREAD
  #define __Pyx_TraceLine(lineno, nogil, goto_error)\
  if (likely(!__Pyx_use_tracing)); else {\
      if (nogil) {\
          if (CYTHON_TRACE_NOGIL) {\
              int ret = 0;\
              PyThreadState *tstate;\
              PyGILState_STATE state = PyGILState_Ensure();\
              tstate = __Pyx_PyThreadState_Current;\
              if (__Pyx_IsTracing(tstate, 0, 0) && tstate->c_tracefunc && __pyx_frame->f_trace) {\
                  ret = __Pyx_call_line_trace_func(tstate, __pyx_frame, lineno);\
              }\
              PyGILState_Release(state);\
              if (unlikely(ret)) goto_error;\
          }\
      } else {\
          PyThreadState* tstate = __Pyx_PyThreadState_Current;\
          if (__Pyx_IsTracing(tstate, 0, 0) && tstate->c_tracefunc && __pyx_frame->f_trace) {\
              int ret = __Pyx_call_line_trace_func(tstate, __pyx_frame, lineno);\
              if (unlikely(ret)) goto_error;\
          }\
      }\
  }
  #else
  #define __Pyx_TraceLine(lineno, nogil, goto_error)\
  if (likely(!__Pyx_use_tracing)); else {\
      PyThreadState* tstate = __Pyx_PyThreadState_Current;\
      if (__Pyx_IsTracing(tstate, 0, 0) && tstate->c_tracefunc && __pyx_frame->f_trace) {\
          int ret = __Pyx_call_line_trace_func(tstate, __pyx_frame, lineno);\
          if (unlikely(ret)) goto_error;\
      }\
  }
  #endif
#else
  #define __Pyx_TraceLine(lineno, nogil, goto_error)   if ((1)); else goto_error;
#endif

/* FetchCommonType.proto */
static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type);

/* PyObjectGetAttrStr.proto */
#if CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
#else
#define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
#endif

/* CythonFunctionShared.proto */
#define __Pyx_CyFunction_USED 1
#define __Pyx_CYFUNCTION_STATICMETHOD  0x01
#define __Pyx_CYFUNCTION_CLASSMETHOD   0x02
#define __Pyx_CYFUNCTION_CCLASS        0x04
#define __Pyx_CyFunction_GetClosure(f)\
    (((__pyx_CyFunctionObject *) (f))->func_closure)
#define __Pyx_CyFunction_GetClassObj(f)\
    (((__pyx_CyFunctionObject *) (f))->func_classobj)
#define __Pyx_CyFunction_Defaults(type, f)\
    ((type *)(((__pyx_CyFunctionObject *) (f))->defaults))
#define __Pyx_CyFunction_SetDefaultsGetter(f, g)\
    ((__pyx_CyFunctionObject *) (f))->defaults_getter = (g)
typedef struct {
    PyCFunctionObject func;
#if PY_VERSION_HEX < 0x030500A0
    PyObject *func_weakreflist;
#endif
    PyObject *func_dict;
    PyObject *func_name;
    PyObject *func_qualname;
    PyObject *func_doc;
    PyObject *func_globals;
    PyObject *func_code;
    PyObject *func_closure;
    PyObject *func_classobj;
    void *defaults;
    int defaults_pyobjects;
    size_t defaults_size;  // used by FusedFunction for copying defaults
    int flags;
    PyObject *defaults_tuple;
    PyObject *defaults_kwdict;
    PyObject *(*defaults_getter)(PyObject *);
    PyObject *func_annotations;
} __pyx_CyFunctionObject;
static PyTypeObject *__pyx_CyFunctionType = 0;
#define __Pyx_CyFunction_Check(obj)  (__Pyx_TypeCheck(obj, __pyx_CyFunctionType))
static PyObject *__Pyx_CyFunction_Init(__pyx_CyFunctionObject* op, PyMethodDef *ml,
                                      int flags, PyObject* qualname,
                                      PyObject *self,
                                      PyObject *module, PyObject *globals,
                                      PyObject* code);
static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *m,
                                                         size_t size,
                                                         int pyobjects);
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *m,
                                                            PyObject *tuple);
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *m,
                                                             PyObject *dict);
static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *m,
                                                              PyObject *dict);
static int __pyx_CyFunction_init(void);

/* CythonFunction.proto */
static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml,
                                      int flags, PyObject* qualname,
                                      PyObject *closure,
                                      PyObject *module, PyObject *globals,
                                      PyObject* code);

/* PyDictVersioning.proto */
#if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
#define __PYX_DICT_VERSION_INIT  ((PY_UINT64_T) -1)
#define __PYX_GET_DICT_VERSION(dict)  (((PyDictObject*)(dict))->ma_version_tag)
#define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
    (version_var) = __PYX_GET_DICT_VERSION(dict);\
    (cache_var) = (value);
#define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
    static PY_UINT64_T __pyx_dict_version = 0;\
    static PyObject *__pyx_dict_cached_value = NULL;\
    if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
        (VAR) = __pyx_dict_cached_value;\
    } else {\
        (VAR) = __pyx_dict_cached_value = (LOOKUP);\
        __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
    }\
}
static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
#else
#define __PYX_GET_DICT_VERSION(dict)  (0)
#define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
#define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP)  (VAR) = (LOOKUP);
#endif

/* CLineInTraceback.proto */
#ifdef CYTHON_CLINE_IN_TRACEBACK
#define __Pyx_CLineForTraceback(tstate, c_line)  (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
#else
static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line);
#endif

/* CodeObjectCache.proto */
typedef struct {
    PyCodeObject* code_object;
    int code_line;
} __Pyx_CodeObjectCacheEntry;
struct __Pyx_CodeObjectCache {
    int count;
    int max_count;
    __Pyx_CodeObjectCacheEntry* entries;
};
static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
static PyCodeObject *__pyx_find_code_object(int code_line);
static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);

/* AddTraceback.proto */
static void __Pyx_AddTraceback(const char *funcname, int c_line,
                               int py_line, const char *filename);

/* GCCDiagnostics.proto */
#if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
#define __Pyx_HAS_GCC_DIAGNOSTIC
#endif

/* CIntToPy.proto */
static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);

/* CIntFromPy.proto */
static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);

/* CIntFromPy.proto */
static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);

/* FastTypeChecks.proto */
#if CYTHON_COMPILING_IN_CPYTHON
#define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
#else
#define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
#define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
#define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
#endif
#define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)

/* CheckBinaryVersion.proto */
static int __Pyx_check_binary_version(void);

/* FunctionImport.proto */
static int __Pyx_ImportFunction(PyObject *module, const char *funcname, void (**f)(void), const char *sig);

/* InitStrings.proto */
static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);


/* Module declarations from 'libc.string' */

/* Module declarations from 'libc.stdint' */

/* Module declarations from 'cuda.ccuda' */
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuInit)(unsigned int); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuDeviceGet)(__pyx_t_4cuda_5ccuda_CUdevice *, int); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuCtxCreate)(__pyx_t_4cuda_5ccuda_CUcontext *, unsigned int, __pyx_t_4cuda_5ccuda_CUdevice); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuCtxDestroy)(__pyx_t_4cuda_5ccuda_CUcontext); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuMemAlloc)(__pyx_t_4cuda_5ccuda_CUdeviceptr *, size_t); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuMemFree)(__pyx_t_4cuda_5ccuda_CUdeviceptr); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuMemcpyHtoD)(__pyx_t_4cuda_5ccuda_CUdeviceptr, void const *, size_t); /*proto*/
static __pyx_t_4cuda_5ccuda_CUresult (*__pyx_f_4cuda_5ccuda_cuMemcpyDtoH)(void *, __pyx_t_4cuda_5ccuda_CUdeviceptr, size_t); /*proto*/

/* Module declarations from 'cuda.tests.test_ccuda' */
#define __Pyx_MODULE_NAME "cuda.tests.test_ccuda"
extern int __pyx_module_is_main_cuda__tests__test_ccuda;
int __pyx_module_is_main_cuda__tests__test_ccuda = 0;

/* Implementation of 'cuda.tests.test_ccuda' */
static const char __pyx_k_ctx[] = "ctx";
static const char __pyx_k_err[] = "err";
static const char __pyx_k_dptr[] = "dptr";
static const char __pyx_k_main[] = "__main__";
static const char __pyx_k_name[] = "__name__";
static const char __pyx_k_test[] = "__test__";
static const char __pyx_k_hptr1[] = "hptr1";
static const char __pyx_k_hptr2[] = "hptr2";
static const char __pyx_k_device[] = "device";
static const char __pyx_k_test_ccuda_memcpy[] = "test_ccuda_memcpy";
static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback";
static const char __pyx_k_cuda_tests_test_ccuda[] = "cuda.tests.test_ccuda";
static const char __pyx_k_cuda_tests_test_ccuda_pyx[] = "cuda/tests/test_ccuda.pyx";
static PyObject *__pyx_n_s_cline_in_traceback;
static PyObject *__pyx_n_s_ctx;
static PyObject *__pyx_n_s_cuda_tests_test_ccuda;
static PyObject *__pyx_kp_s_cuda_tests_test_ccuda_pyx;
static PyObject *__pyx_n_s_device;
static PyObject *__pyx_n_s_dptr;
static PyObject *__pyx_n_s_err;
static PyObject *__pyx_n_s_hptr1;
static PyObject *__pyx_n_s_hptr2;
static PyObject *__pyx_n_s_main;
static PyObject *__pyx_n_s_name;
static PyObject *__pyx_n_s_test;
static PyObject *__pyx_n_s_test_ccuda_memcpy;
static PyObject *__pyx_pf_4cuda_5tests_10test_ccuda_test_ccuda_memcpy(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
static PyObject *__pyx_codeobj_;
static PyObject *__pyx_tuple__2;
/* Late includes */

/* "cuda/tests/test_ccuda.pyx":14
 * cimport cuda.ccuda as ccuda
 * 
 * def test_ccuda_memcpy():             # <<<<<<<<<<<<<<
 *     # Init CUDA
 *     err = ccuda.cuInit(0)
 */

/* Python wrapper */
static PyObject *__pyx_pw_4cuda_5tests_10test_ccuda_1test_ccuda_memcpy(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static char __pyx_doc_4cuda_5tests_10test_ccuda_test_ccuda_memcpy[] = "test_ccuda_memcpy()";
static PyMethodDef __pyx_mdef_4cuda_5tests_10test_ccuda_1test_ccuda_memcpy = {"test_ccuda_memcpy", (PyCFunction)__pyx_pw_4cuda_5tests_10test_ccuda_1test_ccuda_memcpy, METH_NOARGS, __pyx_doc_4cuda_5tests_10test_ccuda_test_ccuda_memcpy};
static PyObject *__pyx_pw_4cuda_5tests_10test_ccuda_1test_ccuda_memcpy(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("test_ccuda_memcpy (wrapper)", 0);
  __pyx_r = __pyx_pf_4cuda_5tests_10test_ccuda_test_ccuda_memcpy(__pyx_self);

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_4cuda_5tests_10test_ccuda_test_ccuda_memcpy(CYTHON_UNUSED PyObject *__pyx_self) {
  __pyx_t_4cuda_5ccuda_CUresult __pyx_v_err;
  __pyx_t_4cuda_5ccuda_CUdevice __pyx_v_device;
  __pyx_t_4cuda_5ccuda_CUcontext __pyx_v_ctx;
  __pyx_t_4cuda_5ccuda_CUdeviceptr __pyx_v_dptr;
  char __pyx_v_hptr1[0x400];
  char __pyx_v_hptr2[0x400];
  PyObject *__pyx_r = NULL;
  __Pyx_TraceDeclarations
  __Pyx_RefNannyDeclarations
  __pyx_t_4cuda_5ccuda_CUresult __pyx_t_1;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_TraceFrameInit(__pyx_codeobj_)
  __Pyx_RefNannySetupContext("test_ccuda_memcpy", 0);
  __Pyx_TraceCall("test_ccuda_memcpy", __pyx_f[0], 14, 0, __PYX_ERR(0, 14, __pyx_L1_error));

  /* "cuda/tests/test_ccuda.pyx":16
 * def test_ccuda_memcpy():
 *     # Init CUDA
 *     err = ccuda.cuInit(0)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuInit(0); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 16, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":17
 *     # Init CUDA
 *     err = ccuda.cuInit(0)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Get device
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 17, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":21
 *     # Get device
 *     cdef ccuda.CUdevice device
 *     err = ccuda.cuDeviceGet(&device, 0)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuDeviceGet((&__pyx_v_device), 0); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 21, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":22
 *     cdef ccuda.CUdevice device
 *     err = ccuda.cuDeviceGet(&device, 0)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Construct context
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 22, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":26
 *     # Construct context
 *     cdef ccuda.CUcontext ctx
 *     err = ccuda.cuCtxCreate(&ctx, 0, device)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuCtxCreate((&__pyx_v_ctx), 0, __pyx_v_device); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 26, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":27
 *     cdef ccuda.CUcontext ctx
 *     err = ccuda.cuCtxCreate(&ctx, 0, device)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Allocate dev memory
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 27, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":31
 *     # Allocate dev memory
 *     cdef ccuda.CUdeviceptr dptr
 *     err = ccuda.cuMemAlloc(&dptr, 1024)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuMemAlloc((&__pyx_v_dptr), 0x400); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":32
 *     cdef ccuda.CUdeviceptr dptr
 *     err = ccuda.cuMemAlloc(&dptr, 1024)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Set h1 and h2 memory to be different
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 32, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":36
 *     # Set h1 and h2 memory to be different
 *     cdef char[1024] hptr1
 *     memset(hptr1, 1, 1024)             # <<<<<<<<<<<<<<
 *     cdef char[1024] hptr2
 *     memset(hptr2, 2, 1024)
 */
  (void)(memset(__pyx_v_hptr1, 1, 0x400));

  /* "cuda/tests/test_ccuda.pyx":38
 *     memset(hptr1, 1, 1024)
 *     cdef char[1024] hptr2
 *     memset(hptr2, 2, 1024)             # <<<<<<<<<<<<<<
 *     assert(memcmp(hptr1, hptr2, 1024) != 0)
 * 
 */
  (void)(memset(__pyx_v_hptr2, 2, 0x400));

  /* "cuda/tests/test_ccuda.pyx":39
 *     cdef char[1024] hptr2
 *     memset(hptr2, 2, 1024)
 *     assert(memcmp(hptr1, hptr2, 1024) != 0)             # <<<<<<<<<<<<<<
 * 
 *     # h1 to D
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((memcmp(__pyx_v_hptr1, __pyx_v_hptr2, 0x400) != 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 39, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":42
 * 
 *     # h1 to D
 *     err = ccuda.cuMemcpyHtoD(dptr, <void*>hptr1, 1024)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuMemcpyHtoD(__pyx_v_dptr, ((void *)__pyx_v_hptr1), 0x400); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 42, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":43
 *     # h1 to D
 *     err = ccuda.cuMemcpyHtoD(dptr, <void*>hptr1, 1024)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # D to h2
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 43, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":46
 * 
 *     # D to h2
 *     err = ccuda.cuMemcpyDtoH(<void*>hptr2, dptr, 1024)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 * 
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuMemcpyDtoH(((void *)__pyx_v_hptr2), __pyx_v_dptr, 0x400); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 46, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":47
 *     # D to h2
 *     err = ccuda.cuMemcpyDtoH(<void*>hptr2, dptr, 1024)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Validate h1 == h2
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 47, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":50
 * 
 *     # Validate h1 == h2
 *     assert(memcmp(hptr1, hptr2, 1024) == 0)             # <<<<<<<<<<<<<<
 * 
 *     # Cleanup
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((memcmp(__pyx_v_hptr1, __pyx_v_hptr2, 0x400) == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 50, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":53
 * 
 *     # Cleanup
 *     err = ccuda.cuMemFree(dptr)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 *     err = ccuda.cuCtxDestroy(ctx)
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuMemFree(__pyx_v_dptr); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 53, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":54
 *     # Cleanup
 *     err = ccuda.cuMemFree(dptr)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 *     err = ccuda.cuCtxDestroy(ctx)
 *     assert(err == 0)
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 54, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":55
 *     err = ccuda.cuMemFree(dptr)
 *     assert(err == 0)
 *     err = ccuda.cuCtxDestroy(ctx)             # <<<<<<<<<<<<<<
 *     assert(err == 0)
 */
  __pyx_t_1 = __pyx_f_4cuda_5ccuda_cuCtxDestroy(__pyx_v_ctx); if (unlikely(__pyx_t_1 == ((__pyx_t_4cuda_5ccuda_CUresult)__pyx_e_4cuda_5ccuda_CUDA_ERROR_NOT_FOUND) && PyErr_Occurred())) __PYX_ERR(0, 55, __pyx_L1_error)
  __pyx_v_err = __pyx_t_1;

  /* "cuda/tests/test_ccuda.pyx":56
 *     assert(err == 0)
 *     err = ccuda.cuCtxDestroy(ctx)
 *     assert(err == 0)             # <<<<<<<<<<<<<<
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!Py_OptimizeFlag)) {
    if (unlikely(!((__pyx_v_err == 0) != 0))) {
      PyErr_SetNone(PyExc_AssertionError);
      __PYX_ERR(0, 56, __pyx_L1_error)
    }
  }
  #endif

  /* "cuda/tests/test_ccuda.pyx":14
 * cimport cuda.ccuda as ccuda
 * 
 * def test_ccuda_memcpy():             # <<<<<<<<<<<<<<
 *     # Init CUDA
 *     err = ccuda.cuInit(0)
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("cuda.tests.test_ccuda.test_ccuda_memcpy", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_TraceReturn(__pyx_r, 0);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyMethodDef __pyx_methods[] = {
  {0, 0, 0, 0}
};

#if PY_MAJOR_VERSION >= 3
#if CYTHON_PEP489_MULTI_PHASE_INIT
static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def); /*proto*/
static int __pyx_pymod_exec_test_ccuda(PyObject* module); /*proto*/
static PyModuleDef_Slot __pyx_moduledef_slots[] = {
  {Py_mod_create, (void*)__pyx_pymod_create},
  {Py_mod_exec, (void*)__pyx_pymod_exec_test_ccuda},
  {0, NULL}
};
#endif

static struct PyModuleDef __pyx_moduledef = {
    PyModuleDef_HEAD_INIT,
    "test_ccuda",
    0, /* m_doc */
  #if CYTHON_PEP489_MULTI_PHASE_INIT
    0, /* m_size */
  #else
    -1, /* m_size */
  #endif
    __pyx_methods /* m_methods */,
  #if CYTHON_PEP489_MULTI_PHASE_INIT
    __pyx_moduledef_slots, /* m_slots */
  #else
    NULL, /* m_reload */
  #endif
    NULL, /* m_traverse */
    NULL, /* m_clear */
    NULL /* m_free */
};
#endif
#ifndef CYTHON_SMALL_CODE
#if defined(__clang__)
    #define CYTHON_SMALL_CODE
#elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
    #define CYTHON_SMALL_CODE __attribute__((cold))
#else
    #define CYTHON_SMALL_CODE
#endif
#endif

static __Pyx_StringTabEntry __pyx_string_tab[] = {
  {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback, sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
  {&__pyx_n_s_ctx, __pyx_k_ctx, sizeof(__pyx_k_ctx), 0, 0, 1, 1},
  {&__pyx_n_s_cuda_tests_test_ccuda, __pyx_k_cuda_tests_test_ccuda, sizeof(__pyx_k_cuda_tests_test_ccuda), 0, 0, 1, 1},
  {&__pyx_kp_s_cuda_tests_test_ccuda_pyx, __pyx_k_cuda_tests_test_ccuda_pyx, sizeof(__pyx_k_cuda_tests_test_ccuda_pyx), 0, 0, 1, 0},
  {&__pyx_n_s_device, __pyx_k_device, sizeof(__pyx_k_device), 0, 0, 1, 1},
  {&__pyx_n_s_dptr, __pyx_k_dptr, sizeof(__pyx_k_dptr), 0, 0, 1, 1},
  {&__pyx_n_s_err, __pyx_k_err, sizeof(__pyx_k_err), 0, 0, 1, 1},
  {&__pyx_n_s_hptr1, __pyx_k_hptr1, sizeof(__pyx_k_hptr1), 0, 0, 1, 1},
  {&__pyx_n_s_hptr2, __pyx_k_hptr2, sizeof(__pyx_k_hptr2), 0, 0, 1, 1},
  {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
  {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
  {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
  {&__pyx_n_s_test_ccuda_memcpy, __pyx_k_test_ccuda_memcpy, sizeof(__pyx_k_test_ccuda_memcpy), 0, 0, 1, 1},
  {0, 0, 0, 0, 0, 0, 0}
};
static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) {
  return 0;
}

static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);

  /* "cuda/tests/test_ccuda.pyx":14
 * cimport cuda.ccuda as ccuda
 * 
 * def test_ccuda_memcpy():             # <<<<<<<<<<<<<<
 *     # Init CUDA
 *     err = ccuda.cuInit(0)
 */
  __pyx_tuple__2 = PyTuple_Pack(6, __pyx_n_s_err, __pyx_n_s_device, __pyx_n_s_ctx, __pyx_n_s_dptr, __pyx_n_s_hptr1, __pyx_n_s_hptr2); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__2);
  __Pyx_GIVEREF(__pyx_tuple__2);
  __pyx_codeobj_ = (PyObject*)__Pyx_PyCode_New(0, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__2, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_cuda_tests_test_ccuda_pyx, __pyx_n_s_test_ccuda_memcpy, 14, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj_)) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_RefNannyFinishContext();
  return 0;
  __pyx_L1_error:;
  __Pyx_RefNannyFinishContext();
  return -1;
}

static CYTHON_SMALL_CODE int __Pyx_InitGlobals(void) {
  if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
  return 0;
  __pyx_L1_error:;
  return -1;
}

static CYTHON_SMALL_CODE int __Pyx_modinit_global_init_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_variable_export_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_function_export_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_type_init_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_type_import_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_variable_import_code(void); /*proto*/
static CYTHON_SMALL_CODE int __Pyx_modinit_function_import_code(void); /*proto*/

static int __Pyx_modinit_global_init_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_global_init_code", 0);
  /*--- Global init code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_variable_export_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0);
  /*--- Variable export code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_function_export_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_function_export_code", 0);
  /*--- Function export code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_type_init_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0);
  /*--- Type init code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_type_import_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0);
  /*--- Type import code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_variable_import_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_import_code", 0);
  /*--- Variable import code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_function_import_code(void) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__Pyx_modinit_function_import_code", 0);
  /*--- Function import code ---*/
  __pyx_t_1 = PyImport_ImportModule("cuda.ccuda"); if (!__pyx_t_1) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (__Pyx_ImportFunction(__pyx_t_1, "cuInit", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuInit, "__pyx_t_4cuda_5ccuda_CUresult (unsigned int)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuDeviceGet", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuDeviceGet, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUdevice *, int)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuCtxCreate", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuCtxCreate, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUcontext *, unsigned int, __pyx_t_4cuda_5ccuda_CUdevice)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuCtxDestroy", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuCtxDestroy, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUcontext)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuMemAlloc", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuMemAlloc, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUdeviceptr *, size_t)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuMemFree", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuMemFree, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUdeviceptr)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuMemcpyHtoD", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuMemcpyHtoD, "__pyx_t_4cuda_5ccuda_CUresult (__pyx_t_4cuda_5ccuda_CUdeviceptr, void const *, size_t)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  if (__Pyx_ImportFunction(__pyx_t_1, "cuMemcpyDtoH", (void (**)(void))&__pyx_f_4cuda_5ccuda_cuMemcpyDtoH, "__pyx_t_4cuda_5ccuda_CUresult (void *, __pyx_t_4cuda_5ccuda_CUdeviceptr, size_t)") < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_RefNannyFinishContext();
  return 0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_RefNannyFinishContext();
  return -1;
}


#ifndef CYTHON_NO_PYINIT_EXPORT
#define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
#elif PY_MAJOR_VERSION < 3
#ifdef __cplusplus
#define __Pyx_PyMODINIT_FUNC extern "C" void
#else
#define __Pyx_PyMODINIT_FUNC void
#endif
#else
#ifdef __cplusplus
#define __Pyx_PyMODINIT_FUNC extern "C" PyObject *
#else
#define __Pyx_PyMODINIT_FUNC PyObject *
#endif
#endif


#if PY_MAJOR_VERSION < 3
__Pyx_PyMODINIT_FUNC inittest_ccuda(void) CYTHON_SMALL_CODE; /*proto*/
__Pyx_PyMODINIT_FUNC inittest_ccuda(void)
#else
__Pyx_PyMODINIT_FUNC PyInit_test_ccuda(void) CYTHON_SMALL_CODE; /*proto*/
__Pyx_PyMODINIT_FUNC PyInit_test_ccuda(void)
#if CYTHON_PEP489_MULTI_PHASE_INIT
{
  return PyModuleDef_Init(&__pyx_moduledef);
}
static CYTHON_SMALL_CODE int __Pyx_check_single_interpreter(void) {
    #if PY_VERSION_HEX >= 0x030700A1
    static PY_INT64_T main_interpreter_id = -1;
    PY_INT64_T current_id = PyInterpreterState_GetID(PyThreadState_Get()->interp);
    if (main_interpreter_id == -1) {
        main_interpreter_id = current_id;
        return (unlikely(current_id == -1)) ? -1 : 0;
    } else if (unlikely(main_interpreter_id != current_id))
    #else
    static PyInterpreterState *main_interpreter = NULL;
    PyInterpreterState *current_interpreter = PyThreadState_Get()->interp;
    if (!main_interpreter) {
        main_interpreter = current_interpreter;
    } else if (unlikely(main_interpreter != current_interpreter))
    #endif
    {
        PyErr_SetString(
            PyExc_ImportError,
            "Interpreter change detected - this module can only be loaded into one interpreter per process.");
        return -1;
    }
    return 0;
}
static CYTHON_SMALL_CODE int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict, const char* from_name, const char* to_name, int allow_none) {
    PyObject *value = PyObject_GetAttrString(spec, from_name);
    int result = 0;
    if (likely(value)) {
        if (allow_none || value != Py_None) {
            result = PyDict_SetItemString(moddict, to_name, value);
        }
        Py_DECREF(value);
    } else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
        PyErr_Clear();
    } else {
        result = -1;
    }
    return result;
}
static CYTHON_SMALL_CODE PyObject* __pyx_pymod_create(PyObject *spec, CYTHON_UNUSED PyModuleDef *def) {
    PyObject *module = NULL, *moddict, *modname;
    if (__Pyx_check_single_interpreter())
        return NULL;
    if (__pyx_m)
        return __Pyx_NewRef(__pyx_m);
    modname = PyObject_GetAttrString(spec, "name");
    if (unlikely(!modname)) goto bad;
    module = PyModule_NewObject(modname);
    Py_DECREF(modname);
    if (unlikely(!module)) goto bad;
    moddict = PyModule_GetDict(module);
    if (unlikely(!moddict)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "loader", "__loader__", 1) < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "origin", "__file__", 1) < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "parent", "__package__", 1) < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "submodule_search_locations", "__path__", 0) < 0)) goto bad;
    return module;
bad:
    Py_XDECREF(module);
    return NULL;
}


static CYTHON_SMALL_CODE int __pyx_pymod_exec_test_ccuda(PyObject *__pyx_pyinit_module)
#endif
#endif
{
  __Pyx_TraceDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannyDeclarations
  #if CYTHON_PEP489_MULTI_PHASE_INIT
  if (__pyx_m) {
    if (__pyx_m == __pyx_pyinit_module) return 0;
    PyErr_SetString(PyExc_RuntimeError, "Module 'test_ccuda' has already been imported. Re-initialisation is not supported.");
    return -1;
  }
  #elif PY_MAJOR_VERSION >= 3
  if (__pyx_m) return __Pyx_NewRef(__pyx_m);
  #endif
  #if CYTHON_REFNANNY
__Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
if (!__Pyx_RefNanny) {
  PyErr_Clear();
  __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
  if (!__Pyx_RefNanny)
      Py_FatalError("failed to import 'refnanny' module");
}
#endif
  __Pyx_RefNannySetupContext("__Pyx_PyMODINIT_FUNC PyInit_test_ccuda(void)", 0);
  if (__Pyx_check_binary_version() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #ifdef __Pxy_PyFrame_Initialize_Offsets
  __Pxy_PyFrame_Initialize_Offsets();
  #endif
  __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(0, 1, __pyx_L1_error)
  #ifdef __Pyx_CyFunction_USED
  if (__pyx_CyFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_FusedFunction_USED
  if (__pyx_FusedFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_Coroutine_USED
  if (__pyx_Coroutine_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_Generator_USED
  if (__pyx_Generator_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_AsyncGen_USED
  if (__pyx_AsyncGen_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_StopAsyncIteration_USED
  if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  /*--- Library function declarations ---*/
  /*--- Threads initialization code ---*/
  #if defined(WITH_THREAD) && PY_VERSION_HEX < 0x030700F0 && defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
  PyEval_InitThreads();
  #endif
  /*--- Module creation code ---*/
  #if CYTHON_PEP489_MULTI_PHASE_INIT
  __pyx_m = __pyx_pyinit_module;
  Py_INCREF(__pyx_m);
  #else
  #if PY_MAJOR_VERSION < 3
  __pyx_m = Py_InitModule4("test_ccuda", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
  #else
  __pyx_m = PyModule_Create(&__pyx_moduledef);
  #endif
  if (unlikely(!__pyx_m)) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(0, 1, __pyx_L1_error)
  Py_INCREF(__pyx_d);
  __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(0, 1, __pyx_L1_error)
  Py_INCREF(__pyx_b);
  __pyx_cython_runtime = PyImport_AddModule((char *) "cython_runtime"); if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(0, 1, __pyx_L1_error)
  Py_INCREF(__pyx_cython_runtime);
  if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
  /*--- Initialize various global constants etc. ---*/
  if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
  if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  if (__pyx_module_is_main_cuda__tests__test_ccuda) {
    if (PyObject_SetAttr(__pyx_m, __pyx_n_s_name, __pyx_n_s_main) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  }
  #if PY_MAJOR_VERSION >= 3
  {
    PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 1, __pyx_L1_error)
    if (!PyDict_GetItemString(modules, "cuda.tests.test_ccuda")) {
      if (unlikely(PyDict_SetItemString(modules, "cuda.tests.test_ccuda", __pyx_m) < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
    }
  }
  #endif
  /*--- Builtin init code ---*/
  if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  /*--- Constants init code ---*/
  if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  /*--- Global type/function init code ---*/
  (void)__Pyx_modinit_global_init_code();
  (void)__Pyx_modinit_variable_export_code();
  (void)__Pyx_modinit_function_export_code();
  (void)__Pyx_modinit_type_init_code();
  (void)__Pyx_modinit_type_import_code();
  (void)__Pyx_modinit_variable_import_code();
  if (unlikely(__Pyx_modinit_function_import_code() < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
  /*--- Execution code ---*/
  #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
  if (__Pyx_patch_abc() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  __Pyx_TraceCall("__Pyx_PyMODINIT_FUNC PyInit_test_ccuda(void)", __pyx_f[0], 1, 0, __PYX_ERR(0, 1, __pyx_L1_error));

  /* "cuda/tests/test_ccuda.pyx":14
 * cimport cuda.ccuda as ccuda
 * 
 * def test_ccuda_memcpy():             # <<<<<<<<<<<<<<
 *     # Init CUDA
 *     err = ccuda.cuInit(0)
 */
  __pyx_t_1 = __Pyx_CyFunction_New(&__pyx_mdef_4cuda_5tests_10test_ccuda_1test_ccuda_memcpy, 0, __pyx_n_s_test_ccuda_memcpy, NULL, __pyx_n_s_cuda_tests_test_ccuda, __pyx_d, ((PyObject *)__pyx_codeobj_)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test_ccuda_memcpy, __pyx_t_1) < 0) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "cuda/tests/test_ccuda.pyx":1
 * # Copyright 2021 NVIDIA Corporation.  All rights reserved.             # <<<<<<<<<<<<<<
 * #
 * # Please refer to the NVIDIA end user license agreement (EULA) associated
 */
  __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_TraceReturn(Py_None, 0);

  /*--- Wrapped vars code ---*/

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  if (__pyx_m) {
    if (__pyx_d) {
      __Pyx_AddTraceback("init cuda.tests.test_ccuda", __pyx_clineno, __pyx_lineno, __pyx_filename);
    }
    Py_CLEAR(__pyx_m);
  } else if (!PyErr_Occurred()) {
    PyErr_SetString(PyExc_ImportError, "init cuda.tests.test_ccuda");
  }
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  #if CYTHON_PEP489_MULTI_PHASE_INIT
  return (__pyx_m != NULL) ? 0 : -1;
  #elif PY_MAJOR_VERSION >= 3
  return __pyx_m;
  #else
  return;
  #endif
}

/* --- Runtime support code --- */
/* Refnanny */
#if CYTHON_REFNANNY
static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
    PyObject *m = NULL, *p = NULL;
    void *r = NULL;
    m = PyImport_ImportModule(modname);
    if (!m) goto end;
    p = PyObject_GetAttrString(m, "RefNannyAPI");
    if (!p) goto end;
    r = PyLong_AsVoidPtr(p);
end:
    Py_XDECREF(p);
    Py_XDECREF(m);
    return (__Pyx_RefNannyAPIStruct *)r;
}
#endif

/* PyErrFetchRestore */
#if CYTHON_FAST_THREAD_STATE
static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
    PyObject *tmp_type, *tmp_value, *tmp_tb;
    tmp_type = tstate->curexc_type;
    tmp_value = tstate->curexc_value;
    tmp_tb = tstate->curexc_traceback;
    tstate->curexc_type = type;
    tstate->curexc_value = value;
    tstate->curexc_traceback = tb;
    Py_XDECREF(tmp_type);
    Py_XDECREF(tmp_value);
    Py_XDECREF(tmp_tb);
}
static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
    *type = tstate->curexc_type;
    *value = tstate->curexc_value;
    *tb = tstate->curexc_traceback;
    tstate->curexc_type = 0;
    tstate->curexc_value = 0;
    tstate->curexc_traceback = 0;
}
#endif

/* Profile */
#if CYTHON_PROFILE
static int __Pyx_TraceSetupAndCall(PyCodeObject** code,
                                   PyFrameObject** frame,
                                   PyThreadState* tstate,
                                   const char *funcname,
                                   const char *srcfile,
                                   int firstlineno) {
    PyObject *type, *value, *traceback;
    int retval;
    if (*frame == NULL || !CYTHON_PROFILE_REUSE_FRAME) {
        if (*code == NULL) {
            *code = __Pyx_createFrameCodeObject(funcname, srcfile, firstlineno);
            if (*code == NULL) return 0;
        }
        *frame = PyFrame_New(
            tstate,                          /*PyThreadState *tstate*/
            *code,                           /*PyCodeObject *code*/
            __pyx_d,                  /*PyObject *globals*/
            0                                /*PyObject *locals*/
        );
        if (*frame == NULL) return 0;
        if (CYTHON_TRACE && (*frame)->f_trace == NULL) {
            Py_INCREF(Py_None);
            (*frame)->f_trace = Py_None;
        }
#if PY_VERSION_HEX < 0x030400B1
    } else {
        (*frame)->f_tstate = tstate;
#endif
    }
    __Pyx_PyFrame_SetLineNumber(*frame, firstlineno);
    retval = 1;
    tstate->tracing++;
    __Pyx_SetTracing(tstate, 0);
    __Pyx_ErrFetchInState(tstate, &type, &value, &traceback);
    #if CYTHON_TRACE
    if (tstate->c_tracefunc)
        retval = tstate->c_tracefunc(tstate->c_traceobj, *frame, PyTrace_CALL, NULL) == 0;
    if (retval && tstate->c_profilefunc)
    #endif
        retval = tstate->c_profilefunc(tstate->c_profileobj, *frame, PyTrace_CALL, NULL) == 0;
    __Pyx_SetTracing(tstate, (tstate->c_profilefunc || (CYTHON_TRACE && tstate->c_tracefunc)));
    tstate->tracing--;
    if (retval) {
        __Pyx_ErrRestoreInState(tstate, type, value, traceback);
        return __Pyx_IsTracing(tstate, 0, 0) && retval;
    } else {
        Py_XDECREF(type);
        Py_XDECREF(value);
        Py_XDECREF(traceback);
        return -1;
    }
}
static PyCodeObject *__Pyx_createFrameCodeObject(const char *funcname, const char *srcfile, int firstlineno) {
    PyCodeObject *py_code = 0;
#if PY_MAJOR_VERSION >= 3
    py_code = PyCode_NewEmpty(srcfile, funcname, firstlineno);
    if (likely(py_code)) {
        py_code->co_flags |= CO_OPTIMIZED | CO_NEWLOCALS;
    }
#else
    PyObject *py_srcfile = 0;
    PyObject *py_funcname = 0;
    py_funcname = PyString_FromString(funcname);
    if (unlikely(!py_funcname)) goto bad;
    py_srcfile = PyString_FromString(srcfile);
    if (unlikely(!py_srcfile)) goto bad;
    py_code = PyCode_New(
        0,
        0,
        0,
        CO_OPTIMIZED | CO_NEWLOCALS,
        __pyx_empty_bytes,     /*PyObject *code,*/
        __pyx_empty_tuple,     /*PyObject *consts,*/
        __pyx_empty_tuple,     /*PyObject *names,*/
        __pyx_empty_tuple,     /*PyObject *varnames,*/
        __pyx_empty_tuple,     /*PyObject *freevars,*/
        __pyx_empty_tuple,     /*PyObject *cellvars,*/
        py_srcfile,       /*PyObject *filename,*/
        py_funcname,      /*PyObject *name,*/
        firstlineno,
        __pyx_empty_bytes      /*PyObject *lnotab*/
    );
bad:
    Py_XDECREF(py_srcfile);
    Py_XDECREF(py_funcname);
#endif
    return py_code;
}
#endif

/* FetchCommonType */
static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type) {
    PyObject* fake_module;
    PyTypeObject* cached_type = NULL;
    fake_module = PyImport_AddModule((char*) "_cython_" CYTHON_ABI);
    if (!fake_module) return NULL;
    Py_INCREF(fake_module);
    cached_type = (PyTypeObject*) PyObject_GetAttrString(fake_module, type->tp_name);
    if (cached_type) {
        if (!PyType_Check((PyObject*)cached_type)) {
            PyErr_Format(PyExc_TypeError,
                "Shared Cython type %.200s is not a type object",
                type->tp_name);
            goto bad;
        }
        if (cached_type->tp_basicsize != type->tp_basicsize) {
            PyErr_Format(PyExc_TypeError,
                "Shared Cython type %.200s has the wrong size, try recompiling",
                type->tp_name);
            goto bad;
        }
    } else {
        if (!PyErr_ExceptionMatches(PyExc_AttributeError)) goto bad;
        PyErr_Clear();
        if (PyType_Ready(type) < 0) goto bad;
        if (PyObject_SetAttrString(fake_module, type->tp_name, (PyObject*) type) < 0)
            goto bad;
        Py_INCREF(type);
        cached_type = type;
    }
done:
    Py_DECREF(fake_module);
    return cached_type;
bad:
    Py_XDECREF(cached_type);
    cached_type = NULL;
    goto done;
}

/* PyObjectGetAttrStr */
#if CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
    PyTypeObject* tp = Py_TYPE(obj);
    if (likely(tp->tp_getattro))
        return tp->tp_getattro(obj, attr_name);
#if PY_MAJOR_VERSION < 3
    if (likely(tp->tp_getattr))
        return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
#endif
    return PyObject_GetAttr(obj, attr_name);
}
#endif

/* CythonFunctionShared */
#include <structmember.h>
static PyObject *
__Pyx_CyFunction_get_doc(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *closure)
{
    if (unlikely(op->func_doc == NULL)) {
        if (op->func.m_ml->ml_doc) {
#if PY_MAJOR_VERSION >= 3
            op->func_doc = PyUnicode_FromString(op->func.m_ml->ml_doc);
#else
            op->func_doc = PyString_FromString(op->func.m_ml->ml_doc);
#endif
            if (unlikely(op->func_doc == NULL))
                return NULL;
        } else {
            Py_INCREF(Py_None);
            return Py_None;
        }
    }
    Py_INCREF(op->func_doc);
    return op->func_doc;
}
static int
__Pyx_CyFunction_set_doc(__pyx_CyFunctionObject *op, PyObject *value, CYTHON_UNUSED void *context)
{
    PyObject *tmp = op->func_doc;
    if (value == NULL) {
        value = Py_None;
    }
    Py_INCREF(value);
    op->func_doc = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_name(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    if (unlikely(op->func_name == NULL)) {
#if PY_MAJOR_VERSION >= 3
        op->func_name = PyUnicode_InternFromString(op->func.m_ml->ml_name);
#else
        op->func_name = PyString_InternFromString(op->func.m_ml->ml_name);
#endif
        if (unlikely(op->func_name == NULL))
            return NULL;
    }
    Py_INCREF(op->func_name);
    return op->func_name;
}
static int
__Pyx_CyFunction_set_name(__pyx_CyFunctionObject *op, PyObject *value, CYTHON_UNUSED void *context)
{
    PyObject *tmp;
#if PY_MAJOR_VERSION >= 3
    if (unlikely(value == NULL || !PyUnicode_Check(value)))
#else
    if (unlikely(value == NULL || !PyString_Check(value)))
#endif
    {
        PyErr_SetString(PyExc_TypeError,
                        "__name__ must be set to a string object");
        return -1;
    }
    tmp = op->func_name;
    Py_INCREF(value);
    op->func_name = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_qualname(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    Py_INCREF(op->func_qualname);
    return op->func_qualname;
}
static int
__Pyx_CyFunction_set_qualname(__pyx_CyFunctionObject *op, PyObject *value, CYTHON_UNUSED void *context)
{
    PyObject *tmp;
#if PY_MAJOR_VERSION >= 3
    if (unlikely(value == NULL || !PyUnicode_Check(value)))
#else
    if (unlikely(value == NULL || !PyString_Check(value)))
#endif
    {
        PyErr_SetString(PyExc_TypeError,
                        "__qualname__ must be set to a string object");
        return -1;
    }
    tmp = op->func_qualname;
    Py_INCREF(value);
    op->func_qualname = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_self(__pyx_CyFunctionObject *m, CYTHON_UNUSED void *closure)
{
    PyObject *self;
    self = m->func_closure;
    if (self == NULL)
        self = Py_None;
    Py_INCREF(self);
    return self;
}
static PyObject *
__Pyx_CyFunction_get_dict(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    if (unlikely(op->func_dict == NULL)) {
        op->func_dict = PyDict_New();
        if (unlikely(op->func_dict == NULL))
            return NULL;
    }
    Py_INCREF(op->func_dict);
    return op->func_dict;
}
static int
__Pyx_CyFunction_set_dict(__pyx_CyFunctionObject *op, PyObject *value, CYTHON_UNUSED void *context)
{
    PyObject *tmp;
    if (unlikely(value == NULL)) {
        PyErr_SetString(PyExc_TypeError,
               "function's dictionary may not be deleted");
        return -1;
    }
    if (unlikely(!PyDict_Check(value))) {
        PyErr_SetString(PyExc_TypeError,
               "setting function's dictionary to a non-dict");
        return -1;
    }
    tmp = op->func_dict;
    Py_INCREF(value);
    op->func_dict = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_globals(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    Py_INCREF(op->func_globals);
    return op->func_globals;
}
static PyObject *
__Pyx_CyFunction_get_closure(CYTHON_UNUSED __pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    Py_INCREF(Py_None);
    return Py_None;
}
static PyObject *
__Pyx_CyFunction_get_code(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context)
{
    PyObject* result = (op->func_code) ? op->func_code : Py_None;
    Py_INCREF(result);
    return result;
}
static int
__Pyx_CyFunction_init_defaults(__pyx_CyFunctionObject *op) {
    int result = 0;
    PyObject *res = op->defaults_getter((PyObject *) op);
    if (unlikely(!res))
        return -1;
    #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    op->defaults_tuple = PyTuple_GET_ITEM(res, 0);
    Py_INCREF(op->defaults_tuple);
    op->defaults_kwdict = PyTuple_GET_ITEM(res, 1);
    Py_INCREF(op->defaults_kwdict);
    #else
    op->defaults_tuple = PySequence_ITEM(res, 0);
    if (unlikely(!op->defaults_tuple)) result = -1;
    else {
        op->defaults_kwdict = PySequence_ITEM(res, 1);
        if (unlikely(!op->defaults_kwdict)) result = -1;
    }
    #endif
    Py_DECREF(res);
    return result;
}
static int
__Pyx_CyFunction_set_defaults(__pyx_CyFunctionObject *op, PyObject* value, CYTHON_UNUSED void *context) {
    PyObject* tmp;
    if (!value) {
        value = Py_None;
    } else if (value != Py_None && !PyTuple_Check(value)) {
        PyErr_SetString(PyExc_TypeError,
                        "__defaults__ must be set to a tuple object");
        return -1;
    }
    Py_INCREF(value);
    tmp = op->defaults_tuple;
    op->defaults_tuple = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_defaults(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context) {
    PyObject* result = op->defaults_tuple;
    if (unlikely(!result)) {
        if (op->defaults_getter) {
            if (__Pyx_CyFunction_init_defaults(op) < 0) return NULL;
            result = op->defaults_tuple;
        } else {
            result = Py_None;
        }
    }
    Py_INCREF(result);
    return result;
}
static int
__Pyx_CyFunction_set_kwdefaults(__pyx_CyFunctionObject *op, PyObject* value, CYTHON_UNUSED void *context) {
    PyObject* tmp;
    if (!value) {
        value = Py_None;
    } else if (value != Py_None && !PyDict_Check(value)) {
        PyErr_SetString(PyExc_TypeError,
                        "__kwdefaults__ must be set to a dict object");
        return -1;
    }
    Py_INCREF(value);
    tmp = op->defaults_kwdict;
    op->defaults_kwdict = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_kwdefaults(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context) {
    PyObject* result = op->defaults_kwdict;
    if (unlikely(!result)) {
        if (op->defaults_getter) {
            if (__Pyx_CyFunction_init_defaults(op) < 0) return NULL;
            result = op->defaults_kwdict;
        } else {
            result = Py_None;
        }
    }
    Py_INCREF(result);
    return result;
}
static int
__Pyx_CyFunction_set_annotations(__pyx_CyFunctionObject *op, PyObject* value, CYTHON_UNUSED void *context) {
    PyObject* tmp;
    if (!value || value == Py_None) {
        value = NULL;
    } else if (!PyDict_Check(value)) {
        PyErr_SetString(PyExc_TypeError,
                        "__annotations__ must be set to a dict object");
        return -1;
    }
    Py_XINCREF(value);
    tmp = op->func_annotations;
    op->func_annotations = value;
    Py_XDECREF(tmp);
    return 0;
}
static PyObject *
__Pyx_CyFunction_get_annotations(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *context) {
    PyObject* result = op->func_annotations;
    if (unlikely(!result)) {
        result = PyDict_New();
        if (unlikely(!result)) return NULL;
        op->func_annotations = result;
    }
    Py_INCREF(result);
    return result;
}
static PyGetSetDef __pyx_CyFunction_getsets[] = {
    {(char *) "func_doc", (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0},
    {(char *) "__doc__",  (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0},
    {(char *) "func_name", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0},
    {(char *) "__name__", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0},
    {(char *) "__qualname__", (getter)__Pyx_CyFunction_get_qualname, (setter)__Pyx_CyFunction_set_qualname, 0, 0},
    {(char *) "__self__", (getter)__Pyx_CyFunction_get_self, 0, 0, 0},
    {(char *) "func_dict", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0},
    {(char *) "__dict__", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0},
    {(char *) "func_globals", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0},
    {(char *) "__globals__", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0},
    {(char *) "func_closure", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0},
    {(char *) "__closure__", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0},
    {(char *) "func_code", (getter)__Pyx_CyFunction_get_code, 0, 0, 0},
    {(char *) "__code__", (getter)__Pyx_CyFunction_get_code, 0, 0, 0},
    {(char *) "func_defaults", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0},
    {(char *) "__defaults__", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0},
    {(char *) "__kwdefaults__", (getter)__Pyx_CyFunction_get_kwdefaults, (setter)__Pyx_CyFunction_set_kwdefaults, 0, 0},
    {(char *) "__annotations__", (getter)__Pyx_CyFunction_get_annotations, (setter)__Pyx_CyFunction_set_annotations, 0, 0},
    {0, 0, 0, 0, 0}
};
static PyMemberDef __pyx_CyFunction_members[] = {
    {(char *) "__module__", T_OBJECT, offsetof(PyCFunctionObject, m_module), PY_WRITE_RESTRICTED, 0},
    {0, 0, 0,  0, 0}
};
static PyObject *
__Pyx_CyFunction_reduce(__pyx_CyFunctionObject *m, CYTHON_UNUSED PyObject *args)
{
#if PY_MAJOR_VERSION >= 3
    Py_INCREF(m->func_qualname);
    return m->func_qualname;
#else
    return PyString_FromString(m->func.m_ml->ml_name);
#endif
}
static PyMethodDef __pyx_CyFunction_methods[] = {
    {"__reduce__", (PyCFunction)__Pyx_CyFunction_reduce, METH_VARARGS, 0},
    {0, 0, 0, 0}
};
#if PY_VERSION_HEX < 0x030500A0
#define __Pyx_CyFunction_weakreflist(cyfunc) ((cyfunc)->func_weakreflist)
#else
#define __Pyx_CyFunction_weakreflist(cyfunc) ((cyfunc)->func.m_weakreflist)
#endif
static PyObject *__Pyx_CyFunction_Init(__pyx_CyFunctionObject *op, PyMethodDef *ml, int flags, PyObject* qualname,
                                       PyObject *closure, PyObject *module, PyObject* globals, PyObject* code) {
    if (unlikely(op == NULL))
        return NULL;
    op->flags = flags;
    __Pyx_CyFunction_weakreflist(op) = NULL;
    op->func.m_ml = ml;
    op->func.m_self = (PyObject *) op;
    Py_XINCREF(closure);
    op->func_closure = closure;
    Py_XINCREF(module);
    op->func.m_module = module;
    op->func_dict = NULL;
    op->func_name = NULL;
    Py_INCREF(qualname);
    op->func_qualname = qualname;
    op->func_doc = NULL;
    op->func_classobj = NULL;
    op->func_globals = globals;
    Py_INCREF(op->func_globals);
    Py_XINCREF(code);
    op->func_code = code;
    op->defaults_pyobjects = 0;
    op->defaults_size = 0;
    op->defaults = NULL;
    op->defaults_tuple = NULL;
    op->defaults_kwdict = NULL;
    op->defaults_getter = NULL;
    op->func_annotations = NULL;
    return (PyObject *) op;
}
static int
__Pyx_CyFunction_clear(__pyx_CyFunctionObject *m)
{
    Py_CLEAR(m->func_closure);
    Py_CLEAR(m->func.m_module);
    Py_CLEAR(m->func_dict);
    Py_CLEAR(m->func_name);
    Py_CLEAR(m->func_qualname);
    Py_CLEAR(m->func_doc);
    Py_CLEAR(m->func_globals);
    Py_CLEAR(m->func_code);
    Py_CLEAR(m->func_classobj);
    Py_CLEAR(m->defaults_tuple);
    Py_CLEAR(m->defaults_kwdict);
    Py_CLEAR(m->func_annotations);
    if (m->defaults) {
        PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m);
        int i;
        for (i = 0; i < m->defaults_pyobjects; i++)
            Py_XDECREF(pydefaults[i]);
        PyObject_Free(m->defaults);
        m->defaults = NULL;
    }
    return 0;
}
static void __Pyx__CyFunction_dealloc(__pyx_CyFunctionObject *m)
{
    if (__Pyx_CyFunction_weakreflist(m) != NULL)
        PyObject_ClearWeakRefs((PyObject *) m);
    __Pyx_CyFunction_clear(m);
    PyObject_GC_Del(m);
}
static void __Pyx_CyFunction_dealloc(__pyx_CyFunctionObject *m)
{
    PyObject_GC_UnTrack(m);
    __Pyx__CyFunction_dealloc(m);
}
static int __Pyx_CyFunction_traverse(__pyx_CyFunctionObject *m, visitproc visit, void *arg)
{
    Py_VISIT(m->func_closure);
    Py_VISIT(m->func.m_module);
    Py_VISIT(m->func_dict);
    Py_VISIT(m->func_name);
    Py_VISIT(m->func_qualname);
    Py_VISIT(m->func_doc);
    Py_VISIT(m->func_globals);
    Py_VISIT(m->func_code);
    Py_VISIT(m->func_classobj);
    Py_VISIT(m->defaults_tuple);
    Py_VISIT(m->defaults_kwdict);
    if (m->defaults) {
        PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m);
        int i;
        for (i = 0; i < m->defaults_pyobjects; i++)
            Py_VISIT(pydefaults[i]);
    }
    return 0;
}
static PyObject *__Pyx_CyFunction_descr_get(PyObject *func, PyObject *obj, PyObject *type)
{
#if PY_MAJOR_VERSION < 3
    __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
    if (m->flags & __Pyx_CYFUNCTION_STATICMETHOD) {
        Py_INCREF(func);
        return func;
    }
    if (m->flags & __Pyx_CYFUNCTION_CLASSMETHOD) {
        if (type == NULL)
            type = (PyObject *)(Py_TYPE(obj));
        return __Pyx_PyMethod_New(func, type, (PyObject *)(Py_TYPE(type)));
    }
    if (obj == Py_None)
        obj = NULL;
#endif
    return __Pyx_PyMethod_New(func, obj, type);
}
static PyObject*
__Pyx_CyFunction_repr(__pyx_CyFunctionObject *op)
{
#if PY_MAJOR_VERSION >= 3
    return PyUnicode_FromFormat("<cyfunction %U at %p>",
                                op->func_qualname, (void *)op);
#else
    return PyString_FromFormat("<cyfunction %s at %p>",
                               PyString_AsString(op->func_qualname), (void *)op);
#endif
}
static PyObject * __Pyx_CyFunction_CallMethod(PyObject *func, PyObject *self, PyObject *arg, PyObject *kw) {
    PyCFunctionObject* f = (PyCFunctionObject*)func;
    PyCFunction meth = f->m_ml->ml_meth;
    Py_ssize_t size;
    switch (f->m_ml->ml_flags & (METH_VARARGS | METH_KEYWORDS | METH_NOARGS | METH_O)) {
    case METH_VARARGS:
        if (likely(kw == NULL || PyDict_Size(kw) == 0))
            return (*meth)(self, arg);
        break;
    case METH_VARARGS | METH_KEYWORDS:
        return (*(PyCFunctionWithKeywords)(void*)meth)(self, arg, kw);
    case METH_NOARGS:
        if (likely(kw == NULL || PyDict_Size(kw) == 0)) {
            size = PyTuple_GET_SIZE(arg);
            if (likely(size == 0))
                return (*meth)(self, NULL);
            PyErr_Format(PyExc_TypeError,
                "%.200s() takes no arguments (%" CYTHON_FORMAT_SSIZE_T "d given)",
                f->m_ml->ml_name, size);
            return NULL;
        }
        break;
    case METH_O:
        if (likely(kw == NULL || PyDict_Size(kw) == 0)) {
            size = PyTuple_GET_SIZE(arg);
            if (likely(size == 1)) {
                PyObject *result, *arg0;
                #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
                arg0 = PyTuple_GET_ITEM(arg, 0);
                #else
                arg0 = PySequence_ITEM(arg, 0); if (unlikely(!arg0)) return NULL;
                #endif
                result = (*meth)(self, arg0);
                #if !(CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS)
                Py_DECREF(arg0);
                #endif
                return result;
            }
            PyErr_Format(PyExc_TypeError,
                "%.200s() takes exactly one argument (%" CYTHON_FORMAT_SSIZE_T "d given)",
                f->m_ml->ml_name, size);
            return NULL;
        }
        break;
    default:
        PyErr_SetString(PyExc_SystemError, "Bad call flags in "
                        "__Pyx_CyFunction_Call. METH_OLDARGS is no "
                        "longer supported!");
        return NULL;
    }
    PyErr_Format(PyExc_TypeError, "%.200s() takes no keyword arguments",
                 f->m_ml->ml_name);
    return NULL;
}
static CYTHON_INLINE PyObject *__Pyx_CyFunction_Call(PyObject *func, PyObject *arg, PyObject *kw) {
    return __Pyx_CyFunction_CallMethod(func, ((PyCFunctionObject*)func)->m_self, arg, kw);
}
static PyObject *__Pyx_CyFunction_CallAsMethod(PyObject *func, PyObject *args, PyObject *kw) {
    PyObject *result;
    __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *) func;
    if ((cyfunc->flags & __Pyx_CYFUNCTION_CCLASS) && !(cyfunc->flags & __Pyx_CYFUNCTION_STATICMETHOD)) {
        Py_ssize_t argc;
        PyObject *new_args;
        PyObject *self;
        argc = PyTuple_GET_SIZE(args);
        new_args = PyTuple_GetSlice(args, 1, argc);
        if (unlikely(!new_args))
            return NULL;
        self = PyTuple_GetItem(args, 0);
        if (unlikely(!self)) {
            Py_DECREF(new_args);
            return NULL;
        }
        result = __Pyx_CyFunction_CallMethod(func, self, new_args, kw);
        Py_DECREF(new_args);
    } else {
        result = __Pyx_CyFunction_Call(func, args, kw);
    }
    return result;
}
static PyTypeObject __pyx_CyFunctionType_type = {
    PyVarObject_HEAD_INIT(0, 0)
    "cython_function_or_method",
    sizeof(__pyx_CyFunctionObject),
    0,
    (destructor) __Pyx_CyFunction_dealloc,
    0,
    0,
    0,
#if PY_MAJOR_VERSION < 3
    0,
#else
    0,
#endif
    (reprfunc) __Pyx_CyFunction_repr,
    0,
    0,
    0,
    0,
    __Pyx_CyFunction_CallAsMethod,
    0,
    0,
    0,
    0,
    Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC,
    0,
    (traverseproc) __Pyx_CyFunction_traverse,
    (inquiry) __Pyx_CyFunction_clear,
    0,
#if PY_VERSION_HEX < 0x030500A0
    offsetof(__pyx_CyFunctionObject, func_weakreflist),
#else
    offsetof(PyCFunctionObject, m_weakreflist),
#endif
    0,
    0,
    __pyx_CyFunction_methods,
    __pyx_CyFunction_members,
    __pyx_CyFunction_getsets,
    0,
    0,
    __Pyx_CyFunction_descr_get,
    0,
    offsetof(__pyx_CyFunctionObject, func_dict),
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
#if PY_VERSION_HEX >= 0x030400a1
    0,
#endif
#if PY_VERSION_HEX >= 0x030800b1
    0,
#endif
#if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
    0,
#endif
};
static int __pyx_CyFunction_init(void) {
    __pyx_CyFunctionType = __Pyx_FetchCommonType(&__pyx_CyFunctionType_type);
    if (unlikely(__pyx_CyFunctionType == NULL)) {
        return -1;
    }
    return 0;
}
static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *func, size_t size, int pyobjects) {
    __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
    m->defaults = PyObject_Malloc(size);
    if (unlikely(!m->defaults))
        return PyErr_NoMemory();
    memset(m->defaults, 0, size);
    m->defaults_pyobjects = pyobjects;
    m->defaults_size = size;
    return m->defaults;
}
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *func, PyObject *tuple) {
    __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
    m->defaults_tuple = tuple;
    Py_INCREF(tuple);
}
static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *func, PyObject *dict) {
    __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
    m->defaults_kwdict = dict;
    Py_INCREF(dict);
}
static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *func, PyObject *dict) {
    __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
    m->func_annotations = dict;
    Py_INCREF(dict);
}

/* CythonFunction */
static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml, int flags, PyObject* qualname,
                                      PyObject *closure, PyObject *module, PyObject* globals, PyObject* code) {
    PyObject *op = __Pyx_CyFunction_Init(
        PyObject_GC_New(__pyx_CyFunctionObject, __pyx_CyFunctionType),
        ml, flags, qualname, closure, module, globals, code
    );
    if (likely(op)) {
        PyObject_GC_Track(op);
    }
    return op;
}

/* PyDictVersioning */
#if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj) {
    PyObject *dict = Py_TYPE(obj)->tp_dict;
    return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
}
static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj) {
    PyObject **dictptr = NULL;
    Py_ssize_t offset = Py_TYPE(obj)->tp_dictoffset;
    if (offset) {
#if CYTHON_COMPILING_IN_CPYTHON
        dictptr = (likely(offset > 0)) ? (PyObject **) ((char *)obj + offset) : _PyObject_GetDictPtr(obj);
#else
        dictptr = _PyObject_GetDictPtr(obj);
#endif
    }
    return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
}
static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version) {
    PyObject *dict = Py_TYPE(obj)->tp_dict;
    if (unlikely(!dict) || unlikely(tp_dict_version != __PYX_GET_DICT_VERSION(dict)))
        return 0;
    return obj_dict_version == __Pyx_get_object_dict_version(obj);
}
#endif

/* CLineInTraceback */
#ifndef CYTHON_CLINE_IN_TRACEBACK
static int __Pyx_CLineForTraceback(CYTHON_NCP_UNUSED PyThreadState *tstate, int c_line) {
    PyObject *use_cline;
    PyObject *ptype, *pvalue, *ptraceback;
#if CYTHON_COMPILING_IN_CPYTHON
    PyObject **cython_runtime_dict;
#endif
    if (unlikely(!__pyx_cython_runtime)) {
        return c_line;
    }
    __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
#if CYTHON_COMPILING_IN_CPYTHON
    cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
    if (likely(cython_runtime_dict)) {
        __PYX_PY_DICT_LOOKUP_IF_MODIFIED(
            use_cline, *cython_runtime_dict,
            __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback))
    } else
#endif
    {
      PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
      if (use_cline_obj) {
        use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
        Py_DECREF(use_cline_obj);
      } else {
        PyErr_Clear();
        use_cline = NULL;
      }
    }
    if (!use_cline) {
        c_line = 0;
        PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
    }
    else if (use_cline == Py_False || (use_cline != Py_True && PyObject_Not(use_cline) != 0)) {
        c_line = 0;
    }
    __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
    return c_line;
}
#endif

/* CodeObjectCache */
static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
    int start = 0, mid = 0, end = count - 1;
    if (end >= 0 && code_line > entries[end].code_line) {
        return count;
    }
    while (start < end) {
        mid = start + (end - start) / 2;
        if (code_line < entries[mid].code_line) {
            end = mid;
        } else if (code_line > entries[mid].code_line) {
             start = mid + 1;
        } else {
            return mid;
        }
    }
    if (code_line <= entries[mid].code_line) {
        return mid;
    } else {
        return mid + 1;
    }
}
static PyCodeObject *__pyx_find_code_object(int code_line) {
    PyCodeObject* code_object;
    int pos;
    if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
        return NULL;
    }
    pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
    if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
        return NULL;
    }
    code_object = __pyx_code_cache.entries[pos].code_object;
    Py_INCREF(code_object);
    return code_object;
}
static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
    int pos, i;
    __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
    if (unlikely(!code_line)) {
        return;
    }
    if (unlikely(!entries)) {
        entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
        if (likely(entries)) {
            __pyx_code_cache.entries = entries;
            __pyx_code_cache.max_count = 64;
            __pyx_code_cache.count = 1;
            entries[0].code_line = code_line;
            entries[0].code_object = code_object;
            Py_INCREF(code_object);
        }
        return;
    }
    pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
    if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
        PyCodeObject* tmp = entries[pos].code_object;
        entries[pos].code_object = code_object;
        Py_DECREF(tmp);
        return;
    }
    if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
        int new_max = __pyx_code_cache.max_count + 64;
        entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
            __pyx_code_cache.entries, ((size_t)new_max) * sizeof(__Pyx_CodeObjectCacheEntry));
        if (unlikely(!entries)) {
            return;
        }
        __pyx_code_cache.entries = entries;
        __pyx_code_cache.max_count = new_max;
    }
    for (i=__pyx_code_cache.count; i>pos; i--) {
        entries[i] = entries[i-1];
    }
    entries[pos].code_line = code_line;
    entries[pos].code_object = code_object;
    __pyx_code_cache.count++;
    Py_INCREF(code_object);
}

/* AddTraceback */
#include "compile.h"
#include "frameobject.h"
#include "traceback.h"
static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
            const char *funcname, int c_line,
            int py_line, const char *filename) {
    PyCodeObject *py_code = 0;
    PyObject *py_srcfile = 0;
    PyObject *py_funcname = 0;
    #if PY_MAJOR_VERSION < 3
    py_srcfile = PyString_FromString(filename);
    #else
    py_srcfile = PyUnicode_FromString(filename);
    #endif
    if (!py_srcfile) goto bad;
    if (c_line) {
        #if PY_MAJOR_VERSION < 3
        py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
        #else
        py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
        #endif
    }
    else {
        #if PY_MAJOR_VERSION < 3
        py_funcname = PyString_FromString(funcname);
        #else
        py_funcname = PyUnicode_FromString(funcname);
        #endif
    }
    if (!py_funcname) goto bad;
    py_code = __Pyx_PyCode_New(
        0,
        0,
        0,
        0,
        0,
        __pyx_empty_bytes, /*PyObject *code,*/
        __pyx_empty_tuple, /*PyObject *consts,*/
        __pyx_empty_tuple, /*PyObject *names,*/
        __pyx_empty_tuple, /*PyObject *varnames,*/
        __pyx_empty_tuple, /*PyObject *freevars,*/
        __pyx_empty_tuple, /*PyObject *cellvars,*/
        py_srcfile,   /*PyObject *filename,*/
        py_funcname,  /*PyObject *name,*/
        py_line,
        __pyx_empty_bytes  /*PyObject *lnotab*/
    );
    Py_DECREF(py_srcfile);
    Py_DECREF(py_funcname);
    return py_code;
bad:
    Py_XDECREF(py_srcfile);
    Py_XDECREF(py_funcname);
    return NULL;
}
static void __Pyx_AddTraceback(const char *funcname, int c_line,
                               int py_line, const char *filename) {
    PyCodeObject *py_code = 0;
    PyFrameObject *py_frame = 0;
    PyThreadState *tstate = __Pyx_PyThreadState_Current;
    if (c_line) {
        c_line = __Pyx_CLineForTraceback(tstate, c_line);
    }
    py_code = __pyx_find_code_object(c_line ? -c_line : py_line);
    if (!py_code) {
        py_code = __Pyx_CreateCodeObjectForTraceback(
            funcname, c_line, py_line, filename);
        if (!py_code) goto bad;
        __pyx_insert_code_object(c_line ? -c_line : py_line, py_code);
    }
    py_frame = PyFrame_New(
        tstate,            /*PyThreadState *tstate,*/
        py_code,           /*PyCodeObject *code,*/
        __pyx_d,    /*PyObject *globals,*/
        0                  /*PyObject *locals*/
    );
    if (!py_frame) goto bad;
    __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
    PyTraceBack_Here(py_frame);
bad:
    Py_XDECREF(py_code);
    Py_XDECREF(py_frame);
}

/* CIntToPy */
static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wconversion"
#endif
    const long neg_one = (long) -1, const_zero = (long) 0;
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic pop
#endif
    const int is_unsigned = neg_one > const_zero;
    if (is_unsigned) {
        if (sizeof(long) < sizeof(long)) {
            return PyInt_FromLong((long) value);
        } else if (sizeof(long) <= sizeof(unsigned long)) {
            return PyLong_FromUnsignedLong((unsigned long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
            return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
#endif
        }
    } else {
        if (sizeof(long) <= sizeof(long)) {
            return PyInt_FromLong((long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
            return PyLong_FromLongLong((PY_LONG_LONG) value);
#endif
        }
    }
    {
        int one = 1; int little = (int)*(unsigned char *)&one;
        unsigned char *bytes = (unsigned char *)&value;
        return _PyLong_FromByteArray(bytes, sizeof(long),
                                     little, !is_unsigned);
    }
}

/* CIntFromPyVerify */
#define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
    __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
#define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
    __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
#define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
    {\
        func_type value = func_value;\
        if (sizeof(target_type) < sizeof(func_type)) {\
            if (unlikely(value != (func_type) (target_type) value)) {\
                func_type zero = 0;\
                if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
                    return (target_type) -1;\
                if (is_unsigned && unlikely(value < zero))\
                    goto raise_neg_overflow;\
                else\
                    goto raise_overflow;\
            }\
        }\
        return (target_type) value;\
    }

/* CIntFromPy */
static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wconversion"
#endif
    const long neg_one = (long) -1, const_zero = (long) 0;
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic pop
#endif
    const int is_unsigned = neg_one > const_zero;
#if PY_MAJOR_VERSION < 3
    if (likely(PyInt_Check(x))) {
        if (sizeof(long) < sizeof(long)) {
            __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
        } else {
            long val = PyInt_AS_LONG(x);
            if (is_unsigned && unlikely(val < 0)) {
                goto raise_neg_overflow;
            }
            return (long) val;
        }
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (long) 0;
                case  1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0])
                case 2:
                    if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) {
                            return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) {
                            return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) {
                            return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
            }
#endif
#if CYTHON_COMPILING_IN_CPYTHON
            if (unlikely(Py_SIZE(x) < 0)) {
                goto raise_neg_overflow;
            }
#else
            {
                int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
                if (unlikely(result < 0))
                    return (long) -1;
                if (unlikely(result == 1))
                    goto raise_neg_overflow;
            }
#endif
            if (sizeof(long) <= sizeof(unsigned long)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
#endif
            }
        } else {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (long) 0;
                case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, (sdigit) (-(sdigit)digits[0]))
                case  1: __PYX_VERIFY_RETURN_INT(long,  digit, +digits[0])
                case -2:
                    if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 2:
                    if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                            return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case -3:
                    if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                            return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case -4:
                    if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                            return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
            }
#endif
            if (sizeof(long) <= sizeof(long)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
#endif
            }
        }
        {
#if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
            PyErr_SetString(PyExc_RuntimeError,
                            "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
#else
            long val;
            PyObject *v = __Pyx_PyNumber_IntOrLong(x);
 #if PY_MAJOR_VERSION < 3
            if (likely(v) && !PyLong_Check(v)) {
                PyObject *tmp = v;
                v = PyNumber_Long(tmp);
                Py_DECREF(tmp);
            }
 #endif
            if (likely(v)) {
                int one = 1; int is_little = (int)*(unsigned char *)&one;
                unsigned char *bytes = (unsigned char *)&val;
                int ret = _PyLong_AsByteArray((PyLongObject *)v,
                                              bytes, sizeof(val),
                                              is_little, !is_unsigned);
                Py_DECREF(v);
                if (likely(!ret))
                    return val;
            }
#endif
            return (long) -1;
        }
    } else {
        long val;
        PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
        if (!tmp) return (long) -1;
        val = __Pyx_PyInt_As_long(tmp);
        Py_DECREF(tmp);
        return val;
    }
raise_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "value too large to convert to long");
    return (long) -1;
raise_neg_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "can't convert negative value to long");
    return (long) -1;
}

/* CIntFromPy */
static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wconversion"
#endif
    const int neg_one = (int) -1, const_zero = (int) 0;
#ifdef __Pyx_HAS_GCC_DIAGNOSTIC
#pragma GCC diagnostic pop
#endif
    const int is_unsigned = neg_one > const_zero;
#if PY_MAJOR_VERSION < 3
    if (likely(PyInt_Check(x))) {
        if (sizeof(int) < sizeof(long)) {
            __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
        } else {
            long val = PyInt_AS_LONG(x);
            if (is_unsigned && unlikely(val < 0)) {
                goto raise_neg_overflow;
            }
            return (int) val;
        }
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (int) 0;
                case  1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0])
                case 2:
                    if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) {
                            return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) {
                            return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) {
                            return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
            }
#endif
#if CYTHON_COMPILING_IN_CPYTHON
            if (unlikely(Py_SIZE(x) < 0)) {
                goto raise_neg_overflow;
            }
#else
            {
                int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
                if (unlikely(result < 0))
                    return (int) -1;
                if (unlikely(result == 1))
                    goto raise_neg_overflow;
            }
#endif
            if (sizeof(int) <= sizeof(unsigned long)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
#endif
            }
        } else {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (int) 0;
                case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, (sdigit) (-(sdigit)digits[0]))
                case  1: __PYX_VERIFY_RETURN_INT(int,  digit, +digits[0])
                case -2:
                    if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 2:
                    if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                            return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case -3:
                    if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                            return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case -4:
                    if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
                            return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
            }
#endif
            if (sizeof(int) <= sizeof(long)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
#endif
            }
        }
        {
#if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
            PyErr_SetString(PyExc_RuntimeError,
                            "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
#else
            int val;
            PyObject *v = __Pyx_PyNumber_IntOrLong(x);
 #if PY_MAJOR_VERSION < 3
            if (likely(v) && !PyLong_Check(v)) {
                PyObject *tmp = v;
                v = PyNumber_Long(tmp);
                Py_DECREF(tmp);
            }
 #endif
            if (likely(v)) {
                int one = 1; int is_little = (int)*(unsigned char *)&one;
                unsigned char *bytes = (unsigned char *)&val;
                int ret = _PyLong_AsByteArray((PyLongObject *)v,
                                              bytes, sizeof(val),
                                              is_little, !is_unsigned);
                Py_DECREF(v);
                if (likely(!ret))
                    return val;
            }
#endif
            return (int) -1;
        }
    } else {
        int val;
        PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
        if (!tmp) return (int) -1;
        val = __Pyx_PyInt_As_int(tmp);
        Py_DECREF(tmp);
        return val;
    }
raise_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "value too large to convert to int");
    return (int) -1;
raise_neg_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "can't convert negative value to int");
    return (int) -1;
}

/* FastTypeChecks */
#if CYTHON_COMPILING_IN_CPYTHON
static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
    while (a) {
        a = a->tp_base;
        if (a == b)
            return 1;
    }
    return b == &PyBaseObject_Type;
}
static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
    PyObject *mro;
    if (a == b) return 1;
    mro = a->tp_mro;
    if (likely(mro)) {
        Py_ssize_t i, n;
        n = PyTuple_GET_SIZE(mro);
        for (i = 0; i < n; i++) {
            if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
                return 1;
        }
        return 0;
    }
    return __Pyx_InBases(a, b);
}
#if PY_MAJOR_VERSION == 2
static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
    PyObject *exception, *value, *tb;
    int res;
    __Pyx_PyThreadState_declare
    __Pyx_PyThreadState_assign
    __Pyx_ErrFetch(&exception, &value, &tb);
    res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
    if (unlikely(res == -1)) {
        PyErr_WriteUnraisable(err);
        res = 0;
    }
    if (!res) {
        res = PyObject_IsSubclass(err, exc_type2);
        if (unlikely(res == -1)) {
            PyErr_WriteUnraisable(err);
            res = 0;
        }
    }
    __Pyx_ErrRestore(exception, value, tb);
    return res;
}
#else
static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
    int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0;
    if (!res) {
        res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
    }
    return res;
}
#endif
static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
    Py_ssize_t i, n;
    assert(PyExceptionClass_Check(exc_type));
    n = PyTuple_GET_SIZE(tuple);
#if PY_MAJOR_VERSION >= 3
    for (i=0; i<n; i++) {
        if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
    }
#endif
    for (i=0; i<n; i++) {
        PyObject *t = PyTuple_GET_ITEM(tuple, i);
        #if PY_MAJOR_VERSION < 3
        if (likely(exc_type == t)) return 1;
        #endif
        if (likely(PyExceptionClass_Check(t))) {
            if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t)) return 1;
        } else {
        }
    }
    return 0;
}
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
    if (likely(err == exc_type)) return 1;
    if (likely(PyExceptionClass_Check(err))) {
        if (likely(PyExceptionClass_Check(exc_type))) {
            return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
        } else if (likely(PyTuple_Check(exc_type))) {
            return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
        } else {
        }
    }
    return PyErr_GivenExceptionMatches(err, exc_type);
}
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
    assert(PyExceptionClass_Check(exc_type1));
    assert(PyExceptionClass_Check(exc_type2));
    if (likely(err == exc_type1 || err == exc_type2)) return 1;
    if (likely(PyExceptionClass_Check(err))) {
        return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
    }
    return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
}
#endif

/* CheckBinaryVersion */
static int __Pyx_check_binary_version(void) {
    char ctversion[4], rtversion[4];
    PyOS_snprintf(ctversion, 4, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
    PyOS_snprintf(rtversion, 4, "%s", Py_GetVersion());
    if (ctversion[0] != rtversion[0] || ctversion[2] != rtversion[2]) {
        char message[200];
        PyOS_snprintf(message, sizeof(message),
                      "compiletime version %s of module '%.100s' "
                      "does not match runtime version %s",
                      ctversion, __Pyx_MODULE_NAME, rtversion);
        return PyErr_WarnEx(NULL, message, 1);
    }
    return 0;
}

/* FunctionImport */
#ifndef __PYX_HAVE_RT_ImportFunction
#define __PYX_HAVE_RT_ImportFunction
static int __Pyx_ImportFunction(PyObject *module, const char *funcname, void (**f)(void), const char *sig) {
    PyObject *d = 0;
    PyObject *cobj = 0;
    union {
        void (*fp)(void);
        void *p;
    } tmp;
    d = PyObject_GetAttrString(module, (char *)"__pyx_capi__");
    if (!d)
        goto bad;
    cobj = PyDict_GetItemString(d, funcname);
    if (!cobj) {
        PyErr_Format(PyExc_ImportError,
            "%.200s does not export expected C function %.200s",
                PyModule_GetName(module), funcname);
        goto bad;
    }
#if PY_VERSION_HEX >= 0x02070000
    if (!PyCapsule_IsValid(cobj, sig)) {
        PyErr_Format(PyExc_TypeError,
            "C function %.200s.%.200s has wrong signature (expected %.500s, got %.500s)",
             PyModule_GetName(module), funcname, sig, PyCapsule_GetName(cobj));
        goto bad;
    }
    tmp.p = PyCapsule_GetPointer(cobj, sig);
#else
    {const char *desc, *s1, *s2;
    desc = (const char *)PyCObject_GetDesc(cobj);
    if (!desc)
        goto bad;
    s1 = desc; s2 = sig;
    while (*s1 != '\0' && *s1 == *s2) { s1++; s2++; }
    if (*s1 != *s2) {
        PyErr_Format(PyExc_TypeError,
            "C function %.200s.%.200s has wrong signature (expected %.500s, got %.500s)",
             PyModule_GetName(module), funcname, sig, desc);
        goto bad;
    }
    tmp.p = PyCObject_AsVoidPtr(cobj);}
#endif
    *f = tmp.fp;
    if (!(*f))
        goto bad;
    Py_DECREF(d);
    return 0;
bad:
    Py_XDECREF(d);
    return -1;
}
#endif

/* InitStrings */
static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
    while (t->p) {
        #if PY_MAJOR_VERSION < 3
        if (t->is_unicode) {
            *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
        } else if (t->intern) {
            *t->p = PyString_InternFromString(t->s);
        } else {
            *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
        }
        #else
        if (t->is_unicode | t->is_str) {
            if (t->intern) {
                *t->p = PyUnicode_InternFromString(t->s);
            } else if (t->encoding) {
                *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
            } else {
                *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
            }
        } else {
            *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
        }
        #endif
        if (!*t->p)
            return -1;
        if (PyObject_Hash(*t->p) == -1)
            return -1;
        ++t;
    }
    return 0;
}

static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
    return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
}
static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject* o) {
    Py_ssize_t ignore;
    return __Pyx_PyObject_AsStringAndSize(o, &ignore);
}
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
#if !CYTHON_PEP393_ENABLED
static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
    char* defenc_c;
    PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
    if (!defenc) return NULL;
    defenc_c = PyBytes_AS_STRING(defenc);
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
    {
        char* end = defenc_c + PyBytes_GET_SIZE(defenc);
        char* c;
        for (c = defenc_c; c < end; c++) {
            if ((unsigned char) (*c) >= 128) {
                PyUnicode_AsASCIIString(o);
                return NULL;
            }
        }
    }
#endif
    *length = PyBytes_GET_SIZE(defenc);
    return defenc_c;
}
#else
static CYTHON_INLINE const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
    if (unlikely(__Pyx_PyUnicode_READY(o) == -1)) return NULL;
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
    if (likely(PyUnicode_IS_ASCII(o))) {
        *length = PyUnicode_GET_LENGTH(o);
        return PyUnicode_AsUTF8(o);
    } else {
        PyUnicode_AsASCIIString(o);
        return NULL;
    }
#else
    return PyUnicode_AsUTF8AndSize(o, length);
#endif
}
#endif
#endif
static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
    if (
#if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
            __Pyx_sys_getdefaultencoding_not_ascii &&
#endif
            PyUnicode_Check(o)) {
        return __Pyx_PyUnicode_AsStringAndSize(o, length);
    } else
#endif
#if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
    if (PyByteArray_Check(o)) {
        *length = PyByteArray_GET_SIZE(o);
        return PyByteArray_AS_STRING(o);
    } else
#endif
    {
        char* result;
        int r = PyBytes_AsStringAndSize(o, &result, length);
        if (unlikely(r < 0)) {
            return NULL;
        } else {
            return result;
        }
    }
}
static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
   int is_true = x == Py_True;
   if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
   else return PyObject_IsTrue(x);
}
static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject* x) {
    int retval;
    if (unlikely(!x)) return -1;
    retval = __Pyx_PyObject_IsTrue(x);
    Py_DECREF(x);
    return retval;
}
static PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result, const char* type_name) {
#if PY_MAJOR_VERSION >= 3
    if (PyLong_Check(result)) {
        if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
                "__int__ returned non-int (type %.200s).  "
                "The ability to return an instance of a strict subclass of int "
                "is deprecated, and may be removed in a future version of Python.",
                Py_TYPE(result)->tp_name)) {
            Py_DECREF(result);
            return NULL;
        }
        return result;
    }
#endif
    PyErr_Format(PyExc_TypeError,
                 "__%.4s__ returned non-%.4s (type %.200s)",
                 type_name, type_name, Py_TYPE(result)->tp_name);
    Py_DECREF(result);
    return NULL;
}
static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
#if CYTHON_USE_TYPE_SLOTS
  PyNumberMethods *m;
#endif
  const char *name = NULL;
  PyObject *res = NULL;
#if PY_MAJOR_VERSION < 3
  if (likely(PyInt_Check(x) || PyLong_Check(x)))
#else
  if (likely(PyLong_Check(x)))
#endif
    return __Pyx_NewRef(x);
#if CYTHON_USE_TYPE_SLOTS
  m = Py_TYPE(x)->tp_as_number;
  #if PY_MAJOR_VERSION < 3
  if (m && m->nb_int) {
    name = "int";
    res = m->nb_int(x);
  }
  else if (m && m->nb_long) {
    name = "long";
    res = m->nb_long(x);
  }
  #else
  if (likely(m && m->nb_int)) {
    name = "int";
    res = m->nb_int(x);
  }
  #endif
#else
  if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
    res = PyNumber_Int(x);
  }
#endif
  if (likely(res)) {
#if PY_MAJOR_VERSION < 3
    if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
#else
    if (unlikely(!PyLong_CheckExact(res))) {
#endif
        return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
    }
  }
  else if (!PyErr_Occurred()) {
    PyErr_SetString(PyExc_TypeError,
                    "an integer is required");
  }
  return res;
}
static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
  Py_ssize_t ival;
  PyObject *x;
#if PY_MAJOR_VERSION < 3
  if (likely(PyInt_CheckExact(b))) {
    if (sizeof(Py_ssize_t) >= sizeof(long))
        return PyInt_AS_LONG(b);
    else
        return PyInt_AsSsize_t(b);
  }
#endif
  if (likely(PyLong_CheckExact(b))) {
    #if CYTHON_USE_PYLONG_INTERNALS
    const digit* digits = ((PyLongObject*)b)->ob_digit;
    const Py_ssize_t size = Py_SIZE(b);
    if (likely(__Pyx_sst_abs(size) <= 1)) {
        ival = likely(size) ? digits[0] : 0;
        if (size == -1) ival = -ival;
        return ival;
    } else {
      switch (size) {
         case 2:
           if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -2:
           if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case 3:
           if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -3:
           if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case 4:
           if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -4:
           if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
      }
    }
    #endif
    return PyLong_AsSsize_t(b);
  }
  x = PyNumber_Index(b);
  if (!x) return -1;
  ival = PyInt_AsSsize_t(x);
  Py_DECREF(x);
  return ival;
}
static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
  return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
}
static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
    return PyInt_FromSize_t(ival);
}


#endif /* Py_PYTHON_H */
