From: Srdjan Pejic Date: 2009-07-09T11:15:33+09:00 Subject: [ruby-core:24224] Re: Performance issue with Prime class under Ruby 1.8.6 in Windows --000e0cd599cec1828e046e3c6d59 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Hi Roger, Yeah, sorry, I was trying to say that Prime class is slow in 1.8.6. I did a test on Ubuntu, same Ruby version down to patchlevel and the results are similar. I've updated http://gist.github.com/142907 to include the Ubuntu results, so that you can see it for yourself. I'm willing to submit a patch, but I am unclear what the next steps are. Thanks, Srdjan On Wed, Jul 8, 2009 at 6:14 PM, Roger Pack wrote: > > So you're suggesting that the Prime class be optimized is that right? > > =r > > Oh I see what you're saying--windows 1.8.6 Prime class is slow. Have > you compared it with Linux? > > The good news is that with 1.8 on windows: > > user system total real > my solution 7.891000 0.015000 7.906000 ( 7.921875) > library solution 55.094000 0.016000 55.110000 ( 55.265625) > > but with 1.9 > user system total real > my solution 2.234000 0.000000 2.234000 ( 2.234375) > library solution 0.094000 0.000000 0.094000 ( 0.093750) > > :) > > But test it out on Linux and make sure. > > If it's a windows bug then run a profiler against it, fix it, submit a > patch [?] > > =r > > --000e0cd599cec1828e046e3c6d59 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi Roger,

Yeah, sorry, I was trying to say that Prime class is slow = in 1.8.6. I did a test on Ubuntu, same Ruby version down to patchlevel and = the results are similar. I've updated http://gist.github.com/142907 to include th= e Ubuntu results, so that you can see it for yourself.

I'm willing to submit a patch, but I am unclear what the next steps= are.

Thanks,

Srdjan

On Wed= , Jul 8, 2009 at 6:14 PM, Roger Pack <rogerdpack@gmail.com> wrote:
> So you're suggesting that the Prime class be optimized is that ri= ght?
> =3Dr

Oh I see what you're saying--windows 1.8.6 Prime class is slow. = =A0Have
you compared it with Linux?

The good news is that with 1.8 on windows:

=A0 =A0 =A0user =A0 =A0 system =A0 =A0 =A0total =A0 =A0 =A0 =A0real
my solution =A07.891000 =A0 0.015000 =A0 7.906000 ( =A07.921875)
library solution 55.094000 =A0 0.016000 =A055.110000 ( 55.265625)

but with 1.9
=A0 =A0 =A0user =A0 =A0 system =A0 =A0 =A0total =A0 =A0 =A0 =A0real
my solution =A02.234000 =A0 0.000000 =A0 2.234000 ( =A02.234375)
library solution =A00.094000 =A0 0.000000 =A0 0.094000 ( =A00.093750)

:)

But test it out on Linux and make sure.

If it's a windows bug then run a profiler against it, fix it, submit a = patch [?]

=3Dr


--000e0cd599cec1828e046e3c6d59--