[SOT][3.14] Update the internal function to use PyObject_GC_Track replace _PyObject_GC_TRACK#78558
Conversation
… `PyObject_GC_Track`
|
你的PR提交成功,感谢你对开源项目的贡献! |
There was a problem hiding this comment.
Pull request overview
This PR fixes CPython 3.14 internal-API integration issues in Paddle’s SOT pybind layer, addressing compilation problems in debug builds by adjusting which CPython headers/APIs are used.
Changes:
- Include
internal/pycore_genobject.hto ensure_PyGen_GetGeneratorFromFrameand related generator internals are available for compilation. - Replace
_PyObject_GC_TRACKusage with the publicPyObject_GC_TrackAPI when tracking frame objects for GC.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| } | ||
| if (!_PyObject_GC_IS_TRACKED((PyObject *)f)) { | ||
| _PyObject_GC_TRACK((PyObject *)f); | ||
| PyObject_GC_Track((PyObject *)f); | ||
| } |
There was a problem hiding this comment.
The PR title says to replace PyObject_GC_Track with _PyObject_GC_TRACK, but the actual change does the opposite (switches _PyObject_GC_TRACK to PyObject_GC_Track). Please update the title (and/or description) to match the implemented fix to avoid confusion for reviewers and release notes.
|
@ShigureNyako 喵子来 review 下,是 #78484 遇到的 SOT CI 问题的修复 PR |
_PyObject_GC_TRACK replace PyObject_GC_Track_PyObject_GC_TRACK replace PyObject_GC_Track
_PyObject_GC_TRACK replace PyObject_GC_Track_PyObject_GC_TRACK replace PyObject_GC_Track
_PyObject_GC_TRACK replace PyObject_GC_TrackPyObject_GC_Track replace _PyObject_GC_TRACK
|
@ShigureNyako 排查一下 PR-CI-SOT 的日志看看是什么原因导致的 |
…eplace `_PyObject_GC_TRACK` (PaddlePaddle#78558) --------- Co-authored-by: Nyakku Shigure <sigure.qaq@gmail.com>
PR Category
Execute Infrastructure
PR Types
Bug fixes
Description
_PyGen_GetGeneratorFromFrame内部函数编译错误_PyObject_GC_TRACK内部函数因为宏展开导致的更多内部函数使用,报错:undefined symbol: _Py_TriggerGC。 改用公开的 apiPyObject_GC_Track相关链接
是否引起精度变化
否