Memory device and offset reference resistance compensation method thereof

By introducing a read offset compensator into the memory device, detecting and adjusting the reference resistance of the sense amplifier, the margin reduction problem caused by resistance mismatch in semiconductor memory read operation is solved, and the accuracy of data reading is improved and speed.

CN119068936APending Publication Date: 2024-12-03SAMSUNG ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410627365.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2023-06-01
Filing Date
2024-05-21
Publication Date
2024-12-03

AI Technical Summary

Technical Problem

In the read operation, the existing semiconductor memory has different resistance distributions due to the mismatch of MTJ resistors or sense amplifier resistors, resulting in a decrease in the read margin, affecting the accuracy and speed of data reading.

Method used

By introducing a read offset compensator into the memory device, the number of error bits of the output data is detected, and the reference resistance of the sense amplifier is calculated and adjusted to compensate for local resistance, improving the accuracy and speed of the read operation.

Benefits of technology

By compensating the reference resistance of the sense amplifier, the read margin is improved, the accuracy and speed of data reading are enhanced, and the performance of the memory is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119068936A_ABST
    Figure CN119068936A_ABST
Patent Text Reader

Abstract

A memory device and an offset reference resistance compensation method thereof are provided. The memory device includes: a memory cell array including memory cells; a row decoder; a column decoder; a sense amplifier reading data stored in the memory cell by detecting a difference between a source line voltage and a reference voltage during a read operation; and a control logic including a read offset compensator that receives the output data from the sense amplifier and performs an offset reference resistance compensation operation. The read offset compensator compares a number of error bits of the output data with a threshold value, performs an offset reference resistance compensation operation based on a result of the comparison, calculates a local resistance for compensating an offset reference resistance of the sense amplifier during the offset reference resistance compensation operation, and adjusting a reference resistance of the sense amplifier during the read operation based on the local resistance.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application claims the priority of Korean Patent Application No. 10-2023-0071125 filed in the Korean Intellectual Property Office on June 1, 2023, the contents of which are incorporated herein by reference in their entirety. Technical Field

[0002] Example embodiments consistent with the present disclosure relate to a semiconductor memory device, and more particularly, to a memory device including a read offset compensator and a method for compensating an offset reference resistance thereof. Background Art

[0003] Semiconductor memories can be mainly classified as volatile memories or nonvolatile memories. Volatile memories (e.g., DRAM or SRAM) have fast read and write speeds, but data stored in volatile memories disappear when the power is disconnected. In contrast, nonvolatile memories retain data even when the power is disconnected. Summary of the invention

[0004] One aspect provides a memory device capable of increasing a read margin through offset reference resistance compensation.

[0005] According to one aspect of one or more embodiments, a memory device is provided, the memory device comprising: a memory cell array comprising a plurality of memory cells; a row decoder connected to the memory cell array through a word line; a column decoder connected to the memory cell array through a bit line and a source line; a sense amplifier configured to read data stored in the memory cell by detecting a difference between a source line voltage and a reference voltage during a read operation; and control logic including a read offset compensator, the read offset compensator receiving output data from the sense amplifier and performing an offset reference resistance compensation operation, wherein the read offset compensator compares the number of erroneous bits of the output data with a threshold value, performs the offset reference resistance compensation operation based on a result of the comparison, calculates a local resistance of an offset reference resistance for compensating the sense amplifier during the offset reference resistance compensation operation, and adjusts the reference resistance of the sense amplifier based on the local resistance during the read operation.

[0006] According to an aspect of one or more embodiments, a read offset compensator of a memory device is provided, the read offset compensator comprising: an error detector configured to determine whether the number of error bits of output data input from a plurality of sense amplifiers of the memory device is greater than a threshold value, and output a compensation enable signal based on a result of the determination; an offset reference resistance generator configured to generate an offset reference resistance; and a plurality of sense amplifier offset compensators corresponding to the plurality of sense amplifiers, respectively, each of the plurality of sense amplifier offset compensators configured to receive output data from a corresponding sense amplifier of the plurality of sense amplifiers, compare the output data with expected data, and adjust an offset reference resistance of the sense amplifier based on a result of the comparison; wherein each of the plurality of sense amplifier offset compensators calculates a local resistance for compensating an offset reference resistance of a corresponding sense amplifier of the plurality of sense amplifiers during an offset reference resistance compensation operation, and adjusts the reference resistance of the corresponding sense amplifier of the plurality of sense amplifiers based on the local resistance during a read operation.

[0007] According to an aspect of one or more embodiments, a method for compensating for an offset reference resistance of a memory device is provided, the method comprising: writing the same data to a plurality of memory cells of the memory device; reading output data of a plurality of sense amplifiers; determining whether the number of error bits of the output data from the plurality of sense amplifiers is greater than a threshold value, and outputting a compensation enable signal based on the result of the determination; and calculating a local resistance of each of the plurality of sense amplifiers based on the compensation enable signal, and compensating for the offset reference resistance using the local resistance, wherein, during a read operation, the memory device adjusts a reference resistance based on the local resistance. BRIEF DESCRIPTION OF THE DRAWINGS

[0008] The above and other aspects of the present disclosure will become apparent by describing in detail embodiments of the present disclosure with reference to the attached drawings.

[0009] Figure 1 is a block diagram illustrating a storage device according to example embodiments.

[0010] Figure 2 is a diagram showing a method according to an example embodiment Figure 1 0026] Block diagram of a memory device of a storage device shown in FIG.

[0011] Figure 3 is a diagram showing a method according to an example embodiment Figure 1 A diagram of a memory block of a memory cell array of a memory device.

[0012] Figures 4 to 6 is used to describe the Figure 3Schematic diagram of a first memory cell of a memory block.

[0013] Figure 7 is a diagram showing a method according to an example embodiment Figure 2 A block diagram of a read offset compensator for a memory device shown in FIG.

[0014] Figure 8 is a diagram showing a method according to an example embodiment Figure 7 A block diagram of a first sense amplifier offset compensator of a read offset compensator is shown in FIG.

[0015] Fig. 9 is a diagram showing a method according to an example embodiment Figure 8 A circuit diagram of the decision logic of the first sense amplifier offset compensator is shown in FIG.

[0016] Fig.10 is used to explain the Fig. 9 Graph showing the logical operation results of the decision logic shown in .

[0017] Fig.11 and Fig.12 is a diagram showing a method according to an example embodiment Figure 8 A block diagram of an error detector of a first sense amplifier offset compensator is shown in FIG.

[0018] Figures 13 to 15 is a diagram showing some example embodiments Fig.12 The error detector shown in FIG. 1 is a circuit diagram and a graph of an example in which a 2-bit error is detected.

[0019] Fig.16 is a circuit diagram illustrating an example in which an error detector receives first to tenth output data according to example embodiments.

[0020] Fig.17 is a diagram showing a method according to an example embodiment Fig.16 0047 is a circuit diagram of an example of a third OR gate of the circuit diagram shown in .

[0021] Fig.18 is used to explain the Figure 8 Graph of the offset reference resistance generated by the offset reference resistance generator of the first sense amplifier offset compensator shown in FIG.

[0022] Fig.19 is a graph for explaining a read margin before and after compensating for an offset reference resistance according to example embodiments.

[0023] Fig. 20 is a flowchart illustrating an offset reference resistance compensation operation of a memory device according to example embodiments. DETAILED DESCRIPTION

[0024] Magnetoresistive random access memory (MRAM) may include a magnetic tunnel junction (MTJ). The magnetization direction of the MTJ may change according to the direction of a current applied to the MTJ. The resistance value of the MTJ may change according to the magnetization direction of the MTJ. MRAM may use these MTJ characteristics to store or read data.

[0025] The MRAM can perform a read operation by comparing the resistance value of the MTJ with a reference resistance Rref having an intermediate size between the resistance distribution R0 having data 0 and the resistance distribution R1 having data 1. However, due to mismatches such as mismatches of MTJ resistance or sense amplifier resistance, the resistance distribution of the MRAM may be different for each input / output terminal (I / O). There is a disadvantage in that if the resistance distribution of the MRAM changes, the read margin of the read operation may be reduced.

[0026] Hereinafter, various exemplary embodiments will be described in detail and clearly to such an extent that a person having ordinary skill in the art can easily implement the various exemplary embodiments.

[0027] Figure 1 1 is a block diagram showing a storage device according to an example embodiment. The storage device 1000 may be a flash memory device based on a flash memory. For example, the storage device 1000 may be implemented as a solid state drive (SSD), a universal flash memory (UFS), a memory card, etc.

[0028] Reference Figure 1 , the memory device 1000 may include a memory device 1100 and a memory controller 1200. The memory device 1100 may receive an input / output signal IO from the memory controller 1200 through an input / output line, receive a control signal CTRL through a control line, and receive an external power supply PWR through a power line. The memory device 1000 may store data in the memory device 1100 under the control of the memory controller 1200.

[0029] The memory device 1100 may include a memory cell array 1110 and a peripheral circuit 1115. The memory cell array 1110 may include a plurality of memory blocks BLK1 to BLKn (see Figure 2 ). Each memory block may have a vertical 3D structure. Each memory block may include a plurality of memory cells. Multi-bit data may be stored in each memory cell.

[0030] In terms of design layout structure, the memory cell array 1110 may be located near (eg, disposed on) or above the peripheral circuit 1115. The structure in which the memory cell array 1110 is located above the peripheral circuit 1115 may be referred to as a cell-on-periphery (COP) structure.

[0031] In an example embodiment, the memory cell array 1110 may be manufactured as a chip separate from the peripheral circuit 1115. An upper chip including the memory cell array 1110 and a lower chip including the peripheral circuit 1115 may be connected to each other by a bonding method. Such a structure may be referred to as a chip-to-chip (C2C) structure.

[0032] The peripheral circuit 1115 may include an analog circuit and / or a digital circuit required to store data in the memory cell array 1110 or read data stored in the memory cell array 1110. The peripheral circuit 1115 may receive external power PWR through a power line and generate various levels of internal power.

[0033] The peripheral circuit 1115 may receive a command, an address, and / or data from the memory controller 1200 through an input / output line. That is, the input / output signal IO may include a command, an address, and / or data. In some example embodiments, the peripheral circuit 1115 may store data in the memory cell array 1110 according to the control signal CTRL. In some example embodiments, the peripheral circuit 1115 may read the data stored in the memory cell array 1110 and provide the read data to the memory controller 1200.

[0034] The peripheral circuit 1115 may include a read offset compensator 2000. The read offset compensator 2000 may determine whether the number of error bits of the output data is greater than a threshold value, and perform an offset reference resistance compensation operation according to the determination result. The memory device 1100 may improve the read margin during a normal read operation through the offset reference resistance compensation operation. The read offset compensator 2000 will be described in more detail below.

[0035] Figure 2 is a more detailed illustration of the Figure 1 0046. Block diagram of a memory device 1100 shown in FIG. Figure 1 The memory device 1000 may be a resistive memory device based on a resistive memory. For example, the memory device 1100 may be an MRAM, a resistive random access memory (ReRAM), or a phase change random access memory (PRAM).

[0036] Reference Figure 1 and Figure 2 , the memory device 1100 may include a memory cell array 1110 and a peripheral circuit 1115. The peripheral circuit 1115 may include a row decoder 1120, a column decoder 1130, an input / output circuit 1140, a word line (WL) voltage generator 1150, and a control logic 1160.

[0037] The memory cell array 1110 may include a plurality of memory blocks BLK1 to BLKn. Each memory block may include a plurality of memory cells. Each memory cell may store multi-bit data. Each memory block (eg, BLK1) may be connected to a plurality of word lines WL1 to WLm.

[0038] The row decoder 1120 may be connected to the memory cell array 1110 through a plurality of word lines WL1 to WLm. The row decoder 1120 may select a word line during a program operation or a read operation. The row decoder 1120 may receive a word line voltage VWL from a word line voltage generator 1150 and provide the word line voltage VWL for a program operation or a read operation to a selected word line.

[0039] The column decoder 1130 may be connected to the memory cell array 1110 through source lines SL and / or bit lines BL. The column decoder 1130 may select the source lines SL and / or the bit lines BL in response to a selection signal provided from the control logic 1160. The column decoder 1130 may select the source lines SL and / or the bit lines BL using a plurality of N-channel metal oxide semiconductor (NMOS) transistors (not shown).

[0040] The input / output circuit 1140 may be internally connected to the column decoder 1130 through data lines, and externally connected to the memory controller 1200 through input / output lines IO1 to IOn (see Figure 1 ). The input / output circuit 1140 may receive program data from the memory controller 1200 during a program operation. The input / output circuit 1140 may provide data read from the memory cell array 1110 to the memory controller 1200 during a read operation.

[0041] The input / output circuit 1140 may include a sense amplifier (S / A) 1141 and a write driver (W / D) 1142. The input / output circuit 1140 may receive or output data from an input / output terminal. The number of input / output terminals may vary according to the type of the memory device 1000. The input / output circuit 1140 may provide data to the write driver 1142 in response to a control signal, or output data provided from the sense amplifier 1141 to the outside.

[0042] The sense amplifier (S / A) 1141 can read the data stored in the selected memory cell by sensing the difference between the voltage of the source line SL and the reference voltage Vref during the read operation. The reference voltage Vref can be provided by a reference voltage generator circuit (not shown). The sense amplifier 1141 can operate in response to a control signal provided from the control logic 1160.

[0043] Write driver (W / D) 1142 may receive a control signal from control logic 1160 and provide a programming current to the data line. The programming current may be used to program a selected memory cell to one of multiple states. During a multi-level cell programming operation, write driver 1142 may provide the programming current one or more times depending on the multiple states of the selected memory cell.

[0044] The word line (WL) voltage generator 1150 may receive internal power from the control logic 1160 and generate a word line voltage VWL required for reading or writing data. The word line voltage VWL may be provided to a selected word line WL through the row decoder 1120. The word line voltage generator 1150 may include a plurality of word line (WL) drivers 1151 to 115m.

[0045] Control logic 1160 may control read and / or write operations of memory device 1100 using command CMD, address ADDR, and control signal CTRL provided from memory controller 1200. Address ADDR may include a row address for selecting a memory block or a word line and a column address for selecting a memory cell.

[0046] The control logic 1160 may include a read offset compensator 2000. The read offset compensator 2000 may determine whether the number of error bits of the output data is greater than a threshold value, and perform an offset reference resistance compensation operation according to the determination result. The read offset compensator 2000 may compensate the reference resistance Rref by the amount of the local resistance. The local resistance may be calculated during the offset reference resistance compensation operation. According to example embodiments, the memory device 1100 may be calibrated to have a local resistance for compensating the offset reference resistance individually for each sense amplifier. Therefore, the memory device 1100 may improve the read margin during the read operation.

[0047] Figure 3 is a diagram showing a method according to an example embodiment Figure 1 1 is a diagram of a memory block BLK1 of a memory cell array 1110. Figures 4 to 6 is used to describe the Figure 3 Memory blocks BLK1 to BLKn each have a similar structure and function, and therefore, it will be understood that the description of BLK1 is also applicable to BLK2 to BLKn, and their repeated descriptions are omitted for the sake of brevity.

[0048] Reference Figures 3 to 6, the memory cell array 1100 may include a plurality of memory cells MC. Each of the plurality of memory cells MC may be an MRAM cell, and the plurality of memory cells may be connected to word lines WL1 to WLm, bit lines BL1 to BLn, and source lines SL1 to SLn. The plurality of memory cells MC each have a similar structure and function, so it will be understood that the description of the memory cell MC is also applicable to other memory cells in the plurality of memory cells MC, and for the sake of brevity, their repeated description is omitted.

[0049] For example, the memory cell MC may include an access transistor TR and a variable resistance element MTJ (e.g., a magnetic tunnel junction). The first end of the access transistor TR may be connected to the first source line SL1, the second end of the access transistor TR may be connected to the first end of the variable resistance element MTJ, and the gate of the access transistor TR may be connected to the first word line WL1. The second end of the variable resistance element MTJ may be connected to the first bit line BL1.

[0050] Data can be stored in each of the plurality of memory cells by adjusting the resistance value of the variable resistance element MTJ of each memory cell. Figure 4 and Figure 6 As shown in FIG, the variable resistance element MTJ may include a free layer FRL, a barrier layer BRL, and a fixed layer FXL. The barrier layer BRL may be disposed between the free layer FRL and the fixed layer FXL, the free layer FRL may be connected to the first bit line BL1, and the fixed layer FXL may be connected to the second end of the access transistor TR.

[0051] The magnetization direction of the fixed layer FXL may be fixed to a specific direction, and the magnetization direction of the free layer FRL may change according to a specific condition (eg, the direction of a write current). According to some example embodiments, the variable resistance element MTJ may further include an antiferromagnetic layer for fixing the magnetization direction of the fixed layer FXL.

[0052] The free layer FRL may include a material having a variable magnetization direction. The magnetization direction of the free layer FRL may be changed by an electric / magnetic factor provided from the outside and / or inside of the memory cell. The free layer FRL may include a ferromagnetic material containing at least one of cobalt (Co), iron (Fe) and nickel (Ni). For example, the free layer FRL may include at least one selected from FeB, Fe, Co, Ni, Gd, Dy, CoFe, NiFe, MnAs, MnBi, MnSb, CrO2, MnOFe2O3, FeOFe2O3, NiOFe2O3, CuOFe2O3, MgOFe2O3, EuO and Y3Fe5O12. However, the present disclosure is not limited to these examples.

[0053] The thickness of the barrier layer BRL may be less than the spin diffusion distance. The barrier layer BRL may include a non-magnetic material. For example, the barrier layer BRL may include at least one selected from the group of oxides of magnesium (Mg), titanium (Ti), aluminum (Al), magnesium-zinc (MgZn) and magnesium-boron (MgB), and nitrides of titanium (Ti) and vanadium (V). However, the present disclosure is not limited to these examples.

[0054] The fixed layer FXL may have a magnetization direction fixed by the antiferromagnetic layer. The fixed layer FXL may include a ferromagnetic material. For example, the fixed layer FXL may include at least one selected from the group of CoFeB, Fe, Co, Ni, Gd, Dy, CoFe, NiFe, MnAs, MnBi, MnSb, CrO2, MnOFe2O3, FeOFe2O3, NiOFe2O3, CuOFe2O3, MgOFe2O3, EuO, and Y3Fe5O12. According to some embodiments, the antiferromagnetic layer may include an antiferromagnetic material. For example, the antiferromagnetic layer may include at least one selected from the group of PtMn, IrMn, MnO, MnS, MnTe, MnF2, FeCl2, FeO, CoCl2, CoO, NiCl2, NiO, and Cr. However, the present disclosure is not limited to these examples.

[0055] like Figure 4 As shown in , the magnetization direction of the free layer FRL can be changed according to the direction of the write current WC1 or WC2 flowing through the variable resistance element MTJ. Figure 4 When the current flows in the direction from the first source line SL1 to the first bit line BL1, the magnetization direction of the free layer FRL may be opposite to the magnetization direction of the fixed layer FXL, which corresponds to an antiparallel state. Figure 4 In the second write current WC2 shown in FIG, when the current flows in a direction from the first bit line BL1 to the first source line SL1, the magnetization direction of the free layer FRL may be the same as the magnetization direction of the fixed layer FXL, which corresponds to a parallel state.

[0056] Refer to the more detailed description below Figure 5 , when the variable resistance element MTJ is in an anti-parallel state, the variable resistance element MTJ may have an anti-parallel resistance value R1 (also called a half-balanced resistance). When the variable resistance element MTJ is in a parallel state, the variable resistance element MTJ may have a parallel resistance value R0 (also called a balanced resistance). That is, data may be stored in the memory cell MC according to the resistance value of the variable resistance element MTJ, and the data stored in the memory cell MC may be read by determining the resistance value of the variable resistance element MTJ. Figure 5 In , the vertical axis represents probability and the horizontal axis represents resistance.

[0057] When the variable resistance element MTJ is in a semi-equilibrium state, the variable resistance element MTJ may have a Figure 5 The semi-balanced resistance R1 is shown in FIG. When the variable resistance element MTJ is in a balanced state, the variable resistance element MTJ may have a balanced resistance R0. The memory device 1100 may distinguish data 0 or data 1 using the size of the resistance value.

[0058] The memory device 1100 can perform a read operation by comparison with a reference resistance Rref having an intermediate level between data 0 and data 1. When the memory device 1100 is manufactured, the reference resistance Rref can be changed externally without using a fixed value. For example, the reference resistance can be determined by a test operation. Data can be stored in the memory cell MC according to the resistance value of the variable resistance element MTJ. Data stored in the memory cell MC can be read by reading the resistance value of the variable resistance element MTJ.

[0059] Reference Figure 6 , the access transistor TR may include a body substrate 111, a gate electrode 112, and junctions 113 and 114. The junction 113 may be formed on the body substrate 111 and may be connected to the first source line SL1. The junction 114 may be formed on the body substrate 111 and may be connected to the first bit line BL1 through the MTJ element. The gate electrode 112 may be formed on the body substrate 111 between the junction 113 and the junction 114 and may be connected to the first word line WL1.

[0060] Figure 7 is a diagram showing a method according to an example embodiment Figure 2 A block diagram of an example of a read offset compensator 2000 is shown in FIG. Figure 7 , the read offset compensator 2000 may include an error detector 2001, an offset reference resistor (Rref) generator 2002, and a first sense amplifier (S / A) offset compensator to an Nth sense amplifier (S / A) offset compensator (e.g., S / A offset compensator 1 to S / A offset compensator N).

[0061] The read offset compensator 2000 may provide the first reference voltage Vref1 to the nth reference voltage Vrefn to the first sense amplifier S / A respectively. (i=1 to n). The read offset compensator 2000 can be configured to have a first sense amplifier to an nth sense amplifier S / A, respectively. (i=1 to n) receives the first output data to the nth output data DOUT (i=1 to n), and adjust the first reference voltage Vref1 to the nth reference voltage Vrefn. In some example embodiments, the first sense amplifier S / A <1> To nth sense amplifier S / A <n>can be connected to the first source line SL <1> To the nth source line SL <n>.

[0062] The error detector 2001 can be respectively connected from the first sense amplifier to the nth sense amplifier S / A (i=1 to n) receives the first output data to the nth output data DOUT (i=1 to n), and generates a compensation enable signal CMP_EN. The compensation enable signal CMP_EN may be provided to the first sense amplifier offset compensator to the nth sense amplifier offset compensator. When the number of error bits of the output data is greater than a threshold value, the error detector 2001 may activate the compensation enable signal CMP_EN. For example, when the number of error bits of the output data is 2 or more, the error detector 2001 may activate the compensation enable signal CMP_EN to a high level.

[0063] The offset reference resistor generator 2002 may generate an offset reference resistor Offset_Rref. When the memory device 1100 is manufactured, the offset reference resistor Offset_Rref may be changed externally without using a fixed value. The offset reference resistor Offset_Rref may be determined through a test operation. The offset reference resistor generator 2002 may provide the offset reference resistor Offset_Rref to the first sense amplifier offset compensator to the Nth sense amplifier offset compensator.

[0064] The first sense amplifier (S / A) offset compensator (S / A offset compensator 1) 2100 can be configured to generate a first sense amplifier (S / A) offset compensator 2101 from the first sense amplifier (S / A) offset compensator 2102. <1> Receive the first output data DOUT <1> In response to the compensation enable signal CMP_EN of the error detector 2001, the first sense amplifier offset compensator 2100 may generate the first output data DOUT <1> With the expected data EXP_DATA (see Fig. 9 ) for comparison. The expected data EXP_DATA may be stored in the first sense amplifier offset compensator 2100. The first sense amplifier offset compensator 2100 may increase or decrease the count value according to the comparison result. The first sense amplifier offset compensator 2100 may adjust the offset reference resistance (Offset_Rref). For example, the first sense amplifier offset compensator 2100 may use the count value to adjust the offset reference resistance.

[0065] The second sense amplifier (S / A) offset compensator (S / A offset compensator 2) 2200 can be configured to receive the second sense amplifier S / A <2> Receive the second output data DOUT <2> , to increase or decrease the count value in response to the compensation enable signal CMP_EN. The second sense amplifier offset compensator 2200 can adjust the second reference voltage Vref2 by adjusting the offset reference resistor (Offset_Rref) using the count value. The Nth sense amplifier (S / A) offset compensator (S / A offset compensator N) can adjust the second reference voltage Vref2 from the nth sense amplifier S / A <n>Receive nth output data DOUT <n>and adjusts the nth reference voltage Vrefn by adjusting the offset reference resistor (Offset_Rref).

[0066] Figure 8 is a diagram showing a method according to an example embodiment Figure 7 A block diagram of an example of a first sense amplifier (S / A) offset compensator (S / A offset compensator 1) 2100 is shown in FIG. Figure 8 , the first sense amplifier (S / A) offset compensator (S / A offset compensator 1) 2100 may include a decision logic 2110, an up / down counter 2120, an adder 2130 and an offset reference resistor (Rref) adjuster 2140.

[0067] The first sense amplifier (S / A) offset compensator (S / A offset compensator 1) 2100 can be configured to generate a first sense amplifier (S / A) offset compensator 2101 from the first sense amplifier (S / A) offset compensator 2102. <1> Receive the first output data DOUT <1> The first sense amplifier offset compensator 2100 may increase or decrease the count value in response to the compensation enable signal CMP_EN. The first sense amplifier offset compensator 2100 may adjust the first reference voltage Vref1 by adjusting the offset reference resistor (Offset_Rref) using the count value. In some example embodiments, the first sense amplifier S / A <1> The first source line SL <1> Receives a first source line voltage VSL1.

[0068] The decision logic 2110 can be obtained from the first sense amplifier S / A <1> Receive the first output data DOUT <1> The decision logic 2110 may respond to the compensation enable signal CMP_EN of the error detector 2001 and convert the first output data DOUT <1> EXP_DATA (see Fig. 9 ) is compared and a count increase signal CNT_INC is generated. The count increase signal CNT_INC may be provided to the up / down counter 2120.

[0069] The up / down counter 2120 may receive a count increase signal CNT_INC from the decision logic 2110 and generate an up count signal CNT_UP or a down count signal CNT_DN. The up count signal CNT_UP is a signal for increasing the offset reference resistor Offset_Rref by the local resistance Lref. The local resistance Lref may be predetermined. The down count signal CNT_DN is a signal for reducing the offset reference resistor Offset_Rref by the local resistance Lref.

[0070] The adder 2130 may receive an offset reference resistance Offset_Rref from the offset reference resistance (Rref) generator 2002. The adder 2130 may receive an up-count signal CNT_UP from the up / down counter 2120 and generate a reference resistance increase signal for increasing the offset reference resistance Offset_Rref by the local resistance Lref. The adder 2130 may receive a down-count signal from the up / down counter 2120 and generate a reference resistance decrease signal for decreasing the offset reference resistance Offset_Rref by the local resistance Lref.

[0071] The offset reference resistance (Rref) adjuster 2140 may receive a reference resistance increase signal or a reference resistance decrease signal from the adder 2130 and adjust the offset reference resistance (Offest_Rref). For example, in some example embodiments, the offset reference resistance (Rref) adjuster 2140 may receive the offset reference resistance (Offest_Rref) from the adder 2130. In some example embodiments, the offset reference resistance (Rref) adjuster 2140 may directly receive the offset reference resistance (Offest_Rref) from the offset reference resistance (Rref) generator 2002. The offset reference resistance adjuster 2140 may control (or generate) the first reference voltage Vref1 by adjusting the offset reference resistance (Offset_Rref). The first reference voltage Vref1 may be provided to the first sense amplifier S / A <1> .

[0072] Fig. 9 is a diagram showing a method according to an example embodiment Figure 8 An example circuit diagram of the decision logic 2110 is shown in FIG. Fig. 9 , the decision logic 2110 can perform exclusive OR (XOR) logic operations and AND (AND) logic operations.

[0073] For example, the decision logic 2110 may include an XOR gate and an AND gate. The XOR gate may receive the first output data DOUT <1> The AND gate can receive the output signal of the XOR gate and the compensation enable signal CMP_EN and perform an AND logic operation. The AND gate can output a count increase signal CNT_INC.

[0074] Fig.10 is used to explain the Fig. 9 2110 is a diagram showing the logical operation result of the decision logic 2110 shown in FIG. Fig.10 When the compensation enable signal CMP_EN is logic 0, regardless of the output data DOUT Regardless of the logic value of the expected data EXP_DATA, the count increase signal CNT_INC is always logic 0.

[0075] When the compensation enable signal CMP_EN is logic 1, the output data DOUT and the logic value of the expected data EXP_DATA, the count increase signal CNT_INC is logic 0 or logic 1. For example, if the output data DOUT The count increase signal CNT_INC is logic 0. If the output data DOUT If the logic value of the expected data EXP_DATA is different, the count increase signal CNT_INC is logic 1.

[0076] exist Figure 8 In the example, the decision logic 2110 may receive the first output data DOUT <1> And the first output data DOUT <1> is compared with the expected data EXP_DATA. When the compensation enable signal CMP_EN is activated, if the first output data DOUT <1> If the data EXP_DATA is different from the expected data EXP_DATA, the decision logic 2110 may generate a count increase signal CNT_INC.

[0077] Fig.11 and Fig.12 is a diagram showing some example embodiments Figure 8 A block diagram of the error detector 2001 is shown in FIG. Fig.11 and Fig.12 An example is shown in which the error detector 2001 according to some example embodiments is a 2-bit error detector. The error detector 2001 may receive the first output data to the n-th output data and detect whether there is an error of 2 or more bits. When an error of 2 or more bits is detected, the error detector 2001 may activate the compensation enable signal CMP_EN.

[0078] Reference Fig.11 , the first output data DOUT <1> All the second to n-th output data “pass”. Since no 2-bit or more error is detected, the error detector 2001 does not activate the compensation enable signal CMP_EN. That is, the compensation enable signal CMP_EN has logic 0.

[0079] Reference Fig.12 , the first output data DOUT <1> And the second output data DOUT <2> The third output data to the nth output data are “passed”. Since 2 bits or more of errors are detected, the error detector 2001 may activate the compensation enable signal CMP_EN. That is, the compensation enable signal CMP_EN has logic 1.

[0080] Figures 13 to 15 12 according to some example embodiments, the error detector 2001 may receive the first output data to the nth output data and generate a compensation enable signal CMP_EN. This example assumes that data 0 is stored in all memory cells and that the expected data EXP_DATA is 0.

[0081] The error detector 2001 may include a first full adder (full adder 1), a second full adder (full adder 2), and an OR gate. The first full adder (full adder 1) may receive the first output data DOUT through the carry input terminal Cin. <1> and receives the second output data DOUT through the data input terminal <2> and the third output data DOUT <3> The first full adder can convert the first output data DOUT <1> , the second output data DOUT <2> and the third output data DOUT <3> The sum of the first and second full adders is provided to the carry input terminal Cin of the second full adder. The first full adder can provide the carry value to the OR gate through the carry output terminal Cout.

[0082] The second full adder (full adder 2) can receive the fourth output data DOUT through the data input terminal <4> and the fifth output data DOUT <5> The second full adder can calculate the output of the first full adder, the fourth output data DOUT <4> and the fifth output data DOUT <5> The second full adder can provide the carry value to the OR gate through the carry output terminal Cout.

[0083] Fig.13 The first output data DOUT is shown <1> And the second output data DOUT <2> Example of "failure". Fig.13 and Fig.14 , when the first output data DOUT <1> And the second output data DOUT <2> is 1 and the third output data DOUT <3> When is 0, the first full adder may output data 1 through the carry output terminal Cout. The data sum SUM of the first full adder is data 0 and may be provided to the carry input terminal Cin of the second full adder.

[0084] When the fourth output data DOUT <4> and the fifth output data DOUT <5> When each is 0 and data 0 is received through the carry input terminal Cin, the data sum SUM of the second full adder is data 0. The second full adder can output data 0 through the carry output terminal Cout. The OR gate can receive data 1 from the first full adder and data 0 from the second full adder, and activate the compensation enable signal CMP_EN.

[0085] Fig.15 The first output data DOUT is shown <1> and the fifth output data DOUT <5> Example of "failure". Fig.15 , when the first output data DOUT <1> is 1 and the second output data DOUT <2> and the third output data DOUT <3> When is 0, the first full adder may output data 0 through the carry output terminal Cout. The data sum SUM of the first full adder is data 1 and may be provided to the carry input terminal Cin of the second full adder.

[0086] When the fourth output data DOUT <4> is 0, the fifth output data DOUT <5> is 1, and data 1 is received through the carry input terminal Cin, the data sum SUM of the second full adder is data 0. The second full adder can output data 1 through the carry output terminal Cout. The OR gate can receive data 0 from the first full adder and data 1 from the second full adder, and activate the compensation enable signal CMP_EN.

[0087] When at least two of the first to n-th output data are different from the expected data EXP_DATA, Fig.12 The error detector 2001 shown in FIG. 2 may activate the compensation enable signal CMP_EN.

[0088] Fig.16 is a diagram showing a method according to an example embodiment Figure 8 The circuit diagram of an example in which the error detector 2001 receives the first output data to the tenth output data is shown in FIG. Fig.16 , the error detector 2001 may include a first error detector 210, a second error detector 220, and a third error detector 230. The first error detector 210 and the second error detector 220 may be as follows Figures 13 to 15 2-bit errors are detected as described in .

[0089] The first error detector 210 may include a first full adder (full adder 1) and a second full adder (full adder 2) and a first OR gate OR1. The first full adder (full adder 1) may receive the first output data D1 through a carry input terminal, and receive the second output data D2 and the third output data D3 through a data input terminal. The first full adder may output a first carry Cout1 through a carry output terminal, and output a first sum SUM1 through a data output terminal.

[0090] The second full adder (full adder 2) can receive the first sum SUM1 through the carry input terminal, and receive the fourth output data D4 and the fifth output data D5 through the data input terminal. The second full adder can output the second carry Cout2 through the carry output terminal, and output the second sum SUM2 through the data output terminal. The first OR gate OR1 can receive the first carry Cout1 and the second carry Cout2, and output the first error detection signal S <1> .

[0091] The second error detector 220 may include a third full adder (full adder 3) and a fourth full adder (full adder 4) and a second OR gate OR2. The third full adder (full adder 3) may receive the sixth output data D6 through a carry input terminal, and receive the seventh output data D7 and the eighth output data D8 through a data input terminal. The third full adder may output a third carry Cout3 through a carry output terminal, and output a third sum SUM3 through a data output terminal.

[0092] The fourth full adder (full adder 4) can receive the third sum SUM3 through the carry input terminal, and receive the ninth output data D9 and the tenth output data D10 through the data input terminal. The fourth full adder can output the fourth carry Cout4 through the carry output terminal, and output the fourth sum SUM4 through the data output terminal. The second OR gate OR2 can receive the third carry Cout3 and the fourth carry Cout4, and output the second error detection signal S <2> .

[0093] The third error detector 230 may include a fifth full adder (full adder 5) and a third OR gate OR3. The fifth full adder (full adder 5) may receive the second sum SUM2 of the first error detector 210 through a data input terminal, and receive the fourth sum SUM4 of the second error detector 220 through a carry input terminal. The fifth full adder may output a fifth carry Cout5 through a carry output terminal, and output the fifth sum SUM5 through a data output terminal. The fifth carry Cout5 may be used as a third error detection signal S <3> The third OR gate OR3 can receive the first error detection signal to the third error detection signal S <1> , S <2> and S <3> , and outputs the compensation enable signal CMP_EN.

[0094] When at least two error bits are detected among the first to fifth data D1 to D5, Fig.16 The error detector 2001 shown in FIG. 2 may activate the first error detection signal S <1> When at least two error bits are detected among the sixth to tenth data D6 to D10, the second error detection signal S may be activated. <2> .

[0095] One error bit may be detected among the first to fifth data D1 to D5, and one error bit may be detected among the sixth to tenth data D6 to D10. Fig.16 In the example embodiment shown in FIG. 1 , the error detector 2001 may activate the third error detection signal S <3> When at least two error bits are detected among the first data D1 to the tenth data D10, Fig.16 The error detector 2001 shown in FIG. 2 may activate the compensation enable signal CMP_EN.

[0096] Fig.17 is a diagram showing a method according to an example embodiment Fig.16 The third error detector 230 may include a compensation enable signal generator 231 configured with dynamic logic instead of the third OR gate OR3.

[0097] Reference Fig.17 , the compensation enable signal generator 231 may include a first P-channel metal oxide semiconductor (PMOS) transistor PM1, a first NMOS transistor NM1, a second NMOS transistor NM2, a third NMOS transistor NM3, a first inverter INV1, a second inverter INV2, and a third inverter INV3. The first PMOS transistor PM1 is connected between the power supply terminal and the sensing node SENS, and may be controlled by a precharge signal PRCH provided from the control logic 1160. The first NMOS transistor NM1 to the third NMOS transistor NM3 are connected in parallel between the sensing node SENS and the ground terminal, and may be respectively controlled by the first error detection signal S to the third error detection signal S. <1> , S <2> and S <3> control.

[0098] The first inverter INV1 and the second inverter INV2 may be connected to the sensing node SENS, and the third inverter INV3 may be connected between the sensing node SENS and the output terminal. The compensation enable signal generator 231 may output the compensation enable signal CMP_EN through the output terminal. When any one of the first to third error detection signals is activated, the sensing node SENS may be discharged through the ground terminal. Therefore, the compensation enable signal generator 231 may activate the compensation enable signal CMP_EN.

[0099] exist Fig.16 In the embodiment, when the number of the first error detector 210 and the second error detector 220 increases, the size of the third OR gate OR3 may increase. Fig.17 The compensation enable signal generator 231 shown in FIG. 1 may receive the first to third error detection signals using NMOS transistors, and thus the chip size may be reduced.

[0100] Fig.18 is used to explain the Figure 8 FIG. 2 is a graph of an offset reference resistance (Rref) generated by the offset reference resistance generator 2002. Figure 8 and Fig.18 , the offset reference resistor Offset_Rref is different from the general reference resistor Rref used to distinguish data 0 from data 1 during a read operation (see Figure 5 ). The offset reference resistor Offset_Rref is a resistor used to adjust the resistance distribution of the memory device 1100, such as Fig.18 As shown in , the resistance distribution of the memory device 1100 is changed due to the mismatch between the MTJ resistance, Rref, and the S / A resistance. Fig.18 , the vertical axis represents probability, and the horizontal axis represents resistance.

[0101] The up-count signal is a signal for increasing the offset reference resistance Offset_Rref by the local resistance Lref. The local resistance Lref may be predetermined. The down-count signal is a signal for reducing the offset reference resistance Offset_Rref by the local resistance Lref. The offset reference resistance Offset_Rref may be increased by an integer multiple of the local resistance Lref according to the up-count signal.

[0102] When the resistance distribution moves from R0' to R1', the offset reference resistance Offset_Rref may increase by Lref1. When the resistance distribution moves from R0' to R2', the offset reference resistance Offset_Rref may increase by Lref2.

[0103] Fig.19 is a graph for explaining a read margin before and after compensating for an offset reference resistance according to example embodiments. Fig.19 In the figure, M1 is the reading margin before compensating the offset reference resistor, and M2 is the reading margin after compensating the offset reference resistor. Fig.19 , after compensating the offset reference resistor, the reading margin can be improved by M2-M1. Fig.19 , the vertical axis represents probability, and the horizontal axis represents resistance.

[0104] During a read operation, the memory device 1100 may perform a read operation on Data 0 and Data 1 centered around the reference resistance Rref. If the resistance distribution changes from Rp to Rp+ due to a mismatch of MTJ resistance or S / A resistance, the read margin of the memory device 1100 may be reduced to M1.

[0105] The memory device 1100 may compensate the reference resistance Rref by the local resistance Lref1 calculated during the offset reference resistance compensation operation described above. Therefore, the reference resistance is changed from Rref to Rref+Lref1, and Rap is changed to Rap+. Since the memory device 1100 is individually calibrated to have a local resistance for each sense amplifier, it may have a read margin of M2 during a read operation.

[0106] Fig. 20 is a flow chart illustrating an offset reference resistance compensation operation of a memory device according to example embodiments. Fig. 20 , the memory device 1100 may write the same data into all memory cells (S110). For example, the memory device 1100 may write data 0 into all memory cells.

[0107] The memory device 1100 may perform a read operation on all memory cells (S120). The memory device 1100 may read the output data DOUT <n:1>The memory device 1100 may detect an error bit of the output data (S130). The expected data may be 0. During a read operation, when the output data is not 0, the memory device 1100 may be considered as "failed".

[0108] The memory device 1100 may determine whether the number of error bits of the output data is greater than a threshold value (S140). When the number of error bits of the output data is greater than the threshold value, the error detector 2001 may activate the compensation enable signal CMP_EN. For example, when the number of error bits of the output data is 2 or greater, the error detector 2001 may activate the compensation enable signal CMP_EN to a high level.

[0109] When the number of error bits of the output data is greater than the threshold value (S140, Yes), the memory device 1100 may compensate the offset reference resistance (S150). Each sense amplifier offset compensator (eg, 2100) may generate a sense amplifier offset from the first sense amplifier S / A <1> Receive the first output data DOUT <1> In response to the compensation enable signal CMP_EN of the error detector 2001, the first sense amplifier offset compensator 2100 may generate the first output data DOUT <1> The first sense amplifier offset compensator 2100 may increase the count value according to the comparison result. The first sense amplifier offset compensator 2100 may compensate the offset reference resistance using the count value. The first sense amplifier offset compensator 2100 may adjust the first reference voltage Vref1 by compensating the offset reference resistance.

[0110] The memory device 1100 may determine whether the output data is the final output data (S160). If the output data is the final output data, the operation ends. If the output data is not the final output data, an offset reference resistance compensation operation may be performed on the next output data (S145). In step S140, if the number of error bits is less than or equal to the threshold value (S140, no), the memory device 1100 may perform an offset reference resistance compensation operation on the next output data.

[0111] According to various example embodiments, a memory device may write the same data to all memory cells, read the output data, determine whether the number of error bits is greater than a threshold value, and perform an offset reference resistance compensation operation according to the determination result. The read margin during the read operation may be improved by the offset reference resistance compensation operation. Although various example embodiments have been described with reference to the accompanying drawings, it will be apparent to those skilled in the art that various changes and modifications may be made thereto without departing from the spirit and scope of the present disclosure as set forth in the appended claims. < / n> < / n> < / n> < / n>

Claims

1. A memory device, include: a memory cell array comprising a plurality of memory cells; a row decoder connected to the memory cell array via word lines; a column decoder connected to the memory cell array via bit lines and source lines; a sense amplifier configured to read data stored in the memory cell by detecting a difference between a source line voltage and a reference voltage during a read operation; as well as control logic including a read offset compensator that receives output data from the sense amplifier and performs an offset reference resistance compensation operation, The read offset compensator compares the number of error bits of the output data with a threshold value and performs an offset reference resistance compensation operation based on the result of the comparison, wherein during the offset reference resistance compensation operation, the read offset compensator calculates a local resistance of an offset reference resistance for compensating a sense amplifier and adjusts a reference resistance of the sense amplifier during a read operation based on the local resistance.

2. The memory device according to claim 1, in, The read offset compensator includes: an error detector configured to determine whether the number of error bits of the output data from the sense amplifier is greater than a threshold value, and output a compensation enable signal based on a result of the determination; a decision logic configured to compare output data of the sense amplifier with expected data based on the compensation enable signal and to generate a count increase signal when the output data is different from the expected data; and An up / down counter is configured to generate an up-count signal based on the count-up signal.

3. The memory device according to claim 2, in, The read offset compensator also includes: an offset reference resistance generator configured to generate an offset reference resistance; an adder configured to receive the up-count signal and generate a reference resistance increasing signal for increasing the offset reference resistance by the local resistance in response to the up-count signal; and The offset reference resistance adjuster is configured to receive the reference resistance increase signal from the adder and adjust the offset reference resistance.

4. The memory device according to claim 3, in, The offset reference resistor adjuster adjusts the offset reference resistor to generate an adjusted reference voltage and provides the adjusted reference voltage to the sense amplifier.

5. The memory device according to claim 1, in, The plurality of memory cells of the memory cell array are written with the same data before the offset reference resistance compensation operation.

6. The memory device according to claim 1, in, The sense amplifier includes a plurality of sense amplifiers; and Wherein, the read offset compensator comprises: an error detector configured to determine whether the number of error bits of the output data from the plurality of sense amplifiers is greater than a threshold value, and output a compensation enable signal based on a result of the determination; an offset reference resistance generator configured to generate an offset reference resistance for each of the plurality of sense amplifiers; and A plurality of sense amplifier offset compensators respectively correspond to the plurality of sense amplifiers, each of the plurality of sense amplifier offset compensators being configured to: receive output data from a corresponding sense amplifier of the plurality of sense amplifiers, compare the output data with expected data, and adjust an offset reference resistance of the sense amplifier based on a result of the comparison.

7. The memory device according to claim 6, in, Each of the plurality of sense amplifier offset compensators comprises: a decision logic configured to compare the output data with expected data based on the compensation enable signal and generate a count increase signal when the output data is different from the expected data; an up / down counter configured to generate an up-count signal based on the count-increase signal; an adder configured to: receive the up-count signal and the offset reference resistance, and generate a reference resistance increase signal for increasing the offset reference resistance by a local resistance of the sense amplifier corresponding to the sense amplifier offset compensator in response to the up-count signal; and The offset reference resistance adjuster is configured to receive the reference resistance increase signal from the adder and adjust the offset reference resistance based on the reference resistance increase signal.

8. The memory device according to claim 7, in, The offset reference resistance adjuster adjusts the offset reference resistance to generate an adjusted reference voltage of the sense amplifier corresponding to the sense amplifier offset compensator, and provides the adjusted reference voltage to the sense amplifier.

9. The memory device according to claim 7, in, The decision logic includes: a first logic gate configured to receive the output data and the expected data and perform an XOR operation on the received output data and the expected data; and The second logic gate is configured to receive the compensation enable signal and the output signal of the first logic gate, and perform an AND operation on the compensation enable signal and the output signal to generate a count increase signal.

10. The memory device according to claim 6, in, The error detector includes a first full adder and a second full adder, and the error detector outputs a compensation enable signal by performing an OR operation on an output of a carry output terminal of the first full adder and an output of a carry output terminal of the second full adder.

11. A read offset compensator for a memory device, the read offset compensator include: an error detector configured to compare the number of error bits of output data from a plurality of sense amplifiers of the memory device with a threshold value; an offset reference resistance generator configured to generate an offset reference resistance; as well as a plurality of sense amplifier offset compensators, respectively corresponding to the plurality of sense amplifiers, each of the plurality of sense amplifier offset compensators being configured to: perform an offset reference resistance compensation operation, Wherein, each of the plurality of sense amplifier offset compensators calculates a local resistance for compensating an offset reference resistance of a corresponding sense amplifier among the plurality of sense amplifiers during an offset reference resistance compensation operation, and adjusts a reference resistance of the corresponding sense amplifier among the plurality of sense amplifiers during a read operation based on the local resistance.

12. The read offset compensator according to claim 11, in, the error detector being configured to determine whether the number of error bits of output data from a plurality of sense amplifiers of the memory device is greater than a threshold value, and output a compensation enable signal based on a result of the determination; and Each of the plurality of sense amplifier offset compensators is configured to receive output data from a corresponding sense amplifier of the plurality of sense amplifiers, compare the output data with expected data, and adjust an offset reference resistance of the sense amplifier based on a result of the comparison.

13. The read offset compensator according to claim 11, in, Each of the plurality of sense amplifier offset compensators comprises: a decision logic configured to compare the output data with expected data based on the compensation enable signal and generate a count increase signal when the output data is different from the expected data; an up / down counter configured to generate an up-count signal based on the count-increase signal; an adder configured to: receive the up-count signal and the offset reference resistance, and generate a reference resistance increase signal for adding the offset reference resistance and the local resistance in response to the up-count signal; and The offset reference resistance adjuster is configured to receive the reference resistance increase signal from the adder and adjust the offset reference resistance based on the reference resistance increase signal.

14. The read offset compensator according to claim 13, in, The offset reference resistance adjuster adjusts the offset reference resistance to generate an adjusted reference voltage and provides the adjusted reference voltage to a corresponding sense amplifier among the plurality of sense amplifiers.

15. The read offset compensator according to claim 13, in, The decision logic includes: a first logic gate configured to receive the output data and the expected data and perform an XOR operation; and The second logic gate is configured to receive the compensation enable signal and the output signal of the first logic gate, and perform an AND operation on the compensation enable signal and the output signal to generate a count increase signal.

16. The read offset compensator according to claim 11, in, The error detector includes a first full adder and a second full adder, and the error detector outputs a compensation enable signal by performing an OR operation on a carry output terminal of the first full adder and a carry output terminal of the second full adder.

17. A method for compensating an offset reference resistance of a memory device, the method include: writing the same data to a plurality of memory cells of a memory device; reading output data of a plurality of sense amplifiers; determining whether the number of error bits of output data from the plurality of sense amplifiers is greater than a threshold value, and outputting a compensation enable signal based on a result of the determination; as well as calculating a local resistance of each of the plurality of sense amplifiers based on a compensation enable signal, and compensating an offset reference resistance using the local resistance, Therein, the memory device adjusts a reference resistance during a read operation based on a local resistance.

18. The method according to claim 17, further comprising: include: Output data of each of the plurality of sense amplifiers is compared with corresponding expected data based on a compensation enable signal, and a count increase signal corresponding to the sense amplifier is generated when the output data is different from the expected data.

19. The method according to claim 18, further comprising: include: An offset reference resistor corresponding to the sense amplifier is increased by a local resistance based on the count increase signal.

20. The method according to claim 19, further comprising: include: An offset reference resistor corresponding to the sense amplifier is adjusted to generate an adjusted reference voltage, and the adjusted reference voltage is provided to the sense amplifier.

21. The method according to claim 17, in, The plurality of memory cells of the memory device include access transistors and variable resistance elements.