summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiampaolo Rodola <g.rodola@gmail.com>2016-03-01 15:46:19 +0100
committerGiampaolo Rodola <g.rodola@gmail.com>2016-03-01 15:46:19 +0100
commitf2a1a605eb9e43e6e6d7a8d911eb3df73ec791ec (patch)
treed6dade5f59f88edc01746121f2bbb3f220c5205c
parent47199f2a15b5c6b6dc3f18e87cbea687c52bac13 (diff)
downloadpsutil-f2a1a605eb9e43e6e6d7a8d911eb3df73ec791ec.tar.gz
update doc
-rw-r--r--README.rst2
-rw-r--r--docs/index.rst11
2 files changed, 6 insertions, 7 deletions
diff --git a/README.rst b/README.rst
index 2a88f934..1559636b 100644
--- a/README.rst
+++ b/README.rst
@@ -226,7 +226,7 @@ Process management
pgids(real=1000, effective=1000, saved=1000)
>>>
>>> p.cpu_times()
- pcputimes(user=1.02, system=0.31)
+ pcputimes(user=1.02, system=0.31, children_user=0.32, children_system=0.1)
>>> p.cpu_percent(interval=1.0)
12.1
>>> p.cpu_affinity()
diff --git a/docs/index.rst b/docs/index.rst
index 9d4b8c22..0a0674d4 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -915,12 +915,11 @@ Process class
.. method:: cpu_times()
- Return a tuple whose values are process CPU **user** and **system**
- times which means the amount of time expressed in seconds that a process
- has spent in
- `user / system mode <http://stackoverflow.com/questions/556405/what-do-real-user-and-sys-mean-in-the-output-of-time1>`__.
- On Linux, BSD and SunOS it also return two extra fields: **children_user**
- and **children_system**.
+ Return a (user, system) namedtuple representing the accumulated process
+ time, in seconds (see
+ `explanation <http://stackoverflow.com/questions/556405/>`__).
+ On Linux, BSD and SunOS the namedtuple also includes `children_user` times
+ and `children_system` times.
This is similar to
`os.times() <http://docs.python.org//library/os.html#os.times>`__
but can be used for any process PID.