Revision: 1079
Author: tim.bunce
Date: Sun Feb 21 08:38:54 2010
Log: Use PL_clocktick instead of CLK_TCK
http://www.cpantesters.org/cpan/report/6849702

http://code.google.com/p/perl-devel-nytprof/source/detail?r=1079

Modified:
 /trunk/NYTProf.xs

=======================================
--- /trunk/NYTProf.xs   Sat Feb 20 08:49:23 2010
+++ /trunk/NYTProf.xs   Sun Feb 21 08:38:54 2010
@@ -1862,7 +1862,7 @@
ticks = (call_end_ctime.tms_utime - subr_entry->initial_call_cputimes.tms_utime) + (call_end_ctime.tms_stime - subr_entry->initial_call_cputimes.tms_stime); /* ignore overhead_ticks when using cputime because the resolution is so poor */
-        incl_subr_sec = (ticks / (NV)CLK_TCK);
+        incl_subr_sec = (ticks / (NV)PL_clocktick);
     }
     else {
         time_of_day_t sub_end_time;
@@ -2783,7 +2783,7 @@

     /* Save the process id early. We monitor it to detect forks */
     last_pid = getpid();
-    ticks_per_sec = (profile_usecputime) ? CLK_TCK : CLOCKS_PER_TICK;
+    ticks_per_sec = (profile_usecputime) ? PL_clocktick : CLOCKS_PER_TICK;
DB_INIT_cv = (SV*)GvCV(gv_fetchpv("DB::_INIT", FALSE, SVt_PVCV)); DB_fin_cv = (SV*)GvCV(gv_fetchpv("DB::finish_profile", FALSE, SVt_PVCV));

--
You've received this message because you are subscribed to
the Devel::NYTProf Development User group.

Group hosted at:  http://groups.google.com/group/develnytprof-dev
Project hosted at:  http://perl-devel-nytprof.googlecode.com
CPAN distribution:  http://search.cpan.org/dist/Devel-NYTProf

To post, email:  [email protected]
To unsubscribe, email:  [email protected]

Reply via email to