Major cleanup of new pmap code.