summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
Diffstat (limited to 'Include')
-rw-r--r--Include/objimpl.h2
-rw-r--r--Include/pymem.h4
-rw-r--r--Include/pystate.h10
3 files changed, 7 insertions, 9 deletions
diff --git a/Include/objimpl.h b/Include/objimpl.h
index 746f9c9..ed9e7a9 100644
--- a/Include/objimpl.h
+++ b/Include/objimpl.h
@@ -109,7 +109,7 @@ PyAPI_FUNC(Py_ssize_t) _Py_GetAllocatedBlocks(void);
/* Macros */
#ifdef WITH_PYMALLOC
#ifndef Py_LIMITED_API
-PyAPI_FUNC(void) _PyObject_DebugMallocStats(FILE *out);
+PyAPI_FUNC(int) _PyObject_DebugMallocStats(FILE *out);
#endif /* #ifndef Py_LIMITED_API */
#endif
diff --git a/Include/pymem.h b/Include/pymem.h
index 09d1502..8ee0efd 100644
--- a/Include/pymem.h
+++ b/Include/pymem.h
@@ -24,10 +24,6 @@ PyAPI_FUNC(int) _PyMem_SetupAllocators(const char *opt);
/* Try to get the allocators name set by _PyMem_SetupAllocators(). */
PyAPI_FUNC(const char*) _PyMem_GetAllocatorsName(void);
-#ifdef WITH_PYMALLOC
-PyAPI_FUNC(int) _PyMem_PymallocEnabled(void);
-#endif
-
/* Track an allocated memory block in the tracemalloc module.
Return 0 on success, return -1 on error (failed to allocate memory to store
the trace).
diff --git a/Include/pystate.h b/Include/pystate.h
index cf45b05..d149aeb 100644
--- a/Include/pystate.h
+++ b/Include/pystate.h
@@ -36,6 +36,8 @@ typedef struct {
int import_time; /* -X importtime */
int show_ref_count; /* -X showrefcount */
int show_alloc_count; /* -X showalloccount */
+ int dump_refs; /* PYTHONDUMPREFS */
+ int malloc_stats; /* PYTHONMALLOCSTATS */
} _PyCoreConfig;
#define _PyCoreConfig_INIT (_PyCoreConfig){.use_hash_seed = -1}
@@ -111,7 +113,7 @@ typedef struct _is {
PyObject *after_forkers_child;
#endif
} PyInterpreterState;
-#endif
+#endif /* !Py_LIMITED_API */
/* State unique per thread */
@@ -133,7 +135,7 @@ typedef int (*Py_tracefunc)(PyObject *, struct _frame *, int, PyObject *);
#define PyTrace_C_EXCEPTION 5
#define PyTrace_C_RETURN 6
#define PyTrace_OPCODE 7
-#endif
+#endif /* Py_LIMITED_API */
#ifdef Py_LIMITED_API
typedef struct _ts PyThreadState;
@@ -238,7 +240,7 @@ typedef struct _ts {
/* XXX signal handlers should also be here */
} PyThreadState;
-#endif
+#endif /* !Py_LIMITED_API */
PyAPI_FUNC(PyInterpreterState *) PyInterpreterState_New(void);
@@ -363,7 +365,7 @@ PyAPI_FUNC(int) PyGILState_Check(void);
Return NULL before _PyGILState_Init() is called and after _PyGILState_Fini()
is called. */
PyAPI_FUNC(PyInterpreterState *) _PyGILState_GetInterpreterStateUnsafe(void);
-#endif
+#endif /* !Py_LIMITED_API */
/* The implementation of sys._current_frames() Returns a dict mapping