[issue44590] Create frame objects lazily when needed

2022-02-23 Thread STINNER Victor


STINNER Victor  added the comment:

I created bpo-46836: "[C API] Move PyFrameObject to the internal C API".

--
nosy: +vstinner

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-08-01 Thread Nick Coghlan


Nick Coghlan  added the comment:

The newly linked pull request isn't actually for this ticket, it's for 
bpo-44800, a follow-up refactoring proposal related to the variable, struct 
field, and API naming schemes used for the new lighter weight execution frames.

However, the commit message and PR description refer back to this ticket as 
well, so the RoundUp automation picked it up.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-08-01 Thread Nick Coghlan


Change by Nick Coghlan :


--
nosy: +ncoghlan
nosy_count: 3.0 -> 4.0
pull_requests: +26041
pull_request: https://github.com/python/cpython/pull/27525

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-07-29 Thread Mark Shannon


Change by Mark Shannon :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-07-26 Thread Mark Shannon


Mark Shannon  added the comment:


New changeset ae0a2b756255629140efcbe57fc2e714f0267aa3 by Mark Shannon in 
branch 'main':
bpo-44590: Lazily allocate frame objects (GH-27077)
https://github.com/python/cpython/commit/ae0a2b756255629140efcbe57fc2e714f0267aa3


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-07-09 Thread Mark Shannon


Change by Mark Shannon :


--
keywords: +patch
pull_requests: +25626
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/27077

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44590] Create frame objects lazily when needed

2021-07-09 Thread Mark Shannon


New submission from Mark Shannon :

In https://bugs.python.org/issue44032 we moved most of the data in the frame 
stack, that is the locals, stack, and "specials" (globals, builtins, code etc), 
from the heap allocated stack to a (mostly) contiguous array in memory.
That offered some speed up due to better cache locality, and faster allocation 
of frame objects (they are now fixed size so can use a simple freelist).

However, data is still split between the stack allocated frame and the heap 
allocated frame.

We should move the remaining data to the stack and only allocate heap objects 
lazily when needed for tracebacks and the like. This should improve performance 
further by removing the vast majority of heap frame allocations and further 
improving locality of reference.

Not only does this have immediate performance benefits, it also paves the way 
for even better Python-to-Python calls by allowing stack frames to overlap and 
pass arguments with the minimal amount of copying and INCREF/DECREF pairs.

--
assignee: Mark.Shannon
components: Interpreter Core
messages: 397196
nosy: Mark.Shannon, gvanrossum, pablogsal
priority: normal
severity: normal
status: open
title: Create frame objects lazily when needed
type: performance
versions: Python 3.11

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com