[issue3106] speedup some comparisons

2008-12-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: I committed the patch, which will also help #1717. Thanks! -- resolution: -> fixed status: open -> closed ___ Python tracker ___ __

[issue3106] speedup some comparisons

2008-12-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 2008-12-15 16:34, Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > Le lundi 15 décembre 2008 à 14:41 +, Marc-Andre Lemburg a écrit : >> Why have you removed the complete error handling section in >> PyUnicode_RichCompare() ? > > Becaus

[issue3106] speedup some comparisons

2008-12-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le lundi 15 décembre 2008 à 14:41 +, Marc-Andre Lemburg a écrit : > Why have you removed the complete error handling section in > PyUnicode_RichCompare() ? Because the only error that can occur is a TypeError when one of the two arguments is not an unicode

[issue3106] speedup some comparisons

2008-12-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 2008-12-13 16:08, Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > Here is a new patch without any dispatch shortcut in ceval.c, just > optimizations in unicodeobject.c and longobject.c. Net result on pybench: > > Test

[issue3106] speedup some comparisons

2008-12-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: > If there's not a hurry, would like to review this a bit more when I get > back early next week. No pb! ___ Python tracker ___

[issue3106] speedup some comparisons

2008-12-13 Thread Raymond Hettinger
Raymond Hettinger added the comment: If there's not a hurry, would like to review this a bit more when I get back early next week. ___ Python tracker ___ _

[issue3106] speedup some comparisons

2008-12-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: Here is a new patch without any dispatch shortcut in ceval.c, just optimizations in unicodeobject.c and longobject.c. Net result on pybench: Test minimum run-timeaverage run-time thisothe

[issue3106] speedup some comparisons

2008-11-16 Thread Antoine Pitrou
Antoine Pitrou <[EMAIL PROTECTED]> added the comment: Hello, > You may get better timings if you more the types-are-equal test inside > the types-i-know test. I get no discernable difference. > In general, I'm not too keen on adding this kind of dispatch code to > ceval.c. It saves the time s

[issue3106] speedup some comparisons

2008-11-16 Thread Raymond Hettinger
Raymond Hettinger <[EMAIL PROTECTED]> added the comment: You may get better timings if you more the types-are-equal test inside the types-i-know test. Instead of: + if (Py_TYPE(v) == Py_TYPE(w)) { + if (PyLong_CheckExact(v)) { + i

[issue3106] speedup some comparisons

2008-07-14 Thread Raymond Hettinger
Changes by Raymond Hettinger <[EMAIL PROTECTED]>: -- assignee: -> rhettinger ___ Python tracker <[EMAIL PROTECTED]> ___ ___ Python-bugs

[issue3106] speedup some comparisons

2008-07-13 Thread Antoine Pitrou
Antoine Pitrou <[EMAIL PROTECTED]> added the comment: Raymond, would you want to take a look? -- nosy: +rhettinger ___ Python tracker <[EMAIL PROTECTED]> ___ __

[issue3106] speedup some comparisons

2008-06-13 Thread Antoine Pitrou
New submission from Antoine Pitrou <[EMAIL PROTECTED]>: This patch is an experiment in making faster some of the most common comparisons (str vs. str, int vs. int). I don't know if it may bring noticeable speedups in real-world situations, but here are the synthetic benchmark numbers (from pybenc