Re: [Python-Dev] Third milestone of FAT Python

2015-12-17 Thread Franklin? Lee
On Wed, Dec 16, 2015 at 2:01 AM, Victor Stinner wrote: > Le mercredi 16 décembre 2015, Franklin? Lee > a écrit : >> >> I am confident that the time overhead and the savings will beat the >> versioning dict. The versioning dict method has

Re: [Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Victor Stinner
2015-12-15 12:23 GMT+01:00 Franklin? Lee : > I was thinking (as an alternative to versioning dicts) about a > dictionary which would be able to return name/value pairs, which would > also be internally used by the dictionary. This would be way less > sensitive to

Re: [Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Victor Stinner
2015-12-15 22:10 GMT+01:00 Franklin? Lee : > (Stealing your style of headers.) I'm using reStructured Text, it's not really a new style :-) > Overhead > > > If inner functions are being created a lot, that's extra work. But I > guess you should expect a

Re: [Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Franklin? Lee
I realized yet another thing, which will reduce overhead: the original array can store values directly, and you maintain the refs by repeatedly updating them when moving refs around. RefCells will point to a pointer to the value cell (which already exists in the table). - `getitem` will be

Re: [Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Franklin? Lee
More thoughts. (Stealing your style of headers.) Just store a pointer to value = Instead of having the inner dict store k_v pairs. In C, the values in our hash tables will be: struct refcell{ PyObject *value; // NULL if deleted }; It's not necessary

[Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Franklin? Lee
On Sat, Dec 04, 2015 at 7:49 AM, Victor Stinner wrote: > Versionned dictionary > = > > In the previous milestone of FAT Python, the versionned dictionary was a > new type inherited from the builtin dict type which added a __version__ > read-only

Re: [Python-Dev] Third milestone of FAT Python

2015-12-15 Thread Victor Stinner
Le mercredi 16 décembre 2015, Franklin? Lee a écrit : > > I am confident that the time overhead and the savings will beat the > versioning dict. The versioning dict method has to save a reference to > the variable value and a reference to the name, and regularly

Re: [Python-Dev] Third milestone of FAT Python

2015-12-07 Thread Nikolaus Rath
On Dec 04 2015, Victor Stinner wrote: > Hi, > > I implemented 3 new optimizations in FAT Python: loop unrolling, constant > folding and copy builtin functions to constants. In the previous thread, > Terry Reedy asked me if the test suite is complete enough to ensure that

Re: [Python-Dev] Third milestone of FAT Python

2015-12-06 Thread Emile van Sebille
On 12/4/2015 11:39 AM, MRAB wrote: On 2015-12-04 19:22, Isaac Morland wrote: On Fri, 4 Dec 2015, MRAB wrote: > Constant folding is when, say, "1 + 2" replaced by "2". Isn't that called backspacing? ;-) Oops! I meant "1 + 1", of course. Or "3". Either would work. :-) Oh, you must surely

[Python-Dev] Third milestone of FAT Python

2015-12-04 Thread Victor Stinner
Hi, I implemented 3 new optimizations in FAT Python: loop unrolling, constant folding and copy builtin functions to constants. In the previous thread, Terry Reedy asked me if the test suite is complete enough to ensure that FAT Python doesn't break the Python semantic. I can now say that the

Re: [Python-Dev] Third milestone of FAT Python

2015-12-04 Thread MRAB
On 2015-12-04 19:22, Isaac Morland wrote: On Fri, 4 Dec 2015, MRAB wrote: > Constant folding is when, say, "1 + 2" replaced by "2". Isn't that called backspacing? ;-) Oops! I meant "1 + 1", of course. Or "3". Either would work. :-) ___ Python-Dev

Re: [Python-Dev] Third milestone of FAT Python

2015-12-04 Thread Victor Stinner
2015-12-04 20:16 GMT+01:00 MRAB : > On 2015-12-04 12:49, Victor Stinner wrote: > [snip] > > I don't think that's constant folding, but constant _propagation_. > > Constant folding is when, say, "1 + 2" replaced by "2". Oh, you're right. I update the documentation. To

Re: [Python-Dev] Third milestone of FAT Python

2015-12-04 Thread MRAB
On 2015-12-04 12:49, Victor Stinner wrote: [snip] Constant folding This optimization propagates constant values of variables. Example: def func() x = 1 y = x return y Constant folding: def func() x = 1 y = 1

Re: [Python-Dev] Third milestone of FAT Python

2015-12-04 Thread Isaac Morland
On Fri, 4 Dec 2015, MRAB wrote: Constant folding is when, say, "1 + 2" replaced by "2". Isn't that called backspacing? ;-) Isaac Morland CSCF Web Guru DC 2619, x36650 WWW Software Specialist ___ Python-Dev mailing list