Improve bf2run debug mode. Add dynamic mem.