postgresql/src
Tom Lane 8d3e0906df Extend GB18030 encoding conversion to cover full Unicode range.
Our previous code for GB18030 <-> UTF8 conversion only covered Unicode code
points up to U+FFFF, but the actual spec defines conversions for all code
points up to U+10FFFF.  That would be rather impractical as a lookup table,
but fortunately there is a simple algorithmic conversion between the
additional code points and the equivalent GB18030 byte patterns.  Make use
of the just-added callback facility in LocalToUtf/UtfToLocal to perform the
additional conversions.

Having created the infrastructure to do that, we can use the same code to
map certain linearly-related subranges of the Unicode space below U+FFFF,
allowing removal of the corresponding lookup table entries.  This more
than halves the lookup table size, which is a substantial savings;
utf8_and_gb18030.so drops from nearly a megabyte to about half that.

In support of doing that, replace ISO10646-GB18030.TXT with the data file
gb-18030-2000.xml (retrieved from
http://source.icu-project.org/repos/icu/data/trunk/charset/data/xml/ )
in which these subranges have been deleted from the simple lookup entries.

Per bug #12845 from Arjen Nienhuis.  The conversion code added here is
based on his proposed patch, though I whacked it around rather heavily.
2015-05-15 15:02:13 -04:00
..
backend Extend GB18030 encoding conversion to cover full Unicode range. 2015-05-15 15:02:13 -04:00
bin Support --verbose option in reindexdb. 2015-05-15 21:45:55 +09:00
common Reorganize our CRC source files again. 2015-04-14 17:03:42 +03:00
include TABLESAMPLE, SQL Standard and extensible 2015-05-15 14:37:10 -04:00
interfaces Fix parallel make risk with new check temp-install setup 2015-04-29 20:34:22 -04:00
makefiles Fix parallel make risk with new check temp-install setup 2015-04-29 20:34:22 -04:00
pl Support "expanded" objects, particularly arrays, for better performance. 2015-05-14 12:08:49 -04:00
port TABLESAMPLE, SQL Standard and extensible 2015-05-15 14:37:10 -04:00
template
test TABLESAMPLE, SQL Standard and extensible 2015-05-15 14:37:10 -04:00
timezone
tools Enable transforms tests for python 2 on MSVC builds 2015-04-29 13:49:24 -04:00
tutorial
.gitignore
bcc32.mak
DEVELOPERS
Makefile
Makefile.global.in doc build: use unique Makefile variable to control temp install 2015-05-12 12:30:50 -04:00
Makefile.shlib Add transforms feature 2015-04-26 10:33:14 -04:00
nls-global.mk
win32.mak