mem: Minimize the use of MemObject.