Speedup collect of shared strings