fix nogil profiling
authorRobert Bradshaw <robertwb@math.washington.edu>
Mon, 20 Jul 2009 23:29:54 +0000 (16:29 -0700)
committerRobert Bradshaw <robertwb@math.washington.edu>
Mon, 20 Jul 2009 23:29:54 +0000 (16:29 -0700)
Cython/Compiler/Nodes.py

index 3a821c3786711db6dd2812c1bc6358cd90ad4d32..a0ee977ccac2213bc790055eaaa2dfe66734f85f 100644 (file)
@@ -1057,7 +1057,7 @@ class FuncDefNode(StatNode, BlockNode):
                              self.entry.scope.is_c_class_scope)
         
         if code.globalstate.directives['profile'] is None:
-            profile = 'inline' not in self.modifiers
+            profile = 'inline' not in self.modifiers and not lenv.nogil
         else:
             profile = code.globalstate.directives['profile']
             if profile and lenv.nogil:
@@ -5788,7 +5788,7 @@ proto="""
 # but maybe some other profilers don't. 
 
 trace_utility_code = UtilityCode(proto="""
-#define CYTHON_TRACING 0
+#define CYTHON_TRACING 1
 #define CYTHON_TRACING_REUSE_FRAME 0
 
 #if CYTHON_TRACING