WIP: work on memory elements.
Added compressed I/O reader.