clean up and some cpu flags tests

Change-Id: I956257fc47e026ac8c1a825286ea9aa144de97b9