Shut down memory subsystem at exit, don't use abs with floats