Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
pypy.org
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PyPy
pypy.org
Commits
aa71b020
Commit
aa71b020
authored
13 years ago
by
Armin Rigo
Browse files
Options
Downloads
Patches
Plain Diff
Add a paragraph "Abuse of itertools".
parent
b51f57e3
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
source/performance.txt
+9
-0
9 additions, 0 deletions
source/performance.txt
with
9 additions
and
0 deletions
source/performance.txt
+
9
−
0
View file @
aa71b020
...
...
@@ -68,6 +68,15 @@
sometimes not. In most cases (like ``csv`` and ``cPickle``), we're slower
than cPython, with the notable exception of ``json`` and ``heapq``.
* **Abuse of itertools**: The itertools module is often "abused" in the
sense that it is used for the wrong purposes. From our point of view,
itertools is great if you have iterations over millions of items, but
not for most other cases. It gives you 3 lines in functional style
that replace 10 lines of Python loops (longer but arguably much easier
to read). The pure Python version is generally not slower even on
CPython, and on PyPy it allows the JIT to work much better --- simple
Python code is fast.
We generally consider things that are slower on PyPy than CPython to be bugs
of PyPy. If you find some issue that is not documented here,
please report it to our `bug tracker`_ for investigation.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment