add MEM.h to support mem operations