memory efficiency fix