better coding style for q7