tests and fixes for cpu