On Sun, Oct 07, 2001 at 06:29:37AM -0400, Thomas Dickey wrote:
> > It comes out about the same; the decoding logic offsets the gain of doing
> > less compares.  It pulls ahead of raw strstr with a simple optimization
> > of removing an unnecessary inner loop conditional (about 10% on my system),
> > so it's not quite RAM-bound.
> > 
> > I hadn't looked at decoding logic much; a big reason this ends up faster
> 
> well, then measure (has anyone, recently? -- all I see is assertions).

I didn't spend the time (assembling results and cleaning up source) since
the end result was the same or better; the table method for looking up UTF
lengths refuted my original statement, so I wasn't out to convince anyone
of anything.

Anyhow, I might do this for decoding UTF-8 characters; I'm interested in
knowing whether validating logic involves a speed hit, along with comparing
speeds of UCS-4 code for simple operations against UTF-8 equivalents.

-- 
Glenn Maynard
-
Linux-UTF8:   i18n of Linux on all levels
Archive:      http://mail.nl.linux.org/linux-utf8/

Reply via email to