Further changes to remove memory access functions