be
able to understand the crash case better.
Cheers,
Kristján
-Original Message-
From: Martin v. Löwis [mailto:[EMAIL PROTECTED]
Sent: 23. janúar 2007 23:32
To: Kristján V. Jónsson
Cc: 'python-dev@python.org'
Subject: Re: [Python-Dev] Object creation hook
Kristján V. Jónsson schrieb:
I am
Hello there.
I am trying to insert a hook into python enabling a callback for all
just-created objects. The intention is to debug and find memory leaks, e.g. by
having the hook function insert the object into a WeakKeyDictionary.
I have already added a method to object to set such a hook, and
You want to disable the obmalloc module when using valgrind, as I have when
using Rational Purify.
obmalloc does some evil stuff to recocnize its memory.
You also want to disable it so that you get verification on a per-block level.
Actually, obmalloc could be improved in this aspect. Similar
Doesn't it end up in a call to PyString_Concat()?
That should return a PyStringConcatenationObject too, right?
K
Construct like s = a + b + c + d + e , where a, b etc. have been
assigned string values earlier will not benefit from the patch.
: Martin v. Löwis [mailto:[EMAIL PROTECTED]
Sent: 16. október 2006 19:38
To: Kristján V. Jónsson
Cc: Anthony Baxter; python-dev@python.org
Subject: Re: [Python-Dev] Promoting PCbuild8 (Was: Python 2.5
performance)
Kristján V. Jónsson schrieb:
I must confess that I am not familiar
Well, it ought to be possible. I can turn off the instrumentation on the other
modules, and see what happens.
K
-Original Message-
From: Giovanni Bajo [mailto:[EMAIL PROTECTED]
Sent: 12. október 2006 20:30
To: Kristján V. Jónsson
Cc: python-dev@python.org
Subject: Re: Python 2.5
Hello
there.
I just got round to
do some comparative runs of 2.5 32 bit Release, built with visual studio 2003
and 2005.
Here the figures
(pybench with default arguments)
.NET
2003:
Test
minimum average operation
This patch looks really nice to use here at CCP. Our code is full of string
contcatenations so I will probably try to apply the patch soon and see what it
gives us in a real life app. The floating point integer cache was also a big
win. Soon, standard python won't be able to keep up with the
the VisualStudio8 64
bit build of 2.5 doesn't compile clean. We have a number of warnings of
truncation from 64 bit to 32:
Often it is a
question of doing an explicit cast, but sometimes we are using "int" for results
from strlen and such.
Is there any
interest in fixing this up?
Cheers,
Hm, doesn´t seem to be so for my regular python.
Python 2.3.3 Stackless 3.0 040407 (#51, Apr 7 2004, 19:28:46) [MSC v.1200 32 bi
t (Intel)] on win32
Type help, copyright, credits or license for more information.
x = -0.0
y = 0.0
x,y
(0.0, 0.0)
maybe it is 2.3.3, or maybe it is stackless
]
On Behalf Of [EMAIL PROTECTED]
Sent: 3. október 2006 00:54
To: Terry Reedy
Cc: python-dev@python.org
Subject: Re: [Python-Dev] Caching float(0.0)
Terry Kristján V. Jónsson [EMAIL PROTECTED] wrote:
Anyway, Skip noted that 50% of all floats are whole
numbers between
-10 and 10
:37
To: Kristján V. Jónsson
Cc: Bob Ippolito; python-dev@python.org
Subject: Re: [Python-Dev] Caching float(0.0)
Kristján V. Jónsson schrieb:
I can't see how this situation is any different from the
re-use of low
ints. There is no fundamental law that says that ints
below 100
Well, a lot of extension code, like ours use PyFloat_FromDouble(foo); This can
be from vectors and stuff. Very often these are values from a database.
Integral float values are very common in such case and id didn't occur to me
that they weren't being reused, at least for small values.
Acting on this excellent advice, I have patched in a reuse for -1.0, 0.0 and
1.0 for EVE Online. We use vectors and stuff a lot, and 0.0 is very, very
common. I'll report on the refcount of this for you shortly.
K
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL
.
something like:
int i = (int) fval;
if ((double)i == fval i=-1 i6) {
Py_INCREF(table[i]);
return table[i];
}
Cheers,
Kristján
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
On Behalf Of Kristján V. Jónsson
Sent: 29. september 2006 15:18
To: Fredrik
Hello
All.
I just added
patch 1552880 to sourceforge. It is a patch for 2.6
(and 2.5) which allows unicode paths in sys.path and uses the unicode file api
on windows.
This is tried and
tested on 2.5, and backported to 2.3 and is currently running on clients in
china and esewhere. It is
Hello all.
I am working on updating the PCBuild8 directory in the trunk. This should fix
this issue, unify platform builds for win32, x64 and I64, and provide better
support for PGO builds.
Hopefully when this is checked in, I can backport it to 2.5, since PCBuild8 is
not an official platform
I see. There is a file, called
pythoncore_pgo_link.txt where you have to add the object
too.
But pythoncore_pgo is a bit broken in other ways at the
moment. I am working on making it better in the trunk.
(I also think that MS should improve their tools to make
PGO building a one step
The string isn´t necessarily text, so selecting latin-1 doesn´t help (in
fact, what happens is that the current default encoding is used, in his case
this was ascii). What if it is image data? What if you are using a dict to
implement a singleton set for arbitrary objects?
The point is that
That was a purely altruistic proposal. I've already
discovered that sets are finalized and that some code that
works with dict emulating a set may not work with a set. It
will not make much difference for me if my proposal will be
implemented in 2.6 or even in 3.0, but the sooner
Actually, I was looking at the 1989 standard which is what we are supposed to
be using, right? But the exact wording in 99 is:
If the request can be honored, the signal function returns the value of func
for the
most recent successful call to signal for the specified signal sig. Otherwise,
a
This is, in fact, exactly what the python trunk does right now. This is done
in exceptions.c
Kristján
-Original Message-
From: Scott Dial [mailto:[EMAIL PROTECTED]
Sent: 17. júní 2006 12:54
To: Python Dev
Cc: Martin v. Löwis; Kristján V. Jónsson
Subject: Re: [Python-Dev] Python 2.4
() anyway? shouldn´t
that be python.exe? I don´t want a dll that I embed to mess with my signal
handling)
Cheers,
Kristján
-Original Message-
From: Martin v. Löwis [mailto:[EMAIL PROTECTED]
Sent: 17. júní 2006 13:28
To: Scott Dial
Cc: Python Dev; Kristján V. Jónsson
Subject: Re
, but I
cannot write kristján = 1. But that's for a future PEP.
Kristján
-Original Message-
From: Nick Coghlan [mailto:[EMAIL PROTECTED]
Sent: 16. júní 2006 15:30
To: Kristján V. Jónsson
Cc: Python Dev
Subject: Re: [Python-Dev] unicode imports
Kristján V. Jónsson wrote:
A cursory glance
-
From: Nick Coghlan [mailto:[EMAIL PROTECTED]
Sent: 17. júní 2006 04:17
To: Phillip J. Eby
Cc: Kristján V. Jónsson; Python Dev
Subject: Re: [Python-Dev] unicode imports
Phillip J. Eby wrote:
Actually, you would want to put it in sys.path_hooks, and then
instances would be placed
.
Kristján
-Original Message-
From: Neil Hodgson [mailto:[EMAIL PROTECTED]
Sent: 17. júní 2006 04:53
To: Kristján V. Jónsson
Cc: Python Dev
Subject: Re: [Python-Dev] unicode imports
Kristján V. Jónsson:
Although python has had full unicode support for filenames for a long
time
. Jónsson
Cc: Python Dev
Subject: Re: [Python-Dev] unicode imports
Kristján V. Jónsson wrote:
The standard install path in chinese distributions can be with a
non-ANSI path, and installing an embedded python application there
will break it.
I very much doubt this. On a Chinese system, the Program
One thing I have
often lamented having in PyString_FromFormat (and cousins, like PyErr_Format) is
to be able to integrate PyObject pointers. Adding something like %S and %R
(for str() and repr() respectively) seems very useful to me. Is there any
reason why this isn´t there?
Cheers,
,
it is something I will have to patch in for our application.
Cheers,
Kristján
-Original Message-
From: Nick Coghlan [mailto:[EMAIL PROTECTED]
Sent: 19. júní 2006 13:46
To: Kristján V. Jónsson
Cc: Martin v. Löwis; Python Dev
Subject: Re: [Python-Dev] unicode imports
Kristján V. Jónsson wrote
I remember you voicing this point at the Texas sprint. I can't say I agree.
The behaviour of certain function (like signal and fopen) is undefined for
certain arguments. Undefined is undefined, exiting the program with an
admonition is one of the possible outcomes (as is formatting your hard
Greetings!
Although python has
had full unicode support for filenames for a long time on selected platforms
(e.g. Windows), there is one glaring deficiency: It cannot import from
paths containing unicode. I´ve tried creating folders with chinese
characters and adding them to path, to no
I notice that file()
throws an IOError when it detects an invalid mode string. Wouldn't a
ValueError be more appropriate?
Kristján
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
Thanks for the reminder.
What I intend to add is to finalize the PCBuild8 directory, and fix CRT runtime
error handling for VC8.
The change as proposed involves adding macros around a select few CRT calls
(fopen, strftime, etc) where user supplied parameters are passed to the CRT
innards.
Code
Right, it is a FILETIME in the API, but the resolution stored on disk is
limited to what the disk format provides. FAT32 is particularly skinny.
I imagine that the value to store comes from GetSystemTimeAsFileTime which is
updated with the clock interrupt.
K
-Original Message-
From:
As a side note, It always seemed to me that the bf_getcharbuffer´s semantics
were poorly defined. At least in the 2.3 documentation. Has that, and the
need for it, changed recently?
Kristján
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brett
35 matches
Mail list logo