clean memory. also, -O3 rocks