flag handling in compare operation corrected, shift operations corrected