Re: [dev] [sbase][PATCH] Add factor(1)

From: Mattias Andrée <maandree_AT_kth.se>
Date: Fri, 26 Feb 2016 09:52:13 +0100

On Fri, 26 Feb 2016 09:45:41 +0100
isabella parakiss <izaberina_AT_gmail.com> wrote:

> On 2/26/16, Mattias Andrée <maandree_AT_kth.se> wrote:
> > Performance is not really something suckless
> > concerns itself about. They favour solutions
> > that are simpler to implement and maintain
> > but asymptotically slower. But in the case of
> ^^^^^^^^^^^^^^
> this is awful.
>
> i don't understand this whole approach to computing.
> why would you rather write *dumb*, *slow* code that "gets
> the job done", instead of actually trying to make it
> decent? programming trivial utilities isn't fun. why are
> you even writing code?
>
> > tommath, I don't think it is asymptotically
> > slower, at least not much, it is just makes
> > a hugh about of memory allocations. Which is
> > a very expensive operation.
> >
> > It should however be noted, that factor(1) is
> > not intended to factorise huge numbers or brake
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> may as well just restrict it to uint64_t. or uint32_t.
> or char.
>
> > RSA numbers, in fact GNU factor will reject to
> > difficult numbers. It should just be able to
> > factor reasonably large numbers. I think 50 times
> > slower than GNU factor is acceptable, but 1000
> ^^^^^^^^^^
> no it's not and you should be ashamed of yourself as a
> computer scientist.

Well I'm not done yet, it will be faster. But for factoring
a few(!) small(!) numbers that could take 0.001 seconds,
0.05 seconds is acceptable and barely noticable.

>
> > times slower is not. Keep in mind though, that
> > the difference depends widely on the number that
> > is being factorised.
> >
>
>
> ---
> xoxo iza
>


Received on Fri Feb 26 2016 - 09:52:13 CET

This archive was generated by hypermail 2.3.0 : Fri Feb 26 2016 - 10:00:23 CET