PATENT DOCUMENT

Publication Number: US-8694854-B1
Application Number: US-201113195852-A
Country: US
Kind Code: B1

Title: Read threshold setting based on soft readout statistics

Abstract:
A method for data storage includes storing data in analog memory cells by programming the memory cells with respective analog input values. After storing the data, respective analog output values are read from the memory cells using multiple read thresholds, which define multiple ranges of the analog output values. Respective numbers of read errors in the data, corresponding to the analog output values falling in the ranges, are assessed. The stored data is recovered based on respective numbers of the read errors assessed in the ranges.

Claims:
The invention claimed is: 
     
       1. A method for data storage, comprising:
 storing data in memory cells; 
 after storing the data, reading the memory cells using multiple read thresholds to produce respective output values, wherein the multiple read thresholds define multiple ranges of the output values; 
 assessing a number of read errors in the data corresponding to the output values included in each of the ranges, wherein the output values of the data included in each of the ranges are bounded by read thresholds of the multiple read thresholds associated with each range; and 
 recovering the stored data based on the number of read errors assessed in each of the ranges. 
 
     
     
       2. The method according to  claim 1 , wherein recovering the stored data comprises adjusting at least one of the read thresholds based on the number of read errors in at least one of the ranges, and retrieving the data from the memory cells using the adjusted read thresholds. 
     
     
       3. The method according to  claim 2 , wherein adjusting the read thresholds comprises adapting the read thresholds based on the number of read errors in at least one of the ranges assessed in a first group of the memory cells, and wherein retrieving the data comprises reading the data from a second group of the memory cells using the adapted read thresholds. 
     
     
       4. The method according to  claim 2 , wherein adjusting the read thresholds comprises adapting the read thresholds based on the number of read errors in at least one of the ranges assessed in a given group of the memory cells, and wherein retrieving the data comprises reading the data from the given group of the memory cells using the adapted read thresholds. 
     
     
       5. The method according to  claim 2 , wherein adjusting the read thresholds comprises moving the multiple read thresholds while maintaining separations between the read thresholds. 
     
     
       6. The method according to  claim 2 , wherein adjusting the read thresholds comprises modifying one or more separations between the read thresholds. 
     
     
       7. The method according to  claim 2 , further comprising using a look-up table that maps multiple sets of the read thresholds to one or more parameters related to the output values, wherein adjusting the read thresholds comprises estimating the parameters based on the read output values, and obtaining the read thresholds from the look-up table using the estimated parameters. 
     
     
       8. The method according to  claim 1 , wherein the read thresholds comprise at least a hard threshold and two soft thresholds on opposite sides of the hard threshold, and wherein the ranges comprise at least a first range between the hard threshold and one of the soft thresholds, and a second range between the hard threshold and the other of the soft thresholds. 
     
     
       9. The method according to  claim 1 , wherein storing the data comprises programming each memory cell to a respective one of multiple programming levels, and wherein reading the analog output values comprises positioning the multiple read thresholds in a boundary region between a given pair of the programming levels. 
     
     
       10. The method according to  claim 1 , wherein recovering the stored data comprises computing soft decoding metrics based on the number of read errors in at least one of the ranges, and decoding an Error Correction Code (ECC) that encodes the stored data using the soft decoding metrics. 
     
     
       11. The method according to  claim 10 , wherein recovering the stored data comprises computing the soft decoding metrics over a first group of the memory cells, and decoding the ECC that encodes the data stored in a second group of the memory cells. 
     
     
       12. The method according to  claim 1 , wherein storing the data comprises encoding the data with an Error Correction Code (ECC), and wherein assessing the number of read errors in each range comprises correcting the read errors using the ECC and determining a respective count of the read errors in each range that were corrected by the ECC. 
     
     
       13. The method according to  claim 1 , wherein storing the data comprises programming each memory cell to a respective one of multiple programming levels, and wherein the output values corresponding to at least one of the programming levels are distributed in accordance with a non-Gaussian distribution. 
     
     
       14. A data storage apparatus, comprising:
 an interface configured to communicate with a memory, wherein the memory includes a plurality of memory cells; and 
 circuitry configured to:
 store data in the memory cells of the memory; 
 read, after storing the data, the memory cells using multiple read thresholds to produce respective output values of the data, wherein the multiple read thresholds define multiple ranges of the output values; 
 assess a number of read errors in the data corresponding to the output values included in each of the ranges, wherein the output values of the data included in each of the ranges are bounded by associated read thresholds; and 
 recover the stored data based on the number of the read errors assessed in each of the ranges. 
 
 
     
     
       15. The apparatus according to  claim 14 , wherein to recover the stored data, the circuitry is further configured to adjust at least one of the read thresholds based on the number of read errors in at least one of the ranges, and retrieving the data from the memory cells using the adjusted read thresholds. 
     
     
       16. The apparatus according to  claim 15 , wherein the circuitry is further configured to adjust the read thresholds based on the number of read errors in at least one of the ranges assessed in a first group of the memory cells, and to retrieve the data from a second group of the memory cells using the adjusted read thresholds. 
     
     
       17. The apparatus according to  claim 15 , wherein the circuitry is further configured to adjust the read thresholds based on the number of read errors in at least one of the ranges assessed in given group of the memory cells, and to retrieve the data from the given group of the memory cells using the adjusted read thresholds. 
     
     
       18. The apparatus according to  claim 15 , wherein the circuitry is further configured to move the multiple read thresholds while maintaining separations between the read thresholds. 
     
     
       19. The apparatus according to  claim 15 , wherein the circuitry is further configured to modify one or more separations between the read thresholds. 
     
     
       20. The apparatus according to  claim 15 , wherein the circuitry is further configured use a look-up table that maps multiple sets of read thresholds to one or more parameters related to the output values, and to adjust the read thresholds by estimating the parameters based on the read output values, and obtaining the read thresholds from the look-up table using the estimated parameters. 
     
     
       21. The apparatus according to  claim 14 , wherein the read thresholds comprise at least a hard threshold and two soft thresholds on opposite sides of the hard threshold, and wherein the ranges comprise at least a first range between the hard threshold and one of the soft thresholds, and a second range between the hard threshold and the other of the soft thresholds. 
     
     
       22. The apparatus according to  claim 14 , wherein the circuitry is further configured to program each memory cell to a respective one of multiple programming levels, and to position the multiple read thresholds in a boundary region between a given pair of the programming levels. 
     
     
       23. The apparatus according to  claim 14 , wherein the circuitry is further configured to recover the stored data by computing soft decoding metrics based on the number of read errors in at least one of the ranges, and decoding an Error Correction Code (ECC) that encodes the stored data using the soft decoding metrics. 
     
     
       24. The apparatus according to  claim 23 , wherein the circuitry is further configured to compute the soft decoding metrics over a first group of the memory cells, and to decode the ECC that encodes the data stored in a second group of the memory cells. 
     
     
       25. The apparatus according to  claim 14 , wherein the circuitry is further configured to encode the stored data with an Error Correction Code (ECC), and to assess the number of read errors in each range by correcting the read errors using the ECC and determining a respective count of the read errors in each range that were corrected by the ECC. 
     
     
       26. The apparatus according to  claim 14 , wherein the circuitry is further configured to program each memory cell to a respective one of multiple programming levels, and wherein the output values corresponding to at least one of the programming levels are distributed in accordance with a non-Gaussian distribution. 
     
     
       27. A data storage apparatus, comprising:
 a memory comprising a plurality of memory cells; and 
 circuitry configured to:
 store data in the memory cells of the memory; 
 read, after storing the data, the memory cells using multiple read thresholds to produce respective output values of the data, wherein the multiple read thresholds define multiple ranges of the output values; 
 assess a number of read errors in the data corresponding to the output values included in each of the ranges, wherein the output values of the data included in each of the ranges are bounded by associated read thresholds; and 
 adjust at least one of the read thresholds based on the number of read errors assessed in each of the ranges. 
 
 
     
     
       28. A method for data storage, comprising:
 storing data in analog memory cells by programming the memory cells with respective analog input values; 
 setting multiple read thresholds for reading respective analog output values from the memory cells, wherein the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value; and 
 retrieving the stored data by reading the analog output values from the memory cells using the multiple read thresholds. 
 
     
     
       29. The method according to  claim 28 , wherein setting the read thresholds comprises estimating one or more Cumulative Distribution Functions (CDFs) of the analog output values, and setting the read thresholds based on the estimated CDFs. 
     
     
       30. The method according to  claim 28 , and comprising holding a mapping that defines multiple sets of the read thresholds depending on one or more parameters related to the analog output values, wherein setting the read thresholds comprises estimating the parameters based on the read analog output values, and obtaining the read thresholds from the mapping using the estimated parameters. 
     
     
       31. A data storage apparatus, comprising:
 an interface, which is configured to communicate with a memory comprising analog memory cells; and 
 circuitry, which is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to set multiple read thresholds for reading respective analog output values from the memory cells, wherein the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value, and to retrieve the stored data by reading the analog output values from the memory cells using the multiple read thresholds. 
 
     
     
       32. The apparatus according to  claim 31 , wherein the circuitry is configured to estimate one or more Cumulative Distribution Functions (CDFs) of the analog output values, and to set the read thresholds based on the estimated CDFs. 
     
     
       33. The apparatus according to  claim 31 , wherein the circuitry is configured to hold a mapping that defines multiple sets of the read thresholds depending on one or more parameters related to the analog output values, and to set the read thresholds by estimating the parameters based on the read analog output values, and obtaining the read thresholds from the mapping using the estimated parameters. 
     
     
       34. A data storage apparatus, comprising:
 a memory comprising analog memory cells; and 
 circuitry, which is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to set multiple read thresholds for reading respective analog output values from the memory cells, wherein the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value, and to retrieve the stored data by reading the analog output values from the memory cells using the multiple read thresholds. 
 
     
     
       35. A method for data storage, comprising:
 using a look-up table that maps multiple sets of read thresholds for reading memory cells to one or more parameters related to values read from the memory cells; 
 storing data in a group of the analog memory cells; 
 after storing the data, reading respective output values from the memory cells in the group and estimating the parameters based on the read output values; and 
 setting the read thresholds for subsequent read operations dependent upon the look-up table, using the estimated parameters. 
 
     
     
       36. The method according to  claim 35 , wherein the parameters comprise at least one parameter type selected from a group of types consisting of a variance of a distribution of at least some of the output values, a width of the distribution of at least some of the output values, and a distance between distributions of subsets of the output values. 
     
     
       37. A data storage apparatus, comprising:
 an interface, which is configured to communicate with a memory comprising analog memory cells; and 
 circuitry, which is configured to hold a mapping that defines multiple sets of read thresholds for reading analog memory cells depending on one or more parameters related to analog values read from the memory cells, to store data in a group of the analog memory cells by programming the memory cells in the group with respective analog input values, to read, after storing the data, respective analog output values from the memory cells in the group and to estimate the parameters based on the read analog output values, and to set the read thresholds for subsequent readout operations based on the mapping using the estimated parameters. 
 
     
     
       38. The apparatus according to  claim 37 , wherein the parameters comprise at least one parameter type selected from a group of types consisting of a variance of a distribution of at least some of the analog output values, a width of the distribution and a distance between distributions of subsets of the analog output values. 
     
     
       39. A data storage apparatus, comprising:
 a memory comprising analog memory cells; and 
 circuitry, which is configured to hold a mapping that defines multiple sets of read thresholds for reading analog memory cells depending on one or more parameters related to analog values read from the memory cells, to store data in a group of the analog memory cells by programming the memory cells in the group with respective analog input values, to read, after storing the data, respective analog output values from the memory cells in the group and to estimate the parameters based on the read analog output values, and to set the read thresholds for subsequent readout operations based on the mapping using the estimated parameters.

Description:
CROSS-REFERENCE TO RELATED APPLICATIONS 
     This application claims the benefit of U.S. Provisional Patent Application 61/374,377, filed Aug. 17, 2010, whose disclosure is incorporated herein by reference. 
    
    
     FIELD OF THE INVENTION 
     The present invention relates generally to memory devices, and particularly to methods and systems for setting read thresholds in non-volatile memory devices. 
     BACKGROUND OF THE INVENTION 
     Analog memory cells, such as Flash memory cells, are typically read by comparing the analog cell values to one or more read thresholds. Various techniques for setting and adjusting read thresholds are known in the art. For example, U.S. Pat. No. 5,657,332, whose disclosure is incorporated herein by reference, describes methods for recovering from hard errors in a solid-state memory system. A memory system includes an array of memory cells, each cell capable of having its threshold voltage programmed or erased to an intended level. An error checking scheme is provided for each of a plurality of groups of cells for identifying read errors therein. A read reference level is adjusted before each read operation on the individual group of cells containing read errors, each time the read reference level being displaced a predetermined step from a reference level for normal read, until the error checking means no longer indicates read errors. The drifted threshold voltage of each cell associated with a read error is re-written to its intended level. 
     U.S. Patent Application Publication 2007/0091677, whose disclosure is incorporated herein by reference, describes techniques for reading data from one or more Flash memory cells, and for recovering from read errors. In some embodiments, in the event of an error correction failure by an error detection and correction module, the Flash memory cells are re-read at least once using one or more modified reference voltages, until successful error correction may be carried out. 
     U.S. Pat. No. 6,963,505, whose disclosure is incorporated herein by reference, describes methods for determining a reference voltage. In some embodiments, a set of operating reference cells is established to be used in operating cells in a Non-Volatile Memory (NVM) block or array. At least a subset of cells of the NVM block or array may be read using each of two or more sets of test reference cells, where each set of test reference cells may generate or otherwise provide reference voltages at least slightly offset from each other set of test reference cells. For each set of test reference cells used to read at least a subset of the NVM block, a read error rate may be calculated or otherwise determined. A set of test reference cells associated with a relatively low read error rate may be selected as the set of operating reference cells to be used in operating other cells, outside the subset of cells, in the NVM block or array. 
     U.S. Patent Application Publication 2010/0091535, whose disclosure is incorporated herein by reference, describes various techniques for adjusting read thresholds of analog memory cells. In one of the disclosed techniques, data is encoded with an Error Correction Code (ECC) before it is stored in the memory cells. When retrieving data from the memory cells, the ECC is decoded in order to correct read errors. For a given read error that was corrected by the ECC, the direction of the error, i.e., the programming level with which the read storage value was erroneously associated before applying ECC correction, is determined. Information regarding directions of corrected errors is used for adjusting the read thresholds. 
     SUMMARY OF THE INVENTION 
     A method for data storage includes storing data in analog memory cells by programming the memory cells with respective analog input values. After storing the data, respective analog output values are read from the memory cells using multiple read thresholds, which define multiple ranges of the analog output values. Respective numbers of read errors in the data, corresponding to the analog output values falling in the ranges, are assessed. The stored data is recovered based on respective numbers of the read errors assessed in the ranges. 
     In some embodiments, recovering the stored data includes adjusting at least one of the read thresholds based on the respective numbers of the read errors, and retrieving the data from the memory cells using the adjusted read thresholds. In an embodiment, adjusting the read thresholds includes adapting the read thresholds based on the numbers of the read errors assessed in a first group of the memory cells, and retrieving the data includes reading the data from a second group of the memory cells using the adapted read thresholds. 
     In another embodiment, adjusting the read thresholds includes adapting the read thresholds based on the numbers of the read errors assessed in given group of the memory cells, and retrieving the data includes reading the data from the given group of the memory cells using the adapted read thresholds. In yet another embodiment, adjusting the read thresholds includes moving the multiple read thresholds while preserving separations between the read thresholds. In still another embodiment, adjusting the read thresholds includes modifying one or more separations between the read thresholds. 
     In a disclosed embodiment, the method includes holding a mapping that defines multiple sets of the read thresholds depending on one or more parameters related to the analog output values, and adjusting the read thresholds includes estimating the parameters based on the read analog output values, and obtaining the read thresholds from the mapping using the estimated parameters. In an embodiment, adjusting the read thresholds includes modeling readout of the data using a communication channel model, and adapting the read thresholds so as to maximize a capacity of the communication channel model. 
     In some embodiments, the read thresholds include at least a hard threshold and two soft thresholds on opposite sides of the hard threshold, and the ranges include at least a first range between the hard threshold and one of the soft thresholds, and a second range between the hard threshold and the other of the soft thresholds. In an embodiment, storing the data includes programming each memory cell to a respective one of multiple programming levels, and reading the analog output values includes positioning the multiple read thresholds in a boundary region between a given pair of the programming levels. 
     In a disclosed embodiment, recovering the stored data includes computing soft decoding metrics based on the respective numbers of the read errors, and decoding an Error Correction Code (ECC) that encodes the stored data using the soft decoding metrics. Recovering the stored data may include computing the soft decoding metrics over a first group of the memory cells, and decoding the ECC that encodes the data stored in a second group of the memory cells. 
     In another embodiment, storing the data includes encoding the data with an Error Correction Code (ECC), and assessing the numbers of the read errors includes correcting the read errors using the ECC and determining a respective count of the read errors in each range that were corrected by the ECC. In yet another embodiment, storing the data includes programming each memory cell to a respective one of multiple programming levels, and the analog output values corresponding to at least one of the programming levels are distributed in accordance with a non-Gaussian distribution. 
     There is additionally provided, in accordance with an embodiment of the present invention, a data storage apparatus including an interface and circuitry. The interface is configured to communicate with a memory including analog memory cells. The circuitry is configured to store data in the analog memory cells of the memory by programming the memory cells with respective analog input values, to read, after storing the data, respective analog output values from the memory cells using multiple read thresholds that define multiple ranges of the analog output values, to assess a respective number of read errors in the data corresponding to the analog output values falling in each of the ranges, and to adjust at least one of the read thresholds based on respective numbers of the read errors assessed in the ranges. 
     There is also provided, in accordance with an embodiment of the present invention, a data storage apparatus including a memory and circuitry. The memory includes analog memory cells. The circuitry is configured to store data in the analog memory cells of the memory by programming the memory cells with respective analog input values, to read, after storing the data, respective analog output values from the memory cells using multiple read thresholds that define multiple ranges of the analog output values, to assess a respective number of read errors in the data corresponding to the analog output values falling in each of the ranges, and to adjust at least one of the read thresholds based on respective numbers of the read errors assessed in the ranges. 
     There is further provided, in accordance with an embodiment of the present invention, a method for data storage. The method includes storing data in analog memory cells by programming the memory cells with respective analog input values. Multiple read thresholds are set for reading respective analog output values from the memory cells. the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value. The stored data is retrieved by reading the analog output values from the memory cells using the multiple read thresholds. 
     In an embodiment, setting the read thresholds includes estimating one or more Cumulative Distribution Functions (CDFs) of the analog output values, and setting the read thresholds based on the estimated CDFs. In a disclosed embodiment, the method includes holding a mapping that defines multiple sets of the read thresholds depending on one or more parameters related to the analog output values, and setting the read thresholds includes estimating the parameters based on the read analog output values, and obtaining the read thresholds from the mapping using the estimated parameters. In another embodiment, setting the read thresholds includes modeling readout of the data using a communication channel model, and adapting the read thresholds so as to maximize a capacity of the communication channel model. 
     There is also provided, in accordance with an embodiment of the present invention, a data storage apparatus including an interface and circuitry. The interface is configured to communicate with a memory including analog memory cells. The circuitry is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to set multiple read thresholds for reading respective analog output values from the memory cells, wherein the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value, and to retrieve the stored data by reading the analog output values from the memory cells using the multiple read thresholds. 
     There is moreover provided, in accordance with an embodiment of the present invention, a data storage apparatus including a memory and circuitry. The memory includes analog memory cells. The circuitry is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to set multiple read thresholds for reading respective analog output values from the memory cells, wherein the read thresholds define multiple ranges of the analog output values and are set such that a respective number of the analog output values occurring in each range matches a respective value, and to retrieve the stored data by reading the analog output values from the memory cells using the multiple read thresholds. 
     There is additionally provided, in accordance with an embodiment of the present invention, a method for data storage including holding a mapping that defines multiple sets of read thresholds for reading analog memory cells depending on one or more parameters related to analog values read from the memory cells. Data is stored in a group of the analog memory cells by programming the memory cells in the group with respective analog input values. After storing the data, respective analog output values are read from the memory cells in the group and the parameters are estimated based on the read analog output values. The read thresholds are set for subsequent readout operations based on the mapping using the estimated parameters. 
     In some embodiments, the parameters include a variance of a distribution of at least some of the analog output values, a width of the distribution and/or a distance between distributions of subsets of the analog output values. 
     There is also provided, in accordance with an embodiment of the present invention, a data storage apparatus including an interface and circuitry. The interface is configured to communicate with a memory including analog memory cells. The circuitry is configured to hold a mapping that defines multiple sets of read thresholds for reading analog memory cells depending on one or more parameters related to analog values read from the memory cells, to store data in a group of the analog memory cells by programming the memory cells in the group with respective analog input values, to read, after storing the data, respective analog output values from the memory cells in the group and to estimate the parameters based on the read analog output values, and to set the read thresholds for subsequent readout operations based on the mapping using the estimated parameters. 
     There is further provided, in accordance with an embodiment of the present invention, a data storage apparatus including a memory and circuitry. The memory includes analog memory cells. The circuitry is configured to hold a mapping that defines multiple sets of read thresholds for reading analog memory cells depending on one or more parameters related to analog values read from the memory cells, to store data in a group of the analog memory cells by programming the memory cells in the group with respective analog input values, to read, after storing the data, respective analog output values from the memory cells in the group and to estimate the parameters based on the read analog output values, and to set the read thresholds for subsequent readout operations based on the mapping using the estimated parameters. 
     There is furthermore provided, in accordance with an embodiment of the present invention, a method for data storage including storing data in analog memory cells by programming the memory cells with respective analog input values. After storing the data, respective analog output values are read from the memory cells using multiple read thresholds. Readout of the data is modeled using a communication channel model, and the read thresholds are adapted so as to maximize a capacity of the communication channel model. 
     There is also provided, in accordance with an embodiment of the present invention, a data storage apparatus including an interface and circuitry. The interface is configured to communicate with a memory including analog memory cells. The circuitry is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to read, after storing the data, respective analog output values from the memory cells using multiple read thresholds, to model readout of the data using a communication channel model, and to adapt the read thresholds so as to maximize a capacity of the communication channel model. 
     There is additionally provided, in accordance with an embodiment of the present invention, a data storage apparatus including a memory and circuitry. The memory includes analog memory cells. The circuitry is configured to store data in the analog memory cells by programming the memory cells with respective analog input values, to read, after storing the data, respective analog output values from the memory cells using multiple read thresholds, to model readout of the data using a communication channel model, and to adapt the read thresholds so as to maximize a capacity of the communication channel model. 
     The present invention will be more fully understood from the following detailed description of the embodiments thereof, taken together with the drawings in which: 
    
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         FIG. 1  is a block diagram that schematically illustrates a memory system, in accordance with an embodiment of the present invention; 
         FIG. 2  is a graph showing threshold voltage distributions and read thresholds in a group of analog memory cells, in accordance with an embodiment of the present invention; and 
         FIG. 3  is a flow chart that schematically illustrates a method for adjusting read thresholds, in accordance with an embodiment of the present invention. 
     
    
    
     DETAILED DESCRIPTION OF EMBODIMENTS 
     Overview 
     In memory devices such as Flash memory, data is stored in analog memory cells by programming the memory cells to respective analog input values that represent the stored bit values. Data is retrieved by comparing respective analog output values of the memory cells to one or more read thresholds. In other words, each bit value corresponds to a respective programming level that is represented by a certain region of analog output values. The relation between the analog output value of a given memory cell and the read thresholds is indicative of the memory cell&#39;s programming level, and thus of the data stored in that memory cell. Analog output values may drift over time and may be subject to various types of impairments. Thus, proper setting and adaptation of the read thresholds is important for maintaining low read error probability. 
     Embodiments of the present invention that are described herein provide improved methods and systems for setting read thresholds used for reading analog memory cells. The disclosed techniques are based on reading the memory cells using multiple read thresholds. The multiple read thresholds are typically all positioned in a boundary region between a given pair of programming levels. Positioning of the read thresholds defines multiple ranges of output values between the thresholds. 
     In each range, the number of read errors in the data corresponding to the analog output values falling in the range is assessed. In other words, the number of memory cells whose output value falls in the range even though their stored data corresponds to a different range is assessed separately for each range. One or more of the read thresholds are adjusted based on the numbers of read errors assessed for the different output value ranges. In some embodiments, the stored data is encoded with an Error Correction Code (ECC), and the numbers of errors for the different ranges are obtained from the ECC decoding process. 
     It is possible in principle to perform threshold adaptation based on the number of read errors relative to a single read threshold, e.g., by aiming to equalize the total number of read bits that were corrected by the ECC from “0” to “1” and the total number of bits that were corrected from “1” to “0”. This technique, however, performs well only for certain types of statistical distributions of the output values, and is therefore not valid for all cases. 
     By considering the number of read errors that occur in multiple different ranges of output values, the disclosed techniques are able to focus on subsets of the read errors that are meaningful for threshold setting. As such, the disclosed techniques perform well under a wide variety of real-life output value distributions, such as various non-Gaussian distributions. One example of such a distribution is caused by “stuck bits,” i.e., memory cells whose output values remain fixed and do not respond to programming. 
     Several example embodiments that use the disclosed techniques are described herein. Some embodiments use hard ECC decoding and others use soft decoding. In some embodiments, the assessed numbers of errors for the different output value ranges are used to improve initial soft decoding metrics (e.g., Log Likelihood Ratios LLRs) used for soft ECC decoding. 
     In other embodiments, multiple sets of read thresholds are stored in a Look-Up Table (LUT), and the appropriate set is chosen based on the read output values. Other disclosed techniques adjust the read thresholds such that the absolute number of output values falling in each range of output values matches a respective target number. In other embodiments, the data readout process is modeled in terms of a communication channel, and the read thresholds are adapted so as to maximize the channel capacity. 
     System Description 
       FIG. 1  is a block diagram that schematically illustrates a memory system  20 , in accordance with an embodiment of the present invention. System  20  can be used in various host systems and devices, such as in computing devices, cellular phones or other communication terminals, removable memory modules (sometimes referred to as “Flash drives”), Solid State Disks (SSD), digital cameras, music and other media players and/or any other system or device in which data is stored and retrieved. 
     System  20  comprises a memory device  24 , which stores data in a memory cell array  28 . The memory array comprises multiple analog memory cells  32  that are arranged in word lines  34 . In the context of the present patent application and in the claims, the term “analog memory cell” is used to describe any memory cell that holds a continuous, analog value of a physical parameter, such as an electrical voltage or charge. Array  32  may comprise solid-state analog memory cells of any kind, such as, for example, NAND, NOR and Charge Trap Flash (CTF) Flash cells, phase change RAM (PRAM, also referred to as Phase Change Memory—PCM), Nitride Read Only Memory (NROM), Ferroelectric RAM (FRAM), magnetic RAM (MRAM) and/or Dynamic RAM (DRAM) cells. Although the embodiments described herein refer mainly to analog memory, the disclosed techniques may also be used with various other memory types. 
     The charge levels stored in the cells and/or the analog voltages or currents written into and read out of the cells are referred to herein collectively as analog values, storage values or analog storage values. The analog values written to the memory cells are referred to herein as input analog values, and the analog values read from the memory cells are referred to as analog output values. Although the embodiments described herein mainly address threshold voltages, the methods and systems described herein may be used with any other suitable kind of analog values. 
     System  20  stores data in the analog memory cells by programming the cells to assume respective memory states, which are also referred to as programming states or programming levels. The programming levels are selected from a finite set of possible levels, and each level corresponds to a certain nominal storage value. For example, a 2 bit/cell MLC can be programmed to assume one of four possible programming levels by writing one of four possible nominal storage values into the cell. The techniques described herein mainly address storage densities of a non-integer number of bits per memory cell, i.e., a number of programming levels per cell that is not an integer power of two. 
     Memory device  24  comprises a reading/writing (R/W) unit  36 , which converts data for storage in the memory device to analog storage values and writes them into memory cells  32 . In alternative embodiments, the R/W unit does not perform the conversion, but is provided with voltage samples, i.e., with the storage values for storage in the cells. When reading data out of array  28 , R/W unit  36  converts the storage values of memory cells into digital samples having a resolution of one or more bits. Data is typically written to and read from the memory cells in groups that are referred to as pages. In some embodiments, the R/W unit can erase a group of cells  32  by applying one or more negative erasure pulses to the cells. 
     The storage and retrieval of data in and out of memory device  24  is performed by a memory controller  40 . Memory controller  40  comprises an interface  44  for communicating with memory device  24 , and a processor  48 . The disclosed techniques can be carried out by memory controller  40 , by R/W unit  36 , or both. Thus, in the present context, memory controller  40  and R/W unit  36  are referred to collectively as circuitry that carries out the disclosed techniques. 
     Memory controller  40  communicates with a host  52 , for accepting data for storage in the memory device and for outputting data retrieved from the memory device. Memory controller  40  may be implemented in hardware, e.g., using one or more Application-Specific Integrated Circuits (ASICs) or Field-Programmable Gate Arrays (FPGAs). Alternatively, the memory controller may comprise a microprocessor that runs suitable software, or a combination of hardware and software elements. 
     The configuration of  FIG. 1  is an example system configuration, which is shown purely for the sake of conceptual clarity. Any other suitable memory system configuration can also be used. For example, although the example of  FIG. 1  shows a single memory device, in alternative embodiments memory controller  40  may control multiple memory devices  24 . Elements that are not necessary for understanding the principles of the present invention, such as various interfaces, addressing circuits, timing and sequencing circuits and debugging circuits, have been omitted from the figure for clarity. 
     In the example system configuration shown in  FIG. 1 , memory device  24  and memory controller  40  are implemented as two separate Integrated Circuits (ICs). In alternative embodiments, however, the memory device and the memory controller may be integrated on separate semiconductor dies in a single Multi-Chip Package (MCP) or System on Chip (SoC), and may be interconnected by an internal bus. Further alternatively, some or all of the memory controller circuitry may reside on the same die on which the memory array is disposed. Further alternatively, some or all of the functionality of memory controller  40  can be implemented in software and carried out by a processor or other element of the host system. In some embodiments, host  52  and memory controller  40  may be fabricated on the same die, or on separate dies in the same device package. 
     In some embodiments, memory controller  40  comprises a general-purpose processor, which is programmed in software to carry out the functions described herein. The software may be downloaded to the processor in electronic form, over a network, for example, or it may, alternatively or additionally, be provided and/or stored on non-transitory tangible media, such as magnetic, optical, or electronic memory. 
     In an example configuration of array  28 , memory cells  32  are arranged in multiple rows and columns, and each memory cell comprises a floating-gate transistor. The gates of the transistors in each row are connected by word lines  34 , and the sources of the transistors in each column are connected by bit lines. In the present context, the term “row” is used in the conventional sense to mean a group of memory cells that are fed by a common word line, and the term “column” means a group of memory cells fed by a common bit line. The terms “row” and “column” do not connote a certain physical orientation of the memory cells relative to the memory device. The memory array is typically divided into multiple memory pages, i.e., groups of memory cells that are programmed and read simultaneously. 
     In some embodiments, memory pages are sub-divided into sectors. Pages may be mapped to word lines in various manners. Each word line may store one or more pages. A given page may be stored in all the memory cells of a word line, or in a subset of the memory cells (e.g., the odd-order or even-order memory cells). 
     Erasing of cells is usually carried out in blocks that contain multiple pages. Typical memory devices may comprise thousands of erasure blocks. In a typical two-bit-per-cell MLC device, each erasure block is on the order of 32 word lines, each comprising several tens of thousands of cells. Each word line of such a device is often partitioned into four pages (odd/even order cells, least/most significant bit of the cells). Three-bit-per cell devices having 32 word lines per erasure block would have 192 pages per erasure block, and four-bit-per-cell devices would have 256 pages per block. Alternatively, other block sizes and configurations can also be used. Some memory devices comprise two or more separate memory cell arrays, often referred to as planes. Since each plane has a certain “busy” period between successive write operations, data can be written alternately to the different planes in order to increase programming speed. 
     Read Threshold Setting Based on Soft Readout Statistics 
     In some embodiments, memory controller  40  reads a group of memory cells  32 , e.g., a word line or part of a word line, using multiple read thresholds. The memory controller decodes the stored data based on the read results, i.e., based on where each cell output value falls relative to the read thresholds. The memory controller sets and adjusts the positions of the read thresholds using methods that are described below. 
     The description that follows refers to a specific embodiment involving two programming levels and three read thresholds. The disclosed techniques, however, are in no way limited to this embodiment, and can be generalized in a straightforward manner to any desired number of programming levels and read thresholds. For ease of explanation, the description that follows refers to the disclosed techniques as being carried out by memory controller  40 . In alternative embodiments, however, these techniques can be carried out by R/W unit  36  in the memory device, or jointly by the R/W unit and the memory controller. 
       FIG. 2  is a graph showing threshold voltage distributions and read thresholds in a group of analog memory cells, in accordance with an embodiment of the present invention. In the present example, the memory cells are programmed to two programming levels corresponding to “1” and “0” bit values, respectively. Because of various impairments and inaccuracies, the threshold voltages (V TH ) of the memory cells programmed with “1” are distributed in accordance with a distribution  60 A, and the threshold voltages of the memory cells programmed with “0” are distributed in accordance with a distribution  60 B. Note that, as shown in the figure, the threshold voltage distributions are not necessarily Gaussian or even symmetric, and are not necessarily similar to one another. Moreover, the memory cells are not necessarily divided evenly between the programming levels. 
     The stored data is encoded prior to storage with an Error Correction Code (ECC), such as a Bose-Chaudhuri-Hocquenghem (BCH) code, a Low-Density Parity Check (LDPC) code or any other suitable ECC. In some embodiments, the memory controller decodes the ECC in a hard decoding process, i.e., based on a binary input for each bit. In alternative embodiments, the memory controller decodes the ECC in a soft decoding process, based on soft decoding metrics (e.g., Log Likelihood Ratios—LLRs) that are computed for the bits. 
     Memory controller  40  retrieves the data from the group of memory cells by setting (using R/W unit  36 ) one or more read thresholds, and comparing the threshold voltages of the memory cells to the read thresholds. In the present example, memory controller  40  sets a total of three thresholds—A hard threshold  64  and two soft thresholds  68 A and  68 B on opposite sides of the hard threshold. All three thresholds are positioned in the boundary region between the two programming levels in question. 
     Consider, for example, a hard readout process in which the memory controller reads any memory cell whose threshold voltage is smaller than hard threshold  64  as holding “1”, and any memory cell whose threshold voltage is larger than hard threshold  64  as holding “0”. In this process, the memory cells that belong to distribution  60 A but whose V TH  is larger than threshold  64  will be read erroneously as holding “0”. Similarly, the memory cells that belong to distribution  60 B but whose V TH  is smaller than threshold  64  will be read erroneously as holding “1”. As can be seen in the figure, proper positioning of threshold  64  is important for maintaining low error probability. 
     In some embodiments, memory controller  40  adjusts the position of hard threshold  64  using the following process: The memory controller reads the memory cells using all three read thresholds (hard threshold  64  and soft thresholds  68 A and  68 B). The three thresholds define two finite ranges (intervals)  72 A and  72 B of threshold voltages that fall between the thresholds. For each of the two ranges (intervals  72 A and  72 B), the memory controller assesses the number of read errors occurring in the range. 
     The assessed numbers of errors are illustrated graphically in  FIG. 2 : A shaded region  76 A corresponds to the memory cells that belong to distribution  60 B and whose V TH  falls between thresholds  64  and  68 A. Thus, the area of region  76 A is indicative of the number of read errors occurring in interval  72 A. Similarly, a shaded region  76 B corresponds to the memory cells belonging to distribution  60 A and whose V TH  falls between thresholds  64  and  68 B. The area of region  76 A is thus indicative of the number of read errors occurring in interval  72 B. 
     In some embodiments, memory controller  40  adjusts the position of hard threshold  64  based on the number of read errors falling in intervals  72 A and  72 B. Typically, the memory controller adjusts thresholds  64  so as to equalize these two numbers. In other words, if the number of read errors in interval  72 A is greater than the number or read errors in interval  72 B, the memory controller decreases threshold  64  (i.e., moves it to the left). If the number of read errors in interval  72 A is smaller than the number or read errors in interval  72 B, the memory controller increases threshold  64 . Soft thresholds  68 A and  68 B are typically adjusted together with threshold  64 , so as to maintain the separations between the thresholds. 
     In some embodiments, the numbers of read errors are used for deciding on the direction in which the threshold is to be adjusted, but the amount of adjustment is set regardless of these numbers (e.g., at fixed or predefined increments). In other embodiments, the memory controller sets the size of the adjustment based on the numbers of read errors, e.g., based on the ratio between the numbers. 
     In the disclosed technique, the threshold is adjusted based on the numbers of errors that occur in close proximity to the threshold. This choice is in contrast to basing the adjustment on the total numbers of read errors (the total number of memory cells in distribution  60 A whose V TH  falls above threshold  64 , and the total number of memory cells in distribution  60 B whose V TH  falls below threshold  64 ). As a result, the threshold adjustment process is not sensitive to the actual shapes of distributions  60 A and  60 B. 
     Typically, within each interval (e.g.,  72 A or  72 B) the V TH  distribution is approximately Gaussian, and therefore the direction and size of the read threshold adjustment can be computed with high accuracy and reliability. 
     For example, in some scenarios, a number of memory cells are stuck at certain threshold voltages regardless of programming. These stuck threshold voltages are, with high probability, not in the vicinity of hard threshold  64 . This phenomenon is sometimes referred to as “stuck cells” or “stuck bits.” Such stuck memory cells typically distort the shapes of the V TH  distributions and cause them to deviate from Gaussian. Therefore, the correct adjustment of threshold  64  is by equalizing the total number of read errors while ignoring the “stuck cells.” The disclosed technique overcomes the distorting effect of stuck memory cells, since it considers only the read errors that occur in proximity to the hard read threshold. 
     Generally, considering the numbers of read errors in finite intervals that are close to the read thresholds makes the disclosed technique highly robust and performs well regardless of the actual V TH  distributions. 
     Memory controller  40  may assess the numbers of read errors in the various V TH  ranges (e.g., in intervals  72 A and  72 B) using any suitable method. In some embodiments, the ECC decoding process in the memory controller is able to output the number of corrected read errors (“0” to “1”, and “1” to “0”) for each interval separately. Alternatively, any other suitable method can be used for assessing the numbers of read errors in the various V TH  ranges. 
       FIG. 3  is a flow chart that schematically illustrates a method for adjusting read thresholds, in accordance with an embodiment of the present invention. The method begins with memory controller  40  initializing hard threshold  64  and soft thresholds  68 A and  68 B to some initial positions, at an initialization step  80 . The memory controller then reads a group of memory cells using the three read thresholds, at a readout step  84 . The memory controller decodes the ECC, at an ECC decoding step  88 . ECC decoding may be hard (i.e., based on the read results of threshold  64 ) or soft (i.e., based on the read results of thresholds  64 ,  68 A and  68 B). 
     Memory controller  40  then assesses the number of read errors for each of intervals  72 A and  72 B between the read thresholds, at an error assessment step  92 . For example, the memory controller may compare the data before and after ECC correction, or accept from the ECC decoding process a respective count of the corrected errors for each interval. In the example of  FIG. 2 , the memory controller assesses the number of “0”→“1” errors in interval  72 A, and the number of “1”→“0” errors in interval  72 B. The memory controller adjusts one or more of the read thresholds based on the numbers of read errors assessed for the different intervals, at a threshold adjustment step  96 . 
     In some of the disclosed embodiments, the memory controller assesses the number of errors based on outputs from the ECC decoding process following successful ECC decoding. In practice, however, ECC decoding may sometimes fail. In such cases, the memory controller may attempt ECC decoding on another group of memory cells (either in the same word line or in a different word line), estimate the read threshold positions on that group, and use the resulting read threshold for reading the memory cells for which ECC decoding has failed. The disclosed techniques can be used for adapting the read thresholds and performing data readout using the adapted read thresholds on the same group of memory cells, or for adapting the read thresholds on one group of memory cells and performing data readout using the adapted read thresholds on a different group of memory cells. 
     The embodiment of  FIGS. 2 and 3  above refers to a readout scheme that differentiates between two programming levels using three read thresholds that define a total of four output value intervals: two finite intervals  72 A and  72 B, an infinite interval below threshold  68 A and an infinite interval above threshold  68 B. The disclosed technique adapts the read thresholds based on the number of errors occurring in the two finite intervals  72 A and  72 B. In alternative embodiments, the disclosed technique can be used with any desired number of read thresholds and intervals, such as a scheme that uses five read thresholds defining a total of six intervals. 
     The memory controller may set the separations of the soft thresholds from the hard threshold (i.e., the sizes of intervals  72 A and  72 B) based on any suitable criterion. In some embodiments, the separations are fixed and predetermined. In some embodiments, the memory controller sets the separations based on the V TH  distributions, e.g., based on the Cumulative Distribution Function (CDF) of the V TH  distributions. 
     In an example embodiment, the memory controller sets the separation of a given soft threshold such that a predefined percentage of the memory cells will have V TH  that falls between this soft threshold and the hard threshold. The memory controller may adapt the size of intervals  72 A and  72 B in accordance with such a criterion. When using this criterion, the separation between the hard threshold and a soft threshold typically changes according to the quality of the memory media (e.g., from start-of-life to end-of-life). 
     In some embodiments, the memory controller sets the read thresholds such that the absolute number of memory cells in intervals  72 A and  72 B will match a pre-defined target number. These techniques are particularly useful when ECC decoding fails and the actual numbers of errors are unknown. In some of these embodiments, the memory controller may set the read thresholds without prior knowledge of the V TH  distribution CDF, by explicitly setting the number of memory cells in the intervals. 
     Alternatively, if the CDF or its approximation is known in advance, the CDF can be used to decide how many cells should be included in intervals  72 A and  72 B such that most of the read errors will occur in the intervals. In these embodiments, the memory controller sets the numbers of memory cells in intervals  72 A and  72 B according to the CDF, and the read thresholds are set to meet these numbers during data readout. This setting can be performed without a need to know where the errors occur, e.g., without a need for successful ECC decoding. 
     In some embodiments, the memory controller may hold a set of multiple CDFs, for example CDFs typical of start-of-life and end-of-life conditions, CDFs typical of cycling at various levels, CDFs typical of combined cycling and retention, or any other suitable CDFs. The memory controller may choose the appropriate CDF from the set using side information (e.g. the number of programming and erasure cycles applied to the memory cells). Alternatively, the memory controller may estimate which CDF to use based on the data (e.g. according to the width or standard deviation of the V TH  distribution), or apply a worst-case CDF in all cases. 
     Using Soft Readout Statistics to Set the Spacing Between Soft Read Thresholds 
     In some embodiments, memory controller  40  decodes the ECC in a soft decoding process. Typically, each read bit is assigned a respective soft metric, and the memory controller decodes the ECC based on the soft metrics. Each soft metric indicates the confidence of the respective bit being “1” or “0”. The embodiments described herein refer mainly to LLRs, but the disclosed techniques can be used with any other suitable kind of soft metrics. 
     In an example embodiment, the memory controller assigns the soft metric to a given read bit depending on the interval in which the corresponding output value (V TH ) falls. In the embodiment of  FIG. 2 , for example, the memory controller typically assigns high soft metrics to the memory cells as follows: 
     
       
         
           
               
               
               
             
               
                   
                   
               
               
                   
                 Cell VTH location 
                 Assigned LLR 
               
               
                   
                   
               
             
            
               
                   
                 In interval 72A 
                 “1” with small confidence 
               
               
                   
                 In interval 72B 
                 “0” with small confidence 
               
               
                   
                 Below read threshold 68A 
                 “1” with high confidence 
               
               
                   
                 (below interval 72A) 
                   
               
               
                   
                 Above read threshold 68B 
                 “0” with high confidence 
               
               
                   
                 (above interval 72B) 
               
               
                   
                   
               
            
           
         
       
     
     In this scheme, memory cells whose V TH  is far from the read thresholds are assigned high confidence, since they are unlikely to cause read errors. Memory cells whose V TH  is close to the read thresholds are assigned low confidence, since they are more likely to cause read errors. 
     In some embodiments, memory controller  40  adjusts the separation between the read thresholds (e.g., the distance between the hard threshold and each of the soft thresholds) based on the number of read errors assessed for each interval. In the embodiment of  FIG. 2 , for example, it is typically desirable that most of the read errors will occur within intervals  72 A and  72 B, and only few errors would occur outside these intervals. This sort of setting would yield high-performance soft decoding. 
     In an example embodiment, memory controller  40  adjusts the separation between hard threshold  64  and soft threshold  68 A so that most of the read errors will occur within interval  72 A. The memory controller may check this condition, for example, by comparing the number of errors within interval  72 A to the total number of read errors occurring below threshold  64 . A similar process may be carried out for threshold  68 B and interval  72 B, or jointly for both thresholds  68 A and  68 B. As another example, the memory controller may use additional soft read thresholds and additional ranges (not shown in FIG.  2 ) in order to assess the number of errors falling outside intervals  72 A and  72 B. 
     The memory controller may use any suitable criterion for adjusting the separation between a given soft threshold and the hard threshold, based on the number of read errors occurring in the V TH  interval between these thresholds (e.g., adapt the size of interval  72 A based on the number of errors occurring in this interval). In an example embodiment, the memory controller adapts the separation such that the number of errors in the interval reaches a desired value. As another example, the memory controller may adapt the separation such that a ratio between the number of errors and the number of memory cells in the interval reaches a desired value. This condition is substantially equivalent to setting a constant LLR for the memory cells in the interval. 
     In some embodiments, the memory controller holds a mapping, e.g., Look-Up Table (LUT), of definitions of optimal read threshold positions that are calculated using the disclosed techniques. In one example embodiment, the table is addressed by the distance between the programming level V TH  distributions and by the variance of the V TH  distribution. In other embodiments, the LUT can be accessed by the distance between the programming level V TH  distributions, the variance of the V TH  distribution, the width of the V TH  distribution (i.e., the size of the interval containing X % of the analog values belonging to the distribution, e.g., 99.9%), any suitable combination of these parameters and/or any other suitable parameter of the analog values. 
     The memory controller estimates the distance between levels and the distribution variance, and accesses the LUT with these values to obtain the optimal read threshold setting. The LUT is typically prepared in advance based on an assumed V TH  distribution model, which depends on a relatively small number of V TH  parameters (such as the V TH  distribution variance and distance between programming levels). During readout, the V TH  parameters are estimated from the read data and used for accessing the LUT to estimate the thresholds. In an alternative embodiment, the LUT holds only the separations between the read thresholds, and the hard threshold is estimated using other methods. 
     In an example embodiment, the memory controller may use the variance of the V TH  distribution as input to the LUT, in order to obtain the separation between the hard threshold and the soft thresholds (without having to count the number of read errors or the absolute number of memory cells per interval). In another embodiment, the memory controller may start with an initial threshold separation, count the number of errors or absolute number of cells per interval, and use the LUT to obtain the optimal threshold separation. Further alternatively, the memory controller may adapt the read threshold positions based on the definitions in the LUT, and in particular the separation between read thresholds, in any other suitable manner. 
     Generally, the above-described technique is not limited to LUTs. The memory controller may hold any suitable kind of mapping that defines multiple sets of read threshold values depending on one or more parameters related to the analog output values (e.g., V TH ) read from the memory cells. Alternatively to LUT, the mapping may comprise, for example, an analytical function. The mapping may define the read thresholds in various ways. For example, the mapping may give the absolute positions of the read thresholds, or the separations between them. In the latter case, the absolute position of at least one of the read thresholds may be calculated using other suitable methods. 
     In alternative embodiments, the threshold setting problem can be modeled in terms of maximizing communication channel capacity. In these embodiments, the memory is modeled as a communication channel: The input to the channel corresponds to the bits programmed into a memory cell, and the channel output corresponds to the analog output values (e.g., V TH ) of the memory cell, quantized according to the read thresholds. For example, for three read thresholds, the channel output comprises one of four possible intervals in which the memory cell V TH  may fall. For such a channel, given the V TH  distribution shape, the channel capacity can be calculated. (The capacity in this case is typically defined as the maximum number of bits that can be stored in a memory cell such that there exists a readout algorithm that enables to read the data with error probability as low as desired.) Capacity is typically calculated as a function of the positions (or separation) of the read thresholds, and the position that maximizes capacity is chosen. 
     In the example of  FIG. 2 , the channel in question has two inputs (read bit value being “1” or “0”) and four outputs (cell output value falling below threshold  68 A, between thresholds  68 A and  64 , between thresholds  64  and  68 B, or above threshold  68 B). For a given V TH  distribution, the channel capacity can be computed as a function of the soft threshold positions. In some embodiments, the memory controller adapts the read threshold positions so as to maximize the channel capacity. 
     In an example embodiment, the memory controller may set the separation such that the resulting capacity will be maximized, without having to count the number of errors or the absolute number of cells per interval. In another embodiment, the memory controller may try several read threshold separations (or read threshold positions), count the number of errors (or absolute number of cells) per interval, and deduce the read threshold positions that maximize channel capacity based on this information. Further alternatively, the memory controller may adapt the read threshold positions based on maximizing channel capacity in any other suitable manner. 
     In some embodiments, memory controller  40  may carry out a readout process that combines soft decoding and cancellation of interference from neighboring memory cells. Processes of this sort are described, for example, in U.S. Patent Application Publication 2009/0024905, whose disclosure is incorporated herein by reference. For example, the memory controller may read neighboring cells, estimate their impact on a certain target cell, and compensate for this impact when recovering the data from the target cell. 
     Any of the techniques described herein, e.g., the techniques that set the read thresholds based on the number of read errors or the number of memory cells per interval, may take into account the interference coefficients when determining the read threshold positions. The interference coefficient may be estimated from the read data, or they may be known in advance. 
     When the memory controller carries out interference cancellation, the number of read errors per interval (which are used for estimating the read thresholds) can be defined as the total number of errors, e.g., as counted by comparing the correct data with the original data, as read with the hard threshold. Alternatively, the number of read errors per interval can be defined as the number of read errors after the interference is taken into account. In other words, if the interference cancellation process changes the hard bit value of a given memory cell, then the changed bit value can be used as reference and not the original bit read with the hard threshold. 
     Using Soft Readout Statistics to Improve Initial LLR&#39;S 
     When the memory controller uses a soft ECC decoding process, each bit is assigned an initial LLR (or other soft metric) that indicates the confidence of this bit being “0” or “1”. In some embodiments, the memory controller assigns for each soft interval a predefined initial LLR value. However, the initial LLRs that maximize the probability of successful decoding may vary according to the V TH  distribution. Thus, the memory controller can adjust the initial LLRs based on the numbers of read errors assessed for the various V TH  intervals to improve the initial LLRs to be used in subsequent read operations. For example, after successful ECC decoding, the memory controller may compute an “empirical LLR” for each V TH  interval. 
     The empirical LLR of a given V TH  interval indicates, based on past results, the empirical probability of a cell whose V TH  falls in this interval being “1” or “0”. In an embodiment, memory controller  40  computes the empirical LLR of a given V TH  interval based on the number of correct bits and the number of errors occurring in that interval. These numbers are typically obtained from the ECC decoding process. The empirical LLRs can be used as initial LLRs in subsequent readout operations, so as to improve decoding performance. 
     It will be appreciated that the embodiments described above are cited by way of example, and that the present invention is not limited to what has been particularly shown and described hereinabove. Rather, the scope of the present invention includes both combinations and sub-combinations of the various features described hereinabove, as well as variations and modifications thereof which would occur to persons skilled in the art upon reading the foregoing description and which are not disclosed in the prior art. Documents incorporated by reference in the present patent application are to be considered an integral part of the application except that to the extent any terms are defined in these incorporated documents in a manner that conflicts with the definitions made explicitly or implicitly in the present specification, only the definitions in the present specification should be considered.

Metadata:
Filing Date: 20110802
Publication Date: 20140408
Grant Date: 20140408
Priority Date: 20100817
Inventors: DAR RONEN
GURGI EYAL
ANHOLT MICHA
SOMMER NAFTALI
Assignee: APPLE INC
CPC Classifications: [{"code": "G11C29/52", "inventive": true, "first": true, "tree": "[]"}, {"code": "G11C29/52", "inventive": true, "first": true, "tree": "[]"}, {"code": "G11C11/5642", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C11/5685", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C29/021", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C29/028", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C11/5642", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C29/021", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C11/5685", "inventive": true, "first": false, "tree": "[]"}, {"code": "G11C29/028", "inventive": true, "first": false, "tree": "[]"}]
Family ID: 50391971