| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
| static int uop_optimize_initialized = 0; | ||
| static int uop_optimize_flag = 0; |
There was a problem hiding this comment.
This isn't thread safe or subinterpreter safe. You might want to store the value in a PyThreadState / PyInterpreterState in pylifecycle.c instead.
Sorry, something went wrong.
|
@mdboom did you have a change planned for this? |
Sorry, something went wrong.
No, I don't have a plan. Thanks to @Wulian233 for taking this on. |
Sorry, something went wrong.
| initialize_uops_optimize_flag(void) { | ||
| if (!uops_optimize_initialized) { | ||
| PyInterpreterState *interp = _PyInterpreterState_GET(); | ||
| char *env_var = Py_GETENV("PYTHON_UOPS_OPTIMIZE"); |
There was a problem hiding this comment.
Can you please do this instead at where we check for PYTHON_JIT ? So in pylifecycle.c.
Set the thread state/interp state there as well.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
This is my first time PR for part C, which looks like it might be a small improvement, hopefully I'm not doing anything wrong🙂
About 0.5% faster? (from issue)