-
-
Notifications
You must be signed in to change notification settings - Fork 30.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gh-116088: Insert bottom checks after all sym_set_...() calls #116089
Conversation
Let's go low-tech instead. This reverts commit 23d8a15.
FWIW I'm lukewarm about this. Likely the policy that all queries return false/NULL for |
Note: |
|
Yes, that's correct behavior with these checks. So should I just change that test to assert that the second call doesn't create an executor? |
Yes. |
Note to future readers: whether the test creates an executor or doesn't create one isn't too important to me IMO. As long as CPython doesn't execute incorrect behavior, everything is fine. |
Yeah, all these tests are way over-specified, and we regularly have to adjust them when the implementation changes. They are using internal introspection APIs to verify that the implementation did a specific thing. Unfortunately with optimizers you have to do such things -- if you just test the correct outcome, you'll never catch it when the optimizer just does nothing, and timing tests are out of the question (too flaky). |
…ython#116089) This changes the `sym_set_...()` functions to return a `bool` which is `false` when the symbol is `bottom` after the operation. All calls to such functions now check this result and go to `hit_bottom`, a special error label that prints a different message and then reports that it wasn't able to optimize the trace. No executor will be produced in this case.
…ython#116089) This changes the `sym_set_...()` functions to return a `bool` which is `false` when the symbol is `bottom` after the operation. All calls to such functions now check this result and go to `hit_bottom`, a special error label that prints a different message and then reports that it wasn't able to optimize the trace. No executor will be produced in this case.
…ython#116089) This changes the `sym_set_...()` functions to return a `bool` which is `false` when the symbol is `bottom` after the operation. All calls to such functions now check this result and go to `hit_bottom`, a special error label that prints a different message and then reports that it wasn't able to optimize the trace. No executor will be produced in this case.
Looking for reviews from @Fidget-Spinner and @markshannon. See the issue (gh-116088) for discussion.