Skip to content

Conversation

gvanrossum
Copy link
Member

@gvanrossum gvanrossum commented Jul 6, 2023

This cleans up and fixes the tests for the uops optimizer and executor.
It also fixes a nasty crash when an optimizer is deallocated (which derailed gh-106489).

The uops test wasn't testing anything by default,
and was failing when run with -Xuops.

Made the two executor-related context managers global,
so TestUops can use them (notably `with temporary_optimizer(opt)`).

Made clear_executor() a little more thorough.
@gvanrossum gvanrossum requested a review from markshannon July 6, 2023 21:47
@gvanrossum gvanrossum merged commit 76fac7b into python:main Jul 6, 2023
@gvanrossum gvanrossum deleted the fix-uops-tests branch July 6, 2023 22:46
gvanrossum added a commit to gvanrossum/cpython that referenced this pull request Jul 6, 2023
…6492)

The uops test wasn't testing anything by default,
and was failing when run with -Xuops.

Made the two executor-related context managers global,
so TestUops can use them (notably `with temporary_optimizer(opt)`).

Made clear_executor() a little more thorough.

Fixed a crash upon finalizing a uop optimizer,
by adding a `tp_dealloc` handler.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants