Skip to content

Array export and mass incref/decref #15

Open
@encukou

Description

@encukou

For a stable ABI -- of any flavor -- incref and decref will need to be functions, and so they'll be relatively expensive. We should allow minimizing their usage.

We're missing ways to:

  • Export Python containers to an array of PyObject* (strong references)
    • Preferably in batches (one by one iteration is too slow, everything at once eats memory)
    • Preferably with an option to convert to raw integers
  • Mass decref an array of PyObject*
  • Mass incref an array, to pass it on

Discussion in https://discuss.python.org/t/15993 (confusingly mixed with other topics -- please make a new topic rather than reply)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions