-
Task
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
None
-
5
-
a3d7182e0 (dev), 784783804 (6.10), 17cbf4700 (6.9), adb98cff3 (tqtc/lts-6.8), 4240b54b4 (tqtc/lts-6.5), eaf77edeb (dev), 5c6e78a2f (6.10), c8f56f2a7 (tqtc/lts-6.8), fbec86c1b (tqtc/lts-6.5)
-
Foundation Sprint 137, Foundation Sprint 138, Foundation Sprint 139
The QUnicodeTables::Properties struct contains a
struct {
ushort special : 1;
signed short diff : 15;
} cases[NumCases];
where NumCases is 4. So this part of the struct takes 4*16 = 64 bits = 8 bytes, of a total of sizeof(Properties) == 20.
We might want to look into moving the cases into a separate table, and either just use a single bit in the Properties table to indicate that the character should be looked up (with lower_bound) in the new table, or else place an index into the new table into Properties. With the former approach, the single bit would indicate the all-zero cases struct. With the latter approach, we share the many zero entries by mapping them all to index 0 in the new table.