remove useless structures