unicode string library
git clone git://
Log | Files | Refs | README | LICENSE

commit 4d157807af659ec392043cffd36935eba8c634af
parent 32fbf8efbb801dd603d39e83bda57e369cee8456
Author: Laslo Hunhold <>
Date:   Sat,  8 Jan 2022 16:56:47 +0100

Rename gen/properties.c to gen/character-properties.c

At first I thought we would have one big lookup-table for all
properties, but it doesn't make sense for multiple reasons. Even though
compression remains great even for more than one property (it goes down
to roughly 95-96%), this still has a drastic impact on performance.
Additionally, as mentioned earlier, this allows better LTO for the use
of a single or few functions (which should be the common case), because
each data-table is separate.

Signed-off-by: Laslo Hunhold <>

MMakefile | 10+++++-----
Rgen/properties.c -> gen/character-properties.c | 0
Msrc/character.c | 2+-
3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/Makefile b/Makefile @@ -15,7 +15,7 @@ DATA =\ GEN =\ gen/character-test\ - gen/properties\ + gen/character-properties\ SRC =\ src/character\ @@ -42,9 +42,9 @@ benchmark/utf8-decode.o: benchmark/utf8-decode.c gen/character-test.h benchmark/util.o: benchmark/util.c benchmark/util.h gen/character-prop.o: gen/character-prop.c gen/util.h gen/character-test.o: gen/character-test.c gen/util.h -gen/properties.o: gen/properties.c gen/util.h +gen/character-properties.o: gen/character-properties.c gen/util.h gen/util.o: gen/util.c gen/util.h -src/character.o: src/character.c gen/properties.h grapheme.h src/util.h +src/character.o: src/character.c gen/character-properties.h grapheme.h src/util.h src/utf8.o: src/utf8.c grapheme.h src/util.o: src/util.c gen/types.h grapheme.h src/util.h test/character.o: test/character.c gen/character-test.h grapheme.h test/util.h @@ -55,13 +55,13 @@ test/util.o: test/util.c test/util.h benchmark/character: benchmark/character.o benchmark/util.o libgrapheme.a benchmark/utf8-decode: benchmark/utf8-decode.o benchmark/util.o libgrapheme.a gen/character-test: gen/character-test.o gen/util.o -gen/properties: gen/properties.o gen/util.o +gen/character-properties: gen/character-properties.o gen/util.o test/character: test/character.o test/util.o libgrapheme.a test/utf8-encode: test/utf8-encode.o test/util.o libgrapheme.a test/utf8-decode: test/utf8-decode.o test/util.o libgrapheme.a gen/character-test.h: data/GraphemeBreakTest.txt gen/character-test -gen/properties.h: data/emoji-data.txt data/GraphemeBreakProperty.txt gen/properties +gen/character-properties.h: data/emoji-data.txt data/GraphemeBreakProperty.txt gen/character-properties data/emoji-data.txt: wget -O $@ diff --git a/gen/properties.c b/gen/character-properties.c diff --git a/src/character.c b/src/character.c @@ -4,7 +4,7 @@ #include <stdlib.h> #include <string.h> -#include "../gen/properties.h" +#include "../gen/character-properties.h" #include "../grapheme.h" #include "util.h"