Some refactoring
Added low level memory operations to speed up the display