MemoryMappedFile work; moved a lot of shared bits to SegmentFactory