an error detection and correction system is disclosed for efficiently processing a product code typically employed in an optical storage device . in particular , the present invention decreases the processing time associated with iteratively processing the rows and columns of the product code by processing only those code words that were &# 34 ; flagged &# 34 ; during a previous iteration . if , for example , while processing the column code words a byte in a column code word is corrected , then the corresponding intersecting row code word is flagged for processing during the &# 34 ; row pass .&# 34 ; only the row code words that have been flagged are processed during the &# 34 ; row pass &# 34 ;, which significantly reduces buffer access latency and increases the overall throughput of the storage system . to assist in error detection and correction , an array of erasure pointers is employed where each erasure pointer corresponds to a byte in a code word . if there are no initial pointers set for a code word and the code word is uncorrectable or the possibility of a miscorrection is high , then all of the pointers for that code word are set and all of the intersecting code words are flagged for processing during the next pass . if a code word is error - free or correctable , then its pointers are cleared and the intersecting code words corresponding to the cleared erasure pointers are flagged for processing during the next pass . eventually , enough pointers in a previously uncorrectable code word may be cleared such that the code word becomes correctable .