lkml.org 
[lkml]   [2007]   [Apr]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] console UTF-8 fixes
> So please accept these hard-coded tables in the first round. Maybe one day
> somebody will come up with a better solution. This one should be okay until
> then. (I can also send the script I've written so he can improve it.)

You can pack them a little differently and they'll shrink a lot.

Firstly store
start, size

Secondly pack the offset as 16 bit with the top 4 bits

0-3 value
4 - F
5 - 1D
6 - E0

And the size as an 8 bit range. You need to open code the rule for
20000/30000 but that is tiny anyway.
Unpack is trivial

start = (toptab[*entry>>4]|(*entry&0x0F)) << 8 | entry[1];
end = start + entry[2];
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-04-12 15:13    [W:0.178 / U:0.116 seconds]
©2003-2011 Jasper Spaans. Advertise on this site