The present disclosure relates generally to semiconductor memory and methods, and more particularly, to apparatuses and methods related to sort in memory using table splitting.
Memory devices are typically provided as internal, semiconductor, integrated circuits in computing systems. There are many different types of memory including volatile and non-volatile memory. Volatile memory can require power to maintain its data (e.g., host data, error data, etc.) and includes random access memory (RAM), dynamic random access memory (DRAM), static random access memory (SRAM), synchronous dynamic random access memory (SDRAM), and thyristor random access memory (TRAM), among others. Non-volatile memory can provide persistent data by retaining stored data when not powered and can include NAND flash memory, NOR flash memory, and resistance variable memory such as phase change random access memory (PCRAM), resistive random access memory (RRAM), and magnetoresistive random access memory (MRAM), such as spin torque transfer random access memory (STT RAM), among others.
Computing systems often include a number of processing resources (e.g., one or more processors), which may retrieve and execute instructions and store the results of the executed instructions to a suitable location. A processing resource can comprise a number of functional units such as arithmetic logic unit (ALU) circuitry, floating point unit (FPU) circuitry, and a combinatorial logic block, for example, which can be used to execute instructions by performing logical operations such as AND, OR, NOT, NAND, NOR, and XOR, and invert (e.g., inversion) logical operations on data (e.g., one or more operands). For example, functional unit circuitry may be used to perform arithmetic operations such as addition, subtraction, multiplication, and division on operands via a number of logical operations.
A number of components in a computing system may be involved in providing instructions to the functional unit circuitry for execution. The instructions may be executed, for instance, by a processing resource such as a controller and/or host processor. Data (e.g., the operands on which the instructions will be executed) may be stored in a memory array that is accessible by the functional unit circuitry. The instructions and data may be retrieved from the memory array and sequenced and/or buffered before the functional unit circuitry begins to execute instructions on the data. Furthermore, as different types of operations may be executed in one or multiple clock cycles through the functional unit circuitry, intermediate results of the instructions and data may also be sequenced and/or buffered.
The present disclosure includes systems, apparatuses and methods related to maintaining data in a sorted order in a memory array to improve access time to data in the memory array and directing access to a row of data in cache based upon an address associated with the data. In a number of embodiments, data stored in tables in sorted order can allow access to data based on upon the keys and/or the sorted order of the data, which can increase access times to data the memory array. In a number of embodiments, a content addressable memory (CAM) can be configured to receive an address and perform a look up operation for the address in CAM and open a row in memory (e.g., cache) in response to locating the address in CAM during the look up operation. The look up operation can locate the address in a row of the CAM that is directly coupled to the row in memory and CAM can be configured to open a row in memory that is coupled to the row in the CAM where the address is located. The CAM can be configured to map a received virtual address of a main memory directly to a corresponding select line of the memory.
A memory can comprise a semiconductor material configured to store an electrical charge. However, such a semiconductor material may have slow switching capabilities. As such, a different semiconductor material having faster switching capabilities, but does not store an electrical charge well, may be used for logic circuitry coupled to the memory. Although a semiconductor material used for memory may have slow switching capabilities, the semiconductor material used for memory can have advantages over semiconductor materials having faster switching capabilities. These advantages can include, but are not limited to, a high degree of parallelism, closeness to data, and power efficiency.
In the following detailed description of the present disclosure, reference is made to the accompanying drawings that form a part hereof, and in which is shown by way of illustration how one or more embodiments of the disclosure may be practiced. These embodiments are described in sufficient detail to enable those of ordinary skill in the art to practice the embodiments of this disclosure, and it is to be understood that other embodiments may be utilized and that process, electrical, and/or structural changes may be made without departing from the scope of the present disclosure. As used herein, designators such as “n, “N,” etc., particularly with respect to reference numerals in the drawings, indicate that a number of the particular feature so designated can be included. As used herein, “a number of” a particular thing refers to one or more of such things (e.g., a number of memory arrays can refer to one or more memory arrays). A “plurality of” is intended to refer to more than one of such things.
The figures herein follow a numbering convention in which the first digit or digits correspond to the drawing figure number and the remaining digits identify an element or component in the drawing. Similar elements or components between different figures may be identified by the use of similar digits. For example, 102 may reference element “02” in
Memory array 118 can include control circuitry 111 configured to maintain data stored in tables in memory array 118 in sorted order. The sorted order can be based on keys associated with the data stored in memory array 118. The data stored in tables in sorted order can allow access to data based on upon the keys and/or the sorted order of the data, which can increase access times to data the memory array.
Apparatus 106 can include control circuitry 110 configured to directly map an address received from processing resource 108 and/or host 102 to a row in memory 116. Control circuitry 110 can include CAM 112 that is configured to receive an address and perform a look up operation for the address in CAM 112 and open a row in memory 116 in response to locating the address in CAM 112 in the look up operation. The look up operation can locate the address in a row of the CAM 112 that is directly coupled to the row in memory 116 and CAM 112 can be configured to open a row in memory 116 that is coupled to the row in the CAM 112 where the address is located.
The control circuitry 110 can be coupled to the memory 116. The memory 116 can be coupled to the memory array 118. The control circuitry 110 can include a CAM 112. In at least one embodiment, the CAM 112 can be on chip with the processing resource 108 and the memory 116. In at least one embodiment, the control circuitry 110 can include a state machine 114 (e.g., a finite state machine (FSM)) in communication with the CAM 112. The state machine 114 can generate operation codes (hereinafter referred to as “opcodes”) and provide opcodes to the CAM 112. The opcodes can control operations performed by the CAM 112 described herein, such as a lookup operation. The CAM 112 can be coupled to the memory 116. A single select line of the CAM 112 can be coupled to a single select line of the memory 116 as represented by lines 113-0, 113-1, . . . , 113-N. In at least one embodiment, the memory 116 can be SRAM. However, embodiments of the present disclosure are not so limited.
CAM 112 can be configured concurrently map a received virtual address of the memory array 118 to a corresponding physical address of the memory array 118, map the corresponding physical address of the memory array 118 to a corresponding physical address of the memory 116, and map the corresponding physical address of the memory 116 to a corresponding select line of the memory 116. The CAM 112 can serve as a decoder for the memory 116.
Apparatus 106 can be configured to intercept the virtual address sent to memory array 118 from the host 102 and/or the processing resource 104. The CAM 112 can be configured to determine whether a first portion of rows of memory cells of the CAM 112 stores the intercepted virtual address and determine whether the second portion of the rows of memory cells of the CAM stores the physical address of the memory.
Sort portion 221 can sort and store data associated with the data in data portion 220 using index table 222, key table 224, and logic stripe 226. Index table can include storing a key associated with a portion of data (e.g., a page of data) in data portion 220. For example, index table 222 can include index table rows 223-0, 223-1, 223-2, and 223-3 that are configured to store a particular number of entries each storing a key and an address associated with portion of data (e.g., a page) in data portion 220. In
Index table row 223-0 includes 6 key and address pair entries: A, 9 230-0; B, 8 230-1; D, 0 220-2; E, 3 230-3; F, 4 230-4; and G, 10 230-5. Index table row 223-1 includes 4 key and address pair entries: H, 1 230-6; I, 11 230-7; J, 2 230-8; and K, 7 23-9. Index table row 223-2 includes 4 key and address pair entries: L, 5 230-10, M, 6 230-11; S, 12 230-12; and U, 13 230-13. Each of the key and address pairs 230-0, . . . 230-13 are in sorted order based on alphabetical order of the keys. Key and address pairs can be sorted based upon any criteria than can be applied to the keys. For example, the keys can be numeric and can be sorted from low to high or from high to low.
In
Key table 224 can in an entry for each row of the index table rows that an indicator of the last key stored in each particular row or an adjacent row. Indicators can be comprised of one or more bits. For example, 0,0 in key table entry 234-0 indicates that index table row 223-0 has the first key and address pair for this sorted group, 1, G in key table entry 234-1 indicates that index table row 223-1 includes key and address pairs with keys above G, and 2, K in key table entry 234-2 indicates that index table row 223-2 includes key and address pairs with keys above K. Key table entry 234-3 is empty because key table row 223-3 does not have any key and address pairs.
Sort portion 221 includes logic stripe 226 that can include circuitry to compare incoming key and address pairs to the information in index table 224 and key table 224 to determine where in the sorted order a key and address pair will be placed in index table 222 or where a request for data using a key or sorted order position is located in data portion 220. Logic stripe 226 can include circuitry to shift key and address pairs along the logic stripe so the key and address pairs are maintained in sorted order and stored in a new location in index table 222 when a new key and address pair is added to index table 222.
Prior to a write operation, index table row 323-0 includes 6 key and address pair entries: A, 9 330-0; B, 8 330-1; D, 0 320-2; E, 3 330-3; F, 4 330-4; and G, 10 330-5. Index table row 323-1 includes 4 key and address pair entries: H, 1 330-6; I, 11 330-7; J, 2 330-8; and K, 7 330-9. Index table row 323-2 includes 4 key and address pair entries: L, 5 330-10, M, 6 330-11; S, 12 330-12; and U, 13 330-13. Each of the key and address pairs 330-0, . . . 330-13 are in sorted order based on alphabetical order of the keys. Key and address pairs can be sorted based upon any criteria than can be applied to the keys. For example, the keys can be numeric and can be sorted from low to high or from high to low.
A write operation can include writing data to data portion 320 with a key of N at address 14. Key and address pair 340, N, 14, associated with the data of a write operation is ready to be sorted and inserted into index table 322 while the data from the write operation is written to data portion 320 of memory array 318. Key and address pair 340 can be sorted by writing the key table information, entries 332-0, 332-1, 332-2, 334-0, 334-1, and 334-2 to logic stripe 326, as shown in
In response to logic stripe 326 determining that key and address pair 340 will be placed in index table row 323-2, the data from index table row 323-2 can be stored in logic stripe 326. Key and address pair entries: L, 5 330-10, M, 6 330-11; S, 12 330-12; and U, 13 330-13 from index table row 323-2 can be placed in logic stripe 326, as shown in
Key and address pair 340 can be placed between shifted key and address pair 330-11 and key and address pair 330-12 in logic stripe 326. The key and address pairs in the updated sorted order to include key and address pair 340 can be written back to index table row 323-2 in the updated sorted order, such that index table row 323-2 includes key and address pairs, 330-10, 330-11, 330-14, 330-12, and 330-13 in sorted order, as shown in
Index table row 423-0 includes 6 key and address pair entries: A, 9 430-0; B, 8 430-1; D, 0 430-2; E, 3 430-3; F, 4 430-4; and G, 10 430-5. Index table row 423-1 includes 4 key and address pair entries: H, 1 430-6; I, 11 430-7; J, 2 430-8; and K, 7 430-9. Index table row 423-2 includes 4 key and address pair entries: L, 5 430-10, M, 6 430-11; S, 12 430-12; and U, 13 430-13. Each of the key and address pairs 430-0, . . . 430-13 are in sorted order based on alphabetical order of the keys. Key and address pairs can be sorted based upon any criteria than can be applied to the keys. For example, the keys can be numeric and can be sorted from low to high or from high to low.
A read operation can include reading data from data portion 420 using the address portion of a key and address pair that is located in index table 422 according to embodiments of the present disclosure. An incoming read request can include an indication that data associated with the 7th key and address pair in the sorted order of index table 422 is requested. Logic stripe 426 can be configured to determine where the 7th key and address pair in the sorted order of index table 422 is located based on entries 434-0, 434-1, and 434-2 in key table 426, which can be placed in logic strip 426. Logic stripe 426 can determine that the 7th key and address pair in the sorted order of index table 422 in response to the entry 432-0 indicating that index table row 423-0 has 6 entries and index table row 423-1 has 4 entries, therefore the 7th key and address pair in the sorted order of index table 422 is located in index table row 423-1. Logic stripe 426 can be configured to determine that the 7th key and address pair in the sorted order of index table 422 is the first key and address pair of index table row 423-1 by subtracting the total number of entries in the table index rows prior to the table index row where the requested key and address pair is located. In
The information of key and address pair entries 430-6, 430-7, 430-8, and 430-9 from table index row 423-1 can be placed in logic stripe 426. Logic stripe 426 can be configured to locate the data associated with the request in data portion 420 based on the address of key and address pair 430-1, which includes data associated with key H located at address 1 in data portion 420. The data associated with key H can be read and placed in sense amp stripe 428 and then sent from the memory array to fulfill the read request.
Index table row 523-0 includes 6 key and address pair entries: A, 9 530-0; B, 8 530-1; D, 0 530-2; E, 3 530-3; F, 4 530-4; and G, 10 530-5. Index table row 523-1 includes 4 key and address pair entries: H, 1 530-6; I, 11 530-7; J, 2 530-8; and K, 7 530-9. Index table row 523-2 includes 4 key and address pair entries: L, 5 530-10, M, 6 530-11; S, 12 530-12; and U, 13 530-13. Each of the key and address pairs 530-0, . . . 530-13 are in sorted order based on alphabetical order of the keys. Key and address pairs can be sorted based upon any criteria than can be applied to the keys. For example, the keys can be numeric and can be sorted from low to high or from high to low.
A read operation can include reading data from data portion 520 using the address portion of a key and address pair that is located in index table 522 according to embodiments of the present disclosure. An incoming read request can include an indication that data associated with a key of a key and address pair in the sorted order of index table 522 is requested. Logic stripe 526 can be configured to determine where key L of request 550 is located in the sorted order of index table 522. Logic stripe 526 can located key L located based on entries 534-0, 534-1, and 534-2 in key table 526, which can be placed in logic strip 526. Logic stripe 526 can determine that key L in the sorted order of index table 522 is in index table row 523-2 in response to the entry 532-2 indicating that index table row 523-2 has entries with keys above key K, therefore key L in the sorted order of index table 522 is located in index table row 523-2.
The information of key and address pair entries 530-10, 530-11, 530-12, and 530-13 from table index row 523-2 can be placed in logic stripe 526. Logic stripe 526 can be configured to locate the data associated with the request in data portion 520 based on the address of key L in key and address pair 530-10, which includes data associated with key L located at address 5 in data portion 520. The data associated with key L can be read and placed in sense amp stripe 528 and then sent from the memory array to fulfill the read request.
Index table row 623-0 includes 8 key and address pair entries: A, 7 630-0; B, 6 630-1; D, 0 630-2; E, 3 630-3; F, 4 630-4; G, 5 630-5; H, 1 630-6; and S, 2 630-7. Each of the key and address pairs 630-0, . . . 630-7 are in sorted order based on alphabetical order of the keys. Key and address pairs can be sorted based upon any criteria than can be applied to the keys. For example, the keys can be numeric and can be sorted from low to high or from high to low.
A write operation can include writing data to data portion 620 and writing a key and address pair associated with the data to the index table 622. When writing a key and address pair to a full index table row, the full index table row can be split between two rows to maintain the sorted order. An incoming write request can include an indication that data associated with a key of a key and address pair in the sorted order of index table 622 will be placed in a full index table row. The full index table row can be split by copying the entries in the full index table row to another row. The originally full row can be updated to include half of the entries in the full row and the row where the entries were copied can be updated to include the other of the entries in the full row.
In
Key and address pair 640, I, 8 associated with the write operation can then be placed in index table 622. Key and address pair 640 can be placed in index table in response to logic stripe 626 determining that key and address pair 640 should be located between key and address pairs 630-6 and 630-7 and shifting key and address pair 630-7 to make room for key and address pair 640, as shown in
Key table 624 can be updated to indicate any changes in the quantity of entries in the index table rows or the highest key that is included in each of the index table rows that resulted from the split. In
A number of embodiments can include storing an address associated with the data along with the key, as key and address pairs. The key and address pairs can be stored in an index table in the memory device. Storing the key associated with the portion of data in the sorted order includes comparing the key to the key associated with the portions of data previously stored in the memory device.
A number of embodiments can include accessing the portion of data based on the key associated with the portion of data and/or accessing the portion of data based on a position in the sorted order of the key associated with the portion of data.
In
In a number of embodiments, the key table can be used for storing an indicator of a quantity of keys that are stored in each particular row and an indicator of the last key stored in each particular row.
In a number of embodiments, writing the one or more bits indicative of in the row of the index table in the sorted order can include storing the number of keys in the row of the index table in a logic stripe, comparing the key to the number of keys in the row of the index table using a logic stripe, shifting a portion the number of keys in the row of the index table to new locations in a logic stripe, writing the one or more bits indicative of the key in an open position of a logic stripe that resulted from shifting a portion the number of keys in the row of the index table to new locations in the logic stripe, and/or writing the key and the number of keys in sorted order from a logic stripe to the row of the index table.
In
The method can include locating a row in the index table where one or more bits indicative of the key are located based on comparing the key and the key table that includes in indication of the last key stored in each particular row of the index table, reading the key and address pair from the row in the index table, and/or locating the data in the memory array based on an address of the key and address pair associated the requested data. The request to read data can include an indication of a position in the sorted order of a key associated with the data.
The method can include locating a row in the index table where one or more bits indicative of a key and address pair associated with the data is located based on an indication of a quantity of keys stored in each particular row and/or locating one or more bits indicative of the key and address pair associated with the data based on subtracting a quantity of key and address pairs stored in rows of the index table above the row of the index table from an indication of a position in the sorted order of a key associated with the data.
The method can include providing an indication that the sorted order of the some of the other bits indicative of the number of other keys begins at a particular location in the index table, storing one or more bits indicative of a new key in the row at a location where some of the other bits indicative of the number of other keys were located, storing one or more bits indicative of a new key in the another row, and/or maintaining the sorted order when storing one or more bits indicative of the number of keys in two rows.
In
The method can include updating a key table that includes an indication of a quantity of the first portion of the number of keys in the row and an indication of a quantity of the second portion of the number of keys in the another row. The method can include updating a key table that includes an indication of a last key of the first portion of the number of keys in the row and an indication of a last key of the second portion of the number of keys in the another row. The method can include proving an indication that a sorted order of the another row begins in the second half of the another row and splitting the second portion of number of keys between two rows in response to filling the another row.
Although specific embodiments have been illustrated and described herein, those of ordinary skill in the art will appreciate that an arrangement calculated to achieve the same results can be substituted for the specific embodiments shown. This disclosure is intended to cover adaptations or variations of one or more embodiments of the present disclosure. It is to be understood that the above description has been made in an illustrative fashion, and not a restrictive one. Combination of the above embodiments, and other embodiments not specifically described herein will be apparent to those of skill in the art upon reviewing the above description. The scope of the one or more embodiments of the present disclosure includes other applications in which the above structures and methods are used. Therefore, the scope of one or more embodiments of the present disclosure should be determined with reference to the appended claims, along with the full range of equivalents to which such claims are entitled.
In the foregoing Detailed Description, some features are grouped together in a single embodiment for the purpose of streamlining the disclosure. This method of disclosure is not to be interpreted as reflecting an intention that the disclosed embodiments of the present disclosure have to use more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive subject matter lies in less than all features of a single disclosed embodiment. Thus, the following claims are hereby incorporated into the Detailed Description, with each claim standing on its own as a separate embodiment.
This application claims priority of U.S. Provisional Application Ser. No. 63/027,455, filed on May 20, 2020, the contents of which are incorporated herein by reference.
Number | Date | Country | |
---|---|---|---|
63027455 | May 2020 | US |