mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Fix up a few style nits -- avoid "e.g." and "i.e." -- these make
translation more difficult, as well as reading the English more difficult for non-native speakers.
This commit is contained in:
parent
19b1c6156b
commit
907e76b620
17 changed files with 105 additions and 98 deletions
|
@ -319,8 +319,8 @@ made in calls to sub-functions),
|
|||
is the quotient of \code{tottime} divided by \code{ncalls}
|
||||
|
||||
\item[cumtime ]
|
||||
is the total time spent in this and all subfunctions (i.e., from
|
||||
invocation till exit). This figure is accurate \emph{even} for recursive
|
||||
is the total time spent in this and all subfunctions (from invocation
|
||||
till exit). This figure is accurate \emph{even} for recursive
|
||||
functions.
|
||||
|
||||
\item[percall ]
|
||||
|
@ -331,11 +331,11 @@ provides the respective data of each function
|
|||
|
||||
\end{description}
|
||||
|
||||
When there are two numbers in the first column (e.g.: \samp{43/3}),
|
||||
then the latter is the number of primitive calls, and the former is
|
||||
the actual number of calls. Note that when the function does not
|
||||
recurse, these two values are the same, and only the single figure is
|
||||
printed.
|
||||
When there are two numbers in the first column (for example,
|
||||
\samp{43/3}), then the latter is the number of primitive calls, and
|
||||
the former is the actual number of calls. Note that when the function
|
||||
does not recurse, these two values are the same, and only the single
|
||||
figure is printed.
|
||||
|
||||
\end{funcdesc}
|
||||
|
||||
|
@ -355,7 +355,7 @@ The file selected by the above constructor must have been created by
|
|||
the corresponding version of \module{profile}. To be specific, there is
|
||||
\emph{no} file compatibility guaranteed with future versions of this
|
||||
profiler, and there is no compatibility with files produced by other
|
||||
profilers (e.g., the old system profiler).
|
||||
profilers (such as the old system profiler).
|
||||
|
||||
If several files are provided, all the statistics for identical
|
||||
functions will be coalesced, so that an overall view of several
|
||||
|
@ -377,7 +377,7 @@ modifies the object, and the stripped information is lost. After
|
|||
performing a strip operation, the object is considered to have its
|
||||
entries in a ``random'' order, as it was just after object
|
||||
initialization and loading. If \method{strip_dirs()} causes two
|
||||
function names to be indistinguishable (i.e., they are on the same
|
||||
function names to be indistinguishable (they are on the same
|
||||
line of the same filename, and have the same function name), then the
|
||||
statistics for these two entries are accumulated into a single entry.
|
||||
\end{methoddesc}
|
||||
|
@ -423,7 +423,7 @@ defined:
|
|||
|
||||
Note that all sorts on statistics are in descending order (placing
|
||||
most time consuming items first), where as name, file, and line number
|
||||
searches are in ascending order (i.e., alphabetical). The subtle
|
||||
searches are in ascending order (alphabetical). The subtle
|
||||
distinction between \code{'nfl'} and \code{'stdname'} is that the
|
||||
standard name is a sort of the name as printed, which means that the
|
||||
embedded line numbers get compared in an odd way. For example, lines
|
||||
|
@ -538,10 +538,10 @@ value was obtained (and then squirreled away), until the user's code
|
|||
is once again executing. As a result, functions that are called many
|
||||
times, or call many functions, will typically accumulate this error.
|
||||
The error that accumulates in this fashion is typically less than the
|
||||
accuracy of the clock (i.e., less than one clock tick), but it
|
||||
accuracy of the clock (less than one clock tick), but it
|
||||
\emph{can} accumulate and become very significant. This profiler
|
||||
provides a means of calibrating itself for a given platform so that
|
||||
this error can be probabilistically (i.e., on the average) removed.
|
||||
this error can be probabilistically (on the average) removed.
|
||||
After the profiler is calibrated, it will be more accurate (in a least
|
||||
square sense), but it will sometimes produce negative numbers (when
|
||||
call counts are exceptionally low, and the gods of probability work
|
||||
|
@ -695,8 +695,8 @@ class MyProfiler(Profile):
|
|||
|
||||
The following derived profiler simulates the old style profiler,
|
||||
providing errant results on recursive functions. The reason for the
|
||||
usefulness of this profiler is that it runs faster (i.e., less
|
||||
overhead) than the old profiler. It still creates all the caller
|
||||
usefulness of this profiler is that it runs faster (less
|
||||
overhead) than the new profiler. It still creates all the caller
|
||||
stats, and is quite useful when there is \emph{no} recursion in the
|
||||
user's code. It is also a lot more accurate than the old profiler, as
|
||||
it does not charge all its overhead time to the user's code.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue