Skip to content

Move new vector private declarations to the internal C API #81375

Closed

Description

@vstinner
BPO 37194
Nosy @vstinner, @jdemeyer
PRs
  • bpo-37194: Add a new public PyObject_CallNoArgs() function #13890
  • bpo-37194: Complete PyObject_CallXXX() docs #14156
  • [3.8] bpo-37194: Complete PyObject_CallXXX() docs (GH-14156) #14157
  • [3.7] bpo-37194: Complete PyObject_CallXXX() docs (GH-14156) #14158
  • bpo-37194: Add PyObject_CallNoArgs() rationale #14159
  • bpo-39245: Make Vectorcall public #17893
  • Add symbols of the stable ABI to python3dll.c #23598
  • [3.9] bpo-42415: Add symbols of the stable ABI to python3dll.c (GH-23598) #23801
  • Files
  • stack_overflow-4.py
  • testcapi_call_no_args.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2019-06-17.13:09:16.423>
    created_at = <Date 2019-06-07.11:54:00.354>
    labels = ['interpreter-core', '3.8', '3.9']
    title = 'Move new vector private declarations to the internal C API'
    updated_at = <Date 2020-12-16.21:41:55.141>
    user = 'https://github.com/vstinner'

    bugs.python.org fields:

    activity = <Date 2020-12-16.21:41:55.141>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2019-06-17.13:09:16.423>
    closer = 'vstinner'
    components = ['Interpreter Core']
    creation = <Date 2019-06-07.11:54:00.354>
    creator = 'vstinner'
    dependencies = []
    files = ['48400', '48401']
    hgrepos = []
    issue_num = 37194
    keywords = ['patch']
    message_count = 12.0
    messages = ['344927', '344929', '344936', '344960', '345852', '345854', '345855', '345857', '345858', '345862', '383166', '383208']
    nosy_count = 2.0
    nosy_names = ['vstinner', 'jdemeyer']
    pr_nums = ['13890', '14156', '14157', '14158', '14159', '17893', '23598', '23801']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue37194'
    versions = ['Python 3.8', 'Python 3.9']

    Activity

    1. vstinner commented on Jun 7, 2019

      @vstinner
      MemberAuthor

      bpo-37191: the new vector APIs declare "static inline" functions which are no C89 compatible and so cause compilation issues on pygobject3, python-dbus, xen (for example).

      I propose to move the new *private* declarations to the internal C API.

      I started to work on an application. The blocker issue is _PyObject_CallNoArg() which is now commonly used in CPython code base for best performances. It is used the _testcapi which must *not* be compiled with the internal C API.

      So I suggest to first add a new public PyObject_CallNoArg() function. It would be different than _PyObject_CallNoArg() static inline function: PyObject_CallNoArg() would be a regular function and so fit better with ABI issues.

    2. added
      3.8 (EOL)
      3.9 (EOL)
      interpreter-core
      on Jun 7, 2019
    3. changed the title [-]Move new vector headers to the internal C API[/-] [+]Move new vector private declarations to the internal C API[/+] on Jun 7, 2019
    4. jdemeyer commented on Jun 7, 2019

      @jdemeyer
      Contributor

      I propose to move the new *private* declarations to the internal C API.

      Some of those functions (in particular _PyObject_Vectorcall) are expected to become public in 3.9. They are only private for now since the API is provisional.

    5. vstinner commented on Jun 7, 2019

      @vstinner
      MemberAuthor

      I used testcapi_call_no_args.patch and stack_overflow-4.py to measure the stack consumption of PyObject_CallNoArgs() and PyObject_CallFunctionObjArgs() for PR 13890.

    6. vstinner commented on Jun 7, 2019

      @vstinner
      MemberAuthor

      Oh, I used the wrong bpo number for this change:

      New changeset 740a84d by Victor Stinner in branch 'master':
      bpo-37191: Move TestPEP590 from test_capi to test_call (GH-13892)
      740a84d

      New changeset 5effd10 by Miss Islington (bot) in branch '3.8':
      bpo-37191: Move TestPEP590 from test_capi to test_call (GH-13892)
      5effd10

    7. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      New changeset 2ff58a2 by Victor Stinner in branch 'master':
      bpo-37194: Add a new public PyObject_CallNoArgs() function (GH-13890)
      2ff58a2

    8. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      New changeset 1ce2656 by Victor Stinner in branch 'master':
      bpo-37194: Complete PyObject_CallXXX() docs (GH-14156)
      1ce2656

    9. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      bpo-37191: the new vector APIs declare "static inline" functions which are no C89 compatible and so cause compilation issues on pygobject3, python-dbus, xen (for example).

      bpo-37191 have been fixed, so this issue can now be closed.

    10. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      New changeset ac4202e by Victor Stinner in branch '3.7':
      bpo-37194: Complete PyObject_CallXXX() docs (GH-14156) (GH-14158)
      ac4202e

    11. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      New changeset 71031cf by Victor Stinner in branch '3.8':
      bpo-37194: Complete PyObject_CallXXX() docs (GH-14156) (GH-14157)
      71031cf

    12. vstinner commented on Jun 17, 2019

      @vstinner
      MemberAuthor

      New changeset 5352cc4 by Victor Stinner in branch 'master':
      bpo-37194: Add PyObject_CallNoArgs() rationale (GH-14159)
      5352cc4

    13. vstinner commented on Dec 16, 2020

      @vstinner
      MemberAuthor

      New changeset fcc6935 by Victor Stinner in branch 'master':
      Add symbols of the stable ABI to python3dll.c (GH-23598)
      fcc6935

    14. vstinner commented on Dec 16, 2020

      @vstinner
      MemberAuthor

      New changeset 1662868 by Victor Stinner in branch '3.9':
      Add symbols of the stable ABI to python3dll.c (GH-23598) (GH-23801)
      1662868

    15. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      3.8 (EOL)3.9 (EOL)interpreter-core

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions