remove unused code in Util and CoreUtil