From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/1279 Path: news.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: musl build times Date: Thu, 12 Jul 2012 13:11:00 -0400 Message-ID: <20120712171100.GE544@brightrain.aerifal.cx> References: <47404.50.0.229.11.1342100469.squirrel@lavabit.com> <20120712140518.GC544@brightrain.aerifal.cx> <42355.50.0.229.11.1342111667.squirrel@lavabit.com> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1342113145 18914 80.91.229.3 (12 Jul 2012 17:12:25 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 12 Jul 2012 17:12:25 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-1280-gllmg-musl=m.gmane.org@lists.openwall.com Thu Jul 12 19:12:25 2012 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1SpMwA-0005BD-T3 for gllmg-musl@plane.gmane.org; Thu, 12 Jul 2012 19:12:22 +0200 Original-Received: (qmail 8070 invoked by uid 550); 12 Jul 2012 17:12:05 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 8031 invoked from network); 12 Jul 2012 17:12:04 -0000 Content-Disposition: inline In-Reply-To: <42355.50.0.229.11.1342111667.squirrel@lavabit.com> User-Agent: Mutt/1.5.21 (2010-09-15) Xref: news.gmane.org gmane.linux.lib.musl.general:1279 Archived-At: 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