[Python-checkins] python/dist/src/Python ceval.c,2.401,2.402

mondragon at users.sourceforge.net mondragon at users.sourceforge.net
Mon Jun 21 23:51:41 EDT 2004


Update of /cvsroot/python/python/dist/src/Python
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12985/Python

Modified Files:
	ceval.c 
Log Message:
Making C profiling a configure option (at least temporarily)


Index: ceval.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/ceval.c,v
retrieving revision 2.401
retrieving revision 2.402
diff -C2 -d -r2.401 -r2.402
*** ceval.c	21 Jun 2004 16:31:14 -0000	2.401
--- ceval.c	22 Jun 2004 03:51:38 -0000	2.402
***************
*** 3503,3515 ****
--- 3503,3523 ----
  			PyObject *self = PyCFunction_GET_SELF(func);
  			if (flags & METH_NOARGS && na == 0) {
+ #ifdef WITH_C_PROF
   				BEGIN_C_TRACE
+ #endif
  				x = (*meth)(self, NULL);
+ #ifdef WITH_C_PROF
  				END_C_TRACE
+ #endif
  			}
  			else if (flags & METH_O && na == 1) {
  				PyObject *arg = EXT_POP(*pp_stack);
+ #ifdef WITH_C_PROF
  				BEGIN_C_TRACE
+ #endif
  				x = (*meth)(self, arg);
+ #ifdef WITH_C_PROF
  				END_C_TRACE
+ #endif
  				Py_DECREF(arg);
  			}
***************
*** 3522,3526 ****
--- 3530,3536 ----
  			PyObject *callargs;
  			callargs = load_args(pp_stack, na);
+ #ifdef WITH_C_PROF
  			BEGIN_C_TRACE
+ #endif
  #ifdef WITH_TSC
  			rdtscll(*pintr0);
***************
*** 3530,3534 ****
--- 3540,3546 ----
  			rdtscll(*pintr1);
  #endif
+ #ifdef WITH_C_PROF
  			END_C_TRACE
+ #endif
  			Py_XDECREF(callargs);
  		}




More information about the Python-checkins mailing list