remove useless bits