From: Julian Gilbey <jdg@debian.org>
Date: Tue, 28 Oct 2025 12:16:57 -0700
Subject: Remove -O3 compile flag

Forwarded: not-needed
Last-Update: 2024-06-30

 We use the standard Debian compilation flags
---
 setup.py               | 2 +-
 setup_pydevd_cython.py | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/setup.py b/setup.py
index 0434634..d99ea94 100644
--- a/setup.py
+++ b/setup.py
@@ -116,7 +116,7 @@ try:
         # Enabling -flto brings executable from 4MB to 0.56MB and -Os to 0.41MB
         # Profiling shows an execution around 3-5% slower with -Os vs -O3,
         # so, kept only -flto.
-        extra_compile_args = ["-flto", "-O3"]
+        extra_compile_args = ["-flto"]
         extra_link_args = extra_compile_args[:]
 
         # Note: also experimented with profile-guided optimization. The executable
diff --git a/setup_pydevd_cython.py b/setup_pydevd_cython.py
index 5d6ca0d..af407b8 100644
--- a/setup_pydevd_cython.py
+++ b/setup_pydevd_cython.py
@@ -190,7 +190,7 @@ def build_extension(dir_name, extension_name, target_pydevd_name, force_cython,
             # Enabling -flto brings executable from 4MB to 0.56MB and -Os to 0.41MB
             # Profiling shows an execution around 3-5% slower with -Os vs -O3,
             # so, kept only -flto.
-            extra_compile_args = ["-flto", "-O3"]
+            extra_compile_args = ["-flto"]
             extra_link_args = extra_compile_args[:]
 
             # Note: also experimented with profile-guided optimization. The executable
