/external/python/cpython3/Modules/ |
D | _testbuffer.c | 43 #define HAVE_PTR(suboffsets) (suboffsets && suboffsets[0] >= 0) argument 45 #define ADJUST_PTR(ptr, suboffsets) \ argument 46 (HAVE_PTR(suboffsets) ? *((char**)ptr) + suboffsets[0] : ptr) 157 base->suboffsets = NULL; in ndbuf_new() 172 PyMem_XFree(base->suboffsets); in ndbuf_free() 230 PyMem_XFree(base->suboffsets); in ndarray_dealloc() 269 if (ndbuf->base.suboffsets) in init_flags() 549 if ((dest->suboffsets && dest->suboffsets[dest->ndim-1] >= 0) || in copy_buffer() 550 (src->suboffsets && src->suboffsets[src->ndim-1] >= 0) || in copy_buffer() 561 dest->buf, dest->strides, dest->suboffsets, in copy_buffer() [all …]
|
D | arraymodule.c | 2508 view->suboffsets = NULL; in array_buffer_getbuf()
|
/external/python/cpython3/Objects/ |
D | memoryobject.c | 196 #define HAVE_PTR(suboffsets, dim) (suboffsets && suboffsets[dim] >= 0) argument 198 #define ADJUST_PTR(ptr, suboffsets, dim) \ argument 199 (HAVE_PTR(suboffsets, dim) ? *((char**)ptr) + suboffsets[dim] : ptr) 244 (view->suboffsets && view->suboffsets[dest->ndim-1] >= 0) 398 dest->buf, dest->strides, dest->suboffsets, in copy_single() 399 src->buf, src->strides, src->suboffsets, in copy_single() 430 dest->buf, dest->strides, dest->suboffsets, in copy_buffer() 431 src->buf, src->strides, src->suboffsets, in copy_buffer() 502 dest.suboffsets = NULL; in buffer_to_contiguous() 561 if (src->suboffsets == NULL) { in init_suboffsets() [all …]
|
D | abstract.c | 411 if (view->suboffsets != NULL) return 0; in PyBuffer_IsContiguous() 431 if ((view->suboffsets != NULL) && (view->suboffsets[i] >= 0)) { in PyBuffer_GetPointer() 432 pointer = *((char**)pointer) + view->suboffsets[i]; in PyBuffer_GetPointer() 651 view->suboffsets = NULL; in PyBuffer_FillInfo()
|
/external/python/cpython3/Doc/c-api/ |
D | buffer.rst | 161 and :c:member:`~Py_buffer.suboffsets` MUST be *NULL*. 192 .. c:member:: Py_ssize_t \*suboffsets 195 If ``suboffsets[n] >= 0``, the values stored along the nth dimension are 201 If all suboffsets are negative (i.e. no de-referencing is needed, then 208 The suboffsets array is read-only for the consumer. 214 about whether or not the shape, strides, and suboffsets arrays must be 262 shape, strides, suboffsets 272 | Request | shape | strides | suboffsets | 296 | Request | shape | strides | suboffsets | contig | 321 | Request | shape | strides | suboffsets | contig | readonly | format | [all …]
|
D | typeobj.rst | 1311 :c:member:`~Py_buffer.strides`, :c:member:`~Py_buffer.suboffsets`
|
/external/python/cpython2/Doc/c-api/ |
D | buffer.rst | 77 array. If it is ``0``, :c:data:`strides` and :c:data:`suboffsets` must be 92 .. c:member:: Py_ssize_t *suboffsets 101 If all suboffsets are negative (i.e. no de-referencing is needed, then 106 and suboffsets:: 109 Py_ssize_t *suboffsets, Py_ssize_t *indices) { 114 if (suboffsets[i] >=0 ) { 115 pointer = *((char**)pointer) + suboffsets[i]; 135 about whether or not the shape, strides, and suboffsets arrays must be 193 | | not possible (i.e. without the suboffsets). | 217 | | suboffsets information (which can be NULL if no | [all …]
|
/external/python/cpython2/Objects/ |
D | memoryobject.c | 296 if (view->suboffsets==NULL) { in PyMemoryView_GetContiguous() 378 return _IntTupleFromSsizet(self->view.ndim, self->view.suboffsets); in memory_suboffsets_get() 537 if (view->suboffsets != NULL && in memory_item() 538 view->suboffsets[0] >= 0) { in memory_item() 539 ptr = *((char **)ptr) + view->suboffsets[0]; in memory_item()
|
D | abstract.c | 417 if (view->suboffsets != NULL) return 0; in PyBuffer_IsContiguous() 437 if ((view->suboffsets != NULL) && (view->suboffsets[i] >= 0)) { in PyBuffer_GetPointer() 438 pointer = *((char**)pointer) + view->suboffsets[i]; in PyBuffer_GetPointer() 708 view->suboffsets = NULL; in PyBuffer_FillInfo()
|
/external/python/cpython3/Lib/test/ |
D | test_buffer.py | 737 (x, nd.shape, nd.strides, nd.suboffsets, offset, 779 suboffsets = () 780 if result.suboffsets: 790 suboffsets = [suboffset0] + [-1 for v in range(ndim-1)] 805 if not (sliced and suboffsets): 807 self.assertEqual(result.suboffsets, tuple(suboffsets)) 933 if not (sliced and suboffsets): 935 self.assertEqual(m.suboffsets, tuple(suboffsets)) 957 (not match(req, PyBUF_INDIRECT) and ex.suboffsets) or 1987 self.assertEqual(ex.suboffsets, (0, -1)) [all …]
|
D | test_memoryview.py | 189 self.assertEqual(m.suboffsets, ())
|
/external/python/cpython2/Lib/test/ |
D | test_memoryview.py | 183 self.assertEqual(m.suboffsets, None)
|
/external/python/cpython2/Include/ |
D | object.h | 175 Py_ssize_t *suboffsets; member
|
/external/python/cpython3/Include/ |
D | object.h | 193 Py_ssize_t *suboffsets; member
|
/external/python/cpython3/Doc/whatsnew/ |
D | 3.3.rst | 153 and arrays with suboffsets. 184 * The representation of empty shape, strides and suboffsets is now
|
/external/python/cpython3/Modules/_ctypes/ |
D | _ctypes.c | 2550 view->suboffsets = NULL; in PyCData_NewGetBuffer()
|
/external/python/cpython2/Modules/_ctypes/ |
D | _ctypes.c | 2642 view->suboffsets = NULL; in PyCData_NewGetBuffer()
|
/external/python/cpython2/Doc/library/ |
D | stdtypes.rst | 2823 .. memoryview.suboffsets isn't documented because it only seems useful for C
|
/external/python/cpython3/Doc/library/ |
D | stdtypes.rst | 3770 .. attribute:: suboffsets
|