Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Jeff Hardy
On Thu, Feb 27, 2014 at 8:10 PM, Pawel Jasinski wrote: > I just checked, the part in question is covered by MIT. Oh, that's better. MIT is no problem (once upon a time parts of Mono were LGPL, which is right out). Also, I had assumed that Mono would use native platform libraries for crypto. You

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Pawel Jasinski
I just checked, the part in question is covered by MIT. On Thu, Feb 27, 2014 at 8:48 PM, Slide wrote: > I had asked this question before, but there was some hesitation based on the > licensing of Mono. I'm not sure if that is an issue anymore. > > > On Thu, Feb 27, 2014 at 12:16 PM, Pawel Jasinsk

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Slide
I had asked this question before, but there was some hesitation based on the licensing of Mono. I'm not sure if that is an issue anymore. On Thu, Feb 27, 2014 at 12:16 PM, Pawel Jasinski wrote: > Is there any reason not to use code out of mono? > It looks like it supports SHA2 and RIPEMD160. > h

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Pawel Jasinski
Is there any reason not to use code out of mono? It looks like it supports SHA2 and RIPEMD160. https://bugzilla.xamarin.com/show_bug.cgi?id=11703 On Thu, Feb 27, 2014 at 2:10 PM, Markus Schaber wrote: > Hi, > > Von: Jeff Hardy [mailto:jdha...@gmail.com] >> On Thu, Feb 27, 2014 at 11:11 AM, Markus

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Markus Schaber
Hi, Von: Jeff Hardy [mailto:jdha...@gmail.com] > On Thu, Feb 27, 2014 at 11:11 AM, Markus Schaber > wrote: > > Hi, > > > > I'm just trying to sum it up: > > > > 1) The current code: > >- High memory usage. > >- High load on the large object heap. > >- Limited by the available amount o

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Jeff Hardy
On Thu, Feb 27, 2014 at 11:11 AM, Markus Schaber wrote: > Hi, > > I'm just trying to sum it up: > > 1) The current code: >- High memory usage. >- High load on the large object heap. >- Limited by the available amount of memory (which might be considered a > violation of the Python API

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-27 Thread Markus Schaber
ocher.org] Gesendet: Dienstag, 25. Februar 2014 17:59 An: Jeff Hardy Cc: Markus Schaber; Discussion of IronPython; Emmanuel Chomarat Betreff: Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython "Basically, there's a mismatch between what .NET provides and

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Emmanuel Chomarat
The main issue from what I remember is related to the fact that we can interleave update and digest calls in CPython. This is impossible in .Net (at least with the provided API). The workaround to this issue is to store a local buffer of everything that has already been hashed, in order to rehash i

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Curt Hagenlocher
"Basically, there's a mismatch between what .NET provides and what Python needs for perfect compatibility." Yes. I think I remember implementing this and that's exactly the problem I ran into. I think we looked into incorporating a modified version of the BCL code directly into IronPython, but at

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Jeff Hardy
On Tue, Feb 25, 2014 at 12:38 PM, Markus Schaber wrote: > Hi, > > A coworker just consulted me on a performance problem of IronPython vs. > cPython. > > ... snip ... > > On a closer look, there's the additional (and IMHO much worse) problem that > the update() method seems not to work incrementa

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Doug Blank
I think I just wrote the relevant parts in C#, in a slightly different form: public string sign(List list) { hmac.Initialize(); foreach (string item in list) { byte [] sourcebytes = Encoding.UTF8.GetBytes(item); hmac.TransformBlock(sourcebytes, 0, sourcebyte

[Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Markus Schaber
Hi, A coworker just consulted me on a performance problem of IronPython vs. cPython. The attached test script reproduces the problem. On cPython 2.7.6, it needs about 1.5 seconds on our test directory (once the OS disk cache is hot), and cPython 3.3 needs about 1.7 seconds, while IronPython n

Re: [Ironpython-users] Hashing a directory is magnitudes slower than in cPython

2014-02-25 Thread Markus Schaber
Hi, I forgot to add the attachment... Best regards Markus Schaber CODESYS(r) a trademark of 3S-Smart Software Solutions GmbH Inspiring Automation Solutions 3S-Smart Software Solutions GmbH Dipl.-Inf. Markus Schaber | Product Development Core Technology Memminger Str. 151 | 87439 Kempten | Ger