From: zimoun <zimon.toutoune@gmail.com>
To: Ricardo Wurmus <rekado@elephly.net>
Cc: Guix Devel <guix-devel@gnu.org>
Subject: Re: guix package --search slow ?
Date: Wed, 15 May 2019 11:54:30 +0200 [thread overview]
Message-ID: <CAJ3okZ1cTPXfvhQ0D=qFGVJecMB-GchZ20eJZMZ56L37Do2XAQ@mail.gmail.com> (raw)
In-Reply-To: <87o9447pul.fsf@elephly.net>
On Tue, 14 May 2019 at 22:17, Ricardo Wurmus <rekado@elephly.net> wrote:
>
> For me this command
>
> time guix package --search=python-numpy
>
> when run for the first time takes
>
> real 0m4.729s
> user 0m1.332s
> sys 0m0.815s
>
> All following invocations finish in about a second:
>
> real 0m1.469s
> user 0m1.459s
> sys 0m0.108s
Your machine is probably faster than mine ;-)
Yes, once the cache is warm, then it is faster.
By "All following invocations" you mean a search for a non related
previous one. Right?
It is expected to be faster because the `fold' over all the package
has warmed the memory cache (kernel stuff). Right?
On my machine, I have:
$ time guix package --search=numpy
real 0m7.353s
user 0m1.256s
sys 0m0.136s
$ time guix package --search=conduit
real 0m0.728s
user 0m0.764s
sys 0m0.044s
compared to Debian `aptitude` for example:
$ time aptitude search numpy
real 0m3.513s
user 0m0.692s
sys 0m0.092s
$ time aptitude search conduit
real 0m0.622s
user 0m0.540s
sys 0m0.048s
So yes, it depends on how the memory cache is (echo 1 >
/proc/sys/vm/drop_caches or echo 3 > /proc/sys/vm/drop_caches) , and
once the cache is warmed, it is fast enough.
My point is that the first search is (often)at least twice longer than
the `aptitude` counter part. And even it is longer than a `git grep`
on the raw .scm files.
$ time git --no-pager grep numpy
real 0m4.369s
user 0m0.112s
sys 0m0.132s
$ time git --no-pager grep conduit
real 0m0.069s
user 0m0.108s
sys 0m0.012s
Well, maybe I miss a point.
All the best,
simon
next prev parent reply other threads:[~2019-05-15 9:54 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-14 17:19 guix package --search slow ? zimoun
2019-05-14 20:17 ` Ricardo Wurmus
2019-05-15 9:54 ` zimoun [this message]
2019-05-15 11:35 ` Ricardo Wurmus
2019-05-15 13:34 ` Ludovic Courtès
2019-05-15 13:43 ` Pierre Neidhardt
2019-05-16 15:13 ` Ludovic Courtès
2019-05-15 13:48 ` Jonathan Brielmaier
2019-05-15 14:08 ` Pierre Neidhardt
2019-05-15 14:50 ` zimoun
2019-05-15 15:11 ` Pierre Neidhardt
2019-05-15 14:31 ` zimoun
2019-05-15 14:23 ` zimoun
2019-05-15 18:32 ` zimoun
2019-05-15 20:30 ` Giovanni Biscuolo
2019-05-15 2:22 ` Meiyo Peng
2019-05-15 9:59 ` zimoun
2019-05-15 14:08 ` zimoun
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJ3okZ1cTPXfvhQ0D=qFGVJecMB-GchZ20eJZMZ56L37Do2XAQ@mail.gmail.com' \
--to=zimon.toutoune@gmail.com \
--cc=guix-devel@gnu.org \
--cc=rekado@elephly.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.