Correctly calculate the offset for read&x