Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.misc > #16968

Re: seq command terribly slow

From Richard Kettlewell <rjk@greenend.org.uk>
Newsgroups comp.os.linux.misc
Subject Re: seq command terribly slow
Date 2016-03-13 12:24 +0000
Organization terraraq NNTP server
Message-ID <874mca36r7.fsf@mantic.terraraq.uk> (permalink)
References <slrnne9qgo.5pk.spamtrap42@one.localnet>

Show all headers | View raw


Robert Riches <spamtrap42@jacob21819.net> writes:
> Any ideas why the seq command is so terribly slow?
>
> In order to test whether a new (well, used, but that's another
> story) disk, I tried using seq to generate a non-repeating
> pattern.  After seeing seq consuming 100% CPU time and a very low
> data rate being written to disk, I did some checking on a
> few-years-old system with a Xeon W3680 running Debian 7/Wheezy.
>
> This command shows about 15MB/s:
>
>     seq 1e12 | pv > /dev/null
>
> This command shows about 600MB/s, ~40X faster with much lower
> total CPU use:
>
>     yes '' | cat -n | tr -d ' \t' | head -c 1000000000000 | pv > /dev/null

I see near-reverse behaviour in jessie (on a Q6600).  seq yields more
than 500MB/s while the pipeline is below 300MB/s.

Perhaps seq has been improved since the version in wheezy.

-- 
http://www.greenend.org.uk/rjk/

Back to comp.os.linux.misc | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

seq command terribly slow Robert Riches <spamtrap42@jacob21819.net> - 2016-03-13 04:18 +0000
  Re: seq command terribly slow Richard Kettlewell <rjk@greenend.org.uk> - 2016-03-13 12:24 +0000
    Re: seq command terribly slow Robert Riches <spamtrap42@jacob21819.net> - 2016-03-13 16:42 +0000
      Re: seq command terribly slow "Anonymous Remailer (austria)" <mixmaster@remailer.privacy.at> - 2016-03-14 14:22 +0100
        Re: seq command terribly slow Robert Riches <spamtrap42@jacob21819.net> - 2016-03-15 02:38 +0000
  Re: seq command terribly slow Gernot Fink <g.fink@gmx.net> - 2016-03-13 18:21 +0100
    Re: seq command terribly slow Richard Kettlewell <rjk@greenend.org.uk> - 2016-03-13 17:45 +0000
  Re: seq command terribly slow Eli the Bearded <*@eli.users.panix.com> - 2016-03-14 21:58 +0000
    Re: seq command terribly slow Robert Riches <spamtrap42@jacob21819.net> - 2016-03-15 02:44 +0000
      Re: seq command terribly slow Eli the Bearded <*@eli.users.panix.com> - 2016-03-16 00:41 +0000

csiph-web