check code optimization