perfomance tuning, perfmance measuring, cleanups...