Skip to content

Commit b74396c

Browse files
authored
bpo-43166: Disable ceval.c optimisations for Windows debug builds (GH-24485)
This ensures that ceval.c can be debugged. Also remove some irrelevant options from the pragma.
1 parent da21f7b commit b74396c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Include/pyport.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -180,9 +180,9 @@ typedef int Py_ssize_clean_t;
180180
*/
181181

182182
#if defined(_MSC_VER)
183-
# if defined(PY_LOCAL_AGGRESSIVE)
184-
/* enable more aggressive optimization for visual studio */
185-
# pragma optimize("agtw", on)
183+
# if defined(PY_LOCAL_AGGRESSIVE) && !defined(Py_DEBUG)
184+
/* enable more aggressive optimization for MSVC */
185+
# pragma optimize("gt", on)
186186
#endif
187187
/* ignore warnings if the compiler decides not to inline a function */
188188
# pragma warning(disable: 4710)

0 commit comments

Comments
 (0)