Date: Sun, 14 Dec 2014 07:52:11 -0700 From: Ian Lepore <ian@freebsd.org> To: Poul-Henning Kamp <phk@phk.freebsd.dk> Cc: current@freebsd.org Subject: Re: simple task to speed up booting Message-ID: <1418568731.935.8.camel@freebsd.org> In-Reply-To: <43445.1418553160@critter.freebsd.dk> References: <43445.1418553160@critter.freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
--=-PxMyjFLnRMWIs9bYXqP4 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Sun, 2014-12-14 at 10:32 +0000, Poul-Henning Kamp wrote: > The rotating swirlie ('-/|\') in the loader accounts for a surprisingly > large part of our boot time on systems with slow-ish serial consoles. > > I think right now it takes a step for each 512 byte read, reducing that > to once every 64kB or even 1MB would be an improvement with the kind of > kernel sizes we have today. > I experimented with that a while ago using the attached patch and was disappointed with the results. As I vaguely remember it, a divisor of 8 looked fine, but had no significant speedup. With a divisor of 32 the difference was measureable (only like 1.5 seconds or so faster), but it gave the impression that something was wrong, and the overall perception was that it was slower rather than faster, despite what a stopwatch said. I was testing at 115kbps, maybe at 9600 it would be significant. I don't understand why anything these days is still defaulting to 9600. It's the 21st century, but we never got the George Jetson flying cars we were promised, and apparently we're never going to break loose from the standards set by accoustic-coupled modems. -- Ian --=-PxMyjFLnRMWIs9bYXqP4 Content-Disposition: inline; filename="libstand_twiddle.diff" Content-Type: text/x-patch; name="libstand_twiddle.diff"; charset="us-ascii" Content-Transfer-Encoding: 7bit Index: lib/libstand/twiddle.c =================================================================== --- lib/libstand/twiddle.c (revision 274850) +++ lib/libstand/twiddle.c (working copy) @@ -46,7 +46,11 @@ void twiddle() { static int pos; + static int divisor; - putchar("|/-\\"[pos++ & 3]); - putchar('\b'); + if (divisor-- == 0) { + divisor = 32; + putchar("|/-\\"[pos++ & 3]); + putchar('\b'); + } } --=-PxMyjFLnRMWIs9bYXqP4--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1418568731.935.8.camel>