Skip to content

[SOT][3.12] Support LOAD_ATTR opcode and skip PRECALL_CALL check in Python 3.12 - #61305

Merged
SigureMo merged 13 commits into
PaddlePaddle:developfrom
gouzil:sot_support_LOAD_ATTR
Feb 18, 2024
Merged

[SOT][3.12] Support LOAD_ATTR opcode and skip PRECALL_CALL check in Python 3.12#61305
SigureMo merged 13 commits into
PaddlePaddle:developfrom
gouzil:sot_support_LOAD_ATTR

Conversation

@gouzil

@gouzil gouzil commented Jan 29, 2024

Copy link
Copy Markdown
Member

PR types

Others

PR changes

Others

Description

python 3.12 支持LOAD_ATTR

LOAD_METHOD合并到LOAD_ATTR

相关链接:

@gouzil gouzil changed the title [SOT][3.12] supper LOAD_ATTR [SOT][3.12] supper LOAD_ATTR Jan 29, 2024
@paddle-bot paddle-bot Bot added the contributor External developers label Jan 29, 2024
SigureMo
SigureMo previously approved these changes Feb 5, 2024

@SigureMo SigureMo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTMeow

@SigureMo

SigureMo commented Feb 5, 2024

Copy link
Copy Markdown
Member

标题好好写一下

@gouzil gouzil changed the title [SOT][3.12] supper LOAD_ATTR [SOT][3.12] Support Python 3.12 LOAD_ATTR opcode and clean PRECALL_CALL Feb 5, 2024
}
elif sys.version_info >= (3, 12) and sys.version_info < (3, 13):
# Cache for some opcodes, it's for Python 3.12+
# https://github.com/python/cpython/blob/3.12/Include/internal/pycore_opcode.h#L41-L53

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

行号改一下呀

这段逻辑比较复杂了,包在函数里吧

@SigureMo SigureMo changed the title [SOT][3.12] Support Python 3.12 LOAD_ATTR opcode and clean PRECALL_CALL [SOT][3.12] Support LOAD_ATTR opcode and skip PRECALL_CALL check in Python 3.12 Feb 5, 2024

@SigureMo SigureMo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTMeow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor External developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants