summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/profile.rst2
-rw-r--r--Doc/library/time.rst8
2 files changed, 9 insertions, 1 deletions
diff --git a/Doc/library/profile.rst b/Doc/library/profile.rst
index 5796e3a..68f24ab 100644
--- a/Doc/library/profile.rst
+++ b/Doc/library/profile.rst
@@ -575,7 +575,7 @@ procedure can be used to obtain a better constant for a given platform (see
The method executes the number of Python calls given by the argument, directly
and again under the profiler, measuring the time for both. It then computes the
hidden overhead per profiler event, and returns that as a float. For example,
-on a 1.8Ghz Intel Core i5 running Mac OS X, and using Python's time.clock() as
+on a 1.8Ghz Intel Core i5 running Mac OS X, and using Python's time.process_time() as
the timer, the magical number is about 4.04e-6.
The object of this exercise is to get a fairly consistent result. If your
diff --git a/Doc/library/time.rst b/Doc/library/time.rst
index 25a4ab5..c5d1e83 100644
--- a/Doc/library/time.rst
+++ b/Doc/library/time.rst
@@ -289,6 +289,9 @@ Functions
.. function:: perf_counter()
+ .. index::
+ single: benchmarking
+
Return the value (in fractional seconds) of a performance counter, i.e. a
clock with the highest available resolution to measure a short duration. It
does include time elapsed during sleep and is system-wide. The reference
@@ -300,6 +303,11 @@ Functions
.. function:: process_time()
+ .. index::
+ single: CPU time
+ single: processor time
+ single: benchmarking
+
Return the value (in fractional seconds) of the sum of the system and user
CPU time of the current process. It does not include time elapsed during
sleep. It is process-wide by definition. The reference point of the