add decompress_ptr in toplevel.py