[Python-Dev] os.tmpfile() problem

2007-08-07 Thread Maciej Fijalkowski
I've got slight problem with os.tmpfile(). What I would like to do is to get the filedesc of tmpfile. First approach: os.tmpfile().fileno() of course does not work out, because fileno() does not keep object alive. The solution is to keep os.tmpfile() result somewhere for an arbitrary amount of

[Python-Dev] Segfault

2007-08-20 Thread Maciej Fijalkowski
IMHO this shouldn't segfault: import thread while 1: f = open(/tmp/dupa, w) thread.start_new_thread(f.close, ()) f.close() while it does on cpython 2.5.1, linux box. May I consider this a bug? ___ Python-Dev mailing list

Re: [Python-Dev] Segfault

2007-08-27 Thread Maciej Fijalkowski
Honestly, the argument that this code is already gone in 3.0 is not very valid. 2.x version would be probably used for many years. Cheers, fijal ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev

Re: [Python-Dev] __del__ and tp_dealloc in the IO lib

2009-01-23 Thread Maciej Fijalkowski
That would be break so much code that I doubt that, in practice, you can slip it through within a release. Besides, being able to write simpler code like for L in open(foo.txt) is per-se a good reason *not to* put file objects in cycles; so you will probably need more than one good reason to

Re: [Python-Dev] Core projects for Summer of Code

2009-03-18 Thread Maciej Fijalkowski
While working on the core is admirable, I think gsoc would provide an opportunity to port important Python libraries to 3.x. It's important to remember that doing ports helps the core immensely by uncovering 2to3 and py3k bugs. Hello. It's a very noble task to have important python

[Python-Dev] issue5578 - explanation

2009-03-31 Thread Maciej Fijalkowski
So. The issue was closed and I suppose it was closed by not entirely understanding the problem (or I didn't get it completely). The question is - what the following code should do? def f(): a = 2 class C: exec 'a = 42' abc = a return C print f().abc (quick answer - on python2.5

Re: [Python-Dev] issue5578 - explanation

2009-03-31 Thread Maciej Fijalkowski
attributes. I actually think the 2.5 behavior is correct, and I don't know why it changed in 2.6. --Guido On Tue, Mar 31, 2009 at 8:15 PM, Maciej Fijalkowski fij...@gmail.com wrote: So. The issue was closed and I suppose it was closed by not entirely understanding the problem (or I didn't get

Re: [Python-Dev] issue5578 - explanation

2009-03-31 Thread Maciej Fijalkowski
Shame on me indeed. On Wed, Apr 1, 2009 at 5:38 AM, Guido van Rossum gu...@python.org wrote: OK that might change matters. Shame on you though for posting a patch without any explanation of the issue. On Tue, Mar 31, 2009 at 8:36 PM, Maciej Fijalkowski fij...@gmail.com wrote: Because classes

Re: [Python-Dev] Correction: Python Bug Day on April 25

2009-04-15 Thread Maciej Fijalkowski
On Wed, Apr 15, 2009 at 1:10 PM, Georg Brandl ge...@python.org wrote: Hi, I managed to screw up the date, so here it goes again: I'd like to announce that there will be a Python Bug Day on April 25. As always, this is a perfect opportunity to get involved in Python development, or bring

Re: [Python-Dev] run time error anlysis of python source code

2009-06-21 Thread Maciej Fijalkowski
On Sun, Jun 21, 2009 at 5:05 PM, Daniel Dinizaja...@gmail.com wrote: Hi David, omega_force2...@yahoo.com wrote: It appears that one possibility of investigation into the development of a safety-critical variant of the python language There is some interesting work related to a

[Python-Dev] PyPy 1.7 - widening the sweet spot

2011-11-21 Thread Maciej Fijalkowski
== PyPy 1.7 - widening the sweet spot == We're pleased to announce the 1.7 release of PyPy. As became a habit, this release brings a lot of bugfixes and performance improvements over the 1.6 release. However, unlike the previous

Re: [Python-Dev] PyPy 1.7 - widening the sweet spot

2011-11-22 Thread Maciej Fijalkowski
On Tue, Nov 22, 2011 at 3:15 PM, Stefan Behnel stefan...@behnel.de wrote: Giampaolo Rodolà, 22.11.2011 10:21: 2011/11/21 Terry Reedy: I strongly recommend that where it makes a difference, the pypy python3 project target 3.3. In particular, don't reproduce the buggy narrow-build behavior of

Re: [Python-Dev] PyPy 1.7 - widening the sweet spot

2011-11-24 Thread Maciej Fijalkowski
On Wed, Nov 23, 2011 at 11:13 PM, Philip Jenvey pjen...@underboss.org wrote: On Nov 22, 2011, at 12:43 PM, Amaury Forgeot d'Arc wrote: 2011/11/22 Philip Jenvey pjen...@underboss.org One reason to target 3.2 for now is it's not a moving target. There's overhead involved in managing

Re: [Python-Dev] PEP 380

2011-11-25 Thread Maciej Fijalkowski
On Sat, Nov 26, 2011 at 6:39 AM, Nick Coghlan ncogh...@gmail.com wrote: On Sat, Nov 26, 2011 at 8:14 AM, Michael Foord fuzzy...@voidspace.org.uk wrote: On 24 Nov 2011, at 04:06, Nick Coghlan wrote: On Thu, Nov 24, 2011 at 10:28 AM, Guido van Rossum gu...@python.org wrote: Mea culpa for not

Re: [Python-Dev] A new dict for Xmas?

2011-12-17 Thread Maciej Fijalkowski
On Fri, Dec 16, 2011 at 11:32 PM, Terry Reedy tjre...@udel.edu wrote: On 12/16/2011 5:03 AM, Mark Shannon wrote: Of course using __slots__ saves more memory, but people don't use them much. Do you think the stdlib should be using __slots__ more? Note that unlike some other more advanced

Re: [Python-Dev] A new dict for Xmas?

2011-12-17 Thread Maciej Fijalkowski
On Sat, Dec 17, 2011 at 2:31 PM, Dirkjan Ochtman dirk...@ochtman.nl wrote: On Sat, Dec 17, 2011 at 12:53, Maciej Fijalkowski fij...@gmail.com wrote: Note that unlike some other more advanced approaches, slots do change semantics. There are many cases out there where people would stuff

Re: [Python-Dev] cpython (3.2): don't mention implementation detail

2011-12-20 Thread Maciej Fijalkowski
On Tue, Dec 20, 2011 at 10:51 AM, Antoine Pitrou solip...@pitrou.net wrote: On Mon, 19 Dec 2011 22:42:43 +0100 benjamin.peterson python-check...@python.org wrote: http://hg.python.org/cpython/rev/d85efd73b0e1 changeset:   74088:d85efd73b0e1 branch:      3.2 parent:      74082:71e5a083f9b1

Re: [Python-Dev] cpython (3.2): don't mention implementation detail

2011-12-20 Thread Maciej Fijalkowski
On Tue, Dec 20, 2011 at 12:14 PM, Dirkjan Ochtman dirk...@ochtman.nl wrote: On Tue, Dec 20, 2011 at 11:08, Antoine Pitrou solip...@pitrou.net wrote: If this documentation is to be used by other python implementations, then mentions of performance are outright harmful, since the performance

Re: [Python-Dev] Anyone still using Python 2.5?

2011-12-22 Thread Maciej Fijalkowski
On Thu, Dec 22, 2011 at 11:56 AM, Antoine Pitrou solip...@pitrou.net wrote: On Thu, 22 Dec 2011 09:44:32 + Tim Wintle timwin...@gmail.com wrote: 2.5 apps are the speed-critical ones. Our tests showed the performance was different enough between 2.5 and 2.6 for me to not update. Really?

Re: [Python-Dev] A new dict for Xmas?

2011-12-22 Thread Maciej Fijalkowski
- I wonder whether the shared keys could be computed at compile  time, considering all attribute names that get assigned for  self. The compiler could list those in the code object, and  class creation could iterate over all methods (taking base  classes into account). This is hard, because

Re: [Python-Dev] Hash collision security issue (now public)

2012-01-04 Thread Maciej Fijalkowski
On Wed, Jan 4, 2012 at 12:02 AM, Bill Janssen jans...@parc.com wrote: Christian Heimes li...@cheimes.de wrote: Am 29.12.2011 12:13, schrieb Mark Shannon: The attack relies on being able to predict the hash value for a given string. Randomising the string hash function is quite

Re: [Python-Dev] Hash collision security issue (now public)

2012-01-05 Thread Maciej Fijalkowski
On Thu, Jan 5, 2012 at 3:39 PM, Antoine Pitrou solip...@pitrou.net wrote: On Thu, 5 Jan 2012 15:26:27 +1100 Andrew Bennetts and...@bemusement.org wrote: I don't think that's news either. http://mail.python.org/pipermail/python-dev/2003-May/035907.html and

[Python-Dev] Python 3 benchmarks

2012-01-28 Thread Maciej Fijalkowski
Hi Something that's maybe worth mentioning is that the official python benchmark suite http://hg.python.org/benchmarks/ has a pretty incomplete set of benchmarks for python 3 compared to say what we run for pypy: https://bitbucket.org/pypy/benchmarks I think a very worthwhile project would be to

[Python-Dev] PyPy 1.8 released

2012-02-10 Thread Maciej Fijalkowski
PyPy 1.8 - business as usual We're pleased to announce the 1.8 release of PyPy. As habitual this release brings a lot of bugfixes, together with performance and memory improvements over the 1.7 release. The main highlight of the release is

Re: [Python-Dev] CPU vs Wall time Profiling

2012-02-21 Thread Maciej Fijalkowski
On Tue, Feb 21, 2012 at 2:00 PM, Sümer Cip sum...@gmail.com wrote: Hi all, Is there a reason behind the fact that the Python profilers work with Wall time by default? There are OS-dependent ways to get the CPU time of a thread, and giving that choice to the user _somehow_ ( to use wall vs cpu

Re: [Python-Dev] The ultimate question of life, the universe, and everything

2012-02-22 Thread Maciej Fijalkowski
On Wed, Feb 22, 2012 at 9:59 AM, mar...@v.loewis.de wrote: What is the hash of ePjNTUhitHkL? Regards, Martin P.S. It took me roughly 86h to compute 150 strings colliding for the 64-bit hash function. You should have used pypy, should have been faster.

Re: [Python-Dev] The ultimate question of life, the universe, and everything

2012-02-22 Thread Maciej Fijalkowski
On Wed, Feb 22, 2012 at 11:55 AM, Martin v. Löwis mar...@v.loewis.de wrote: Am 22.02.2012 19:46, schrieb Maciej Fijalkowski: On Wed, Feb 22, 2012 at 9:59 AM,  mar...@v.loewis.de wrote: What is the hash of ePjNTUhitHkL? Regards, Martin P.S. It took me roughly 86h to compute 150 strings

Re: [Python-Dev] Sandboxing Python

2012-03-03 Thread Maciej Fijalkowski
On Sat, Mar 3, 2012 at 1:37 PM, Victor Stinner victor.stin...@gmail.com wrote: Hi, Le 03/03/2012 20:13, Armin Rigo a écrit : I challenge anymore to break pysandbox! I would be happy if anyone breaks it because it would make it more stronger. I tried to run the files from Lib/test/crashers

Re: [Python-Dev] Sandboxing Python

2012-03-03 Thread Maciej Fijalkowski
On Sat, Mar 3, 2012 at 6:51 PM, Guido van Rossum gu...@python.org wrote: On Sat, Mar 3, 2012 at 6:02 PM, Maciej Fijalkowski fij...@gmail.com wrote: On Sat, Mar 3, 2012 at 1:37 PM, Victor Stinner victor.stin...@gmail.com wrote: Hi, Le 03/03/2012 20:13, Armin Rigo a écrit : I challenge

Re: [Python-Dev] Defending against stack overflow (was Sandboxing Python)

2012-03-04 Thread Maciej Fijalkowski
On Sun, Mar 4, 2012 at 12:35 PM, Martin v. Löwis mar...@v.loewis.de wrote: So, how to handle stack overflows (of the C stack)? To prevent a stack overflow an exception must be raised before the VM runs out C stack. To do this we need 2 pieces of info: a) How much stack we've used b) How much

Re: [Python-Dev] Sandboxing Python

2012-03-05 Thread Maciej Fijalkowski
On Mon, Mar 5, 2012 at 1:21 PM, Greg Ewing greg.ew...@canterbury.ac.nz wrote: Armin Rigo wrote: For example, let's assume we can decref a object to 0 before its last usage, at address x.  All you need is the skills and luck to arrange that the memory at x becomes occupied by a new bigger

Re: [Python-Dev] Sandboxing Python

2012-03-05 Thread Maciej Fijalkowski
On Mon, Mar 5, 2012 at 3:40 PM, Martin v. Löwis mar...@v.loewis.de wrote: I strongly disagree that sandbox is secure because it's just segfaults and any code is exploitable that way. Finding segfaults in CPython is easy. As in all you need is armin, a bit of coffee and a free day. Reasons for

Re: [Python-Dev] Non-string keys in type dict

2012-03-07 Thread Maciej Fijalkowski
On Wed, Mar 7, 2012 at 5:42 PM, Benjamin Peterson benja...@python.org wrote: 2012/3/7 Victor Stinner victor.stin...@gmail.com: So my question is: what is the use case of such dict? Why do we still support it? Probably a side-effect of implementation. Can't we simply raise an error if the

Re: [Python-Dev] PEP 414 - some numbers from the Django port

2012-03-08 Thread Maciej Fijalkowski
On Wed, Mar 7, 2012 at 2:36 PM, Vinay Sajip vinay_sa...@yahoo.co.uk wrote: Armin Ronacher armin.ronacher at active-4.com writes: What are you trying to argue?  That the overall Django testsuite does not do a lot of string processing, less processing with native strings? I'm surprised you see

Re: [Python-Dev] Playing with a new theme for the docs, iteration 2

2012-03-25 Thread Maciej Fijalkowski
On Sun, Mar 25, 2012 at 9:25 PM, Georg Brandl g.bra...@gmx.net wrote: On 25.03.2012 21:11, Steven D'Aprano wrote: Georg Brandl wrote: Thanks everyone for the overwhelmingly positive feedback.  I've committed the new design to 3.2 and 3.3 for now, and it will be live for the 3.3 docs

Re: [Python-Dev] Issue 14417: consequences of new dict runtime error

2012-04-03 Thread Maciej Fijalkowski
On Sat, Mar 31, 2012 at 7:45 PM, R. David Murray rdmur...@bitdance.comwrote: On Sun, 01 Apr 2012 03:03:13 +1000, Nick Coghlan ncogh...@gmail.com wrote: On Sun, Apr 1, 2012 at 2:09 AM, Guido van Rossum gu...@python.org wrote: Here's a different puzzle. Has anyone written a demo yet that

Re: [Python-Dev] issue 9141, finalizers and gc module

2012-04-17 Thread Maciej Fijalkowski
On Tue, Apr 17, 2012 at 8:30 PM, Antoine Pitrou solip...@pitrou.net wrote: On Tue, 17 Apr 2012 17:22:57 + Kristján Valur Jónsson krist...@ccpgames.com wrote: We are all consenting adults. Everything is allowed - you just have to live with the consequences. Well, we

Re: [Python-Dev] issue 9141, finalizers and gc module

2012-04-20 Thread Maciej Fijalkowski
** ** *From:* python-dev-bounces+kristjan=ccpgames@python.org [mailto: python-dev-bounces+kristjan=ccpgames@python.org] *On Behalf Of *Maciej Fijalkowski *Sent:* 17. apríl 2012 21:29 *To:* Antoine Pitrou *Cc:* python-dev@python.org *Subject:* Re: [Python-Dev] issue 9141, finalizers

Re: [Python-Dev] a new type for sys.implementation

2012-06-01 Thread Maciej Fijalkowski
On Thu, May 31, 2012 at 6:56 PM, Benjamin Peterson benja...@python.orgwrote: 2012/5/31 Nick Coghlan ncogh...@gmail.com: On Thu, May 31, 2012 at 8:26 PM, Mark Shannon m...@hotpy.org wrote: Eric Snow wrote: The implementation for sys.implementation is going to use a new (but private)

[Python-Dev] JITted regex engine from pypy

2012-06-03 Thread Maciej Fijalkowski
Hi I was reading a bit about the regex module and I would like to present some other solution into speeding up the re module for Python. So, as a bit of background - pypy has a re compatible module. It's also JITted and it's also exportable as a C library (that is a library you can call from C

Re: [Python-Dev] JITted regex engine from pypy

2012-06-03 Thread Maciej Fijalkowski
On Sun, Jun 3, 2012 at 3:06 PM, Calvin Spealman ironfro...@gmail.comwrote: On Sun, Jun 3, 2012 at 7:49 AM, Maciej Fijalkowski fij...@gmail.com wrote: Hi I was reading a bit about the regex module and I would like to present some other solution into speeding up the re module for Python

Re: [Python-Dev] JITted regex engine from pypy

2012-06-03 Thread Maciej Fijalkowski
On Sun, Jun 3, 2012 at 3:46 PM, Nick Coghlan ncogh...@gmail.com wrote: The embedded (in both senses of the term) use cases for CPython pretty much kill the idea, I'm afraid. As I said it can (and should) definitely be optional. Those cases are also one of the biggest question marks over

Re: [Python-Dev] JITted regex engine from pypy

2012-06-03 Thread Maciej Fijalkowski
On Sun, Jun 3, 2012 at 5:21 PM, Martin v. Löwis mar...@v.loewis.dewrote: On the minus side, the JIT only works on x86 and x86_64, on the plus side, since it's 100% API compatible, it can be used as a _xxx speedup module relatively easy. Do people have opinions? The main concern for re is

[Python-Dev] PyPy 1.9 - Yard Wolf

2012-06-08 Thread Maciej Fijalkowski
PyPy 1.9 - Yard Wolf We're pleased to announce the 1.9 release of PyPy. This release brings mostly bugfixes, performance improvements, other small improvements and overall progress on the `numpypy`_ effort. It also brings an improved situation on Windows

Re: [Python-Dev] backporting stdlib 2.7.x from pypy to cpython

2012-06-12 Thread Maciej Fijalkowski
On Mon, Jun 11, 2012 at 8:58 AM, Nick Coghlan ncogh...@gmail.com wrote: On Mon, Jun 11, 2012 at 11:29 AM, Guido van Rossum gu...@python.org wrote: But what guarantee do you have that (a) the right people sign up for the new list, and (b) topics are correctly brought up there instead of on

Re: [Python-Dev] #12982: Should -O be required to *read* .pyo files?

2012-06-14 Thread Maciej Fijalkowski
On Wed, Jun 13, 2012 at 9:13 PM, R. David Murray rdmur...@bitdance.comwrote: On Wed, 13 Jun 2012 20:46:50 +0200, Antoine Pitrou solip...@pitrou.net wrote: On Wed, 13 Jun 2012 11:20:24 -0700 Toshio Kuratomi a.bad...@gmail.com wrote: On Wed, Jun 13, 2012 at 01:58:10PM -0400, R. David

Re: [Python-Dev] CFFI released

2012-06-18 Thread Maciej Fijalkowski
On Mon, Jun 18, 2012 at 7:02 PM, Terry Reedy tjre...@udel.edu wrote: On 6/18/2012 9:14 AM, Armin Rigo wrote: Hi all, We (=fijal and myself) finally released the beta-0.1 version of CFFI. http://cffi.readthedocs.org/ It is a(nother) simple Foreign Function Interface for Python calling C

Re: [Python-Dev] Tunable parameters in dictobject.c (was dictnotes.txt out of date?)

2012-06-18 Thread Maciej Fijalkowski
On Mon, Jun 18, 2012 at 5:04 PM, Antoine Pitrou solip...@pitrou.net wrote: On Mon, 18 Jun 2012 15:28:24 +0100 Mark Shannon m...@hotpy.org wrote: But do they? The results of benchmarking would seem to suggest (at least on my test machine) that overly-sparse dicts are slower. Possibly due

Re: [Python-Dev] on Python's tests (and making them better)

2008-06-05 Thread Maciej Fijalkowski
On Thu, Jun 5, 2008 at 6:23 PM, Benjamin Peterson [EMAIL PROTECTED] wrote: Hi, This summer, I am going to be revamping Python's test suite. Major things I plan to do include - rewriting regrtest.py to be a simple test driver - implementing CPython only decorators - moving skipping data to

[Python-Dev] bug or a feature?

2008-06-10 Thread Maciej Fijalkowski
What do you think about this code: class A: locals()[42] = 98 Seems people rely on it working. Do we consider it part of python language? (Note that you cannot do the same with getattr/setattr which checks if argument is a string) Cheers, fijal ___

Re: [Python-Dev] bug or a feature?

2008-06-10 Thread Maciej Fijalkowski
On Wed, Jun 11, 2008 at 3:36 AM, Scott Dial [EMAIL PROTECTED] wrote: Maciej Fijalkowski wrote: What do you think about this code: class A: locals()[42] = 98 Seems people rely on it working. I apologize for my ignorance, but who? Could you please cite something reputable that relies

Re: [Python-Dev] bug or a feature?

2008-06-11 Thread Maciej Fijalkowski
On Thu, Jun 12, 2008 at 2:32 AM, Terry Reedy [EMAIL PROTECTED] wrote: Scott Dial [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] || If non-string keys are not allowed in __dict__, then the AddOns library | should be changed to add another dict to the object of interest to track |

Re: [Python-Dev] Opcode frequency

2008-06-19 Thread Maciej Fijalkowski
On Thu, Jun 19, 2008 at 1:03 AM, Raymond Hettinger [EMAIL PROTECTED] wrote: Maciej Fijalkowski did an opcode analysis for PyPy, it also shows the relative frequency of opcodes following a specifc one: http://codespeak.net/svn/user/fijal/opcodes.txt Might it make sense to add more PREDICT

Re: [Python-Dev] the explicit self

2008-08-27 Thread Maciej Fijalkowski
You can provide selfless class as a class with special metaclass that overloads __new__ and changes signature of each method. Not sure how good is this, but requires no changes to the language and will work as you want. Cheers, fijal On Wed, Aug 27, 2008 at 8:46 AM, Kilian Klimek [EMAIL

Re: [Python-Dev] ANNOUNCE: CapPython, an object-capability subset of Python

2008-09-19 Thread Maciej Fijalkowski
PyPy offers sandboxing interpreter without compromising language features itself. Here are docs: http://codespeak.net/pypy/dist/pypy/doc/sandbox.html Also, are you aware of directory Lib/test/crashers (in python's svn) which contains some possible ways to segfault cpython? (which can lead to

[Python-Dev] What this code should do?

2008-09-19 Thread Maciej Fijalkowski
Hello, I'm a little clueless about exact semantics of following snippets: http://paste.pocoo.org/show/85698/ is this fine? or shall I fill the bug? (the reason to ask is because a) django is relying on this b) pypy implements it differently) cheers, fijal

Re: [Python-Dev] What this code should do?

2008-09-19 Thread Maciej Fijalkowski
On Fri, Sep 19, 2008 at 9:30 PM, Jean-Paul Calderone [EMAIL PROTECTED] wrote: On Fri, 19 Sep 2008 18:26:05 +0200, Amaury Forgeot d'Arc [EMAIL PROTECTED] wrote: Hello Maciej, Maciej Fijalkowski wrote: Hello, I'm a little clueless about exact semantics of following snippets: http

Re: [Python-Dev] Fwd: Removal of GIL through refcounting removal.

2008-11-01 Thread Maciej Fijalkowski
... We know it is the plan for PyPy to work in this way, and also that Jython and Ironpython works like that (using the host vm's GC), so it seems to be somehow agreeable with the python semantics (perhaps not really with __del__ but they are not really nice anyway). PyPy has a

Re: [Python-Dev] Taint Mode in Python 3.0

2008-12-04 Thread Maciej Fijalkowski
When I try to run this, I get: Fatal Python error: Py_Initialize: can't initialize sys standard streams Traceback (most recent call last): File /home/fijal/lang/python/Python30/Lib/encodings/__init__.py, line 31, in module File /home/fijal/lang/python/Python30/Lib/codecs.py, line 1060, in

Re: [Python-Dev] Taint Mode in Python 3.0

2008-12-04 Thread Maciej Fijalkowski
Hello, The thing is pypy's taint code is broken. Basically you don't only need to patch all places that return pyobject, but also all places that might modify anything. (All side effects) For example innocently looking call to addition might end up calling arbitrary python code (and have

Re: [Python-Dev] Trap SIGSEGV and SIGFPE

2008-12-11 Thread Maciej Fijalkowski
If we could calculate how much stack is left we'd have a much more robust way of doing recursion limits. I suppose this could be done by reading a byte from each page with a temporary SIGSEGV handler installed, but I'm not convinced you can't ask the platform directly somehow. I'd also be

[Python-Dev] PyPy 1.3 released

2010-06-25 Thread Maciej Fijalkowski
to the JIT code, as well as a great speedup of compiling time. Cheers, Maciej Fijalkowski, Armin Rigo, Alex Gaynor, Amaury Forgeot d'Arc and the PyPy team ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python

Re: [Python-Dev] [pypy-dev] PyPy 1.3 released

2010-07-01 Thread Maciej Fijalkowski
. On Fri, Jun 25, 2010 at 11:27 PM, Maciej Fijalkowski fij...@gmail.com wrote: === PyPy 1.3: Stabilization === Hello. We're please to announce release of PyPy 1.3. This release has two major improvements. First of all, we stabilized the JIT compiler since

Re: [Python-Dev] Can Python implementations reject semantically invalid expressions?

2010-07-02 Thread Maciej Fijalkowski
On Fri, Jul 2, 2010 at 12:31 AM, Stefan Behnel stefan...@behnel.de wrote: Glyph Lefkowitz, 02.07.2010 06:43: On Jul 2, 2010, at 12:28 AM, Steven D'Aprano wrote: This question was inspired by something asked on #python today. Consider it a hypothetical, not a serious proposal. We know that

Re: [Python-Dev] Can Python implementations reject semantically invalid expressions?

2010-07-02 Thread Maciej Fijalkowski
On Fri, Jul 2, 2010 at 1:20 AM, Martin v. Löwis mar...@v.loewis.de wrote: Am 02.07.2010 08:55, schrieb Craig Citro: This question has an easy answer - can you possibly tell the difference? Ok, I'm obviously being silly here, but sure you can: The dis module is deliberately (*) not part of

Re: [Python-Dev] Can Python implementations reject semantically invalid expressions?

2010-07-05 Thread Maciej Fijalkowski
On Fri, Jul 2, 2010 at 10:35 PM, Steven D'Aprano st...@pearwood.info wrote: On Sat, 3 Jul 2010 11:39:07 am Greg Ewing wrote: Stefan Behnel wrote: So, would it still be Python if it folded     1 + 1 into     raise TypeError() at compile time? It would have to be     raise

Re: [Python-Dev] What to do with languishing patches?

2010-07-19 Thread Maciej Fijalkowski
On Sun, Jul 18, 2010 at 10:32 PM, Paul Moore p.f.mo...@gmail.com wrote: On 18 July 2010 20:57, Glyph Lefkowitz gl...@twistedmatrix.com wrote: On Jul 18, 2010, at 1:46 PM, Alexander Belopolsky wrote: We already have posponed and remind resolutions, but these are exclusive of accepted.   I

Re: [Python-Dev] Unladen swallow status

2010-07-21 Thread Maciej Fijalkowski
On Wed, Jul 21, 2010 at 6:50 PM, Reid Kleckner reid.kleck...@gmail.com wrote: On Wed, Jul 21, 2010 at 8:11 AM, Tim Golden m...@timgolden.me.uk wrote: Brett suggested that the Unladen Swallow merge to trunk was waiting for some work to complete on the JIT compiler and Georg, as release manager

Re: [Python-Dev] Python Language Summit EuroPython 2010

2010-07-22 Thread Maciej Fijalkowski
On Thu, Jul 22, 2010 at 9:51 AM, Brett Cannon br...@python.org wrote: On Wed, Jul 21, 2010 at 16:58, Antoine Pitrou solip...@pitrou.net wrote: On Wed, 21 Jul 2010 11:42:00 -0400 Jesse Noller jnol...@gmail.com wrote: On Wed, Jul 21, 2010 at 11:11 AM, Tim Golden m...@timgolden.me.uk wrote:

Re: [Python-Dev] Thoughts fresh after EuroPython

2010-07-26 Thread Maciej Fijalkowski
On Mon, Jul 26, 2010 at 12:02 PM, Michael Foord fuzzy...@voidspace.org.uk wrote: On 26/07/2010 04:42, Guido van Rossum wrote: On Sun, Jul 25, 2010 at 8:31 PM, Peter Portante peter.a.porta...@gmail.com  wrote: FWIW: We use Python at Tabblo, straddled across Python 2.5.4 and 2.6.5. They

Re: [Python-Dev] GIL musings (was Re: Thoughts fresh after EuroPython)

2010-07-29 Thread Maciej Fijalkowski
On Thu, Jul 29, 2010 at 6:53 AM, Greg Ewing greg.ew...@canterbury.ac.nz wrote: On 28/07/10 23:12, Antoine Pitrou wrote: It should be noted, though, that a full GC can be detrimental to real-time applications. Kristján has already explained how some of his software disabled the cyclic GC, and

[Python-Dev] PyPy 1.4 released

2010-11-26 Thread Maciej Fijalkowski
Cheers, Carl Friedrich Bolz, Antonio Cuni, Maciej Fijalkowski, Amaury Forgeot d'Arc, Armin Rigo and the PyPy team ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org

Re: [Python-Dev] gc ideas -- sparse memory

2010-12-03 Thread Maciej Fijalkowski
On Sat, Dec 4, 2010 at 6:34 AM, James Y Knight f...@fuhm.net wrote: On Dec 3, 2010, at 10:50 PM, Terry Reedy wrote: On 12/3/2010 7:46 PM, James Y Knight wrote: Sure they are. This is what Java provides you, for example. If you have fixed, but potentially non-unique ids (in Java you get this

Re: [Python-Dev] gc ideas -- sparse memory

2010-12-04 Thread Maciej Fijalkowski
On Sat, Dec 4, 2010 at 1:37 PM, Antoine Pitrou solip...@pitrou.net wrote: On Sat, 4 Dec 2010 15:06:45 +1100 Cameron Simpson c...@zip.com.au wrote: On 03Dec2010 18:15, James Y Knight f...@fuhm.net wrote: | On Dec 3, 2010, at 6:04 PM, Terry Reedy wrote: | gc is implementation specific. CPython

Re: [Python-Dev] Possible optimization for LOAD_FAST ?

2010-12-31 Thread Maciej Fijalkowski
OK, but is it mandatory? For example, in the above code, I can unroll the loop because I found that range is the usual built-in, 5 is a low-enough constant, How do you know xrange is xrange and not something else? Cheers, fijal ___ Python-Dev

Re: [Python-Dev] Possible optimization for LOAD_FAST ?

2010-12-31 Thread Maciej Fijalkowski
On Fri, Dec 31, 2010 at 12:00 PM, Maciej Fijalkowski fij...@gmail.com wrote: OK, but is it mandatory? For example, in the above code, I can unroll the loop because I found that range is the usual built-in, 5 is a low-enough constant, How do you know xrange is xrange and not something else

Re: [Python-Dev] Possible optimization for LOAD_FAST ?

2011-01-05 Thread Maciej Fijalkowski
How about not changing semantics and still making this optimization possible? PyPy already has CALL_LIKELY_BUILTIN which checks whether builtins has been altered (by keeping a flag on the module dictionary) and if not, loads a specific builtin on top of value stack. From my current experience, I

Re: [Python-Dev] r88178 - python/branches/py3k/Lib/test/crashers/underlying_dict.py

2011-01-25 Thread Maciej Fijalkowski
On Tue, Jan 25, 2011 at 1:26 PM, Antoine Pitrou solip...@pitrou.net wrote: On Tue, 25 Jan 2011 01:00:28 +0100 (CET) benjamin.peterson python-check...@python.org wrote: Author: benjamin.peterson Date: Tue Jan 25 01:00:28 2011 New Revision: 88178 Log: another pretty crasher served up by pypy

Re: [Python-Dev] Summer of Code: call for ideas and mentors

2011-03-04 Thread Maciej Fijalkowski
On Fri, Mar 4, 2011 at 10:35 AM, Martin v. Löwis mar...@v.loewis.de wrote: Google Summer of Code is coming up again, and we will again be participating. Arc Riley will setup infrastructure later today, and we need to start thinking about possible projects. Traditionally, people (students and

Re: [Python-Dev] VM and Language summit info for those not at Pycon (and those that are!)

2011-03-12 Thread Maciej Fijalkowski
On Sat, Mar 12, 2011 at 1:14 PM, Martin v. Löwis mar...@v.loewis.de wrote: http://www.boredomandlaziness.org/2011/03/python-vm-summit-rough-notes.html http://www.boredomandlaziness.org/2011/03/python-vm-summit-somewhat-coherent.html Wrt. the remark that other implementations should be

Re: [Python-Dev] VM and Language summit info for those not at Pycon (and those that are!)

2011-03-21 Thread Maciej Fijalkowski
[skipping the whole long discussion] Cython is meant to compile Python code. A cython version would just be a pure Python module, usable with all other implementations, but with type annotations that make it compile to more optimal C code. Type annotations can be provided in an external file

Re: [Python-Dev] GSoC: speed.python.org

2011-03-21 Thread Maciej Fijalkowski
On Mon, Mar 21, 2011 at 12:33 PM, DasIch dasdas...@googlemail.com wrote: Hello Guys, I'm interested in participating in the Google Summer of Code this year and I've been looking at projects in the Wiki, particularly speed.pypy.org[1] as I'm very interested in the current VM development.

Re: [Python-Dev] GSoC: speed.python.org

2011-03-21 Thread Maciej Fijalkowski
On Mon, Mar 21, 2011 at 2:24 PM, DasIch dasdas...@googlemail.com wrote: On Mon, Mar 21, 2011 at 7:48 PM, Antoine Pitrou solip...@pitrou.net wrote: On Mon, 21 Mar 2011 19:33:55 +0100 DasIch dasdas...@googlemail.com wrote: 3. Several benchmarks (at least the Django and Twisted ones) have

Re: [Python-Dev] PEP 399: Pure Python/C Accelerator Module Compatibiilty Requirements

2011-04-06 Thread Maciej Fijalkowski
No worries, it wasn't even my code.  Someone donated it.  The was a discusion on python-dev and collective agreement to allow it to have semantic differences that would let it run faster. IIRC, the final call was made by Uncle Timmy. The bug link is here: http://bugs.python.org/issue3051

Re: [Python-Dev] Policy for making changes to the AST

2011-04-07 Thread Maciej Fijalkowski
AFAIK the AST is CPython-specific so should be treated with the same attitude as changes to the bytecode. That means, do it conservatively, since there *are* people who like to write tools that manipulate or analyze this, and while they know they're doing something CPython and

Re: [Python-Dev] [GSoC] Developing a benchmark suite (for Python 3.x)

2011-04-08 Thread Maciej Fijalkowski
On Fri, Apr 8, 2011 at 3:29 AM, Jesse Noller jnol...@gmail.com wrote: On Thu, Apr 7, 2011 at 7:52 PM, Michael Foord fuzzy...@voidspace.org.uk wrote: On 08/04/2011 00:36, Anthony Scopatz wrote: On Thu, Apr 7, 2011 at 6:11 PM, Michael Foord fuzzy...@voidspace.org.uk wrote: On 07/04/2011

Re: [Python-Dev] [GSoC] Developing a benchmark suite (for Python 3.x)

2011-04-08 Thread Maciej Fijalkowski
On Fri, Apr 8, 2011 at 11:22 AM, Stefan Behnel stefan...@behnel.de wrote: Jesse Noller, 07.04.2011 22:28: On Thu, Apr 7, 2011 at 3:54 PM, Anthony Scopatz wrote: Hi Daniel, Thanks for putting this together.  I am a huge supporter of benchmarking efforts.  My brief comment is below. On Wed,

Re: [Python-Dev] [GSoC] Developing a benchmark suite (for Python 3.x)

2011-04-08 Thread Maciej Fijalkowski
On Fri, Apr 8, 2011 at 12:18 PM, Stefan Behnel stefan...@behnel.de wrote: Maciej Fijalkowski, 08.04.2011 11:41: On Fri, Apr 8, 2011 at 11:22 AM, Stefan Behnelstefan...@behnel.de  wrote: Jesse Noller, 07.04.2011 22:28: On Thu, Apr 7, 2011 at 3:54 PM, Anthony Scopatz wrote: Hi Daniel

Re: [Python-Dev] [GSoC] Developing a benchmark suite (for Python 3.x)

2011-04-11 Thread Maciej Fijalkowski
On Fri, Apr 8, 2011 at 11:22 AM, Stefan Behnel stefan...@behnel.de wrote: Jesse Noller, 07.04.2011 22:28: On Thu, Apr 7, 2011 at 3:54 PM, Anthony Scopatz wrote: Hi Daniel, Thanks for putting this together.  I am a huge supporter of benchmarking efforts.  My brief comment is below. On Wed,

Re: [Python-Dev] [GSoC] Developing a benchmark suite (for Python 3.x)

2011-04-11 Thread Maciej Fijalkowski
On Mon, Apr 11, 2011 at 12:43 PM, Stefan Behnel stefan...@behnel.de wrote: Maciej Fijalkowski, 11.04.2011 11:39: On Fri, Apr 8, 2011 at 11:22 AM, Stefan Behnelstefan...@behnel.de  wrote: Jesse Noller, 07.04.2011 22:28: On Thu, Apr 7, 2011 at 3:54 PM, Anthony Scopatz wrote: Hi Daniel

Re: [Python-Dev] PEP 399: Pure Python/C Accelerator Module Compatibiilty Requirements

2011-04-18 Thread Maciej Fijalkowski
On Sun, Apr 17, 2011 at 4:19 AM, Raymond Hettinger raymond.hettin...@gmail.com wrote: On Apr 16, 2011, at 2:45 PM, Brett Cannon wrote: On Sat, Apr 16, 2011 at 14:23, Stefan Krah ste...@bytereef.org wrote: Brett Cannon br...@python.org wrote: In the grand python-dev tradition of silence

Re: [Python-Dev] PEP 399: Pure Python/C Accelerator Module Compatibiilty Requirements

2011-04-19 Thread Maciej Fijalkowski
On Tue, Apr 19, 2011 at 10:57 AM, Nick Coghlan ncogh...@gmail.com wrote: On Tue, Apr 19, 2011 at 3:06 PM, Stefan Behnel stefan...@behnel.de wrote: I think this social problem of the PEP can only be solved if the CPython project stops doing the major share of the stdlib maintenance, thus freeing

Re: [Python-Dev] PEP 399: Pure Python/C Accelerator Module Compatibiilty Requirements

2011-04-19 Thread Maciej Fijalkowski
On Tue, Apr 19, 2011 at 12:01 PM, Stefan Behnel stefan...@behnel.de wrote: Nick Coghlan, 19.04.2011 10:57: On Tue, Apr 19, 2011 at 3:06 PM, Stefan Behnel wrote: I think this social problem of the PEP can only be solved if the CPython project stops doing the major share of the stdlib

Re: [Python-Dev] PEP 399: Pure Python/C Accelerator Module Compatibiilty Requirements

2011-04-19 Thread Maciej Fijalkowski
Once this move is made/accepted, I would expect the other implementation to rapidly move away from their custom implementations of the stdlib and contribute to the shared code base and documentation. Yes, this places a burden on CPython, but in the long term in benefits *all* of the projects

Re: [Python-Dev] Proposal for a common benchmark suite

2011-04-29 Thread Maciej Fijalkowski
On Thu, Apr 28, 2011 at 11:10 PM, Stefan Behnel stefan...@behnel.de wrote: M.-A. Lemburg, 28.04.2011 22:23: Stefan Behnel wrote: DasIch, 28.04.2011 20:55: the CPython benchmarks have an extensive set of microbenchmarks in the pybench package Try not to care too much about pybench. There

Re: [Python-Dev] the role of assert in the standard library ?

2011-04-29 Thread Maciej Fijalkowski
On Fri, Apr 29, 2011 at 9:55 AM, Holger Krekel holger.kre...@gmail.com wrote: On Fri, Apr 29, 2011 at 12:31 AM, Raymond Hettinger raymond.hettin...@gmail.com wrote: On Apr 28, 2011, at 3:07 PM, Guido van Rossum wrote: On Thu, Apr 28, 2011 at 2:53 PM, Raymond Hettinger

Re: [Python-Dev] CPython optimization: storing reference counters outside of objects

2011-05-24 Thread Maciej Fijalkowski
On Sun, May 22, 2011 at 1:57 AM, Artur Siekielski artur.siekiel...@gmail.com wrote: Hi. The problem with reference counters is that they are very often incremented/decremented, even for read-only algorithms (like traversal of a list). It has two drawbacks: 1. CPU cache lines (64 bytes on X86)

[Python-Dev] Language summit writeup anyone?

2011-06-20 Thread Maciej Fijalkowski
Hi. Unfortunately I'm missing Europython (and language summit) this year. Did anyone do a writeup on what was discussed? Cheers, fijal ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe:

Re: [Python-Dev] Is there any fun with benchmarks

2011-06-22 Thread Maciej Fijalkowski
On Wed, Jun 22, 2011 at 3:24 PM, Nick Coghlan ncogh...@gmail.com wrote: On Wed, Jun 22, 2011 at 10:47 PM, anatoly techtonik techto...@gmail.com wrote: I wonder if upcoming speed.python.org has any means to validate these claims for different Python releases? Is there any place where I can

Re: [Python-Dev] making socket.getaddrinfo use cached dns

2011-07-16 Thread Maciej Fijalkowski
On Thu, Jul 7, 2011 at 7:59 PM, Oleg Broytman p...@phdru.name wrote: Hello.   We are sorry but we cannot help you. This mailing list is to work on developing Python (adding new features to Python itself and fixing bugs); Well, it seems this post is about adding a new feature isn't it?

  1   2   3   4   >