mirror of
https://github.com/johndoe6345789/typthon.git
synced 2026-04-24 13:45:05 +00:00
Fixed additional patterns: - _PyOpcode_* → _TyOpcode_* (all opcode metadata) - _PyUOpName → _TyUOpName - _PyFunction_* → _TyFunction_* - _PyListIterObject → _TyListIterObject - _Py_T_OBJECT → _Ty_T_OBJECT - Py_BEGIN_ALLOW_THREADS, Py_END_ALLOW_THREADS → Ty_* - PyDoc_STRVAR, PyDoc_STR → TyDoc_* - PyInterpreterState, PyThread_*, PyTime_t → Ty* - PyStructSequence_* → TyStructSequence_* - PyLockStatus → TyLockStatus - PyVarObject_HEAD_INIT → TyVarObject_HEAD_INIT - PyBaseExceptionObject → TyBaseExceptionObject - Fixed _PyExc_ → _TyExc_ in exception macros Build is progressing further. Co-authored-by: johndoe6345789 <224850594+johndoe6345789@users.noreply.github.com>
44 lines
1.6 KiB
C
44 lines
1.6 KiB
C
#ifndef Ty_CPYTHON_CEVAL_H
|
|
# error "this header file must not be included directly"
|
|
#endif
|
|
|
|
PyAPI_FUNC(void) TyEval_SetProfile(Ty_tracefunc, TyObject *);
|
|
PyAPI_FUNC(void) TyEval_SetProfileAllThreads(Ty_tracefunc, TyObject *);
|
|
PyAPI_FUNC(void) TyEval_SetTrace(Ty_tracefunc, TyObject *);
|
|
PyAPI_FUNC(void) TyEval_SetTraceAllThreads(Ty_tracefunc, TyObject *);
|
|
|
|
/* Look at the current frame's (if any) code's co_flags, and turn on
|
|
the corresponding compiler flags in cf->cf_flags. Return 1 if any
|
|
flag was set, else return 0. */
|
|
PyAPI_FUNC(int) TyEval_MergeCompilerFlags(PyCompilerFlags *cf);
|
|
|
|
PyAPI_FUNC(TyObject *) _TyEval_EvalFrameDefault(TyThreadState *tstate, struct _PyInterpreterFrame *f, int exc);
|
|
|
|
PyAPI_FUNC(Ty_ssize_t) PyUnstable_Eval_RequestCodeExtraIndex(freefunc);
|
|
// Old name -- remove when this API changes:
|
|
_Ty_DEPRECATED_EXTERNALLY(3.12) static inline Ty_ssize_t
|
|
_TyEval_RequestCodeExtraIndex(freefunc f) {
|
|
return PyUnstable_Eval_RequestCodeExtraIndex(f);
|
|
}
|
|
|
|
PyAPI_FUNC(int) _TyEval_SliceIndex(TyObject *, Ty_ssize_t *);
|
|
PyAPI_FUNC(int) _TyEval_SliceIndexNotNone(TyObject *, Ty_ssize_t *);
|
|
|
|
|
|
// Trampoline API
|
|
|
|
typedef struct {
|
|
FILE* perf_map;
|
|
TyThread_type_lock map_lock;
|
|
} PerfMapState;
|
|
|
|
PyAPI_FUNC(int) PyUnstable_PerfMapState_Init(void);
|
|
PyAPI_FUNC(int) PyUnstable_WritePerfMapEntry(
|
|
const void *code_addr,
|
|
unsigned int code_size,
|
|
const char *entry_name);
|
|
PyAPI_FUNC(void) PyUnstable_PerfMapState_Fini(void);
|
|
PyAPI_FUNC(int) PyUnstable_CopyPerfMapFile(const char* parent_filename);
|
|
PyAPI_FUNC(int) PyUnstable_PerfTrampoline_CompileCode(PyCodeObject *);
|
|
PyAPI_FUNC(int) PyUnstable_PerfTrampoline_SetPersistAfterFork(int enable);
|