Memory system with error correction and data scrubbing circuits

By introducing a data scrubbing circuit and an ECC encoding and decoding circuit into the memory system, combined with environmental interference and time detection, efficient error correction and data scrubbing under high voltage and high temperature are achieved, solving the complexity and complexity of error correction in the existing technology. The problem of power consumption improves the performance and durability of memory.

CN112930519BActive Publication Date: 2024-09-24SUPERMEM INC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201980067024.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2019-08-15
Filing Date
2019-10-11
Publication Date
2024-09-24
Estimated Expiration
2039-10-11

AI Technical Summary

Technical Problem

Existing non-volatile memory technology is difficult to achieve effective error correction under high voltage, high temperature and environmental interference, resulting in reduced data retention and read and write operation efficiency, and increased power consumption. Traditional error correction code encoding is complex and affects performance.

Method used

Design a memory system with error correction function, including a data memory, an ECC memory and a data scrubbing circuit, by configuring the data scrubbing circuit to respond to the received scrubbing data command, using the ECC encoding and decoding circuit to correct errors in the data memory, and Generate flush data commands based on environmental interference and time detection to optimize the error correction capability and power consumption of the memory.

Benefits of technology

It achieves efficient error correction and data scrubbing under high voltage, high temperature and environmental interference, reduces power consumption, avoids unnecessary data scrubbing and protection operations, and improves memory performance and durability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112930519B_ABST
    Figure CN112930519B_ABST
Patent Text Reader

Abstract

The present invention is an error correction memory system and a method of operating the memory system. In some embodiments, the memory system includes: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory. The data scrubbing circuit can be configured to respond to receiving a scrubbing data command to correct errors in the data memory. The codeword length used for error correction can be longer than the word length used during normal access to the data memory. In some embodiments, the memory system includes a first memory circuit associated with a first bit error rate, and a second memory circuit associated with a second bit error rate. In some embodiments, the memory system includes an error-correctable multi-level cell (MLC) array.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention generally relates to computational memories, and more particularly, to apparatus and methods for error correction of computational memories. Background Art

[0002] Magnetic random access memory (MRAM), phase change memory (PCM), resistive random access memory (RRAM) and ferroelectric random access memory (FRAM) are some non-volatile memory technologies that have faster data writing speeds and higher rewrite endurance than FLASH. For example, high-performance MRAM can be used in edge artificial intelligence computing (Edge-AI) applications, which require complex data structures after model optimization.

[0003] To achieve high performance, non-volatile memories like MRAM present many unique circuit challenges. In particular, read performance is limited by read disturb errors at higher voltage read operations, and write performance is limited by hard break down at higher voltage operations. Another obstacle may be the need for higher-order error correction to achieve long-term data retention at higher temperatures or during higher temperature events. In these cases, two-bit correction circuits can be used, but the circuits add additional delays to read and write operations.

[0004] In addition, some of these non-volatile RAM technologies and traditional volatile memory technologies may be sensitive to environmental disturbances. For example, data in DRAM is sensitive to high temperature external ionizing radiation, and data in MRAM may be erroneous due to high temperature or large magnetic fields.

[0005] Power can be a major limiting factor in electronic device design, and as memory density continues to increase, the portion of total power consumed by memory devices continues to increase. Reducing memory operating power consumption increases error rates for both data retention and read and write operations.

[0006] To achieve adequate error correction strength, redundant circuits that consume a large area may be required. For example, using a low-latency Hamming code, five error correction code (ECC) bits may be required to protect an 8-bit word from a single bit error. As another example, using Bose, Chaudhuri, and Hocquenghem (BCH) codes or low-density parity-check (LDPC) codes, fewer ECC check bits can be used to protect larger data blocks (e.g., 1024 bits or more). However, these ECC codes require more complex encoding and decoding operations and may affect performance.

[0007] To reduce costs and to implement PIM, multi-level cell (MLC) devices (e.g., floating gate or charge trapping FLASH devices, eDRAM capacitors, RRAM, PCM, analog memory) can be used to perform PIM operations by representing the matrix multiplicand in multiple states or continuous analog properties. However, most of these devices will drift during operation, gradually changing the value of the matrix multiplicand. If the device drifts beyond a critical value, a simple "read and restore" operation cannot be used to maintain the correct value. Summary of the invention

[0008] The present invention relates to a memory system with error correction function and a method for operating such memory system. In some embodiments, the memory system includes: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory. The data scrubbing circuit can be configured to respond to receiving a scrubbing data command to correct errors in the data memory. The codeword length used for error correction can be longer than the word length used during normal access to the data memory. In some embodiments, the memory system includes a first memory circuit associated with a first bit error rate, and a second memory circuit associated with a second bit error rate. In some embodiments, the memory system includes an error-correctable multi-layer memory cell (MLC) array.

[0009] In some embodiments, a memory system includes: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory.

[0010] In some embodiments, the data flushing circuit is configured to correct errors in the data storage in response to receiving a flush data command.

[0011] In some embodiments, the codeword length used for error correction is longer than the word length used during normal access to the data memory.

[0012] In some embodiments, the data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

[0013] In some embodiments, the data scrubbing circuit is configured to correct errors in the data memory while accessing the data memory.

[0014] In some embodiments, the memory system further includes an environmental disturbance sensor configured to detect an environmental condition, and wherein the data flushing circuit generates the flush data command based on the detected environmental condition.

[0015] In some embodiments, the environmental condition includes at least one of temperature and a magnetic field.

[0016] In some embodiments, the data scrubbing circuit is configured to detect changes in known data and to generate a flush data command based on the detection of the changes.

[0017] In some embodiments, the memory system further includes a timer circuit configured to: track elapsed time; and determine whether the elapsed time is greater than a timing threshold, and generate a flush data command based on the determination that the elapsed time is greater than the timing threshold.

[0018] In some embodiments, the ECC memory includes a plurality of partitions, and the data memory includes a plurality of memory address ranges, each partition corresponding to a memory address range in the data memory.

[0019] In some embodiments, the ECC memory includes a partition having a plurality of ECC bits, and the number of ECC bits is based on an ECC encoding method associated with a data scrubbing algorithm.

[0020] In some embodiments, the ECC memory includes a set of registers, wherein: each register corresponds to an ECC code word, each ECC code word corresponds to a segment in the data memory, and each register stores the state of the segment.

[0021] In some embodiments, at least one selected from the data memory and the ECC memory includes a magnetic random access memory (MRAM).

[0022] In some embodiments, at least one selected from a data memory and an ECC memory includes a memory cell including a magnetic tunnel junction (MTJ) and a memory cell having a bit error rate of less than 10 -12 Up to 10 -2 Compared with the memory cells in the prior art, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0023] In some embodiments, with a bit error rate of 10 -12 Up to 10 -2 Compared with memory cells between the two, the MJT has two selected from the following characteristics: reduced size, weakened coercive magnetic field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0024] In some embodiments, the data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

[0025] In some embodiments, the data scrubbing circuit or the host is configured to determine whether the data memory is protected, and the ECC memory is configured to: store ECC check bits based on the determination that the data memory is protected; and store operation data based on the determination that the data memory is not protected.

[0026] In some embodiments, the data memory and the ECC memory are included in different memory circuits.

[0027] In some embodiments, the data memory and the ECC memory are included in the same memory circuit.

[0028] In some embodiments, the memory system is electrically coupled to a host device.

[0029] In some embodiments, the data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers, and a MOS transistor having a width-to-length ratio between 1 and 200.

[0030] In some embodiments, the data scrubbing circuit is configured to: receive a data protection command; for each data word in the data to be protected, respond to receiving the protection command: identify the address of a data codeword associated with the data word; determine whether the data word is in a data storage device based on the address; respond to determining that the data word is in the data storage device by reading the data word from the data storage device; respond to determining that the data word is not in the data storage device by: receiving the data word; and writing the data word to the data storage device; performing an ECC encoding operation on the data word; generating a data codeword based on the ECC encoding operation; writing the data codeword to the data storage device at the address; generating an ECC check bit based on the ECC encoding operation; and writing the generated ECC check bit to a corresponding partition in the ECC storage device.

[0031] In some embodiments, the data scrubbing circuit is configured to: receive a scrub data command; and for each data word to be scrubbed, respond to receiving the scrub data command: identify: a starting address of a data codeword and a corresponding ECC storage partition; read a data word associated with the starting address from a data storage device; read an ECC check bit associated with the corresponding ECC storage partition from an ECC storage device; perform an ECC decoding operation based on the data word and the ECC check bit; determine whether the data word includes an error based on the ECC decoding operation; respond to a determination that the data word includes an error, replace the error bit with a correctable bit in the data word, wherein the data word including the correctable bit is a scrubbed data word; respond to a determination that the data word does not include an error, abandon replacing the error bit with the correctable bit in the data word, wherein the data word is a scrubbed data word; determine whether the host requests a scrubbed data word; respond to a determination that the host requests scrubbed data, output the scrubbed data word to a memory controller, which is electrically coupled to the host; respond to a determination that the host does not request scrubbed data, abandon outputting the scrubbed data word to the memory controller.

[0032] In some embodiments, a method of operating a memory system is disclosed, the memory system comprising: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory, the method comprising: responding to receiving a scrub data command, using the data scrubbing circuit to correct errors in the data memory.

[0033] In some embodiments, the codeword length used for error correction is longer than the word length used during normal access to the data memory.

[0034] In some embodiments, the data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

[0035] In some embodiments, the method further includes accessing the data storage while correcting errors in the data storage.

[0036] In some embodiments, the method further includes using an environmental disturbance sensor to detect an environmental condition; and generating a flush data command based on the detected environmental condition.

[0037] In some embodiments, the environmental condition includes at least one of temperature and a magnetic field.

[0038] In some embodiments, the method further includes detecting a change in the known data; and generating a flush data command based on the detection of the change.

[0039] In some embodiments, the method further includes tracking the elapsed time; determining whether the elapsed time is greater than a timing threshold, and generating a flush data command based on the determination that the elapsed time is greater than the timing threshold.

[0040] In some embodiments, the ECC memory includes a plurality of partitions, and the data memory includes a plurality of memory address ranges, each partition corresponding to a memory address range in the data memory.

[0041] In some embodiments, the ECC memory includes a partition having a plurality of ECC bits associated with a data scrubbing algorithm, and the method further includes using the ECC bits to perform an ECC encoding method.

[0042] In some embodiments, the ECC memory includes a set of registers, wherein: each register corresponds to an ECC code word, each ECC code word corresponds to a segment in the data memory, and each register stores the state of the segment.

[0043] In some embodiments, at least one selected from the data memory and the ECC memory includes a magnetic random access memory (MRAM).

[0044] In some embodiments, at least one selected from a data memory and an ECC memory includes a memory cell including a magnetic tunnel junction (MTJ) and a memory cell having a bit error rate of less than 10 -12 Up to 10 -2 Compared with the memory cells therebetween, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0045] In some embodiments, with a bit error rate of 10 -12 Up to 10 -2 Compared with the memory cells between the two, the MTJ has two selected from the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0046] In some embodiments, the data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

[0047] In some embodiments, the method further includes determining whether the data memory is protected by error correction; and storing ECC check bits in the ECC memory according to the setting that the data memory is protected by error correction; and storing operation data in the ECC memory according to the setting that the data memory is not protected by error correction.

[0048] In some embodiments, the data memory and the ECC memory are included in different memory circuits.

[0049] In some embodiments, the data memory and the ECC memory are included in the same memory circuit.

[0050] In some embodiments, the memory system is electrically coupled to a host device.

[0051] In some embodiments, the data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers, and a MOS transistor having a width-to-length ratio between 1 and 200.

[0052] In some embodiments, the method further includes receiving a data protection command; for each data word in the data to be protected, responding to the received protection command: identifying the address of a data codeword associated with the data word; determining whether the data word is in a data storage device based on the address; responding to the determination that the data word is in the data storage device, reading the data word from the data storage device; responding to the determination that the data word is not in the data storage device: writing the data word to the data storage device; performing an ECC encoding operation on the data word; generating a data codeword based on the ECC encoding operation; writing the data codeword to the data storage device at the address; generating an ECC check bit based on the ECC encoding operation; and writing the generated ECC check bit to the corresponding partition in the ECC storage device.

[0053] In some embodiments, the method further includes: for each data word to be scrubbed, responding to receiving a scrub data command: identifying: a starting address of a data codeword and a corresponding ECC memory partition; and reading a data word associated with the starting address from a data memory; reading an ECC check bit associated with a corresponding ECC memory partition from an ECC memory; performing an ECC decoding operation based on the data word and the ECC check bit; determining whether the data word includes an error based on the ECC decoding operation; responding to a determination that the data word includes an error, replacing the error bit with a correctable bit in the data word, wherein the data word including the correctable bit is a scrubbed data word; responding to a determination that the data word does not include an error, abandoning replacing the error bit with a correctable bit in the data word, wherein the data word is a scrubbed data word; determining whether the host requests a scrubbed data word; responding to a determination that the host requests scrubbed data, outputting the scrubbed data word to a memory controller electrically coupled to the host; and responding to a determination that the host does not request scrubbed data, abandoning outputting the scrubbed data word to the memory controller.

[0054] In some embodiments, the memory system is included in one selected from the following items: artificial intelligence edge computing (edge-AI) system, neural network-like system in a data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0055] In some embodiments, a memory system includes: a first memory circuit associated with a first bit error rate; a second memory circuit associated with a second bit error rate, wherein the first bit error rate is greater than the second bit error rate; and a data word stored in the first and second memory circuits, wherein: the data word includes a first partition associated with the first bit error rate, and a second partition associated with the second bit error rate, the first partition of the data word is stored in the first memory circuit, and the second partition of the data word is stored in the second memory circuit.

[0056] In some embodiments, the memory system further includes a data scrubbing circuit electrically coupled to the first memory circuit and the second memory circuit, wherein: the data scrubbing circuit controls the first memory circuit to reduce the first error rate to a third error rate, the data scrubbing circuit controls the second memory circuit to reduce the second error rate to a fourth error rate, and the reduction in the first bit error rate is greater than the reduction in the second bit error rate.

[0057] In some embodiments, a first memory circuit includes a first memory cell including a first magnetic tunnel junction (MTJ) having a first size and a first MOS transistor having a first channel width-to-length (W / L) ratio, and a second memory circuit includes a second memory cell including a second MTJ having a second size and a second MOS transistor having a second W / L ratio, the first size being greater than the second size, and the first W / L ratio being greater than the second W / L ratio.

[0058] In some embodiments, the first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

[0059] In some embodiments, the second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

[0060] In some embodiments, a first memory circuit uses a first read voltage, a first sensing time, and a first word line (WL) voltage, and a second memory circuit uses a second read voltage, a second sensing time, and a second WL voltage, the first read voltage is greater than the second read voltage, the first sensing time is greater than the second sensing time, and the first WL voltage is greater than the second WL voltage.

[0061] In some embodiments, the first memory circuit uses a first write voltage, a first write time, and a first WL voltage. The second memory circuit uses a second write voltage, a second write time, and a second WL voltage, the first write voltage is greater than the second write voltage, the first write time is greater than the second write time, and the first WL voltage is greater than the second WL voltage.

[0062] In some embodiments, in a floating point format, the first partition includes a higher order portion of the sign bit, the exponent bits, and the mantissa bits.

[0063] In some embodiments, in the integer format, the first partition includes a sign bit and higher order bits.

[0064] In some embodiments, in the floating point format, the second partition includes a lower order portion of the mantissa bits.

[0065] In some embodiments, in the integer format, the second partition includes lower order bits.

[0066] In some embodiments, a method of operating a memory system is disclosed, the memory system including a first memory circuit and a second memory circuit, the method including: determining a first partition of a data word to be stored in the memory system based on a first bit error rate; determining a second partition of a data word to be stored in the memory system based on a second bit error rate, the first bit error rate being greater than the second bit error rate; storing the first partition of the data word in the first memory circuit; storing the second partition of the data word in the second memory circuit, wherein: the first memory circuit is associated with the first bit error rate, and the second memory circuit is associated with the second bit error rate.

[0067] In some embodiments, the method further includes controlling the first memory circuit to reduce the first error rate to a third error rate; and controlling the second memory circuit to reduce the second error rate to a fourth error rate, wherein the reduction in the first bit error rate is greater than the reduction in the second bit error rate.

[0068] In some embodiments, the first memory circuit includes a first memory cell including a first MTJ having a first size and a first MOS transistor having a first channel W / L ratio, the second memory circuit includes a second memory cell including a second MTJ having a second size and a second MOS transistor having a second W / L ratio, the first size is larger than the second size, and the first W / L ratio is larger than the second W / L ratio.

[0069] In some embodiments, the first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

[0070] In some embodiments, the second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

[0071] In some embodiments, the method further includes using a first read voltage, a first sensing time, and a first WL voltage in a first memory circuit; and using a second read voltage, a second sensing time, and a second WL voltage in a second memory circuit, wherein: the first read voltage is greater than the second read voltage, the first sensing time is greater than the second sensing time, and the first WL voltage is greater than the second WL voltage.

[0072] In some embodiments, the method further includes using a first write voltage, a first write time, and a first WL voltage in a first memory circuit; and using a second write voltage, a second write time, and a second WL voltage in a second memory circuit, wherein: the first write voltage is greater than the second write voltage, the first write time is greater than the second write time, and the first WL voltage is greater than the second WL voltage.

[0073] In some embodiments, in a floating point format, the first partition includes a higher order portion of the sign bit, the exponent bits, and the mantissa bits.

[0074] In some embodiments, in the integer format, the first partition includes a sign bit and higher order bits.

[0075] In some embodiments, in the floating point format, the second partition includes a lower order portion of the mantissa bits.

[0076] In some embodiments, in the integer format, the second partition includes lower order bits.

[0077] In some embodiments, the memory system is included in one selected from the following items: artificial intelligence edge computing (edge-AI) system, neural network-like system in a data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0078] In some embodiments, a memory system includes: a data input; a multi-level memory cell (MLC) array; a write circuit electrically coupled to the MLC array and the data input; a Gray code to binary decoder circuit electrically coupled to the write circuit; a read circuit electrically coupled to the MLC array; a binary to Gray code encoder circuit electrically coupled to the read circuit and the data input; a memory circuit configured to store ECC check bits; an ECC encoder electrically coupled to the memory circuit and the binary to Gray code encoder circuit; an ECC decoder electrically coupled to the memory circuit and the Gray code to binary encoder circuit and configured to output recovered data; and a data scrubbing controller configured to control data recovery in the memory system.

[0079] In some embodiments, an MLC array includes memory cell circuits having more than two stable physical states.

[0080] In some embodiments, the memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive RAM (RRAM) cell.

[0081] In some embodiments, the ECC encoder and decoder use one selected from the group consisting of: Hamming code, BCH code, Reed-Solomon code, and LDPC code.

[0082] In some embodiments, the memory circuit and the MLC array are located on different integrated circuits.

[0083] In some embodiments, the memory circuit is located in a predetermined partition of the MLC array.

[0084] In some embodiments, the data scrubbing controller is configured to initiate data scrubbing operations at predetermined intervals in response to detection of an environmental disturbance or in response to receiving a command from a host.

[0085] In some embodiments, a method for data scrubbing of an MLC includes: reading data from the MLC, the data being represented by a binary code or an analog value; converting the data to a Gray code; reading corresponding check bit data from a memory circuit configured to store ECC check bits; calculating the location of a correctable error in the data in the Gray code form and correcting it; converting the corrected data to a binary code or a corrected analog value; and overwriting the corrected data onto the data in the MLC by a write circuit.

[0086] In some embodiments, an MLC array includes memory cell circuits having more than two stable physical states.

[0087] In some embodiments, the memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive RAM (RRAM) cell.

[0088] In some embodiments, the method further comprises performing ECC encoding and decoding using one selected from the group consisting of: Hamming code, BCH code, Reed-Solomon code, and LDPC code.

[0089] In some embodiments, the memory circuit and the MLC array are located on different integrated circuits.

[0090] In some embodiments, the memory circuits are located in predetermined partitions of the MLC array.

[0091] In some embodiments, the method further includes initiating a data scrubbing operation at predetermined intervals in response to detection of an environmental disturbance or in response to receiving a command from a host.

[0092] In some embodiments, the memory system is included in one selected from the following items: artificial intelligence edge computing (edge-AI) system, neural network-like system in a data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0093] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments, but is not intended to limit the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0094] Figure 1 A system including a memory system is depicted according to an embodiment.

[0095] Figure 2 A data memory and an ECC memory are depicted according to an embodiment.

[0096] Figure 3 A method of operating a memory system is described according to an embodiment.

[0097] Figure 4 A method of operating a memory system is described according to an embodiment.

[0098] Figure 5 A memory system is depicted according to an embodiment.

[0099] Figure 6 Data word partitioning is depicted according to an embodiment.

[0100] Figure 7 A method of operating a memory system is described according to an embodiment.

[0101] Figure 8 A memory system is depicted according to an embodiment.

[0102] Fig. 9 Data recovery is described according to an embodiment.

[0103] Fig.10 A method of operating a memory system is described according to an embodiment.

[0104] Fig.11 A system including a memory system is depicted according to an embodiment.

[0105] Fig.12 An example computing device including a memory system is depicted according to an embodiment. DETAILED DESCRIPTION

[0106] In the following description of the embodiments, reference is made to the accompanying drawings which form a part of the description and show by way of example specific embodiments that may be practiced. Other embodiments may of course be used and structural changes made without departing from the scope of the disclosed embodiments.

[0107] Figure 1 A memory system is depicted including memory system 100. In some embodiments, memory system 100 is electrically coupled to host 160 and memory controller 170. In some examples, memory system 100 may include more than 1 GB of storage space on a single die.

[0108] In some examples, the host 160 or the memory controller 170 may generate a flush data command to start data flushing of the data storage in the memory system 100, or generate a protection command to start protection of the data storage in the memory system 100. In some examples, the condition for generating the start flush data command may be programmed by the host 160 or the memory controller 170. In some examples, the condition for generating the start protection command may be programmed by the host 160 or the memory controller 170.

[0109] As an exemplary advantage, the memory system 100 can achieve highly efficient error correction and data scrubbing. For example, as described below, an exemplary embodiment of the memory system 100 can respond to specific conditions (such as a changing environment) to reduce power consumption by two to four times compared to a memory system that does not use the disclosed scrub data command, without reducing actual performance or increasing area. A memory system that does not use the disclosed scrub data command or the disclosed protection command will perform data scrubbing or protection when scrubbing or protection may not be needed (such as the bit error rate is sufficient to meet system requirements). Such a memory system may cause inefficiencies in operation (such as higher power consumption and slower speed) due to indiscriminate protection or scrubbing of data (such as only during system startup or shutdown). In some examples, due to the improved efficiency, the design requirements of MRAM using spin transfer torque (STT) for write operations may be relaxed. As another example, a simpler MTJ manufacturing process (such as to reduce device manufacturing costs) can be used to reduce data retention errors. As yet another example, using the memory system 100, MRAM devices can shrink linear dimensions by as much as 70% due to relaxed requirements.

[0110] As used herein, a "flush data command" is a command configured to initiate a data scrubbing operation of a data storage device, and a flush data command is generated and transmitted to a data scrubbing circuit based on a determination that specific conditions are met. Such specific conditions may include conditions identified during normal operation, such as environmental conditions, passage of time, and changes in known data (as described herein). Normal operation includes (but is not limited to) read and write operations, column enable and precharge operations, update operations, sector write and erase operations, defect repair operations, and wear-leveling operations. When these specific conditions are not met, a flush data command is not generated to avoid unnecessary data scrubbing. For example, in a conventional memory system, data may be automatically scrubbed during system startup or shutdown. In the disclosed memory system, data may be scrubbed only in response to receiving a flush data command; startup or shutdown is not sufficient to cause the generation of a flush data command.

[0111] As used herein, a "protection command" is a command configured to enable data protection of a data storage device. A protection command is generated based on a determination that certain conditions are met and transmitted to a data scrubbing circuit. When these certain conditions are not met, a protection command will not be generated to avoid unnecessary encoding. For example, in a conventional memory system, data may be protected by default. In the disclosed memory system, data may be protected only in response to receiving a protection command.

[0112] For example, the high-performance MRAM included in the memory system 100 can be efficiently protected or scrubbed and is more suitable for edge-AI (such as smart speakers, dashcams, drones, robots, self-driving cars) or neural network applications, which require faster and more efficient memory (such as high bandwidth and low latency, high performance after compression of neural network models, high performance at high temperatures, and uninterrupted data access). Memory technologies with non-deterministic write mechanisms are plagued by high bit error rates (BER). The memory system 100 uses the disclosed data scrubbing and protection methods to advantageously achieve more robust operation in systems such as self-driving cars.

[0113] Memory system 100 may include data scrubbing circuit 110, data memory 120, and ECC memory 130. In some embodiments, data memory 120 is a random access memory (RAM) of a computer system. In some embodiments, data memory 120 and ECC memory 130 are non-volatile RAM.

[0114] In some embodiments, the data scrubbing circuit 110 performs data scrubbing without affecting read or write access to the data memory 120. By performing data protection or data scrubbing while memory data is accessed, memory errors (such as magnetic tunnel junction (MTJ) errors) can be reduced without adding latency to critical circuits (such as scrubbing data at higher read and write speeds, scrubbing data without affecting rated read and write speeds). For example, latency reduction can allow the memory system to operate at a bandwidth of TB per second.

[0115] In some embodiments, the data scrubbing circuit 110 includes an ECC decoder circuit and a local register for temporarily storing the current position associated with the ECC code in the codeword. In some embodiments, the data storage 120 is divided into a plurality of sub-circuits, generally referred to as storage banks. Each storage bank can be configured to operate independently of other storage banks.

[0116] As an example, during a protection or data scrubbing operation, the memory system 100 may receive a data access command from a host (e.g., an edge-AI system). When an ongoing data protection or data scrubbing operation is performed on a data storage library, the data access command may be associated with an operation (e.g., read data, write data) on another data storage library. In this case, the ongoing data protection or data scrubbing operation may be performed simultaneously with the data access.

[0117] When the ongoing data protection or data scrubbing operation is performed on the same data storage library, the data access command may be associated with the operation (e.g., read data, write data) on the data storage library. In this case, the data scrubbing controller 113 may suspend the data protection or data scrubbing operation and give control of the data storage library to the data access operation such as the read operation or the write operation. After the data access operation is completed, the data scrubbing controller takes back the control of the data storage library, and the suspended data protection or data scrubbing operation resumes from the position (e.g., the corresponding address) of the ECC codeword before the interruption. In some examples, during this period, the data scrubbing controller 113 may perform a data protection or data scrubbing operation on another storage library.

[0118] In some examples, a data scrubbing circuit or a host (such as a central processing unit (CPU), a graphics processing unit (GPU), a single chip system (SoC), a programmable processor, a special application integrated circuit, or a microcontroller) is configured to determine whether the data storage is protected (such as the data scrubbing circuit or the host checks the register in the ECC memory to see whether the corresponding segment is protected by error correction), and the ECC memory is configured to store ECC check bits based on the determination that the data storage is protected, and to store operation data based on the determination that the data storage is not protected. For example, if the operation data in the data storage is not protected (such as ECC is not required), the ECC memory can be used to store additional operation data. As shown in the figure, the data scrubbing circuit can be electrically coupled to the ECC memory and the data storage. As an exemplary advantage, if it is not expected that the product will be used in a harsh environment (such as a wearable electronic device that is not in a high temperature or high magnetic field environment), the data storage capacity of the ECC memory can be released to the host system.

[0119] In some examples, the ECC memory is configured to store the operation data at the first time, and in response to the activation of the protect data command, the ECC memory is updated to store the ECC check bits. In these examples, the operation data can be moved to a blank area in the data memory, another storage device in the system, or to a remote storage device via a data network. If these are not feasible, the memory system can send an error message to the host.

[0120] In some embodiments, the data memory and the ECC memory are included in different memory circuits. For example, the data memory and the ECC memory are included on different chips. In some embodiments, the data memory and the ECC memory are included in the same memory circuit. For example, the data memory and the ECC memory are included on the same chip. As another example, the data memory and the ECC memory are included in the same memory array; for example, the data memory is included in a first portion of the array, and the ECC memory is included in a second portion of the array.

[0121] By achieving the benefits of high-efficiency error correction and data scrubbing described herein, memory cells may be configured to enhance overwrite endurance or performance, reduce power consumption, or a combination of these desirable characteristics. This may be achieved without necessarily reducing the error rate of the memory system (as the high-efficiency error correction and data scrubbing of the disclosed system may at least offset the increased error rate associated with these desirable characteristics).

[0122] For example, the voltage level of a write operation can be reduced by 5 to 50%, thereby enhancing the rewrite endurance of a memory cell and reducing power consumption without reducing the error rate of the memory system (e.g., without requiring additional circuit design and reducing the probability of failure during a write operation, the write voltage or write time is sufficient to mitigate device-circuit mismatch and / or random STT effects). As another example, the voltage level of a memory cell read operation can be increased by 5 to 50%, or the read time can be reduced by 5 to 50%, thereby enhancing the read performance without reducing the error rate of the memory system (e.g., without requiring additional circuit design, the read voltage or read time is sufficient to mitigate device-circuit mismatch and reduce read disturbance errors). In some examples, for a 1MB array, the read performance can be increased to more than 7GB per second.

[0123] In some embodiments, the data memory may include a portion of a magnetic random access memory (MRAM). In some embodiments, the ECC memory may also include a portion of an MRAM. In some examples, the storage cell used in at least one of the data memory and the ECC memory includes a magnetic tunnel junction (MTJ) and a bit error rate of less than 10 -12 Up to 10 -2 Compared with a memory cell between 100 nm and 200 nm, the memory cell has one of the following characteristics: reduced size, reduced coercive magnetic field, reduced magnetic anisotropy, and reduced saturation magnetization. In some examples, the data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nm and 200 nm and a MOS transistor having a width-to-length ratio between 1 and 200.

[0124] In some embodiments, the data memory may include static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM). In some embodiments, the ECC memory may include SRAM, DRAM, or eDRAM. For example, the SRAM, DRAM, or eDRAM may include memory cells implemented in sub-micron (e.g., 28 nanometers and below) technology with a bit error rate of 10 -16 Up to 10 -10Thus, the memory system 100 can advantageously allow SRAM, DRAM, or eDRAM process technology to be scaled down to smaller technology nodes without sacrificing power, area, or performance or soft error rate (e.g., read disturb, write error, retention error), etc. In addition, using the memory system 100, SRAM, DRAM, or eDRAM at smaller technology nodes can operate over a wider temperature range and be more radiation resistant.

[0125] In some embodiments, a data scrubbing circuit is configured to respond to receiving a flush data command to correct errors in the memory. Memory systems that do not utilize the disclosed flush data command may flush data when the data memory may not need to be flushed (e.g., the bit error rate (e.g., the available bit error rate (UBER) is sufficient to meet system requirements)). Such memory systems may be less efficient (e.g., higher power consumption, slower speed) due to indiscriminate flushing of data. By including a data scrubbing circuit configured to respond to receiving a flush data command to correct errors in the data memory, data can be efficiently flushed and unnecessary flushing can be avoided.

[0126] In some embodiments, the codeword length used for error correction is longer than the word length used during normal access to the data memory. For example, the word groups during normal access are part of the ECC codeword so that these word groups are protected by the ECC. That is, the entire ECC codeword is not used during normal read operations (such as accessing the normal access word portion). There are many ways to handle write operations, for example, the codeword length can have a length of 8192 bits, while the uncoded word can have a length of 64 bits.

[0127] In some embodiments, the data memory 120 is divided into multiple pages, each page having the size of an ECC codeword length (e.g., 8192 bits). When a host (e.g., an edge-AI system) sends a write command with a data word (e.g., a word with a length of 64 bits), the data scrubbing controller 113 uses the extra bits contained in each page (e.g., a page mark bit) to mark the target page of the data word as "unprotected". When the data scrubbing controller 113 starts a data scrubbing operation on an "unprotected" page, the ECC check bit data in the corresponding ECC memory 130 is not used immediately. Instead, the data scrubbing controller first performs a protection operation to generate a set of ECC check bits corresponding to the new page data, and updates the page mark bit from "unprotected" to "protected" before performing the data scrubbing operation.

[0128] As an exemplary advantage, a longer codeword length increases efficiency during error correction, i.e., a smaller number of ECC check bits are required to correct the raw bit error rate (RBER) to the desired UBER. As a result, the size of the memory system can be reduced and the cost can be reduced.

[0129] In some embodiments, the data scrubbing circuit 110 includes a data buffer 111, an ECC operation engine 112, and a data scrubbing controller 113. The data scrubbing circuit may also be configured to use a codeword associated with a codeword length to correct errors in the data storage.

[0130] For example, when a data scrubbing command is initiated, all data words (e.g., ECC pages) associated with an ECC code are read from the data memory 120, and the ECC check bits associated with the ECC page are read from the ECC memory 130. The data words and the ECC check bits are sent to the ECC operation engine 112 via the data buffer 111. In some examples, the data buffer 111 may be configured as a first-in-first-out (FIFO) memory. In some examples, while the ECC operation engine 112 is performing an ECC decoding operation, normal data access (e.g., a read request from a host or a memory controller) to read data words in the data memory 120 may be suspended. After the ECC operation engine 112 has decoded the ECC page, correctable errors are detected. The number and location of the errors detected by the ECC operation engine may be sent to the data scrubbing controller 113. All detected errors are corrected by writing the correct data back to the corresponding locations in the data memory 120 (e.g., using the data scrubbing controller).

[0131] Figure 2 2 is a diagram depicting a data memory and an ECC memory according to an embodiment. In some embodiments, the ECC memory 230 includes a plurality of partitions, and the data memory includes a plurality of memory address ranges, each partition corresponding to a memory address range in the data memory. For example, the ECC memory includes an ECC check bit partition 231, and the data memory includes an ECC codeword 221. The ECC check bit partition 231 may correspond to a memory address range associated with the ECC codeword 221.

[0132] In some embodiments, the ECC check bit partition includes a plurality of ECC bits, and the number of ECC bits is based on an ECC encoding method associated with a data scrubbing algorithm. For example, the data scrubbing algorithm is one of a Bose, Chaudhuri, and Hocquenghem (BCH) code and a low-density parity check (LDPC) code. In one example, in a BCH (8640, 8192, 32) code, 448 ECC bits are associated with each ECC codeword (e.g., an ECC page) in 8192 bits, and can correct up to 32 errors in the ECC codeword. As an exemplary advantage, implementing this encoding scheme consumes approximately 5.2% of the area to store the ECC check bits, compared to more than 20% of the area consumed in a system using 2-bit ECC on a 64-bit word.

[0133] For example, the following describes an example of BCH encoding. A data scrubbing circuit can be used to perform BCH encoding and decoding. The nk-dimensional state vector R(t)=(r n-k-1(t) ,r n-k-1(t) ,…,r 1 (t),r 0 (t)) T , where r i (t) represents the state of the i-th reminder register at time t, and u(t) represents the single bit input at time t. R(t+1) can be expressed as:

[0134] (1) R(t+1)=A·R(t)+b·u(t),

[0135] The matrix A is

[0136] (2) And the vector b is

[0137] (3)b=(g n-k-1 ,g n-k-1 ,…,g 1 ,g 0 ) T .

[0138] Recursively, R(t+p) can be calculated as

[0139] (4) R(t+p)=

[0140] A p ·R(t)+(A p-1 b,A p-2 b,…,b)·(u(t),u(t+1),…,u(t+p-1)) T =

[0141] A p ·R(t)+B p ·U p (t).

[0142] In some embodiments, the ECC memory includes a set of registers. Each register corresponds to an ECC code word. Each ECC code word corresponds to a segment in the data memory. Each register stores the state of the segment. For example, the register can be used to store a page mark bit.

[0143] In some embodiments, data memory 220 is substantially similar to data memory 120, and ECC memory 230 is substantially similar to ECC memory 130. Although data memory and ECC memory are depicted using blocks, the data memory and ECC memory may of course be included in one or more memory arrays without departing from the scope of the present invention.

[0144] In some embodiments, the memory system 100 includes an environmental disturbance sensor 140 configured to detect environmental conditions and generate a data scrubbing command based on the detected environmental conditions. In some embodiments, the environmental conditions include at least one selected from temperature and a magnetic field. In some embodiments, the environmental disturbance sensor is included in a data scrubbing controller (such as data scrubbing controller 113).

[0145] For example, the environmental disturbance sensor detects that the temperature reaches a critical value (eg, a critical temperature associated with a critical bit error rate). In response to detecting that the temperature reaches the critical value, the data scrubbing controller generates a scrubbing data command to initiate data scrubbing of the data storage.

[0146] As another example, the environmental disturbance sensor detects that the magnetic field reaches a threshold value (eg, a threshold magnetic field strength associated with a threshold bit error rate). In response to detecting that the magnetic field reaches the threshold value, the data scrubbing controller generates a scrubbing data command to initiate data scrubbing of the data storage.

[0147] In some embodiments, the data scrubbing circuit is configured to detect changes in known data (e.g., data known to the host or the memory system 100, predetermined data (e.g., checkerboard data having alternating 0s and 1s)) and generate a scrubbing data command based on the detection of the changes. For example, MRAM may be sensitive to high magnetic fields (e.g., magnetic fields greater than 100 to 1000 Oersteds), and high magnetic fields may increase the probability of errors associated with the known data.

[0148] As another example, the memory may be sensitive to high temperatures (e.g., temperatures exceeding 150 degrees Celsius), and the high temperatures may increase the probability of errors associated with the memory. The environmental disturbance sensor may detect that the temperature reaches a certain temperature threshold and initiate the generation of a flush data command to correct the erroneous data caused by the high temperature.

[0149] Although magnetic field and temperature are used as exemplary parameters for detecting environmental conditions that may increase the probability of errors associated with memory, the environmental disturbance sensor can of course detect other conditions as well. For example, the environmental disturbance sensor can detect ionizing radiation, which can cause charge-based memory circuits to lose data. In another example, the environmental disturbance sensor can detect mechanical stress excursions.

[0150] As an exemplary advantage, sensors and programmable closed-loop control can manage memory (such as MRAM) to mitigate the effects of high temperature, temperature fluctuations, magnetic fields, or other disturbances. Therefore, without adding compensation circuits, it is possible to operate at higher temperatures or over a wider temperature range and increase endurance. For example, at about room temperature, an environmental disturbance sensor can determine that no data scrubbing is required (such as 0% of memory operations are used for scrubbing). At 125 degrees Celsius, a memory device (including MTJ) with 60% intrinsic retention capability may only require 2% additional read and write operations to scrub all data. In contrast, other systems may require more than 20% additional operations to correct errors under similar circumstances.

[0151] In some embodiments, the memory system 100 includes a timer circuit 150 configured to track the elapsed time and determine whether the elapsed time is greater than a timing threshold, and to generate a flush data command based on the determination that the elapsed time is greater than the timing threshold. For example, the bit error rate (BER) of the memory increases in proportion to time (e.g., the BER is cumulative), and the timing threshold corresponds to a critical BER (e.g., a system BER requirement). The timer circuit 150 tracks the elapsed time (e.g., between 1 microsecond and 100 hours) after the start time (i.e., the time when the ECC check bit is generated), and can initiate the generation of the flush data command before the accumulated BER of the data memory exceeds a level that cannot be corrected by the ECC method. In some embodiments, the timer circuit 150 is included in a data scrubbing controller (e.g., data scrubbing controller 113).

[0152] Figure 3 A method 300 for operating a memory system according to an embodiment is depicted. The method 300 includes step 302, receiving a command to protect data. For example, the protection command is received from the data scrubbing circuit 110, the host 160, or the memory controller 170. As another example, the protection command is received after determining that the data memory needs protection (e.g., reaching a temperature, magnetic field, timing threshold, or bit error rate threshold).

[0153] As an exemplary advantage, the memory system can achieve highly efficient error correction and data scrubbing. For example, compared to a memory system that does not utilize the disclosed scrubbing data command or the disclosed protection command, the exemplary embodiment of the memory system 100 can reduce power consumption by four times without reducing actual performance or increasing area. A memory system that does not utilize the disclosed protection command will protect data even when protection may not be needed (such as when the bit error rate already meets system requirements). Such memory systems may be inefficient (such as higher power consumption and slower speed) because they protect data indiscriminately. For example, when a protection command is not received, a portion or all of a data scrubbing circuit or a memory storing ECC check bits will be shut down. By using the protect data command, data can be efficiently protected and unnecessary protection can be avoided.

[0154] In some embodiments, in response to receiving the protection command, method 300 is performed for each data word in the data to be protected (step 304). For example, each data word to be protected may be a portion of data memory 120, such as a portion of the data memory having a more sensitive bit error rate. As another example, each data word to be protected may be the entirety of data memory 120. In some embodiments, multiple words are protected sequentially. In some embodiments, multiple words are protected in parallel.

[0155] In some embodiments, method 300 includes step 306 of identifying an address for a data codeword associated with the data word. For example, the protection command includes an address range associated with the data to be protected. As another example, the host identifies the address associated with ECC codeword 221 (e.g., the host determines a portion of the memory that is important to the system function).

[0156] In some embodiments, the method 300 includes step 308, determining whether the data word is in the data memory according to the address. For example, a bit is added to the protection command to indicate whether the data word is in the data memory. As another example, the data scrubbing circuit 110 determines whether the data word to be protected is stored in the data memory 120.

[0157] In some embodiments, the method 300 includes step 310, in response to determining that the data word is in the data memory, reading the data word from the data memory. For example, the read data is stored in the buffer memory. As another example, the data scrubbing circuit 110 determines that the data word to be protected is stored in the data memory 120, and reads the data word to be protected from the data memory 120.

[0158] In some embodiments, method 300 includes step 312, in response to determining that the data word is not in the data memory, receiving the data word (step 312a) and writing the data word to the data memory (step 312b). For example, data scrubbing circuit 110 determines that the data word is not stored in data memory 120 and writes the data word to data memory 120. In some embodiments, the data word to be written and protected is provided by host 160.

[0159] In some embodiments, the method 300 includes step 314 of performing an ECC encoding operation on the data word. For example, based on a data scrubbing algorithm, the data word to be protected is encoded according to an ECC encoding operation associated with the data scrubbing algorithm.

[0160] In some embodiments, the method 300 includes step 316 of generating a data codeword based on an ECC encoding operation. For example, generating an ECC codeword 221 based on an ECC encoding operation.

[0161] In some embodiments, method 300 includes step 318 of writing the data codeword to the data memory at the address. For example, writing ECC codeword 221 to the data memory 220 at the address.

[0162] In some embodiments, the method 300 includes step 320 of generating ECC check bits according to the ECC encoding operation. For example, generating ECC check bits associated with the ECC check bit partition 221 according to the ECC encoding operation.

[0163] In some embodiments, method 300 includes step 322, writing the generated ECC check bits to the corresponding partition in the ECC memory. For example, the ECC check bits are written to the ECC check bit partition 221. In some embodiments, after the protection command is completed to instruct to protect the data memory, a completion signal is sent to notify the host.

[0164] In some embodiments, method 300 is performed before the packaging operation of the integrated circuit to protect the data written in the memory of the integrated circuit. As an exemplary advantage, the memory system using method 300 is particularly advantageous when it is used for long-term storage or needs to undergo a standard packaging method process (e.g., 260° C., 90 seconds). For example, data stored in non-volatile memories such as MRAM and PCM will have a higher error rate after the packaging operation.

[0165] In some embodiments, method 300 is performed after long-term storage of an integrated circuit to protect data written to the memory of the integrated circuit. The generated ECC check bits can be used to remove errors accumulated during storage to increase the data retention specification of the product.

[0166] Figure 4A method 400 for operating a memory system according to an embodiment is depicted. The method 400 includes step 402 of receiving a flush data command. For example, the flush data command is received from the data scrubbing circuit 110, the host 160, or the memory controller 170. As another example, after a threshold value (e.g., temperature, magnetic field, timing threshold value, bit error rate threshold value) is reached, the data scrubbing controller sends the flush data command.

[0167] As an exemplary advantage, the memory system can achieve highly efficient error correction and data scrubbing. For example, as discussed, in response to certain conditions, the power consumption of the exemplary embodiment of the memory system 100 can be reduced by four times without sacrificing substantial performance or increasing area, compared to a memory system that does not utilize the disclosed flush data command. A memory system that does not utilize the disclosed flush data command may flush or protect data when flushing is not necessary (such as when the bit error rate has reached the system requirement). Because data is flushed indiscriminately, such a memory system may be inefficient (such as higher power consumption and slower speed). For example, some or all of the data flushing circuitry or the memory storing the ECC check bits may be shut down when the flush data command is not received. By using the flush data command, data can be flushed efficiently without unnecessary flushing.

[0168] In some embodiments, in response to receiving a flush data command, method 400 is performed for each data word to be flushed (step 404). For example, each data word to be flushed may be a portion of data memory 120, such as a portion of data memory having a more sensitive bit error rate. As another example, each data word to be flushed may be the entirety of data memory 120. In some embodiments, multiple words to be flushed are flushed sequentially. In some embodiments, multiple words to be flushed are flushed in parallel.

[0169] In some embodiments, method 400 includes step 406, identifying: the starting address of the data codeword (step 406a) and the corresponding ECC memory partition (step 406b). For example, the flush data command includes an address associated with the data to be flushed. As another example, the host identifies the address associated with the ECC codeword 221 and the ECC check bit partition 231 (such as the host determines the most important part of the memory for system function).

[0170] In some embodiments, method 400 includes step 408, reading a data word associated with the start address from a data memory. For example, the read data is stored in a buffer memory. As another example, a data word associated with the data codeword is read from the data memory.

[0171] In some embodiments, the method 400 includes step 410 of reading ECC check bits associated with a corresponding ECC memory partition from the ECC memory. For example, the ECC check bits associated with the ECC check bit partition 231 are read from the ECC memory 230.

[0172] In some embodiments, method 400 includes step 412 of performing an ECC decoding operation based on the data word and the ECC check bits. For example, based on a data scrubbing algorithm, ECC operation engine 112 performs an ECC decoding operation based on the data word and the ECC check bits associated with ECC check bit partition 231 .

[0173] In some embodiments, method 400 includes step 414 of determining whether the data word has an error based on the ECC decoding operation. For example, based on the data scrubbing algorithm and the ECC decoding operation, the ECC operation engine 112 determines whether the data word has an error.

[0174] In some embodiments, method 400 includes step 416, in response to determining that the data word has an error, replacing the error bit with a correctable bit in the data word, wherein the data word including the correctable bit is a scrubbed data word. For example, ECC operation engine 112 determines that the data word has an error, and the data word includes a correctable bit. In response, the correctable bit of the data word is replaced and corrected, and the corrected data word is a scrubbed data word.

[0175] In some embodiments, method 400 includes step 418 of, in response to determining that the data word does not contain an error, abandoning replacing the error bit with a correctable bit in the data word, wherein the data word is a scrubbed data word. For example, ECC operation engine 112 determines that the data word does not contain an error, and in response, does not replace any bits in the data word.

[0176] In some embodiments, method 400 includes step 420 of determining whether the host requests the scrubbed data word. For example, the request from host 160 is a data request from a processor of a computer system (including memory system 100 and host 160).

[0177] In some embodiments, method 400 includes step 422, in response to determining that the host requests the scrubbed data, outputting the scrubbed data word to a memory controller electrically coupled to the host. For example, in response to determining (e.g., by the memory controller) that the host makes a data request, the scrubbed data word is output to the memory controller and provided to the host, and the scrubbed data word resides in the data memory.

[0178] In some embodiments, method 400 includes step 424, in response to determining that the host has not requested the flushed data, aborting outputting the flushed data word to the memory controller. For example, in response to determining (e.g., by the memory controller) that the host has not made a data request, the flushed data word resides in the data memory and is not output to the memory controller. In some embodiments, after the flushing of the data memory is completed based on the command to flush the data, a completion signal is sent to notify the host.

[0179] Different parts of a data word may have different susceptibilities to errors. For example, an error in the most significant bit (MSB) of an integer will have more severe consequences relative to the value represented than an error in a lower order bit. Additionally, many modern computing applications (such as machine learning and video and image processing) are inherently fault tolerant; enforcing a conservative error correction scheme across the entire system may not be necessary. However, conventional memory circuits may be designed based on the assumption that all parts of the same data word have the same error rate. In these conventional memory circuits, power and area are wasted by using memory circuits designed for low fault tolerance to store data that can tolerate more faults.

[0180] Figure 5 Memory system 500 is depicted according to an embodiment. In some embodiments, memory system 500 is included in memory system 100. In some embodiments, memory system 500 may be included in a machine learning or video or imaging processing system.

[0181] In some embodiments, memory system 500 includes a first memory circuit 502 and a second memory circuit 504. First memory circuit 502 may be associated with a first bit error rate, second memory circuit 504 may be associated with a second bit error rate, and the first bit error rate may be greater than the second bit error rate. For example, the first bit error rate is 10 -16 Up to 10 -12 and the second bit error rate is between 10 -12 Up to 10 -6 between.

[0182] In some embodiments, the first memory circuit 502 includes a data protection circuit, such as an error correction coding circuit, a data scrubbing circuit, a redundancy circuit, or a combination of these circuits, to reduce the first error rate to a third error rate. For example, the system may not tolerate a portion of data having a first error rate; the data portion may be stored in the first memory circuit to reduce the first error rate to a third error rate to meet system requirements. In some embodiments, the first memory circuit 502 includes a circuit configured to verify data and reduce the error rate after a write operation, or a circuit configured to prevent bit flips and reduce active power.

[0183] In some embodiments, the second memory circuit 504 includes a data protection circuit, such as an error correction coding circuit, a data scrubbing circuit, a redundancy circuit, or a combination of these circuits, to reduce the error rate from the second error rate to the fourth error rate. In some embodiments, the second memory circuit 504 includes a circuit configured to verify data and reduce the error rate after a write operation, or a circuit configured to prevent bit inversion and reduce effective power. In some embodiments, these circuits included in the second memory circuit 504 may consume less power and have a smaller area than comparable circuits in the first memory circuit 502.

[0184] In some embodiments, data word 508 is stored in a first memory circuit and a second memory circuit. Data word 508 may include a first partition 510 associated with a first bit error rate and a second partition 512 associated with a second bit error rate. First partition 510 of data word 508 may be stored in first memory circuit 502, and second partition 512 of data word 508 may be stored in second memory circuit 504.

[0185] In some embodiments, the size of each partition is determined by a host (e.g., host 160). For example, for 8-bit signed integer data, the host may determine that the sign bit and the three most significant bits are stored in a first partition associated with a lower bit error rate, and the four least significant bits are stored in a second partition associated with a higher bit error rate. The significance of the bits may be determined by the digital format used by the software, and the result may be communicated to the host. For example, the order from most significant bit to least significant bit may be: sign bit, exponent bit, MSB to LSB in the mantissa.

[0186] In some embodiments, the size of each partition is updated in response to changing conditions. For example, the size of each partition can be updated based on magnetic and temperature conditions that affect the memory circuit. As another example, it can be determined that a partition in a first memory circuit is no longer important and the partition can be moved to a second memory circuit.

[0187] Data word 508 may be associated with address 516. In some embodiments, address 516 corresponds to a location in a memory circuit that stores a partition. The data word may be physically stored in different partitions, but to a user of memory system 500 (e.g., a host, a memory controller), the data word appears to be stored in a location associated with address 516.

[0188] In some embodiments, the memory system includes a third memory circuit 506. The data word 508 may include a third partition 514, and the third partition may be stored in the third memory circuit 506. The data word 508 may not include a third partition, and the data word 508 may be stored in the first memory circuit and the second memory circuit.

[0189] Although the description includes embodiments with two memory circuits and three memory circuits and two partitions and three partitions, the memory system may of course include more or fewer memory circuits, and the data words may include more or fewer partitions stored in the respective memory circuits without departing from the scope of the present invention.

[0190] In some embodiments, the memory system 500 includes a data scrubbing circuit 516 electrically coupled to the first memory circuit and the second memory circuit. The data scrubbing circuit 516 can control the first memory circuit 502 to reduce the first error rate to a third error rate, and can control the second memory circuit 504 to reduce the second error rate to a fourth error rate. In some embodiments, the first bit error rate is reduced more than the second bit error rate. For example, the third error rate is 10 -20 Up to 10 -16 The fourth error rate is between 10 -16 Up to 10 -10 In some embodiments, the data scrubbing circuit 516 and other processing circuits are on the same chip as the memory circuit. In some embodiments, the data scrubbing circuit 516 and other processing circuits are on a different chip than the memory circuit.

[0191] As an exemplary advantage, power and area can be reduced. For example, more circuit area or power consumption resources will be appropriately biased towards partitions with higher bit error rates or higher error sensitivity (such as the most important parts of the memory), while fewer resources will be appropriately directed to partitions with lower bit error rates or lower error sensitivity (such as not wasting resources on partitions with lower bit error rates or lower error sensitivity); thereby saving power and reducing the area of ​​error correction circuit design. As another example, computing applications such as neural network applications, machine learning, and video or image processing systems can be fault-tolerant, and some parts of the data can be less sensitive to errors. By distinguishing parts of the data with less error sensitivity, the power and area consumption of the memory circuit can be reduced.

[0192] As another exemplary advantage, in the case of large numerical data such as neural network parameters, the design of the memory system can be efficiently partitioned according to the sensitivity of bits within the data word to errors, thereby avoiding the use of unnecessary computing resources.

[0193] In some embodiments, the first memory circuit 502 includes a first memory cell including a first magnetic tunnel junction (MTJ) having a first size and a first MOS transistor having a first channel width-to-length (W / L) ratio. The second memory circuit 504 includes a second memory cell including a second MTJ having a second size and a second MOS transistor having a second W / L ratio. The first size is greater than the second size, and the first W / L ratio is greater than the second W / L ratio.

[0194] For example, the first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200. As another example, the second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

[0195] As an exemplary advantage, area can be reduced. For example, more area (such as larger devices with lower error rates) will be appropriately biased towards partitions with higher bit error rates or higher error sensitivity (such as the most important parts of the memory), while less area (such as smaller devices with lower error rates) will be appropriately directed to partitions with lower bit error rates or lower error sensitivity (such as not wasting area for partitions with lower bit error rates or lower error sensitivity); thereby reducing the area of ​​the memory circuit. As another example, computing applications such as machine learning and video or image processing systems can be fault-tolerant, and some parts of the data can be less sensitive to errors. By dividing the parts of the data that are less error-sensitive, the area of ​​the memory circuit can be reduced.

[0196] In some embodiments, the first memory circuit 502 uses a first read voltage, a first sensing time, and a first word line (WL) voltage, and the second memory circuit 504 uses a second read voltage, a second sensing time, and a second WL voltage. The first read voltage is greater than the second read voltage, the first sensing time is greater than the second sensing time, and the first WL voltage is greater than the second WL voltage.

[0197] For example, the first read voltage is in the range of 50 millivolts to 300 millivolts, or the first sensing time is in the range of 3 nanoseconds to 500 nanoseconds, or both, to reduce the sensing error rate. During the read operation, the first WL voltage may be in the range of 100% to 200% of the rated gate voltage for the access transistor. The second read voltage may be in the range of 30 millivolts to 100 millivolts, or the second sensing time may be in the range of 2 nanoseconds to 100 nanoseconds, or both, to reduce the readout power consumption. During the read operation, the second WL voltage may be in the range of 70% to 150% of the rated gate voltage for the access transistor.

[0198] In some embodiments, the first memory circuit 502 uses a first write voltage, a first write time, and a first word line (WL) voltage, and the second memory circuit 504 uses a second write voltage, a second write time, and a second WL voltage. The first write voltage is greater than the second write voltage, the first write time is greater than the second write time, and the first WL voltage is greater than the second WL voltage.

[0199] For example, the first write voltage is in the range of 500 mV to 1500 mV, or the longer write time is in the range of 5 ns to 1000 ns, or both, to reduce the write error rate. During the write operation, the first WL voltage can be in the range of 100% to 300% of the rated gate voltage for the access transistor. The second write voltage can be in the range of 300 mV to 1000 mV, or the shorter write time can be in the range of 2 ns to 500 ns, or both, to reduce the write power consumption. During the write operation, the second WL voltage can be in the range of 70% to 200% of the rated gate voltage for the access transistor.

[0200] As an exemplary advantage, power can be reduced. For example, more resources (such as higher voltage, longer sense / write time) will be appropriately biased towards partitions with higher bit error rates or higher error sensitivity (such as the most important parts of the memory), while fewer resources (such as lower voltage, shorter sense / write time) will be appropriately directed to partitions with lower bit error rates or lower error sensitivity (such as not wasting resources on partitions with lower bit error rates or lower error sensitivity); thereby saving read and / or write power. As another example, computing applications such as machine learning and video or image processing systems can be fault-tolerant, and some parts of the data may be less sensitive to errors. By partitioning the less error-sensitive parts of the data, power can be reduced.

[0201] Figure 66 is a diagram depicting data word partitions according to an embodiment. In some embodiments, data word 600 includes partitions 602 and 604. For example, data word 600 includes partitions formed in a standard single-precision format, divided into more error-sensitive bits (MESBs) such as partition 602 and less error-sensitive bits (LESBs) such as partition 604. In some embodiments, partitions 602 and 604 are substantially similar to partitions 510 and 512, and data word 600 may be stored in memory system 500. In some embodiments, the length of data word 600 is a power of 2.

[0202] In some examples, the data word 600 is in a floating point format. The first partition 602 includes a sign bit, an exponent bit, and a higher order portion of the mantissa bits, and the second partition 604 includes a lower order portion of the mantissa bits. In some examples, the data word 600 is in an integer format, the first partition 602 includes a sign bit and higher order bits, and the second partition 604 includes lower order bits.

[0203] Although an embodiment including two partitions is described with respect to data word 600, data word 600 may of course include more partitions, each partition being associated with a bit error rate, without departing from the scope of the present invention.

[0204] Figure 7 A method of operating a memory system is depicted according to an embodiment. In some embodiments, method 700 includes step 702 of determining a first partition of data words to be stored in the memory system based on a first bit error rate. For example, it is determined (e.g., by a host based on a system fault tolerance associated with the data, based on the digital format of data word 600) that partition 602 is more sensitive to errors (e.g., has a higher error rate).

[0205] In some embodiments, method 700 includes determining a second partition of data words to be stored in the memory system based on the second bit error rate, the first bit error rate being greater than the second bit error rate, at step 704. For example, it is determined (e.g., by the host) that partition 604 is less sensitive to errors than the first partition (e.g., has a lower error rate than the first partition).

[0206] In some embodiments, method 700 includes storing a first partition of the data word in a first memory circuit at step 706. For example, first partition 602 is stored in first memory circuit 502. First memory circuit 502 may be configured to correct data having a first bit error rate.

[0207] In some embodiments, method 700 includes storing a second partition of the data word in a second memory circuit at step 708. For example, second partition 604 is stored in second memory circuit 504. Second memory circuit 504 may be configured to correct data having a second bit error rate.

[0208] In some embodiments, the first memory circuit is associated with a first bit error rate and the second memory circuit is associated with a second bit error rate. For example, memory circuit 502 is associated with a first bit error rate and memory circuit 504 is associated with a second bit error rate, and the second bit error rate is greater than the first bit error rate.

[0209] Figure 8 The memory system 800 is depicted according to an embodiment. The memory system 800 includes: a data input 802; a multi-level cell (MLC) memory array 804; a write circuit 806 electrically coupled to the MLC memory array and the data input; a Gray code to binary decoder circuit 808 electrically coupled to the write circuit; a read circuit 810 electrically coupled to the MLC memory array; a binary to Gray code encoder circuit 812 electrically coupled to the read circuit and the data input; a memory circuit 814 configured to store ECC check bits; an ECC encoder 816 electrically coupled to the memory circuit and the binary to Gray code encoder circuit; an ECC decoder 818 electrically coupled to the memory circuit and the Gray code to binary encoder circuit and configured to output recovered data; and a data scrubbing controller 820 configured to control data recovery in the memory system.

[0210] In some examples, multi-level cell (MLC) devices may be used for computational operations in memory (e.g., in neural network-like operations) by representing matrix multiplicands with multiple states or continuous analog characteristics. In some embodiments, the MLC is an analog memory. Memory devices may exhibit drift during operation, which may gradually change the value of the matrix multiplicand. As an exemplary advantage, the memory system 800 uses Gray coding to efficiently recover data after it has experienced drift (e.g., correct the drift before a simple "read and restore" operation can correct the erroneous data); the frequency of data refresh may be reduced. Gray coding is a form of digital data representation in which adjacent states differ by one bit. This feature advantageously ensures that small changes in device state only change a small number of bits, reducing the need for error correction circuitry, thereby reducing the power and area of ​​error correction circuitry associated with the memory.

[0211] In some embodiments, the memory circuit 814 is located on a different integrated circuit from the MLC memory 804. For example, the memory circuit, the ECC encoder circuit, and the ECC decoder circuit are on the same chip, which is different from the chip where the MLC memory 804 is located. In some embodiments, the MLC memory 804 and the memory circuit 814 are on the same chip. For example, the MLC memory 804 and the memory circuit 814 may be included in the same memory array. In some cases, the memory circuit may be located in a predetermined partition of the MLC memory array (e.g., the MLC memory array and the memory circuit are included in the same memory).

[0212] In some embodiments, the MLC memory array includes a memory cell circuit having more than two stable physical states. For example, the memory cell circuit may have eight stable states, and each stable state represents a number from zero to seven in binary. In some embodiments, the MLC memory array includes an analog memory device (such as an analog device configured to store a series of continuous values). For example, the memory cell circuit may be one selected from the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive memory (RRAM) cell.

[0213] In some embodiments, the ECC encoder and decoder use one selected from the following: Hamming code, BCH code, Reed-Solomon code, and LDPC code. In some examples, the check bit size in the check-bit memory 814 is determined by the ECC method. In some embodiments, the readout circuit 810 includes an analog-to-digital converter (ADC).

[0214] In some embodiments, data scrubbing controller 820 is generally similar to data scrubbing circuit 110, but is used with MLC memory. In some embodiments, memory system 800 includes environmental disturbance sensor 140 and / or timer 150 to determine when data scrubbing should be initiated. In some examples, data scrubbing controller is configured to initiate data scrubbing operations at predetermined intervals (e.g., using timer 150, as described herein) in response to detection of environmental disturbances (e.g., using environmental disturbance sensor 140, as described herein), or in response to receiving a command from a host, as described herein. For example, data may be periodically read out and data scrubbing performed on the data to mitigate drift in the data.

[0215] Fig. 9904; the upper and lower values ​​for each column are mathematically equivalent. Curve 906 corresponds to an ideal range of discrete values ​​(e.g., voltages) that can be stored in an MLC memory. In some cases, the curve may deviate from curve 906 due to non-idealities such as device drift. For example, the curve corresponding to the binary value "100" in curve 908 is shifted to the right due to drift; in these examples, data including "100" may be erroneously changed to "101". The memory system 800 or method 1000 may be used to restore the ideal level corresponding to "100".

[0216] Fig.10 A method 1000 of operating a memory system is depicted according to an embodiment. The method 1000 includes step 1002 of reading data from an MLC memory, the data being represented by a binary code or an analog value. For example, a portion or all of the data is read from the MLC memory 804 using a read circuit 810. The data may be read and scrubbed sequentially or in parallel. When reading and scrubbing the data in parallel, the memory system 800 may include more than one non-memory array element (e.g., a read circuit, a Gray code encoder / decoder, an ECC memory, an ECC encoder / decoder, a write circuit) to enable simultaneous data scrubbing of the MLC data.

[0217] In some embodiments, the method 1000 includes step 1004 of converting the data into Gray code. For example, the binary to Gray code encoder circuit 812 converts the read data into Gray code.

[0218] In some embodiments, method 1000 includes step 1006 of reading corresponding check bit data from a memory circuit configured to store ECC check bits, for example, reading ECC check bits corresponding to read data in memory circuit 814 to perform a data scrubbing operation on the read data.

[0219] In some embodiments, method 1000 includes calculating the location of correctable errors in the data using Gray code at step 1008. For example, after performing an ECC operation on the read data, the data scrubbing controller 820 calculates the location of the correctable errors based on the result of the ECC operation (e.g., based on the decoded ECC word).

[0220] In some embodiments, the method 1000 includes step 1010 of correcting correctable errors in the data using Gray codes. For example, based on the ECC method, the data scrubbing controller 820 corrects the correctable errors using Gray codes.

[0221] In some embodiments, method 1000 includes converting the corrected data into a binary code or a corrected analog value at step 1012. For example, Gray code to binary decoder circuit 808 is used to convert the corrected Gray code data back into a binary value (such as for MLC memory) or a corrected analog value (such as in analog memory).

[0222] In some embodiments, method 1000 includes step 1014 of overwriting the corrected data on the data in the MLC memory using a write circuit. For example, if the data being scrubbed is determined to be erroneous, the corrected and converted data is written to memory 804 using write circuit 806.

[0223] Although referenced Figures 8 to 10 Specific architectures and methods are described, but the disclosed MLC or analog memory may of course employ binary error correction architectures and methods for error correcting MLC or analog memory without departing from the scope of the present invention.

[0224] Fig.11 A system 1100 including a memory system is depicted according to an embodiment. System 1100 may include: a memory system 1110 (such as memory systems 100, 500, 800), electrically coupled to a memory controller 1120; a processor 1130; a direct memory access (DMA) controller 1140; a peripheral interface 1150; a real-time timer (RTC) 1160; and other circuits 1170. Exemplary elements of system 1100 are electrically coupled to a bus data bus 1180. In some embodiments, system 1100 is part of a portable electronic device (such as a smart watch or a smart phone). In some embodiments, system 1100 is part of a machine learning system. In some embodiments, system 1100 is part of a distributed information collection and processing network (such as a cloud, a neural network).

[0225] In some embodiments, the memory system 1110 is included in one selected from the following items: an artificial intelligence edge computing (edge-AI) system, a neural network system in a data center, an Internet of Things system, an automotive electronic system, a microcontroller system, a mobile communication system, a programmable computing system (such as an FPGA), a hardware security system, a telematics system, a biomedical electronic device, a robot, and a drone.

[0226] Fig.12 An example of a computing device 1200 is depicted according to an embodiment. In some embodiments, the device 1200 is configured to be coupled to the disclosed system and configured to perform the operating methods associated with the system disclosed herein.

[0227] Device 1200 may be a computer host connected to a network. Device 1200 may be a client computer or a server. Fig.12 As shown, the device 1200 can be any suitable type of microprocessor-based device, such as a dedicated computing device, a personal computer, a workstation, a server, a handheld computing device (portable electronic device) such as a mobile phone or a tablet, an edge computing device for artificial intelligence (edge-AI), or a neural network device. For example, the device may include one or more processors 1202, an input device 1206, an output device 1208, a memory 1210, and a communication device 1204. The input device 1206 and the output device 1208 can generally correspond to those disclosed above, and can be connected to a computer or integrated with the computer.

[0228] Input device 1206 may be any suitable device for providing input, such as a camera sensor, a touch screen, a keyboard or keypad, a mouse, or a voice recognition device. Output device 1208 may be any suitable device for providing output, such as an illuminator, a touch screen, a haptic device, or a speaker.

[0229] Memory 1210 may be any suitable device that provides storage, such as RAM including electrical, magnetic, or optical storage, cache memory, a hard disk, or a removable storage disk. In some examples, memory 1210 includes memory system 100, 500, or 800. Communication device 1204 may include any suitable device capable of sending and receiving signals over a network, such as a network interface chip or device. The components of the computer may be connected in any suitable manner, such as via a physical bus or wirelessly.

[0230] The software 1212 , which may be stored in the memory 1210 and executed by the processor 1210 , may include, for example, programming that embodies the functions of the present invention (eg, embodied in the above-mentioned apparatus).

[0231] The software 1212 may also be stored and / or transferred to any non-transitory, computer-readable storage medium for use by or in connection with an instruction execution system, device, or apparatus (such as those described above), which retrieves instructions associated with the software from the instruction execution system, device, or apparatus and executes the instructions. In the context of the present invention, a computer-readable storage medium may be any medium, such as memory 1210, that may contain or store programming for use by or in connection with an instruction execution system, device, or apparatus.

[0232] The software 1212 may also be transmitted in any transmission medium for use by or in connection with an instruction execution system, apparatus, or device (such as those described above), which can retrieve instructions associated with the software from the instruction execution system, apparatus, or device and execute the instructions. In the context of the present invention, a transmission medium can be any medium that can communicate, propagate, or transmit programming for use by or in connection with an instruction execution system, apparatus, or device. Transmission readable media may include, but are not limited to, electronic, magnetic, optical, electromagnetic, or infrared wired or wireless transmission media.

[0233] The device 1200 may be connected to a network, which may be any suitable type of interconnected communication system. The network may implement any suitable communication protocol and may be protected by any suitable security protocol. The network may include any suitable arrangement of network links that may implement the sending and receiving of network signals, such as a wireless network connection, a T1 or T3 line, a cable network, a digital subscriber line (DSL), or a telephone line.

[0234] Device 1200 may implement any operating system suitable for operation on a network. Software 1212 may be written in any suitable programming language, such as C, C++, Java, or Python. In various embodiments, the application software embodying the functionality of the present invention may be deployed in different configurations, such as in a client-slave arrangement or through a web browser, for example as a web-based application or web service.

[0235] In one aspect, a memory system includes: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory.

[0236] In some aspects of the above memory system, the data scrubbing circuit is configured to correct errors in the data memory in response to receiving a flush data command.

[0237] In some aspects of the above memory systems, a codeword length used for error correction is longer than a word length used during normal access of the data memory.

[0238] In some aspects of the above memory system, the data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

[0239] In some aspects of the above memory system, the data scrubbing circuit is configured to correct errors in the data memory while accessing the data memory.

[0240] In some aspects of the above memory system, the memory system further includes an environmental disturbance sensor configured to detect an environmental condition, and wherein the data flushing circuit generates the flush data command based on the detected environmental condition.

[0241] In some aspects of the foregoing memory systems, the environmental condition includes at least one of temperature and a magnetic field.

[0242] In some aspects of the above memory systems, the data flushing circuit is configured to detect changes in known data and generate a flush data command based on the detection of the changes.

[0243] In some aspects of the above memory system, the memory system further includes a timer circuit configured to: track elapsed time; and determine whether the elapsed time is greater than a timing threshold, and generate a flush data command based on the determination that the elapsed time is greater than the timing threshold.

[0244] In some aspects of the above memory system, the ECC memory includes a plurality of partitions, and the data memory includes a plurality of memory address ranges, each partition corresponding to a memory address range in the data memory.

[0245] In some aspects of the above memory system, the ECC memory includes a partition having a plurality of ECC bits, and the number of ECC bits is based on an ECC encoding method associated with a data scrubbing algorithm.

[0246] In some aspects of the above memory system, the ECC memory includes a set of registers, wherein: each register corresponds to an ECC code word, each ECC code word corresponds to a segment in the data memory, and each register stores the state of the segment.

[0247] In some aspects of the above memory systems, at least one selected from the group consisting of data memory and ECC memory includes magnetic random access memory (MRAM).

[0248] In some aspects of the above memory system, at least one selected from a data memory and an ECC memory includes a memory cell including a magnetic tunnel junction (MTJ) and a memory cell having a bit error rate of 10 -12 Up to 10 -2 Compared with the memory cells therebetween, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0249] In some aspects of the above memory system, with a bit error rate of 10 -12 Up to 10 -2 Compared with memory cells between the two, the MJT has two selected from the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0250] In some aspects of the above memory systems, the data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

[0251] In some aspects of the above-mentioned memory system, the data scrubbing circuit or the host is configured to determine whether the data memory is protected, and the ECC memory is configured to: store ECC check bits based on the determination that the data memory is protected; and store operation data based on the determination that the data memory is not protected.

[0252] In some aspects of the above memory systems, the data memory and the ECC memory are included in different memory circuits.

[0253] In some aspects of the above memory systems, the data memory and the ECC memory are included in the same memory circuit.

[0254] In some aspects of the above memory systems, the memory system is electrically coupled to a host device.

[0255] In some aspects of the above memory system, the data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers and a MOS transistor having a width-to-length ratio between 1 and 200.

[0256] In some aspects of the above-mentioned memory system, the data scrubbing circuit is configured to: receive a data protection command for data; and for each data word in the data to be protected, respond to receiving the protection command: identify an address for a data codeword associated with the data word; determine whether the data word is in a data memory based on the address; respond to determining that the data word is in the data memory, read the data word from the data memory; respond to determining that the data word is not in the data memory: receive the data word; and write the data word to the data memory; perform an ECC encoding operation on the data word; generate a data codeword based on the ECC encoding operation; write the data codeword to the data memory at the address; generate an ECC check bit based on the ECC encoding operation; and write the generated ECC check bit to a corresponding partition in the ECC memory.

[0257] In some aspects of the above-mentioned memory system, the data scrubbing circuit is configured to: receive a scrubbing data command; for each data word to be scrubbed, respond to receiving the scrubbing data command: identify: the starting address of the data codeword and the corresponding ECC memory partition; read the data word associated with the starting address from the data memory; read the ECC check bits associated with the corresponding ECC memory partition from the ECC memory; perform an ECC decoding operation based on the data word and the ECC check bits; determine whether the data word includes an error based on the ECC decoding operation; respond to the determination that the data word includes an error, replace the error bit with a correctable bit in the data word, wherein the data word including the correctable bit is a scrubbed data word; respond to the determination that the data word does not include an error, abandon the replacement of the error bit with the correctable bit in the data word, wherein the data word is a scrubbed data word; determine whether the host requests a scrubbed data word; respond to the determination that the host requests the scrubbed data, output the scrubbed data word to a memory controller, which is electrically coupled to the host; respond to the determination that the host does not request the scrubbed data, abandon the output of the scrubbed data word to the memory controller.

[0258] In one aspect, a method of operating a memory system is disclosed, the memory system comprising: a data memory; an ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory. The method includes: in response to receiving a flush data command, using the data scrubbing circuit to correct errors in the data memory.

[0259] In some aspects of the above method, the codeword length used for error correction is longer than the word length used during normal access of the data memory.

[0260] In some aspects of the above method, the data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

[0261] In some aspects of the above method, the method further includes accessing the data storage while correcting errors in the data storage.

[0262] In some aspects of the above method, the method further includes using an environmental disturbance sensor to detect environmental conditions; and generating a flush data command based on the detected environmental conditions.

[0263] In some aspects of the above methods, the environmental condition includes at least one of temperature and a magnetic field.

[0264] In some aspects of the above method, the method further includes detecting changes in known data; and generating a flush data command based on the detection of the changes.

[0265] In some aspects of the above method, the method further includes tracking the elapsed time; determining whether the elapsed time is greater than a timing threshold, and generating a flush data command based on the determination that the elapsed time is greater than the timing threshold.

[0266] In some aspects of the above method, the ECC memory includes a plurality of partitions, and the data memory includes a plurality of memory address ranges, each partition corresponding to a memory address range in the data memory.

[0267] In some aspects of the above method, the ECC memory includes a partition having a plurality of ECC bits associated with a data scrubbing algorithm, and the method further includes using the ECC bits to perform an ECC encoding method.

[0268] In some aspects of the above method, the ECC memory includes a set of registers, wherein: each register corresponds to an ECC code word, each ECC code word corresponds to a segment in the data memory, and each register stores the state of the segment.

[0269] In some aspects of the above method, at least one selected from the group consisting of a data memory and an ECC memory comprises a magnetic random access memory (MRAM).

[0270] In some aspects of the above method, at least one selected from a data memory and an ECC memory includes a memory cell including a magnetic tunnel junction (MTJ) with a bit error rate of 10 -12 Up to 10 -2 Compared with the memory cells therebetween, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0271] In some aspects of the above method, the -12 Up to 10 -2 Compared with memory cells between the two, the MJT has two selected from the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

[0272] In some aspects of the above method, the data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

[0273] In some aspects of the above method, the method further includes determining whether the data memory is protected; based on the determination that the data memory is protected, storing ECC check bits in the ECC memory; and based on the determination that the data memory is not protected, storing the operation data in the ECC memory.

[0274] In some aspects of the above method, the data memory and the ECC memory are included in different memory circuits.

[0275] In some aspects of the above method, the data memory and the ECC memory are included in the same memory circuit.

[0276] In some aspects of the above methods, the memory system is electrically coupled to a host device.

[0277] In some aspects of the above method, the data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers and a MOS transistor having a width-to-length ratio between 1 and 200.

[0278] In some aspects of the above method, the method also includes: receiving a data protection command; for each data word in the data to be protected, responding to the received protection command: identifying the address of a data codeword associated with the data word; determining whether the data word is in a data storage device based on the address; responding to the determination that the data word is in the data storage device, reading the data word from the data storage device; responding to the determination that the data word is not in the data storage device: receiving the data word; writing the data word to the data storage device; performing an ECC encoding operation on the data word; generating a data codeword based on the ECC encoding operation; writing the data codeword to the data storage device at the address; generating an ECC check bit based on the ECC encoding operation; and writing the generated ECC check bit to the corresponding partition in the ECC storage device.

[0279] In some aspects of the above method, the method further includes: for each data word to be flushed, responding to receiving a flush data command: identifying: a starting address for a data codeword, and a corresponding ECC memory partition; reading a data word associated with the starting address from a data memory; reading an ECC check bit associated with the corresponding ECC memory partition from an ECC memory; performing an ECC decoding operation based on the data word and the ECC check bit; determining whether the data word includes an error based on the ECC decoding operation; responding to a determination that the data word includes an error, replacing the error bit with a correctable bit in the data word, wherein the data word including the correctable bit is a flushed data word; responding to a determination that the data word does not include an error, abandoning replacing the error bit with a correctable bit in the data word, wherein the data word is a flushed data word; determining whether the host requests a flushed data word; responding to a determination that the host requests flushed data, outputting the flushed data word to a memory controller, which is electrically coupled to the host; responding to a determination that the host does not request flushed data, abandoning outputting the flushed data word to the memory controller.

[0280] In some aspects of the above-mentioned memory system, the memory system is included in one selected from the following items: artificial intelligence edge computing (edge-AI) system, neural network-like system in data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0281] In one aspect, a memory system includes: a first memory circuit associated with a first bit error rate; and a second memory circuit associated with a second bit error rate, wherein the first bit error rate is greater than the second bit error rate; and a data word is stored in the first memory circuit and the second memory circuit, wherein: the data word includes a first partition associated with the first bit error rate and a second partition associated with the second bit error rate, the first partition of the data word is stored in the first memory circuit, and the second partition of the data word is stored in the second memory circuit.

[0282] In some aspects of the above-mentioned memory system, the memory system also includes a data scrubbing circuit, which is electrically coupled to the first memory circuit and the second memory circuit, wherein: the data scrubbing circuit controls the first memory circuit to reduce the first error rate to a third error rate; the data scrubbing circuit controls the second memory circuit to reduce the second error rate to a fourth error rate; and the reduction in the first bit error rate is greater than the reduction in the second bit error rate.

[0283] In some aspects of the above-mentioned memory system, the first memory circuit includes a first memory cell, which includes a first magnetic tunnel junction (MTJ) having a first size and a first MOS transistor having a first channel width-to-length (W / L) ratio; the second memory circuit includes a second memory cell, which includes a second MTJ having a second size and a second MOS transistor having a second W / L ratio, the first size is larger than the second size, and the first W / L ratio is larger than the second W / L ratio.

[0284] In some aspects of the above memory system, the first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

[0285] In some aspects of the above memory system, the second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

[0286] In some aspects of the above-mentioned memory system, the first memory circuit uses a first read voltage, a first sensing time and a first word line (WL) voltage, and the second memory circuit uses a second read voltage, a second sensing time and a second WL voltage, the first read voltage is greater than the second read voltage, the first sensing time is greater than the second sensing time, and the first WL voltage is greater than the second WL voltage.

[0287] In some aspects of the above-mentioned memory system, the first memory circuit uses a first write voltage, a first write time, and a first WL voltage, and the second memory circuit uses a second write voltage, a second write time, and a second WL voltage, the first write voltage is greater than the second write voltage, the first write time is greater than the second write time, and the first WL voltage is greater than the second WL voltage.

[0288] In some aspects of the above memory system, in a floating point format, the first partition includes a sign bit, an exponent bit, and a higher order portion of the mantissa bits.

[0289] In some aspects of the foregoing memory systems, in the integer format, the first partition includes a sign bit and higher order bits.

[0290] In some aspects of the foregoing memory system, in the floating point format, the second partition includes a lower order portion of the mantissa bits.

[0291] In some aspects of the foregoing memory system, in the integer format, the second partition includes lower order bits.

[0292] In one aspect, a method of operating a memory system is disclosed, the memory system including a first memory circuit and a second memory circuit, the method comprising: determining a first partition of data words to be stored in the memory system based on a first bit error rate; determining a second partition of data words to be stored in the memory system based on a second bit error rate, the first bit error rate being greater than the second bit error rate; storing the first partition of the data words in the first memory circuit; and storing the second partition of the data words in the second memory circuit, wherein: the first memory circuit is associated with the first bit error rate, and the second memory circuit is associated with the second bit error rate.

[0293] In some aspects of the above method, the method also includes controlling the first memory circuit to reduce the first error rate to a third error rate; and controlling the second memory circuit to reduce the second error rate to a fourth error rate, wherein the reduction in the first bit error rate is greater than the reduction in the second bit error rate.

[0294] In some aspects of the above method, the first memory circuit includes a first memory cell, which includes a first MTJ having a first size and a first MOS transistor having a first channel W / L ratio; the second memory circuit includes a second memory cell, which includes a second MTJ having a second size and a second MOS transistor having a second W / L ratio, the first size is larger than the second size, and the first W / L ratio is larger than the second W / L ratio.

[0295] In some aspects of the above method, the first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

[0296] In some aspects of the above method, the second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

[0297] In some aspects of the above method, the method also includes: using a first read voltage, a first sensing time, and a first WL voltage in a first memory circuit; and using a second read voltage, a second sensing time, and a second WL voltage in a second memory circuit, wherein: the first read voltage is greater than the second read voltage, the first sensing time is greater than the second sensing time, and the first WL voltage is greater than the second WL voltage.

[0298] In some aspects of the above method, the method also includes: using a first write voltage, a first write time, and a first WL voltage in a first memory circuit; and using a second write voltage, a second write time, and a second WL voltage in a second memory circuit, wherein: the first write voltage is greater than the second write voltage, the first write time is greater than the second write time, and the first WL voltage is greater than the second WL voltage.

[0299] In some aspects of the above method, in the floating point format, the first partition includes a sign bit, an exponent bit, and a higher order portion of the mantissa bits.

[0300] In some aspects of the above method, in the integer format, the first partition includes a sign bit and higher order bits.

[0301] In some aspects of the above method, in the floating point format, the second partition includes a lower order portion of the mantissa bits.

[0302] In some aspects of the above method, in the integer format, the second partition includes lower order bits.

[0303] In some aspects of the above-mentioned memory system, the memory system is included in one selected from the following items: artificial intelligence edge computing (edge-AI) system, neural network-like system in data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0304] In one aspect, a memory system includes: a data input; a multi-level cell (MLC) array; a write circuit electrically coupled to the MLC array and the data input; a Gray code to binary decoder circuit electrically coupled to the write circuit; a read circuit electrically coupled to the MLC array; a binary to Gray code encoder circuit electrically coupled to the read circuit and the data input; a memory circuit configured to store ECC check bits; an ECC encoder electrically coupled to the memory circuit and the binary to Gray code encoder circuit; an ECC decoder electrically coupled to the memory circuit and the Gray code to binary encoder circuit and configured to output recovered data; and a data scrubbing controller configured to control data recovery in the memory system.

[0305] In some aspects of the above memory systems, the MLC array includes memory cell circuits having more than two stable physical states.

[0306] In some aspects of the above-mentioned memory system, the memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive RAM (RRAM) cell.

[0307] In some aspects of the above memory system, the ECC encoder and decoder use one selected from the group consisting of: a Hamming code, a BCH code, a Reed-Solomon code, and a LDPC code.

[0308] In some aspects of the above memory systems, the memory circuit is located on a different integrated circuit from the MLC array.

[0309] In some aspects of the above memory systems, the memory circuits are located in predetermined partitions of the MLC array.

[0310] In some aspects of the above memory systems, the data scrubbing controller is configured to initiate a data scrubbing operation at predetermined intervals in response to detection of an environmental disturbance or in response to receiving a command from a host.

[0311] In one aspect, a method for data scrubbing of an MLC includes: reading data from the MLC, the data being represented by a binary code or an analog value; converting the data into a Gray code; reading corresponding check bit data from a memory circuit configured to store ECC check bits; calculating the location of a correctable error in the data in the Gray code form and correcting it; converting the corrected data into a binary code or a corrected analog value; and overwriting the corrected data onto the data in the MLC by a write circuit.

[0312] In some aspects of the above methods, the MLC array includes memory cell circuits having more than two stable physical states.

[0313] In some aspects of the above method, the memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive RAM (RRAM) cell.

[0314] In some aspects of the above method, the method further includes performing ECC encoding and decoding using one selected from the following items: Hamming code, BCH code, Reed-Solomon code, and LDPC code.

[0315] In some aspects of the above method, the memory circuit is located on a different integrated circuit than the MLC array.

[0316] In some aspects of the above method, the memory circuit is located in a predetermined partition of the MLC array.

[0317] In some aspects of the above method, the method further includes initiating a data scrubbing operation at a predetermined interval in response to detecting an environmental disturbance or in response to receiving a command from a host.

[0318] In some aspects of the above-mentioned memory system, the memory system is included in one of the following items: artificial intelligence edge computing (edge-AI) system, neural network system in data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

[0319] Although "electrically coupled" and "coupled" are used in the present invention to illustrate the electrical connection between two elements of the readout circuit, the electrical connection certainly does not necessarily need to be directly connected between the terminals of the components to be coupled together. Without departing from the scope of the present invention, different combinations and connections of the components can achieve constant current and adjustable bias voltage readout circuits. For example, the circuit is connected between the terminals of the components that are electrically coupled together. In another example, a closed (conductive) switch is connected between the terminals of the components that are coupled together. In yet another example, additional elements are connected between the terminals of the components that are coupled together without affecting the constant current characteristics of the circuit. For example, buffers, amplifiers, and passive circuit elements can be added without affecting the characteristics of the readout circuit and without departing from the scope of the present invention.

[0320] In some embodiments, two electrically coupled components may be topologically coupled. As used herein, two components are "topologically coupled" if they provide electrical influence to each other within a topology or within the same portion of a topology. For example, the reference sensor and the first current source of the disclosed readout circuit are electrically coupled on the same branch of the readout circuit.

[0321] Likewise, while "non-electrically coupled" is used in the present invention to describe a power cutoff between two components of a readout circuit, the power cutoff certainly does not necessarily require a substantial opening between the terminals of the components to be switched. Moreover, "non-coupled" is not limited to meaning that power transfer between two components is prevented. For example, a high impedance element is connected between the terminals of the non-coupled components. In another example, an open (non-conductive) switch is connected between the terminals of the disconnected components, effectively disconnecting the components.

[0322] Generally, the term "substantially" as used herein is used to describe that (multiple) elements or quantities ideally have a precise quality (e.g., fixed, identical, uniform, equal, similar, proportional), but actually have a quality that is functionally equivalent to the precise quality. For example, describing an element or quantity as being substantially fixed or uniform can deviate from the fixed or uniform value as long as the deviation is within the tolerance of the system (e.g., accuracy requirements, etc.). As another example, describing two elements or quantities as being substantially equal can be approximately equal as long as the difference is within the tolerance and does not functionally affect the operation of the system.

[0323] Likewise, although some elements or quantities are described in an absolute sense without the word "substantially", these elements and quantities can certainly have functionally equivalent qualities to the absolute description. For example, in some embodiments, a ratio is described as 1. However, of course, the ratio can be greater or less than 1, as long as the ratio is within the tolerance of the system (such as accuracy requirements, etc.).

[0324] As used herein, "substantially identical" sensors produce similar responses to a given stimulus. For example, for a given temperature change, "substantially identical" bolometers produce similar changes in resistance.

[0325] Although the disclosed embodiments have been fully described with reference to the accompanying drawings, it should be noted that various changes and modifications will be apparent to those skilled in the art. Such changes and modifications should be understood to be included in the disclosed embodiments within the scope defined by the appended claims.

[0326] The terms used in the description of the various embodiments described herein are only for the purpose of describing specific embodiments and are not intended to be used for limitation. The singular forms "one", "an" and "the" as used in the description of the various embodiments and the appended claims are intended to include multiple forms unless otherwise clearly indicated in the context. Moreover, the term "and / or" used in this article certainly refers to and covers any and all possible combinations of one or more of the listed associated items. It should be further understood that when the words "comprise", "comprises", "includes" and / or "includes" are used in this specification, the presence of the features, integers, steps, operations, elements and / or components is clearly indicated, but the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof is not excluded.

Claims

1. A memory system, It is characterized in that include: Data storage; ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory for data scrubbing with a codeword length longer than a word length used during normal access of the data memory; The entire ECC codeword is not used during normal access. During data scrubbing, all data words associated with the ECC code are read from the data memory, and the ECC check bits associated with the ECC codeword are read from the ECC memory, and data scrubbing is completed through the ECC check bits.

2. The memory system according to claim 1, It is characterized in that The data flushing circuit is configured to respond to receiving a flush data command to correct errors in the data storage.

3. The memory system according to claim 1, It is characterized in that The data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

4. The memory system according to claim 1, It is characterized in that The data scrubbing circuit is configured to correct errors in the data memory while accessing the data memory.

5. The memory system according to claim 1, It is characterized in that An environmental disturbance sensor is also included, configured to detect an environmental condition, and wherein the data flushing circuit generates a flush data command based on the detected environmental condition.

6. The memory system according to claim 5, It is characterized in that The environmental condition includes at least one of temperature and a magnetic field.

7. The memory system according to claim 1, It is characterized in that The data scrubbing circuit is configured to detect changes in known data and to generate a flush data command based on the detection of the changes.

8. The memory system according to claim 1, Features: The memory system further includes a timer circuit configured to: Tracking elapsed time; and It is determined whether the elapsed time is greater than a timing threshold, and a flush data command is generated based on the determination that the elapsed time is greater than the timing threshold.

9. The memory system according to claim 1, Features: The ECC memory includes multiple partitions, and The data memory includes a plurality of memory address ranges, and each partition corresponds to a memory address range in the data memory.

10. The memory system according to claim 1, Features: The ECC memory includes a partition having a plurality of ECC bits, and The number of ECC bits is based on the ECC encoding method associated with the data scrubbing algorithm.

11. The memory system according to claim 1, Features: The ECC memory includes a set of registers, including: Each register corresponds to an ECC code word. Each ECC codeword corresponds to a sector in the data memory, and Each register stores the status of the segment.

12. The memory system of claim 1, It is characterized in that At least one selected from the data memory and the ECC memory includes a magnetic random access memory (MRAM).

13. The memory system of claim 1, It is characterized in that At least one selected from a data memory and an ECC memory includes a memory cell including a magnetic tunnel junction (MTJ) and a memory cell having a bit error rate of less than 10 -12 Up to 10 -2 Compared with memory cells in the past, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

14. The memory system of claim 13, It is characterized in that With a bit error rate of 10 -12 Up to 10 -2 Compared with memory cells in the past, the MJT has two selected from the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

15. The memory system of claim 1, It is characterized in that The data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

16. The memory system of claim 1, Features: Data scrubbing circuitry or host configuration to determine whether data storage is protected, and The ECC memory is configured as: storing ECC check bits based on a determination that the data memory is protected; and Based on the determination that the data memory is not protected, it is used to store operation data.

17. The memory system of claim 1, It is characterized in that The data memory and the ECC memory are included in different memory circuits.

18. The memory system of claim 1, It is characterized in that The data memory and the ECC memory are included in the same memory circuit.

19. The memory system of claim 1, It is characterized in that The memory system is electrically coupled to the host device.

20. The memory system of claim 1, It is characterized in that The data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers and a MOS transistor having a width-to-length ratio between 1 and 200.

21. The memory system of claim 1, It is characterized in that The data scrubbing circuit system is configured to: receiving a protection command for the data; and For each data word in the data to be protected, respond to the received protection command: identifying an address of a data codeword associated with the data word; Determining whether the data word is in the data memory according to the address; In response to determining that the data word is in the data memory, reading the data word from the data memory; In response to a determination that the data word is not in data memory: receiving the data word; and writing the data word into the data memory; performing an ECC encoding operation on the data word; Generate a data codeword based on an ECC encoding operation; writing the data codeword into the data memory at the address; Generate ECC check bits based on the ECC encoding operation; and The generated ECC check bits are written into the corresponding partition in the ECC memory.

22. The memory system of claim 1, It is characterized in that The data scrubbing circuit is configured to: Receive data scrubbing commands; For each data word to be flushed, respond to receive flush data command: Identification: The starting address of the data codeword, and Corresponding ECC memory partition; reading a data word associated with a starting address from a data memory; reading ECC check bits associated with the corresponding ECC memory partition from the ECC memory; performing an ECC decoding operation based on the data word and the ECC check bits; Determining whether the data word includes an error based on an ECC decoding operation; In response to determining that the data word includes an error, replacing the error bit with a correctable error bit in the data word, including the data word after the data word having the correctable error bit is scrubbed; In response to determining that the data word does not include an error, abandoning replacing the error bit with a correctable error bit in the data word, wherein the data word is a scrubbed data word; Determine whether the host requests the flushed data word; In response to determining that the host requests the scrubbed data, outputting the scrubbed data word to a memory controller electrically coupled to the host; and In response to determining that the host has not requested the flushed data, outputting the flushed data word to the memory controller is aborted.

23. A method of operating a memory system, It is characterized in that The memory system includes: Data storage; ECC memory; and a data scrubbing circuit electrically coupled to the ECC memory and the data memory, The method includes: In response to receiving a flush data command, using a data flushing circuit to correct errors in the data memory, the codeword length used for data flushing being longer than the word length used during normal access to the data memory; The entire ECC codeword is not used during normal access. During data scrubbing, all data words associated with the ECC code are read from the data memory, and the ECC check bits associated with the ECC codeword are read from the ECC memory, and data scrubbing is completed through the ECC check bits.

24. The method of claim 23, It is characterized in that The data scrubbing circuit includes a data buffer, a data scrubbing controller, an ECC encoding circuit, and an ECC decoding circuit.

25. The method of claim 23, It is characterized in that This also includes accessing data storage while correcting errors in the data storage.

26. The method of claim 23, It is characterized in that Also includes: Using environmental disturbance sensors to detect environmental conditions; and A flush data command is generated based on the detected environmental conditions.

27. The method of claim 26, It is characterized in that The environmental condition includes at least one of temperature and a magnetic field.

28. The method of claim 23, It is characterized in that Also includes: Detect changes in known data; and Generate flush data commands based on detection of changes.

29. The method of claim 23, It is characterized in that Also includes: Track elapsed time; Determine whether the elapsed time is greater than the timing threshold, and A flush data command is generated based on a determination that the elapsed time is greater than a timing threshold.

30. The method of claim 23, Features: The ECC memory includes multiple partitions, and The data memory includes a plurality of memory address ranges, and each partition corresponds to a memory address range in the data memory.

31. The method of claim 23, It is characterized in that The ECC memory includes a partition having a plurality of ECC bits associated with a data scrubbing algorithm, and the method further includes using the ECC bits to perform an ECC encoding method.

32. The method of claim 23, Features: The ECC memory includes a set of registers, including: Each register corresponds to an ECC code word. Each ECC codeword corresponds to a sector in the data memory, and Each register stores the status of the segment.

33. The method of claim 23, It is characterized in that At least one selected from the data memory and the ECC memory includes a magnetic random access memory (MRAM).

34. The method of claim 23, It is characterized in that At least one selected from a data memory and an ECC memory includes a memory cell having a magnetic tunnel junction (MTJ) with a bit error rate of 10 -12 Up to 10 -2 Compared with the memory cells in the past, the present invention has one of the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

35. The method of claim 34, It is characterized in that With a bit error rate of 10 -12 Up to 10 -2 Compared with a memory cell in the past, the MTJ has two selected from the following characteristics: reduced size, reduced coercive field, reduced magnetic anisotropy, and reduced saturation magnetization.

36. The method of claim 23, It is characterized in that The data memory includes static random access memory (SRAM), dynamic random access memory (DRAM), or embedded DRAM (eDRAM).

37. The method of claim 23, It is characterized in that Also includes: Determine whether data storage is protected; Based on the determination that the data memory is protected, storing ECC check bits in the ECC memory; and Based on the determination that the data memory is not protected, the operation data is stored in the ECC memory.

38. The method of claim 23, It is characterized in that The data memory and the ECC memory are included in different memory circuits.

39. The method of claim 23, It is characterized in that The data memory and the ECC memory are included in the same memory circuit.

40. The method of claim 23, It is characterized in that The memory system is electrically coupled to the host device.

41. The method of claim 23, It is characterized in that The data memory and the ECC memory include a memory cell including an MTJ having a size between 20 nanometers and 200 nanometers and a MOS transistor having a width-to-length ratio between 1 and 200.

42. The method of claim 23, The characteristic is that include: receiving a protection command for the data; and For each data word in the data to be protected, respond to the received protection command: identifying an address of a data codeword associated with the data word; Determine whether the data word is in the data memory according to the address; In response to determining that the data word is in the data memory, reading the data word from the data memory; In response to a determination that the data word is not in data memory: receiving the data word; and writing the data word into the data memory; performing an ECC encoding operation on the data word; Generate a data codeword based on an ECC encoding operation; writing the data codeword into the data memory at the address; Generate ECC check bits based on the ECC encoding operation; and The generated ECC check bits are written into the corresponding partition in the ECC memory.

43. The method of claim 23, It is characterized in that Also includes: For each data word to be flushed, respond to receive flush data command: Identification: The starting address of the data codeword, and Corresponding ECC memory partition; reading a data word associated with a starting address from a data memory; reading ECC check bits associated with the corresponding ECC memory partition from the ECC memory; performing an ECC decoding operation based on the data word and the ECC check bits; Determining whether the data word includes an error based on an ECC decoding operation; In response to determining that the data word includes an error, replacing the error bit with a correctable error bit in the data word, wherein the data word including the correctable error bit is a scrubbed data word; In response to determining that the data word does not include an error, abandoning replacing the error bit with a correctable error bit in the data word, wherein the data word is a scrubbed data word; Determine whether the host requests the flushed data word; responsive to determining that the host requests the scrubbed data word, outputting the scrubbed data word to a memory controller electrically coupled to the host; and In response to determining that the host did not request the flushed data word, outputting the flushed data word to the memory controller is abandoned.

44. The memory system of any one of claims 1 to 22, It is characterized in that The memory system is included in one of the following items: artificial intelligence edge computing (edge-AI) systems, neural network systems in data centers, Internet of Things systems, automotive electronic systems, microcontroller systems, mobile communication systems, programmable computing systems, hardware security systems, telematics systems, biomedical electronic devices, robots, and drones.

45. A memory system, It is characterized in that include: a first memory circuit associated with a first bit error rate; a second memory circuit associated with a second bit error rate, wherein the first bit error rate is greater than the second bit error rate; a data scrubbing circuit electrically coupled to the first memory circuit and the second memory circuit; and A data word stored in a first memory circuit and a second memory circuit, wherein: The data word includes a first partition associated with a first bit error rate and a second partition associated with a second bit error rate, A first partition of the data word is stored in a first memory circuit, and A second partition of the data word is stored in a second memory circuit, wherein: The data scrubbing circuit controls the first memory circuit to reduce the first error rate to a third error rate, The data scrubbing circuit controls the second memory circuit to reduce the second error rate to a fourth error rate, The reduction in the first bit error rate is greater than the reduction in the second bit error rate.

46. ​​The memory system of claim 45, Features: The first memory circuit includes a first memory cell including a first magnetic tunnel junction (MTJ) having a first size and a first MOS transistor having a first channel width-to-length ratio (W / L). The second memory circuit includes a second memory cell including a second MTJ having a second size and a second MOS transistor having a second W / L ratio, The first dimension is greater than the second dimension, and The first W / L ratio is greater than the second W / L ratio.

47. The memory system of claim 45, It is characterized in that The first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

48. The memory system of claim 45, It is characterized in that The second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

49. The memory system of claim 45, Features: The first memory circuit uses a first read voltage, a first sensing time, and a first word line (WL) voltage, The second memory circuit uses a second read voltage, a second sensing time, and a second WL voltage, The first read voltage is greater than the second read voltage, The first sensing time is greater than the second sensing time, and The first WL voltage is greater than the second WL voltage.

50. The memory system of claim 45, Features: The first memory circuit uses a first write voltage, a first write time, and a first WL voltage, The second memory circuit uses a second write voltage, a second write time, and a second WL voltage, The first write voltage is greater than the second write voltage, The first write time is greater than the second write time, and The first WL voltage is greater than the second WL voltage.

51. The memory system of claim 45, It is characterized in that In floating point format, the first partition includes the sign bit, the exponent bits, and the higher order portion of the mantissa bits.

52. The memory system of claim 45, It is characterized in that In integer format, the first partition includes the sign bit and higher order bits.

53. The memory system of claim 45, It is characterized in that In floating point formats, the second partition includes the lower order portion of the mantissa bits.

54. The memory system of claim 45, It is characterized in that In integer format, the second partition includes the lower order bits.

55. A method of operating a memory system, the memory system comprising a first memory circuit and a second memory circuit, It is characterized in that The method includes: determining a first partition of data words to be stored in the memory system based on the first bit error rate; determining a second partition of the data word to be stored in the memory system based on the second bit error rate, the first bit error rate being greater than the second bit error rate; storing a first partition of the data word in a first memory circuit; and A second partition of the data word is stored in a second memory circuit, wherein: The first memory circuit is associated with a first bit error rate, and The second memory circuit is associated with a second bit error rate; controlling the first memory circuit to reduce the first error rate to a third error rate; and The second memory circuit is controlled to reduce the second error rate to a fourth error rate, wherein the reduction range of the first bit error rate is greater than the reduction range of the second bit error rate.

56. The method of claim 55, Features: The first memory circuit includes a first memory cell including a first MTJ having a first size and a first MOS transistor having a first channel W / L ratio, The second memory circuit includes a second memory cell including a second MTJ having a second size and a second MOS transistor having a second W / L ratio, The first dimension is greater than the second dimension, and The first W / L ratio is greater than the second W / L ratio.

57. The method of claim 55, It is characterized in that The first memory circuit includes a memory cell including an MTJ having a size between 40 nanometers and 200 nanometers and a MOS transistor having a W / L ratio between 2 and 200.

58. The method of claim 55, It is characterized in that The second memory circuit includes a memory cell including an MTJ having a size between 20 nanometers and 100 nanometers and a MOS transistor having a W / L ratio between 1 and 100.

59. The method of claim 55, It is characterized in that Also includes: In a first memory circuit, a first read voltage, a first sensing time, and a first WL voltage are used; and In the second memory circuit, a second read voltage, a second sensing time, and a second WL voltage are used, wherein: The first read voltage is greater than the second read voltage, The first sensing time is greater than the second sensing time, and The first WL voltage is greater than the second WL voltage.

60. The method of claim 55, It is characterized in that Also includes: In a first memory circuit, a first write voltage, a first write time, and a first WL voltage are used; and In the second memory circuit, a second write voltage, a second write time, and a second WL voltage are used, wherein: The first write voltage is greater than the second write voltage, The first write time is greater than the second write time, and The first WL voltage is greater than the second WL voltage.

61. The method of claim 55, It is characterized in that In floating point format, the first partition includes the sign bit, the exponent bits, and the higher order portion of the mantissa bits.

62. The method of claim 55, It is characterized in that In integer format, the first partition includes the sign bit and higher order bits.

63. The method of claim 55, It is characterized in that In floating point formats, the second partition includes the lower order portion of the mantissa bits.

64. The method of claim 55, It is characterized in that In integer format, the second partition includes the lower order bits.

65. The memory system of any one of claims 45 to 54, It is characterized in that The memory system is included in one of the following items: artificial intelligence edge computing (edge-AI) system, neural network system in data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.

66. A memory system, It is characterized in that include: Data entry; Multi-layer cell (MLC) arrays; a write circuit electrically coupled to the MLC array and the data input; a Gray code to binary decoder circuit electrically coupled to the write circuit; a readout circuit electrically coupled to the MLC array; a binary to Gray code encoder circuit electrically coupled to the readout circuit and the data input; a memory circuit configured to store ECC check bits; an ECC encoder electrically coupled to the memory circuit and the binary to Gray code encoder circuit; an ECC decoder electrically coupled to the memory circuit and the Gray code to binary encoder circuit and configured to output recovered data; and A data scrubbing controller is configured to control data recovery in a memory system.

67. The memory system of claim 66, It is characterized in that MLC arrays include memory cell circuits that have more than two stable physical states.

68. The memory system of claim 67, It is characterized in that The memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive random access memory (RRAM) cell.

69. The memory system of claim 66, It is characterized in that The ECC encoder and decoder use one selected from the following: Hamming code, BCH code, Reed-Solomon code, and LDPC code.

70. The memory system of claim 66, It is characterized in that The memory circuit and the MLC array are located on different integrated circuits.

71. The memory system of claim 66, It is characterized in that The memory circuits are located in predetermined partitions of the MLC array.

72. The memory system of claim 66, It is characterized in that The data scrubbing controller is configured to initiate data scrubbing operations at predetermined intervals in response to detection of an environmental disturbance or in response to receiving a command from a host.

73. A method for scrubbing data on a multi-layer storage cell (MLC), It is characterized in that include: Read data from the MLC, which is represented by binary code or analog value; and Convert data to Gray code; reading corresponding check bit data from a memory circuit configured to store ECC check bits; The operation can correct the location of errors in the data in the form of Gray code; Correction of correctable errors in data in Gray code form; converting the corrected data into binary code or corrected analog values; and The corrected data is rewritten onto the data in the MLC using a write circuit.

74. The method of claim 73, It is characterized in that MLC arrays include memory cell circuits that have more than two stable physical states.

75. The method of claim 74, It is characterized in that The memory cell circuit is selected from one of the following items: a floating gate FLASH cell organized as a NOR cell, a floating gate FLASH cell organized as a NAND cell, a charge trapping FLASH cell organized as a NOR cell, a charge trapping FLASH cell organized as a NAND cell, a phase change memory (PCM) cell, and a resistive random access memory (RRAM) cell.

76. The method of claim 73, It is characterized in that Also included is ECC encoding and decoding in one selected from the following: Hamming code, BCH code, Reed-Solomon code, and LDPC code.

77. The method of claim 73, It is characterized in that The memory circuit and the MLC array are located on different integrated circuits.

78. The method of claim 73, It is characterized in that The memory circuits are located in predetermined partitions of the MLC array.

79. The method of claim 73, It is characterized in that It also includes responding to the detection of environmental interference or responding to receiving a command from the host to initiate data scrubbing operations at predetermined intervals.

80. The memory system of any one of claims 66 to 72, It is characterized in that The memory system is included in one of the following items: artificial intelligence edge computing (Edge-AI) system, neural network system in data center, Internet of Things system, automotive electronic system, microcontroller system, mobile communication system, programmable computing system, hardware security system, telematics system, biomedical electronic device, robot, and drone.