mailing list of musl libc
 help / color / mirror / code / Atom feed
* musl build times
@ 2012-07-12 13:41 idunham
  2012-07-12 14:05 ` Rich Felker
  0 siblings, 1 reply; 5+ messages in thread
From: idunham @ 2012-07-12 13:41 UTC (permalink / raw)
  To: musl

[-- Attachment #1: Type: text/plain, Size: 540 bytes --]

I was just playing around, and discovered that redirecting to a file
shaves 1 minute, 5 seconds (3:36 vs 2:31) off the build time here (Atom
N270 @1.6 GHz; 5400 RPM SATA HDD in legacy mode, ext2; 1 GB DDR2; gcc
3.4.6, -march=i586; Linux 3.0.31). 2:33 is the time if redirected to
/dev/null (just for the purpose of comparison; I don't think anyone sane
would do this and install it!) I'm going to attach a log of build times
using the different approaches.
Don't bother looking at the first STD/STDJ2--I switched VTs, so the time
is wrong


[-- Attachment #2: buildtimes --]
[-- Type: text/plain, Size: 540 bytes --]

STD Thu Jul 12 06:08:06 PST 2012
Thu Jul 12 06:11:08 PST 2012
NULL Thu Jul 12 06:13:47 PST 2012
Thu Jul 12 06:16:20 PST 2012
FILE Thu Jul 12 06:20:38 PST 2012
Thu Jul 12 06:23:11 PST 2012
STDJ2 Thu Jul 12 06:23:11 PST 2012
Thu Jul 12 06:25:19 PST 2012
NULLJ2 Thu Jul 12 06:25:23 PST 2012
Thu Jul 12 06:27:19 PST 2012
FILEJ2 Thu Jul 12 06:27:19 PST 2012
Thu Jul 12 06:29:16 PST 2012
STDJ2 Thu Jul 12 06:29:54 PST 2012
Thu Jul 12 06:32:32 PST 2012
STD Thu Jul 12 06:33:47 PST 2012
STD Thu Jul 12 06:34:33 PST 2012
Thu Jul 12 06:38:10 PST 2012

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: musl build times
  2012-07-12 13:41 musl build times idunham
@ 2012-07-12 14:05 ` Rich Felker
  2012-07-12 14:30   ` Kurt H Maier
  2012-07-12 16:47   ` idunham
  0 siblings, 2 replies; 5+ messages in thread
From: Rich Felker @ 2012-07-12 14:05 UTC (permalink / raw)
  To: musl

On Thu, Jul 12, 2012 at 06:41:09AM -0700, idunham@lavabit.com wrote:
> I was just playing around, and discovered that redirecting to a file
> shaves 1 minute, 5 seconds (3:36 vs 2:31) off the build time here (Atom
> N270 @1.6 GHz; 5400 RPM SATA HDD in legacy mode, ext2; 1 GB DDR2; gcc

You mean directing output to a file versus to a terminal? If so, which
terminal are you using? That's probably very relevant...

Rich


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: musl build times
  2012-07-12 14:05 ` Rich Felker
@ 2012-07-12 14:30   ` Kurt H Maier
  2012-07-12 16:47   ` idunham
  1 sibling, 0 replies; 5+ messages in thread
From: Kurt H Maier @ 2012-07-12 14:30 UTC (permalink / raw)
  To: musl

On Thu, Jul 12, 2012 at 10:05:18AM -0400, Rich Felker wrote:
> You mean directing output to a file versus to a terminal? If so, which
> terminal are you using? That's probably very relevant...

Also relevant is that linux TTYs have a baud rate limit.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: musl build times
  2012-07-12 14:05 ` Rich Felker
  2012-07-12 14:30   ` Kurt H Maier
@ 2012-07-12 16:47   ` idunham
  2012-07-12 17:11     ` Rich Felker
  1 sibling, 1 reply; 5+ messages in thread
From: idunham @ 2012-07-12 16:47 UTC (permalink / raw)
  To: musl

> On Thu, Jul 12, 2012 at 06:41:09AM -0700, idunham@lavabit.com wrote:
>> I was just playing around, and discovered that redirecting to a file
>> shaves 1 minute, 5 seconds (3:36 vs 2:31) off the build time here (Atom
>> N270 @1.6 GHz; 5400 RPM SATA HDD in legacy mode, ext2; 1 GB DDR2; gcc
>
> You mean directing output to a file versus to a terminal? If so, which
> terminal are you using? That's probably very relevant...
Probably so...
kernel VT with i915 + fbcon.
Now that I think back, I think real textmode was significantly faster.
By the way, this is the same reason "quiet" speeds up boot (my testing
showed ~ 2-3 seconds difference in kernel boot, out of ~8 seconds without
quiet...)
I've noticed similar effects with Xterm & urxvt, though ISTR that urxvt
can be sped up with asynchronous text output (I forget the option,
though).





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: musl build times
  2012-07-12 16:47   ` idunham
@ 2012-07-12 17:11     ` Rich Felker
  0 siblings, 0 replies; 5+ messages in thread
From: Rich Felker @ 2012-07-12 17:11 UTC (permalink / raw)
  To: musl

On Thu, Jul 12, 2012 at 12:47:47PM -0400, idunham@lavabit.com wrote:
> > On Thu, Jul 12, 2012 at 06:41:09AM -0700, idunham@lavabit.com wrote:
> >> I was just playing around, and discovered that redirecting to a file
> >> shaves 1 minute, 5 seconds (3:36 vs 2:31) off the build time here (Atom
> >> N270 @1.6 GHz; 5400 RPM SATA HDD in legacy mode, ext2; 1 GB DDR2; gcc
> >
> > You mean directing output to a file versus to a terminal? If so, which
> > terminal are you using? That's probably very relevant...
> Probably so...
> kernel VT with i915 + fbcon.

That's the problem.

> Now that I think back, I think real textmode was significantly faster.
> By the way, this is the same reason "quiet" speeds up boot (my testing
> showed ~ 2-3 seconds difference in kernel boot, out of ~8 seconds without
> quiet...)
> I've noticed similar effects with Xterm & urxvt, though ISTR that urxvt
> can be sped up with asynchronous text output (I forget the option,
> though).

Most/all of these terminals have a fundamental design flaw: when they
receive text from the application, after applying the changes to their
internal representation of the terminal contents, they immediately,
synchronously, update the visual presentation on-screen, delaying
processing of any further input and allowing it to back up. This is
pathologically inefficient, and didn't matter so much for traditional
vga textmode terminals, but the inefficiency becomes very noticable on
fbcon and X-based terminals.

[Shameless plug starts here:] The only terminal I know of without this
design issue is uuterm. In its main select loop, it processes input
and applies it to its internal terminal representation as long as
input is available. Only when no further input is available (as
determined by select), or when a long interval of time has passed with
no break in the input stream, is the internal representation applied
to the screen contents. Even with a fairly expensive text rendering
system that accounts for unicode combining characters and glyph
substitution, it's still many times faster than the Linux console and
most X-based terminal apps just because it doesn't perform repetitive
video updates only to overwrite them immediately with new updates.

Rich


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-07-12 17:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-12 13:41 musl build times idunham
2012-07-12 14:05 ` Rich Felker
2012-07-12 14:30   ` Kurt H Maier
2012-07-12 16:47   ` idunham
2012-07-12 17:11     ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).