summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_peepholer.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove test for BINARY_DIVIDE.Raymond Hettinger2005-01-071-1/+0
|
* Teach the peephole optimizer to fold simple constant expressions.Raymond Hettinger2005-01-021-0/+28
|
* Maintain peepholer's cumlc invariant by updating the running totalRaymond Hettinger2004-11-021-3/+5
| | | | | | everytime a LOAD_CONSTANT is encountered, created, or overwritten. Added two tests to cover cases affected by the patch.
* SF bug #1053819: Segfault in tuple_of_constantsRaymond Hettinger2004-10-261-0/+17
| | | | | | | Peepholer could be fooled into misidentifying a tuple_of_constants. Added code to count consecutive occurrences of LOAD_CONST. Use the count to weed out the misidentified cases. Added a unittest.
* SF patch #1031667: Fold tuples of constants into a single constantRaymond Hettinger2004-09-221-3/+13
| | | | | | | | Example: >>> import dis >>> dis.dis(compile('1,2,3', '', 'eval')) 0 0 LOAD_CONST 3 ((1, 2, 3)) 3 RETURN_VALUE
* Whitespace normalization.Tim Peters2004-08-261-5/+5
|
* SF Patch #1013667: Cleanup Peepholer OutputRaymond Hettinger2004-08-231-0/+104
* Make a pass to eliminate NOPs. Produce code that is more readable, more compact, and a tiny bit faster. Makes the peepholer more flexible in the scope of allowable transformations. * With Guido's okay, bumped up the magic number so that this patch gets widely exercised before the alpha goes out.