Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
4e882ed7
Commit
4e882ed7
authored
Jan 29, 2001
by
Guido van Rossum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Time compilation and interpretation, too.
parent
67736dda
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
lib/python/TAL/timer.py
lib/python/TAL/timer.py
+4
-1
No files found.
lib/python/TAL/timer.py
View file @
4e882ed7
...
...
@@ -92,6 +92,7 @@ import time
import
getopt
from
driver
import
parsefile
,
copytree
,
talizetree
,
printtree
,
FILE
from
driver
import
compiletree
,
interpretit
def
main
():
count
=
10
...
...
@@ -109,9 +110,11 @@ def main():
file
=
FILE
doc
=
timefunc
(
count
,
parsefile
,
file
)
doc
=
timefunc
(
count
,
copytree
,
doc
)
doc
=
timefunc
(
count
,
talizetree
,
doc
)
doc
2
=
timefunc
(
count
,
talizetree
,
doc
)
timefunc
(
count
,
printtree
,
doc
,
open
(
"/dev/null"
,
"w"
))
timefunc
(
count
,
findmacros
,
doc
)
it
=
timefunc
(
count
,
compiletree
,
doc
)
timefunc
(
count
,
interpretit
,
it
,
None
,
open
(
"/dev/null"
,
"w"
))
def
timefunc
(
count
,
func
,
*
args
):
sys
.
stderr
.
write
(
"%-14s: "
%
func
.
__name__
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment