debug remainder copy