| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
I think this might be a problem because in creation functions such as sym_new_not_null and sym_new_unknown, : cpython/Python/optimizer_symbols.c Lines 690 to 709 in fb8d8d9 PyJitRef_Wrap produces a ref with tag = 0. This means that tag = 0 is the default state, indicating “we have no specific information about borrowing/ownership,” rather than “definitely owned.” Only those explicitly marked with tag = 1 via PyJitRef_Borrow() are “known to be borrowed.” |
Sorry, something went wrong.
|
Mark also reminded me in the last PR: #144414 (review). |
Sorry, something went wrong.
|
Hmm Mark is indeed right. However, currently the only place that can generate borrowed references are LOAD_FAST_BORROW. I suspect we need to create a new tag bit for this to work. We only support good perf on 64 bit systems right now. I propose we drop the 32 bit Windows support so that we have 3 tag bits to use and can support "unknown" references. |
Sorry, something went wrong.
I also don’t think it’s necessary to maintain the performance of legacy systems |
Sorry, something went wrong.
|
I guess I'll mark this PR as draft for now until that is in? |
Sorry, something went wrong.
|
This PR is stale because it has been open for 30 days with no activity. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
If the reference of the returned object is not borrowed, we remove the _MAKE_HEAP_FUNCTION. Hence I ended up changing the test_make_heap_safe_optimized_owned test to test that _MAKE_HEAP_FUNCTION is no longer in the trace as the value returned is not a borrowed reference.
Also, for a "return of a return", given the inner function returns a borrowed reference, the double _MAKE_HEAP_FUNCTION is reduced to just 1 :)
I hope I didn't misunderstand the issue...