Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

We have run out of flags bits inPyTypeObject'stp_flags #134860

Open
Labels
@markshannon

Description

@markshannon

PyTypeObject'stp_flags field is defined as anunsigned long. In effect this means that we have only 32 bits we can use for flags. We have already used all 32 of them.

Bits 15 and 16 are reserved for Stackless Python. Since Stackless Python is pining for the fjords, we could recycle those two bits. However that's not going to last long with likely changes necessary for parallelism and performance.

Any change toPyTypeObject breaks both API and ABI, but that's OK because:

  • Adding a field or changing the size of a field is a backwards compatible API change.
  • The existence ofPyTypeObject is part of the stable ABI, but its layout is not.

The cleanest change, IMO, is to changeunsigned long tp_flags touint64_t tp_flags which gives us another 32 bits, which should last many more years.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp