#
d07c930c |
| 11-May-2013 |
Ingo Weinhold <ingo_weinhold@gmx.de> |
packagefs: Share string instances globally
Introduce a class String which refers to shared private data that is registered in a global hash table (in class StringPool) and use the class consequently
packagefs: Share string instances globally
Introduce a class String which refers to shared private data that is registered in a global hash table (in class StringPool) and use the class consequently. This eliminates duplicate allocations for the same string and also speeds up tests for equality. There's quite a bit overhead for the management structures (apparently even more than for the string data itself), but due to almost all strings being used multiple times this still almost halves the memory usage for string data.
show more ...
|