Added memory segmentation