WO2023226061A1 - 指令的测试方法、装置、测试平台及可读存储介质 - Google Patents

指令的测试方法、装置、测试平台及可读存储介质 Download PDF

Info

Publication number
WO2023226061A1
WO2023226061A1 PCT/CN2022/096076 CN2022096076W WO2023226061A1 WO 2023226061 A1 WO2023226061 A1 WO 2023226061A1 CN 2022096076 W CN2022096076 W CN 2022096076W WO 2023226061 A1 WO2023226061 A1 WO 2023226061A1
Authority
WO
WIPO (PCT)
Prior art keywords
instruction
historical
time interval
memory
target
Prior art date
Application number
PCT/CN2022/096076
Other languages
English (en)
French (fr)
Inventor
李钰
史腾
Original Assignee
长鑫存储技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 长鑫存储技术有限公司 filed Critical 长鑫存储技术有限公司
Priority to US17/899,056 priority Critical patent/US11977465B2/en
Publication of WO2023226061A1 publication Critical patent/WO2023226061A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C29/00Checking stores for correct operation ; Subsequent repair; Testing stores during standby or offline operation
    • G11C29/56External testing equipment for static stores, e.g. automatic test equipment [ATE]; Interfaces therefor

Definitions

  • Embodiments of the present disclosure relate to the field of semiconductor technology, and in particular, to an instruction testing method, device, testing platform, and readable storage medium.
  • memory In the field of semiconductor technology, memory involves many different instructions. Since the internal circuit of the memory takes time to respond to the received instructions, a certain amount of time is required between different instructions.
  • Embodiments of the present disclosure provide an instruction testing method, device, test platform, and readable storage medium.
  • the test platform can efficiently determine the time interval between instructions, and then accurately send each instruction to the memory.
  • the present disclosure provides an instruction testing method, which method is applied to a test platform and includes:
  • test platform When the test platform has a target instruction to be sent to the memory, determine the minimum time interval between the target instruction and each historical instruction that has been sent to the memory, as well as the issuance time of each historical instruction and the current time. time interval; there are timing constraints between each historical instruction and the target instruction;
  • the duration of the vacant instruction is determined.
  • the vacant instruction is in the last historical instruction. Sent after the instruction and before the target instruction;
  • the target instruction is sent to the memory.
  • the duration of the idle instruction is determined based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time.
  • the first time of the target instruction relative to each historical instruction is determined respectively. waiting time
  • the maximum value of the first waiting duration of the target instruction relative to the respective historical instructions is determined as the vacant instruction. duration
  • the target is determined respectively based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time.
  • the first waiting time of the instruction relative to each of the historical instructions includes:
  • the first historical instruction will be The difference between a minimum time interval and the first time interval is determined as the first waiting time of the target instruction relative to the first historical instruction;
  • first minimum time interval is less than or equal to the first time interval, it is determined that the first waiting time of the target instruction relative to the first historical instruction is zero.
  • sending the target instruction to the memory after the vacant instruction includes:
  • the sending time of the target instruction is determined based on the current time and the duration of the idle instruction, and is sent to the memory when the sending time of the target instruction arrives.
  • the target instruction is
  • the method before determining the minimum time interval between the target instruction and each historical instruction that has been sent to the memory, the method further includes:
  • each historical instruction that has been sent by the test platform to the memory and has timing constraints with the target instruction is found.
  • determining the minimum time interval between the target instruction and each historical instruction that has been sent to the memory includes:
  • the minimum time interval between the target instruction and each historical instruction is determined based on the minimum time interval between instructions in the current working mode of the memory.
  • determining the minimum time interval between the target instruction and each historical instruction that has been sent to the memory includes:
  • the minimum time interval between the target instruction and each historical instruction is determined according to the minimum time interval between instructions at the current timing rate of the memory.
  • an instruction testing device which is applied to a test platform and includes:
  • Determining module configured to determine the minimum time interval between the target instruction and each historical instruction that has been sent to the memory when the test platform has a target instruction to be sent to the memory, and the minimum time interval of each historical instruction. The time interval between the issuance moment and the current moment; there are timing constraints on each historical instruction and the target instruction;
  • a processing module configured to determine the duration of the vacant instruction based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time.
  • the vacant instruction is in Sent after the last historical instruction and before the target instruction;
  • a sending module configured to send the target instruction to the memory after the idle instruction.
  • the processing module is used to:
  • the first time of the target instruction relative to each historical instruction is determined respectively. waiting time
  • the maximum value of the first waiting duration of the target instruction relative to the respective historical instructions is determined as the vacant instruction. duration
  • the processing module is used to:
  • the first historical instruction will be The difference between a minimum time interval and the first time interval is determined as the first waiting time of the target instruction relative to the first historical instruction;
  • first minimum time interval is less than or equal to the first time interval, it is determined that the first waiting time of the target instruction relative to the first historical instruction is zero.
  • the sending module is used for:
  • the sending time of the target instruction is determined based on the current time and the duration of the idle instruction, and is sent to the memory when the sending time of the target instruction arrives.
  • the target instruction is
  • search module for:
  • each historical instruction that has been sent by the test platform to the memory and has timing constraints with the target instruction is found.
  • the determining module is used to:
  • the minimum time interval between the target instruction and each historical instruction is determined based on the minimum time interval between instructions in the current working mode of the memory.
  • the determining module is used to:
  • the minimum time interval between the target instruction and each historical instruction is determined according to the minimum time interval between instructions at the current timing rate of the memory.
  • test platform including: at least one processor and a memory;
  • the memory stores computer execution instructions
  • the at least one processor executes the computer execution instructions stored in the memory, so that the at least one processor executes the testing method of the instructions provided in the first aspect.
  • the present disclosure provides a computer-readable storage medium in which computer-executable instructions are stored.
  • a processor executes the computer-executable instructions, the instructions provided in the first aspect are implemented. Test Methods.
  • the instruction testing method, device, test platform and readable storage medium provided by the embodiments of the present disclosure, when the test platform has a target instruction to be sent to the memory, according to the minimum time interval between the target instruction and each historical instruction, and each The time interval between the issuance moment of historical instructions and the current moment determines the duration of the vacant instruction. After the vacant instruction, the target instruction is sent to the memory. This can efficiently determine the time interval between instructions without manual participation, thereby accurately sending each instruction. .
  • Figure 1 is a schematic architectural diagram of an instruction testing system provided in an embodiment of the present disclosure
  • Figure 2 is a schematic step flow chart of an instruction testing method provided in an embodiment of the present disclosure
  • FIG. 3 is a timing diagram illustrating the time limit of a command signal for accessing DRAM provided in an embodiment of the present disclosure
  • Figure 4 is a schematic diagram 1 of the sending time of each historical command and target command in the embodiment of the present disclosure
  • Figure 5 is a schematic flowchart 2 of the steps of an instruction testing method provided in an embodiment of the present disclosure
  • Figure 6 is a schematic diagram 2 of the sending time of each historical command and target command in the embodiment of the present disclosure
  • Figure 7 is a schematic diagram of a program module of an instruction testing device provided in an embodiment of the present disclosure.
  • Figure 8 is a schematic diagram of the hardware structure of a test platform provided by an embodiment of the present disclosure.
  • module refers to any known or later developed hardware, software, firmware, artificial intelligence, fuzzy logic or combination of hardware or/and software code capable of performing the functions associated with that element .
  • the embodiments of the present disclosure can be applied in the semiconductor field, for example, in memory testing links.
  • DRAM Dynamic Random Access Memory
  • Common instructions in DRAM include Active instruction, Precharge instruction, Read instruction, Write instruction, Mode Register Write (MRW) instruction, Mode Register read (Mode Register Read, referred to as MRR) instruction, Refersh instruction, Self-Refrresh instruction, Powerdown instruction, etc.
  • the number of minimum time intervals formed by the combination of multiple instructions will be very large, and the minimum interval time is also affected by the memory operating rate, mode configuration, and storage structure selection. Due to the influence of other factors, calculating the minimum interval time between two instructions is complex and cumbersome.
  • test incentives are essentially a combination of instructions under various working conditions of the memory.
  • the time interval between these instructions must be based on the minimum interval defined by SPEC. To control, otherwise it will be illegal or invalid incentives and have no testing significance.
  • an embodiment of the present disclosure provides an instruction testing method.
  • the test platform has a target instruction to be sent to the memory, according to the minimum time interval between the target instruction and each historical instruction, and each historical instruction, The time interval between the issuing moment of the instruction and the current moment determines the duration of the vacant instruction. After the vacant instruction, the target instruction is sent to the memory. This allows the time interval between instructions to be determined efficiently without manual participation, thereby accurately sending each instruction. instruction.
  • the detailed process can refer to the following embodiments.
  • Figure 1 is a schematic architectural diagram of an instruction testing system provided in an embodiment of the present disclosure.
  • the above-mentioned instruction testing system includes a test platform 101 and a memory 102, wherein the test platform 101 and the memory 102 are communicatively connected.
  • the test platform 101 can simulate various instructions used by various types of memories. During the test process, the test platform 101 can send various instructions to the memory 102 and control the sending time interval between the instructions.
  • test platform 101 may also have functions such as signal reception, data processing, verification, etc., such as checking whether the memory 102 successfully executes each instruction, etc.
  • the memory 102 can be various types of memory, such as DRAM, read-only memory (ROM), random access memory (RAM), etc., which are not limited in the embodiment of the present disclosure.
  • FIG. 2 is a schematic flowchart 1 of the steps of an instruction testing method provided in an embodiment of the present disclosure.
  • the testing method of the above instructions includes:
  • test platform When the test platform has a target instruction to be sent to the memory, determine the minimum time interval between the target instruction and each historical instruction that has been sent to the memory, and the time interval between the issuance time of each historical instruction and the current time.
  • timing constraints mainly include cycle constraints, offset constraints, static timing path constraints, etc.
  • setup time refers to the shortest time that the data input signal must remain stable before the valid edge of the clock
  • hold time refers to the The minimum time the data input signal must remain stable after the valid edge.
  • This minimum amount of time is the above-mentioned setup time. In addition, it also takes time for the clock edge to close the switch. If the data changes during this time period, the new data may be passed to the next level, and an error will occur. Therefore, the data must remain unchanged for a certain period of time, that is, before the clock After the valid edge comes, the data must be kept "unchangeable" for a minimum amount of time. This minimum amount of time is the above-mentioned holding time.
  • FIG. 3 is a timing diagram of a time limit of a command signal for accessing a DRAM provided in an embodiment of the present disclosure.
  • the DRAM-related address signal and data signal waveforms are omitted.
  • the activation signal (active command) 10 represents the row access time, which is when the DRAM controller sends the row address of the DRAM
  • the precharge command (precharge signal) 20 represents a precharge command time, which is When the DRAM controller sends a precharge command to the DRAM.
  • the row active time tRAS defined in a DRAM specification needs to exist between the start signal 10 and the precharge signal 20.
  • the row startup time tRAS requires an absolute timing gap between the row startup of DRAM and the startup row of precharged DRAM.
  • the DRAM controller cannot send the precharge signal 20 to the DRAM within 20ns after sending the startup signal 10, otherwise the precharge signal 20 sent is an invalid signal.
  • the DRAM controller can use a counter to count the corresponding number of clock cycles of the DRAM controller and DRAM. For example, if the frequency of the clock CLK of the DRAM subsystem is 200MHz (that is, the clock cycle is 5ns), the DRAM controller will operate as follows: send a start signal 10; count at least 4 clock cycles of CLK; send a precharge signal 20.
  • test platform when the test platform sends a new instruction each time, it first calculates the minimum time interval between the instruction under the current configuration and rate and previous historical instructions with timing constraints. At the same time, the test platform Record the time interval from the issuance of each of the above historical instructions to the current moment in real time.
  • FIG. 4 is a schematic diagram 1 of the sending time of each historical command and the target command in the embodiment of the present disclosure.
  • S202 Determine the duration of the vacant instruction based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time.
  • the above-mentioned vacant instruction is sent after the last historical instruction and before the target instruction.
  • time interval between the issuance time of a historical command and the current time is greater than or equal to the minimum time interval between the historical command and the target command, then when the target command is sent immediately, the time between the historical command and the target command will be time can meet the timing requirements; if the time interval between the issuance time of a historical command and the current time is less than the minimum time interval between the historical command and the target command, then when the target command is sent immediately, due to the difference between the historical command and the target command The timing requirements cannot be met, so the memory may not respond or may experience response errors.
  • a vacant instruction can be sent based on the minimum time interval between the historical instruction and the target instruction, as well as the time interval between the issuance time of the historical instruction and the current moment, and then the target instruction can be sent after the vacant instruction ends. Since the idle instruction has a certain duration, it is equivalent to waiting for a certain period of time from the current moment before sending the target instruction.
  • the waiting time of the target instruction relative to each historical instruction can be determined, and then The maximum value of the waiting time of the target instruction relative to each historical instruction is used as the length of the idle instruction.
  • the idle instruction is sent, and after the idle instruction ends, the target instruction is sent to the memory. This is equivalent to starting the timing from the current moment and waiting for the idle instruction before sending the target instruction. This can ensure that after the target instruction is sent, the target instruction and each of the above historical instructions can meet the timing requirements.
  • the instruction testing method provided by the embodiment of the present disclosure, when the test platform has a target instruction to be sent to the memory, according to the minimum time interval between the target instruction and each historical instruction, and the time between the issuance time of each historical instruction and the current time interval, determine the duration of the vacant instruction, and send the target instruction to the memory after the vacant instruction. This can efficiently determine the time interval between instructions without manual participation, thereby accurately sending each instruction.
  • FIG. 5 is a schematic flowchart 2 of the steps of an instruction testing method provided in an embodiment of the present disclosure.
  • the testing method of the above instructions includes:
  • test platform When the test platform has a target instruction to be sent to the memory, determine the minimum time interval between the target instruction and each historical instruction that has been sent to the memory, and the time interval between the issuance time of each historical instruction and the current time.
  • the test platform can pre-obtain the timing constraint file corresponding to the memory; when the test platform has a target instruction to be sent to the memory, based on the timing constraint file, it is found that the test platform has sent to the memory the existence of the target instruction. Individual historical instructions with timing constraints.
  • the standard rule file corresponding to the memory can be obtained, and the minimum time interval between the target instruction and each of the above historical instructions can be determined from the standard rule file.
  • the current working mode of the memory can be determined according to the configuration information of the memory; according to the minimum distance between instructions in the current working mode of the memory
  • the time interval determines the minimum time interval between the target instruction and each of the above historical instructions.
  • LPDDR5 DRAM supports three working modes, namely Bank-Group mode (configuration of 4 Banks, 4Bank-Group), 8Bank mode (configuration of 8 Banks, no Bank-Group) and 16Bank mode (configuration of 16 Banks, no Bank-Group).
  • Bank-Group mode is suitable for speeds higher than 3200Mbps and allows burst lengths of 16 and 32 bits.
  • 8Bank mode supports all speeds with burst lengths of 32 bits
  • 16Bank mode supports speeds up to 3200Mbps with burst lengths of 16 or 32 bits.
  • the clock signals used by the memory in different operating modes will also be different, which may result in different minimum time intervals between the same two instructions.
  • the period of the clock signal used in Bank-Group mode is X (ns)
  • the period of the clock signal used in 16Bank mode is Y (ns)
  • the minimum time interval between two instructions is n clock cycles, where ,X ⁇ Y.
  • the minimum time interval between the above two instructions is n*X(ns)
  • 16Bank mode the minimum time interval between the above two instructions is n*Y(ns).
  • the current timing rate of the memory can be determined first; the target can be determined based on the minimum time interval between instructions of the memory at the current timing rate. The minimum time interval between the instruction and each historical instruction.
  • the period of the clock signal used by the memory will be different at different timing rates, therefore, when the timing rate of the memory is different, the minimum time interval between the same two instructions may also be different.
  • the minimum time interval between two instructions has been specified in the standard protocol as max(5,12nWCK), then when 12nWCK>5, the minimum time interval between the above two instructions is determined by the memory clock. This is determined by the signal, that is, the higher the current timing rate of the memory, the smaller the minimum time interval between the above two instructions.
  • S502. Determine the first waiting time of the target instruction relative to each historical instruction based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time.
  • the minimum time interval between the target instruction and each historical instruction is greater than the time interval between the issuance time of each historical instruction and the current time; if the target instruction is between the first historical instruction in each historical instruction and The first minimum time interval between is greater than the first time interval between the issuance time of the first historical instruction and the current time, then the difference between the first minimum time interval and the above-mentioned first time interval is determined as the target instruction relative to the above-mentioned first time interval.
  • the first waiting time of the historical instruction if the first minimum time interval is less than or equal to the first time interval, it is determined that the first waiting time of the target instruction relative to the first historical instruction is zero.
  • the test platform has a target instruction F to be sent to the memory at the current time tf. It is determined that among the instructions sent by the test platform, instruction a, instruction b and instruction c are The target instruction F has timing constraints. The minimum time intervals between the target instruction F and instructions a, instruction b, and instruction c are respectively determined to be m1, m2, and m3. At the same time, the time interval between the issuing time ta of the instruction a and the current time tf is determined to be k1. The time interval between the issuance time tb of instruction b and the current time tf is k2. The time interval between the issuance time tc of instruction c and the current time tf is k3.
  • S503. Determine whether the first waiting time of the target instruction relative to each historical instruction is all zero; when the first waiting time of the target instruction relative to each historical instruction is not uniformly zero, execute S504 and S505; when the target instruction is not equal to each historical instruction. When the first waiting time of the historical instructions is zero, S506 is executed.
  • S504. Determine the maximum value of the first waiting duration of the target instruction relative to each historical instruction as the duration of the vacant instruction.
  • the target instruction when the first waiting time of the target instruction relative to each historical instruction is not uniformly zero, it means that the target instruction needs to wait for a certain period of time before being sent again. In order to ensure that after the target instruction is sent, the target instruction and each historical instruction meet the timing requirements, so the maximum value of the first waiting time of the target instruction relative to each historical instruction can be selected as the duration of the idle instruction.
  • S505. Determine the sending time of the target instruction based on the current time and the duration of the vacant instruction, and send the target instruction to the memory when the sending time of the target instruction arrives.
  • the sending time of the target instruction can be determined based on the current time and the duration of the idle instruction. For example, assuming that the current time is tf and the duration of the idle instruction is T, it can be determined that the sending time of the target instruction is tf+T.
  • the clock of the test platform is monitored.
  • the target instruction is immediately sent to the memory.
  • S506. Determine that the duration of the vacant instruction is zero, and immediately send the target instruction to the memory.
  • the test platform when the first waiting time of the target instruction relative to each historical instruction is zero, it means that the time interval between the issuance time of each historical instruction and the current time is greater than or equal to the time interval between each historical instruction and the target instruction. Minimum time interval. In this case, the test platform does not need to wait and can directly send the target instruction to the memory.
  • the minimum time interval between the target instruction and each historical instruction is first determined, and at the same time, the issuance time and the current time of each historical instruction are recorded.
  • the time interval is based on whether the minimum time interval between the target instruction and each historical instruction is greater than the time interval between the issuing time of each historical instruction and the current time, to determine the waiting time of the target instruction relative to each historical instruction, and select the target instruction relative to
  • the maximum value of the waiting time of each historical instruction is used as the duration of the idle instruction. This can ensure that the timing requirements can be met between the target instruction and each of the above historical instructions after it is sent.
  • FIG. 6 is a second schematic diagram of the sending time of each historical command and the target command in the embodiment of the present disclosure.
  • the test platform has a target instruction F to be sent to the memory at the current moment, and it is determined that among the instructions sent by the test platform, instruction a, instruction b and instruction c have timing constraints with the target instruction F. If Determine respectively that the first waiting time of target instruction F relative to instruction a is d1, the first waiting time of target instruction F relative to instruction b is d2, and the first waiting time of target instruction F relative to instruction c is d3, then take the above The maximum value of d1, d2, and d3 is used as the duration of the idle instruction.
  • the time interval between instruction c and target instruction F may also be determined.
  • the time interval between instruction c and target instruction F is the time interval between the issuance time of instruction c and the current time + the duration of the vacant instruction.
  • the sending time of the target instruction can be automatically determined based on the determined waiting time of the target instruction relative to each historical instruction.
  • the process does not require manual participation, which can effectively improve memory testing efficiency.
  • the embodiment of the present disclosure also provides an instruction testing device, which is applied to the test platform.
  • Figure 7 is a diagram of an instruction testing device provided in the embodiment of the disclosure. Schematic diagram of the program module.
  • the test device for this instruction includes:
  • Determining module 701 configured to determine the minimum time interval between the target instruction and each historical instruction that has been sent to the memory when the test platform has a target instruction to be sent to the memory, and the each historical instruction. The time interval between the issuance time and the current time; there are timing constraints on each historical instruction and the target instruction.
  • the processing module 702 is configured to determine the duration of the vacant instruction based on the minimum time interval between the target instruction and each historical instruction, and the time interval between the issuance time of each historical instruction and the current time. Sent after the last historical instruction and before the target instruction.
  • the sending module 703 is configured to send the target instruction to the memory after the vacant instruction.
  • processing module 702 is used to:
  • the first time of the target instruction relative to each historical instruction is determined respectively. waiting time
  • the maximum value of the first waiting duration of the target instruction relative to the respective historical instructions is determined as the vacant instruction. duration
  • processing module 702 is used to:
  • the first historical instruction will be The difference between a minimum time interval and the first time interval is determined as the first waiting time of the target instruction relative to the first historical instruction;
  • first minimum time interval is less than or equal to the first time interval, it is determined that the first waiting time of the target instruction relative to the first historical instruction is zero.
  • the sending module 703 is used to:
  • the sending time of the target instruction is determined based on the current time and the duration of the idle instruction, and is sent to the memory when the sending time of the target instruction arrives.
  • the target instruction is
  • search module for:
  • each historical instruction that has been sent by the test platform to the memory and has timing constraints with the target instruction is found.
  • the determining module 701 is used to:
  • the minimum time interval between the target instruction and each historical instruction is determined based on the minimum time interval between instructions in the current working mode of the memory.
  • the determining module 701 is used to:
  • the minimum time interval between the target instruction and each historical instruction is determined according to the minimum time interval between instructions at the current timing rate of the memory.
  • the embodiments of the present disclosure also provide a test platform, which includes at least one processor and a memory; wherein, the memory stores computer execution instructions; the above at least one processor The computer execution instructions stored in the memory are executed to implement each step in the instruction testing method described in the above embodiments, which will not be described again in this embodiment.
  • FIG. 8 is a schematic diagram of the hardware structure of a test platform provided by the embodiment of the present disclosure.
  • the test platform 80 of this embodiment includes: a processor 801 and a memory 802; where:
  • Memory 802 used to store computer execution instructions
  • the processor 801 is configured to execute computer execution instructions stored in the memory to implement various steps in the instruction testing method described in the above embodiments. For details, please refer to the relevant descriptions in the foregoing method embodiments.
  • the memory 802 can be independent or integrated with the processor 801 .
  • the device When the memory 802 is provided independently, the device also includes a bus 803 for connecting the memory 802 and the processor 801 .
  • embodiments of the present disclosure also provide a computer-readable storage medium, which stores computer-executable instructions.
  • the processor executes the computer-executed instructions, , to implement each step in the instruction testing method described in the above embodiment, which will not be described again in this embodiment.
  • the disclosed devices and methods can be implemented in other ways.
  • the device embodiments described above are only illustrative.
  • the division of the above modules is only a logical function division. In actual implementation, there may be other division methods.
  • multiple modules may be combined or integrated into Another system, or some features can be ignored, or not implemented.
  • the coupling or direct coupling or communication connection between each other shown or discussed may be through some interfaces, indirect coupling or communication connection of devices or modules, and may be in electrical, mechanical or other forms.
  • the modules described above as separate components may or may not be physically separated.
  • the components shown as modules may or may not be physical units, that is, they may be located in one place, or they may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
  • each functional module in various embodiments of the present disclosure can be integrated into a processing unit, or each module can exist physically alone, or two or more modules can be integrated into one unit.
  • the above-mentioned module integrated units can be implemented in the form of hardware or in the form of hardware plus software functional units.

Landscapes

  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

本公开实施例提供了一种指令的测试方法、装置、测试平台及可读存储介质,涉及半导体技术领域,当测试平台存在待向存储器发送的目标指令时,根据目标指令与各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,在空置指令之后,向存储器发送目标指令,可以不需要人工参与,高效的确定指令之间的时间间隔,从而准确发送各个指令。

Description

指令的测试方法、装置、测试平台及可读存储介质
本公开要求于2022年05月26日提交中国专利局、申请号为202210583104.4、申请名称为“指令的测试方法、装置、测试平台及可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本公开中。
技术领域
本公开实施例涉及半导体技术领域,尤其涉及一种指令的测试方法、装置、测试平台及可读存储介质。
背景技术
在半导体技术领域,存储器会涉及很多种不同的指令,由于存储器内部电路需要时间来响应接收到的指令,因此不同指令之间需要间隔一定的时间。
由于存储器涉及的指令种类众多,多种指令在两两组合后需要确定的时间间隔的数量也会非常多。因此,在日常测试工作中,测试平台如何高效的确定指令之间发送的时间间隔,向存储器准确发送各个指令,是目前亟需解决的技术问题。
发明内容
本公开实施例提供了一种指令的测试方法、装置、测试平台及可读存储介质,测试平台可以高效的确定指令之间发送的时间间隔,进而向存储器准确发送各个指令。
第一方面,本公开提供了一种指令的测试方法,该方法应用于测试平台,包括:
当所述测试平台存在待向存储器发送的目标指令时,确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔;所述各个历史指令与所述目标指令存在时序约束;
根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所 述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,所述空置指令在最后一个所述历史指令之后、所述目标指令之前发送;
在所述空置指令之后,向所述存储器发送所述目标指令。
在一种可行的实施方式中,所述根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,包括:
根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长;
当所述目标指令相对于所述各个历史指令的第一等待时长不均为零时,将所述目标指令相对于所述各个历史指令的第一等待时长中的最大值确定为所述空置指令的时长;
当所述目标指令相对于所述各个历史指令的第一等待时长均为零时,确定所述空置指令的时长为零。
在一种可行的实施方式中,所述根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长,包括:
分别比较所述目标指令与所述各个历史指令之间的最小时间间隔是否大于所述各个历史指令的发出时刻与当前时刻的时间间隔;
若所述目标指令与所述各个历史指令中的第一历史指令之间的第一最小时间间隔,大于所述第一历史指令的发出时刻与当前时刻的第一时间间隔,则将所述第一最小时间间隔与所述第一时间间隔的差值确定为所述目标指令相对于所述第一历史指令的第一等待时长;
若所述第一最小时间间隔小于或等于所述第一时间间隔,则确定所述目标指令相对于所述第一历史指令的第一等待时长为零。
在一种可行的实施方式中,所述在所述空置指令之后,向所述存储器发送所述目标指令,包括:
当所述空置指令的时长为零时,立即向所述存储器发送所述目标指令;
当所述空置指令的时长不为零时,根据所述当前时刻与所述空置指令 的时长,确定所述目标指令的发送时间,并在所述目标指令的发送时间到达时向所述存储器发送所述目标指令。
在一种可行的实施方式中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔之前,还包括:
获取所述存储器对应的时序约束文件;
基于所述时序约束文件,查找出所述测试平台已向所述存储器发送的与所述目标指令存在时序约束的各个历史指令。
在一种可行的实施方式中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,包括:
根据所述存储器的配置信息,确定所述存储器当前的工作模式;
根据所述存储器在当前的工作模式下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
在一种可行的实施方式中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,包括:
确定所述存储器当前的时序速率;
根据所述存储器在当前的时序速率下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
第二方面,本公开提供了一种指令的测试装置,应用于测试平台,包括:
确定模块,用于当所述测试平台存在待向存储器发送的目标指令时,确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔;所述各个历史指令与所述目标指令存在时序约束;
处理模块,用于根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,所述空置指令在最后一个所述历史指令之后、所述目标指令之前发送;
发送模块,用于在所述空置指令之后,向所述存储器发送所述目标指令。
在一种可行的实施方式中,所述处理模块用于:
根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长;
当所述目标指令相对于所述各个历史指令的第一等待时长不均为零时,将所述目标指令相对于所述各个历史指令的第一等待时长中的最大值确定为所述空置指令的时长;
当所述目标指令相对于所述各个历史指令的第一等待时长均为零时,确定所述空置指令的时长为零。
在一种可行的实施方式中,所述处理模块用于:
分别比较所述目标指令与所述各个历史指令之间的最小时间间隔是否大于所述各个历史指令的发出时刻与当前时刻的时间间隔;
若所述目标指令与所述各个历史指令中的第一历史指令之间的第一最小时间间隔,大于所述第一历史指令的发出时刻与当前时刻的第一时间间隔,则将所述第一最小时间间隔与所述第一时间间隔的差值确定为所述目标指令相对于所述第一历史指令的第一等待时长;
若所述第一最小时间间隔小于或等于所述第一时间间隔,则确定所述目标指令相对于所述第一历史指令的第一等待时长为零。
在一种可行的实施方式中,所述发送模块用于:
当所述空置指令的时长为零时,立即向所述存储器发送所述目标指令;
当所述空置指令的时长不为零时,根据所述当前时刻与所述空置指令的时长,确定所述目标指令的发送时间,并在所述目标指令的发送时间到达时向所述存储器发送所述目标指令。
在一种可行的实施方式中,还包括查找模块,用于:
获取所述存储器对应的时序约束文件;
基于所述时序约束文件,查找出所述测试平台已向所述存储器发送的与所述目标指令存在时序约束的各个历史指令。
在一种可行的实施方式中,所述确定模块用于:
根据所述存储器的配置信息,确定所述存储器当前的工作模式;
根据所述存储器在当前的工作模式下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
在一种可行的实施方式中,所述确定模块用于:
确定所述存储器当前的时序速率;
根据所述存储器在当前的时序速率下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
第三方面,本公开提供了一种测试平台,包括:至少一个处理器和存储器;
所述存储器存储计算机执行指令;
所述至少一个处理器执行所述存储器存储的计算机执行指令,使得所述至少一个处理器执行如第一方面提供的指令的测试方法。
第四方面,本公开提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机执行指令,当处理器执行所述计算机执行指令时,实现如第一方面提供的指令的测试方法。
本公开实施例提供的指令的测试方法、装置、测试平台及可读存储介质,当测试平台存在待向存储器发送的目标指令时,根据目标指令与各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,在空置指令之后,向存储器发送目标指令,可以不需要人工参与,高效的确定指令之间的时间间隔,从而准确发送各个指令。
附图说明
图1为本公开实施例中提供的一种指令测试系统的架构示意图;
图2为本公开实施例中提供的一种指令的测试方法的步骤流程示意图一;
图3为本公开实施例中提供的一种存取DRAM的命令信号的时间限制的时序示意图;
图4为本公开实施例中各个历史指令与目标指令的发送时间示意图一;
图5为本公开实施例中提供的一种指令的测试方法的步骤流程示意图二;
图6为本公开实施例中各个历史指令与目标指令的发送时间示意图二;
图7为本公开实施例中提供的一种指令的测试装置的程序模块示意图;
图8为本公开实施例提供的一种测试平台的硬件结构示意图。
具体实施方式
为使本公开实施例的目的、技术方案和优点更加清楚,下面将结合本公开实施例中的附图,对本公开实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本公开一部分实施例,而不是全部的实施例。基于本公开中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本公开保护的范围。此外,虽然本公开中公开内容按照示范性一个或几个实例来介绍,但应理解,可以就这些公开内容的各个方面也可以单独构成一个完整实施方式。
需要说明的是,本公开中对于术语的简要说明,仅是为了方便理解接下来描述的实施方式,而不是意图限定本公开的实施方式。除非另有说明,这些术语应当按照其普通和通常的含义理解。
本公开中说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似或同类的对象或实体,而不必然意味着限定特定的顺序或先后次序,除非另外注明。应该理解这样使用的用语在适当情况下可以互换,例如能够根据本公开实施例图示或描述中给出那些以外的顺序实施。
此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖但不排他的包含,例如,包含了一系列组件的产品或设备不必限于清楚地列出的那些组件,而是可包括没有清楚地列出的或对于这些产品或设备固有的其它组件。
本公开实施例中使用的术语“模块”,是指任何已知或后来开发的硬件、软件、固件、人工智能、模糊逻辑或硬件或/和软件代码的组合,能够执行与该元件相关的功能。
本公开实施例可以应用于半导体领域,例如可以应用于存储器测试环节中。
在半导体领域中,存储器会涉及很多种不同的指令。以动态随机存取存储器(Dynamic Random Access Memory,简称DRAM)为例,DRAM常见的指令有Active指令、Precharge指令、Read指令、Write指令、模式寄存器写入(Mode Register Write,简称MRW)指令、模式寄存器读取(Mode  Register Read,简称MRR)指令、Refersh指令、Self-Refrresh指令、Powerdown指令等。
可以理解的时,每当有指令发送至存储器时,存储器内部电路都需要一定的时间来响应接收到的指令,因此为了保障存储器能够响应每一条指令,向存储器发送的不同指令之间需要间隔一定的时间。例如,工业标准制定协会(Joint Electron Device Engineering Council,简称JEDEC)标准性能评估组织(Standard Performance Evaluation Corporation,简称SPEC)通常会对不同DRAM产品的指令进行详细定义,并规定出两两指令之间的最小间隔时间。
在实际应用过程中,由于存储器涉及的指令种类众多,多种指令在两两组合后形成的最小时间间隔的数量也会非常多,且最小间隔时间还受到存储器运行速率、模式配置、存储结构选择等因素的影响,因此计算两两指令之间的最小间隔时间复杂且繁琐。
目前,在日常测试工作中,很大一部分内容就是编写测试激励,而测试激励实质上是存储器在各种工作情况一个个指令的组合,这些指令间的时间间隔必须要根据SPEC的定义最小间隔时间来控制,否则就是非法或是无效的激励,没有测试意义。
然而,如果每次添加新的激励都需要测试人员重新计算指令间的间隔时间,那么测试人员的工作量无疑是巨大的,因此,如何自动计算两两指令间的最小时间间隔,是目前亟需解决的技术问题。
面对上述技术问题,本公开实施例中提供了一种指令的测试方法,当测试平台存在待向存储器发送的目标指令时,根据目标指令与各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,在空置指令之后,向存储器发送目标指令,由此可以不需要人工参与,高效的确定指令之间的时间间隔,从而准确发送各个指令。详细过程可以参照以下实施例。
参照图1,图1为本公开实施例中提供的一种指令测试系统的架构示意图。
在本公开一些实施例中,上述指令测试系统包括测试平台101与存储器102,其中,测试平台101与存储器102通信连接。
其中,测试平台101可以模拟出各种类型的存储器所使用的各种指令,在测试过程中,测试平台101可以向存储器102发送各种不同指令,以及控制各个指令之间的发送时间间隔。
另外,测试平台101还可以具有接收信号、数据处理、验证等功能,如检查存储器102是否成功执行各指令等。
可选的,存储器102可以为各种类型的存储器,如DRAM、只读存储器(ROM)、随机读写存储器(RAM)等,本公开实施例中不做限制。
参照图2,图2为本公开实施例中提供的一种指令的测试方法的步骤流程示意图一。在本公开一些实施例中,上述指令的测试方法包括:
S201、当测试平台存在待向存储器发送的目标指令时,确定目标指令与已向存储器发送的各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔。
其中,上述各个历史指令与目标指令存在时序约束。
在一些实施例中,时序约束主要包括周期约束、偏移约束、静态时序路径约束等。
示例性的,以常见的建立时间(setup time)与保持时间(hold time)为例,建立时间是指在时钟有效沿之前,数据输入端信号必须保持稳定的最短时间;保持时间是指在时钟有效沿之后,数据输入端信号必须保持稳定的最短时间。
可以理解的是,在理想情况下,只要在时钟有效沿来临时,有效数据也来临(时钟有效沿之前或同时),则时序逻辑元件便能够正确采集到数据;而在时钟有效沿之后(或同时),即使数据发生变化,也不会影响时序逻辑元件的输出了。然而在实际情况中,时钟沿打开开关需要时间,逻辑门的状态改变(电容充放电等)也都需要时间,因此数据的采集是需要一定时间的,在这个时间内数据不能发生变化,即在时钟有效沿来临之前,数据必须提前一个最小时间量“预先准备好”,这个最小时间量就是上述建立时间。另外,时钟沿关闭开关也需要时间,如果在这个时间段内数据有变化的话,那么新数据就有可能被传递到下一级,进而发生错误,所以数据必须保持一定时间不变,即在时钟有效沿来临之后,数据必须保持一个最小时间量“不能变化”,这个最小时间量就是上述保持时间。
为了更好的理解本公开实施例,参照图3,图3为本公开实施例中提供的一种存取DRAM的命令信号的时间限制的时序示意图。
在图3中,为了简便起见,省略了DRAM相关的地址信号与数据信号波形。在时序示意图中,启动信号(active command)10表示行存取时间,其是在DRAM控制器发给DRAM的行地址时,预充命令(预充信号)20表示一个预充命令时间,其是在DRAM控制器发给DRAM的预充命令时。需要注意的是,在一个DRAM的规格中定义的行启动时间(row active time)tRAS,需要在启动信号10与预充信号20之间存在。换句话说,行启动时间tRAS需要一个绝对时间差(absolute timing gap),存在于DRAM的行启动与预充DRAM的该启动的行之间。
举例来说,当启动时间tRAS是20ns,DRAM控制器在发送启动信号10之后的20ns内不能发送预充信号20给DRAM,否则发送的预充信号20就是无效信号。为了满足tRAS这个条件,DRAM控制器可使用一计数器来对DRAM控制器以及DRAM的相应的时钟周期数计数。举例来说,如果DRAM子系统的时钟CLK的频率是200MHz(即时钟周期是5ns),DRAM控制器会如下操作:发送启动信号10;计数至少CLK4个时钟周期;发送预充信号20。
在本公开一些实施例中,当测试平台每次发送一个新的指令时,首先计算该指令在当前配置和速率下与之前各个存在时序约束的历史指令之间的最小时间间隔,同时,测试平台实时记录下上述各个历史指令发出之后到当前时刻的时间间隔。
为了更好的理解本公开实施例,参照图4,图4为本公开实施例中各个历史指令与目标指令的发送时间示意图一。
如图4所示,假设测试平台在当前时刻tf存在待向存储器发送的目标指令F,确定测试平台已发送的指令中,指令a、指令b及指令c与目标指令F存在时序约束,则分别确定目标指令F与指令a、指令b及指令c之间的最小时间间隔,同时确定指令a的发出时刻ta与当前时刻tf的时间间隔、指令b的发出时刻tb与当前时刻tf的时间间隔、指令c的发出时刻tc与当前时刻tf的时间间隔。
S202、根据目标指令与各个历史指令之间的最小时间间隔,以及各个 历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长。
其中,上述空置指令在最后一个历史指令之后、目标指令之前发送。
可以理解的是,如果某个历史指令的发出时刻与当前时刻的时间间隔大于或等于该历史指令与目标指令之间的最小时间间隔,则当目标指令立即发送之后,该历史指令与目标指令之间能够满足时序要求;如果某个历史指令的发出时刻与当前时刻的时间间隔小于该历史指令与目标指令之间的最小时间间隔,则当目标指令立即发送之后,由于该历史指令与目标指令之间无法满足时序要求,因此存储器可能会无法响应或者出现响应错误。
在一些实施例中,如果某个历史指令的发出时刻与当前时刻的时间间隔小于该历史指令与目标指令之间的最小时间间隔,则为了使该历史指令与目标指令之间能够满足时序要求,可以根据该历史指令与目标指令之间的最小时间间隔,以及该历史指令的发出时刻与当前时刻的时间间隔,发送一个空置指令,等该空置指令结束后,再发送目标指令。由于该空置指令具有一定的时长,相当于从当前时刻起,等待一定时长之后,再发送目标指令。
在一些实施例中,如果测试平台已向存储器发送的指令中存在多个与当前要发送的目标指令存在时序约束的历史指令时,可以确定出目标指令相对于各个历史指令的等待时长,然后在目标指令相对于各个历史指令的等待时长中取最大值,作为空置指令的时长。
S203、在空置指令之后,向存储器发送目标指令。
在一些实施例中,在确定空置指令的时长后,发送空置指令,并在空置指令结束后,向存储器发送目标指令。相当于是从当前时刻开始计时,在等待空置指令的时长后再发送目标指令,由此可以保证在目标指令发送之后,目标指令与上述各个历史指令均能够满足时序要求。
本公开实施例提供的指令的测试方法,当测试平台存在待向存储器发送的目标指令时,根据目标指令与各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,在空置指令之后,向存储器发送目标指令,可以不需要人工参与,高效的确定指令之间的时间间隔,从而准确发送各个指令。
基于上述实施例中描述的内容,在一些实施例中,参照图5,图5为 本公开实施例中提供的一种指令的测试方法的步骤流程示意图二。在本公开一些实施例中,上述指令的测试方法包括:
S501、当测试平台存在待向存储器发送的目标指令时,确定目标指令与已向存储器发送的各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔。
其中,上述各个历史指令与目标指令存在时序约束。
在一些实施例中,测试平台可以预先获取存储器对应的时序约束文件;当测试平台存在待向存储器发送的目标指令时,基于该时序约束文件,查找出测试平台已向存储器发送的与目标指令存在时序约束的各个历史指令。
在本公开一些实施例中,当测试平台存在待向存储器发送的目标指令时,可以获取存储器对应的标准规则文件,从标准规则文件中确定出目标指令与上述各个历史指令之间的最小时间间隔。
在本公开另一些实施例中,当测试平台存在待向存储器发送的目标指令时,可以根据存储器的配置信息,确定存储器当前的工作模式;根据存储器在当前的工作模式下各个指令之间的最小时间间隔,确定出目标指令与上述各个历史指令之间的最小时间间隔。
可以理解的是,当存储器对应的配置信息不同时,其对应的工作模式也会不同。
示例性的,以全新低功耗内存标准(Low Power Double Data Rate 5,简称LPDDR5)DRAM为例,LPDDR5 DRAM支持三种工作模式,即Bank-Group模式(配置4个Bank,4Bank-Group)、8Bank模式(配置8个Bank,no Bank-Group)以及16Bank模式(配置16个Bank,no Bank-Group)。
其中,当存储器处于不同的工作模式时,所对应的速度也会存在区别,如Bank-Group模式适用于高于3200Mbps的速度,并允许16和32比特的突发长度。8Bank模式支持突发长度为32比特的所有速度,而16Bank模式则支持突发长度为16或32比特的3200Mbps以下的速度。
由于存储器在不同的工作模式下的速度不同,因此存储器在不同的工作模式下所采用的时钟信号也会不同,由此可能会导致相同两个指令之间的最小时间间隔不同。
例如,假设Bank-Group模式采用的时钟信号的周期为X(ns),16Bank模式采用的时钟信号的周期为Y(ns),某两个指令之间的最小时间间隔为n个时钟周期,其中,X≠Y。则在Bank-Group模式下,上述两个指令之间的最小时间间隔为n*X(ns);在16Bank模式下,上述两个指令之间的最小时间间隔为n*Y(ns)。
在本公开又一些实施例中,当测试平台存在待向存储器发送的目标指令时,可以先确定存储器当前的时序速率;根据存储器在当前的时序速率下各个指令之间的最小时间间隔,确定目标指令与所述各个历史指令之间的最小时间间隔。
其中,由于存储器在不同的时序速率下,所采用的时钟信号的周期会不同,因此,当存储器的时序速率不同时,相同两个指令之间的最小时间间隔可能也会不同。
例如,假设在标准协议中已经规定了某两个指令之间的最小时间间隔为max(5,12nWCK),则在当12nWCK>5时,上述两个指令之间的最小时间间隔由存储器的时钟信号来决定,即存储器当前的时序速率越高,上述两个指令之间的最小时间间隔越小。
S502、根据目标指令与各个历史指令之间的最小时间间隔,以及各个历史指令的发出时刻与当前时刻的时间间隔,分别确定目标指令相对于各个历史指令的第一等待时长。
在一些实施例中,可以分别比较目标指令与各个历史指令之间的最小时间间隔是否大于各个历史指令的发出时刻与当前时刻的时间间隔;若目标指令与各个历史指令中的第一历史指令之间的第一最小时间间隔,大于第一历史指令的发出时刻与当前时刻的第一时间间隔,则将第一最小时间间隔与上述第一时间间隔的差值确定为目标指令相对于上述第一历史指令的第一等待时长;若上述第一最小时间间隔小于或等于上述第一时间间隔,则确定目标指令相对于上述第一历史指令的第一等待时长为零。
为了更好的理解本公开实施例,仍旧参照图4,假设测试平台在当前时刻tf存在待向存储器发送的目标指令F,确定测试平台已发送的指令中,指令a、指令b及指令c与目标指令F存在时序约束,分别确定目标指令F与指令a、指令b及指令c之间的最小时间间隔为m1、m2、m3;同时确 定指令a的发出时刻ta与当前时刻tf的时间间隔为k1、指令b的发出时刻tb与当前时刻tf的时间间隔为k2、指令c的发出时刻tc与当前时刻tf的时间间隔为k3。
则在一些实施例中,若m1>k1,则目标指令F相对于指令a的第一等待时长d1为:d1=m1-k1;若m1≤k1,则d1=0。
若m2>k2,则目标指令F相对于指令b的第一等待时长d2为:d2=m2-k2;若m2≤k2,则d2=0。
若m2>k2,则目标指令F相对于指令c的第一等待时长d3为:d3=m3-k3;若m3≤k3,则d3=0。
S503、判断目标指令相对于各个历史指令的第一等待时长是否均为零;当目标指令相对于各个历史指令的第一等待时长不均为零时,执行S504与S505;当目标指令相对于各个历史指令的第一等待时长均为零时,执行S506。
S504、将目标指令相对于各个历史指令的第一等待时长中的最大值确定为空置指令的时长。
在一些实施例中,当目标指令相对于各个历史指令的第一等待时长不均为零时,说明目标指令需要等待一定时长之后才能再发送。为了确保目标指令发送之后,目标指令与各个历史指令均满足时序要求,因此可以选择目标指令相对于各个历史指令的第一等待时长中的最大值作为空置指令的时长。
S505、根据当前时刻与空置指令的时长,确定目标指令的发送时间,并在目标指令的发送时间到达时向存储器发送目标指令。
在一些实施例中,确定空置指令的时长之后,即可根据当前时刻与空置指令的时长,确定目标指令的发送时间。例如,假设当前时刻为tf,空置指令的时长为T,则可以确定目标指令的发送时间为tf+T。
在确定目标指令的发送时间之后,监测测试平台的时钟,当监测到目标指令的发送时间到达时,立即向存储器发送目标指令。
S506、确定空置指令的时长为零,立即向存储器发送目标指令。
在一些实施例中,当目标指令相对于各个历史指令的第一等待时长均为零时,说明各个历史指令的发出时刻与当前时刻的时间间隔均大于或等 于各个历史指令与目标指令之间的最小时间间隔,此种情况下,测试平台无需等待,可以直接向存储器发送目标指令。
本公开实施例提供的指令的测试方法,当测试平台存在待向存储器发送的目标指令时,先确定目标指令与各个历史指令之间的最小时间间隔,同时记录各个历史指令的发出时刻与当前时刻的时间间隔,根据目标指令与各个历史指令之间的最小时间间隔是否大于各个历史指令的发出时刻与当前时刻的时间间隔,来确定目标指令相对于各个历史指令的等待时长,选择目标指令相对于各个历史指令的等待时长中的最大值作为空置指令的时长,由此可以保证目标指令在发送之后,与上述各个历史指令之间均能够满足时序要求。
基于上述实施例中所描述的内容,为了更好的理解本公开实施例,参照图6,图6为本公开实施例中各个历史指令与目标指令的发送时间示意图二。
在本公开一些实施例中,假设测试平台在当前时刻存在待向存储器发送的目标指令F,确定测试平台已发送的指令中,指令a、指令b及指令c与目标指令F存在时序约束,若分别确定目标指令F相对于指令a的第一等待时长为d1,目标指令F相对于指令b的第一等待时长为d2,目标指令F相对于指令c的第一等待时长为d3,则取上述d1、d2、d3的最大值作为空置指令的时长。
在本公开一些实施例中,在确定出空置指令的时长后,还可以确定出指令c与目标指令F的时间间隔。其中,指令c与目标指令F的时间间隔为指令c的发出时刻与当前时刻的时间间隔+空置指令的时长。
本公开实施例提供的指令的测试方法,当测试平台存在待向存储器发送的目标指令时,可以根据确定的目标指令相对于各个历史指令的等待时长,来自动确定出目标指令的发送时间,此过程不需要人工参与,由此可以有效提升存储器的测试效率。
基于上述实施例中所描述的内容,本公开实施例中还提供一种指令的测试装置,应用于测试平台,参照图7,图7为本公开实施例中提供的一种指令的测试装置的程序模块示意图,该指令的测试装置包括:
确定模块701,用于当所述测试平台存在待向存储器发送的目标指令 时,确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔;所述各个历史指令与所述目标指令存在时序约束。
处理模块702,用于根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,所述空置指令在最后一个所述历史指令之后、所述目标指令之前发送。
发送模块703,用于在所述空置指令之后,向所述存储器发送所述目标指令。
在一种可行的实施方式中,处理模块702用于:
根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长;
当所述目标指令相对于所述各个历史指令的第一等待时长不均为零时,将所述目标指令相对于所述各个历史指令的第一等待时长中的最大值确定为所述空置指令的时长;
当所述目标指令相对于所述各个历史指令的第一等待时长均为零时,确定所述空置指令的时长为零。
在一种可行的实施方式中,处理模块702用于:
分别比较所述目标指令与所述各个历史指令之间的最小时间间隔是否大于所述各个历史指令的发出时刻与当前时刻的时间间隔;
若所述目标指令与所述各个历史指令中的第一历史指令之间的第一最小时间间隔,大于所述第一历史指令的发出时刻与当前时刻的第一时间间隔,则将所述第一最小时间间隔与所述第一时间间隔的差值确定为所述目标指令相对于所述第一历史指令的第一等待时长;
若所述第一最小时间间隔小于或等于所述第一时间间隔,则确定所述目标指令相对于所述第一历史指令的第一等待时长为零。
在一种可行的实施方式中,发送模块703用于:
当所述空置指令的时长为零时,立即向所述存储器发送所述目标指令;
当所述空置指令的时长不为零时,根据所述当前时刻与所述空置指令 的时长,确定所述目标指令的发送时间,并在所述目标指令的发送时间到达时向所述存储器发送所述目标指令。
在一种可行的实施方式中,还包括查找模块,用于:
获取所述存储器对应的时序约束文件;
基于所述时序约束文件,查找出所述测试平台已向所述存储器发送的与所述目标指令存在时序约束的各个历史指令。
在一种可行的实施方式中,确定模块701用于:
根据所述存储器的配置信息,确定所述存储器当前的工作模式;
根据所述存储器在当前的工作模式下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
在一种可行的实施方式中,确定模块701用于:
确定所述存储器当前的时序速率;
根据所述存储器在当前的时序速率下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
需要说明的是,本公开实施例中确定模块701、处理模块702及发送模块703具体执行的内容可以参阅图1至图6所示实施例中相关内容,此处不做赘述。
进一步的,基于上述实施例中所描述的内容,本公开实施例中还提供了一种测试平台,该测试平台包括至少一个处理器和存储器;其中,存储器存储计算机执行指令;上述至少一个处理器执行存储器存储的计算机执行指令,以实现如上述实施例中描述的指令的测试方法中的各个步骤,本实施例此处不再赘述。
为了更好的理解本公开实施例,参照图8,图8为本公开实施例提供的一种测试平台的硬件结构示意图。
如图8所示,本实施例的测试平台80包括:处理器801以及存储器802;其中:
存储器802,用于存储计算机执行指令;
处理器801,用于执行存储器存储的计算机执行指令,以实现上述实施例中描述的指令的测试方法中的各个步骤,具体可以参见前述方法实施例中的相关描述。
可选地,存储器802既可以是独立的,也可以跟处理器801集成在一起。
当存储器802独立设置时,该设备还包括总线803,用于连接存储器802和处理器801。
进一步的,基于上述实施例中所描述的内容,本公开实施例中还提供了一种计算机可读存储介质,该计算机可读存储介质中存储有计算机执行指令,当处理器执行计算机执行指令时,以实现如上述实施例中描述的指令的测试方法中的各个步骤,本实施例此处不再赘述。
在本公开所提供的几个实施例中,应该理解到,所揭露的设备和方法,可以通过其它的方式实现。例如,以上所描述的设备实施例仅仅是示意性的,例如,上述模块的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个模块可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或模块的间接耦合或通信连接,可以是电性,机械或其它的形式。
上述作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。
另外,在本公开各个实施例中的各功能模块可以集成在一个处理单元中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个单元中。上述模块集成的单元既可以采用硬件的形式实现,也可以采用硬件加软件功能单元的形式实现。
最后应说明的是:以上各实施例仅用以说明本公开的技术方案,而非对其限制;尽管参照前述各实施例对本公开进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分或者全部技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本公开各实施例技术方案的范围。

Claims (16)

  1. 一种指令的测试方法,所述方法应用于测试平台,包括:
    当所述测试平台存在待向存储器发送的目标指令时,确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔;所述各个历史指令与所述目标指令存在时序约束;
    根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,所述空置指令在最后一个所述历史指令之后、所述目标指令之前发送;
    在所述空置指令之后,向所述存储器发送所述目标指令。
  2. 根据权利要求1所述的方法,其中,所述根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,包括:
    根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长;
    当所述目标指令相对于所述各个历史指令的第一等待时长不均为零时,将所述目标指令相对于所述各个历史指令的第一等待时长中的最大值确定为所述空置指令的时长;
    当所述目标指令相对于所述各个历史指令的第一等待时长均为零时,确定所述空置指令的时长为零。
  3. 根据权利要求2所述的方法,其中,所述根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长,包括:
    分别比较所述目标指令与所述各个历史指令之间的最小时间间隔是否大于所述各个历史指令的发出时刻与当前时刻的时间间隔;
    若所述目标指令与所述各个历史指令中的第一历史指令之间的第一最小时间间隔,大于所述第一历史指令的发出时刻与当前时刻的第一时间间隔,则将所述第一最小时间间隔与所述第一时间间隔的差值确定为所述目 标指令相对于所述第一历史指令的第一等待时长;
    若所述第一最小时间间隔小于或等于所述第一时间间隔,则确定所述目标指令相对于所述第一历史指令的第一等待时长为零。
  4. 根据权利要求2所述的方法,其中,所述在所述空置指令之后,向所述存储器发送所述目标指令,包括:
    当所述空置指令的时长为零时,立即向所述存储器发送所述目标指令;
    当所述空置指令的时长不为零时,根据所述当前时刻与所述空置指令的时长,确定所述目标指令的发送时间,并在所述目标指令的发送时间到达时向所述存储器发送所述目标指令。
  5. 根据权利要求1所述的方法,其中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔之前,还包括:
    获取所述存储器对应的时序约束文件;
    基于所述时序约束文件,查找出所述测试平台已向所述存储器发送的与所述目标指令存在时序约束的各个历史指令。
  6. 根据权利要求1所述的方法,其中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,包括:
    根据所述存储器的配置信息,确定所述存储器当前的工作模式;
    根据所述存储器在当前的工作模式下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
  7. 根据权利要求1所述的方法,其中,所述确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,包括:
    确定所述存储器当前的时序速率;
    根据所述存储器在当前的时序速率下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
  8. 一种指令的测试装置,应用于测试平台,包括:
    确定模块,用于当所述测试平台存在待向存储器发送的目标指令时,确定所述目标指令与已向所述存储器发送的各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔;所述各个历史指令与所述目标指令存在时序约束;
    处理模块,用于根据所述目标指令与所述各个历史指令之间的最小时 间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,确定空置指令的时长,所述空置指令在最后一个所述历史指令之后、所述目标指令之前发送;
    发送模块,用于在所述空置指令之后,向所述存储器发送所述目标指令。
  9. 根据权利要求8所述的装置,其中,所述处理模块用于:
    根据所述目标指令与所述各个历史指令之间的最小时间间隔,以及所述各个历史指令的发出时刻与当前时刻的时间间隔,分别确定所述目标指令相对于所述各个历史指令的第一等待时长;
    当所述目标指令相对于所述各个历史指令的第一等待时长不均为零时,将所述目标指令相对于所述各个历史指令的第一等待时长中的最大值确定为所述空置指令的时长;
    当所述目标指令相对于所述各个历史指令的第一等待时长均为零时,确定所述空置指令的时长为零。
  10. 根据权利要求9所述的装置,其中,所述处理模块用于:
    分别比较所述目标指令与所述各个历史指令之间的最小时间间隔是否大于所述各个历史指令的发出时刻与当前时刻的时间间隔;
    若所述目标指令与所述各个历史指令中的第一历史指令之间的第一最小时间间隔,大于所述第一历史指令的发出时刻与当前时刻的第一时间间隔,则将所述第一最小时间间隔与所述第一时间间隔的差值确定为所述目标指令相对于所述第一历史指令的第一等待时长;
    若所述第一最小时间间隔小于或等于所述第一时间间隔,则确定所述目标指令相对于所述第一历史指令的第一等待时长为零。
  11. 根据权利要求9所述的装置,其中,所述发送模块用于:
    当所述空置指令的时长为零时,立即向所述存储器发送所述目标指令;
    当所述空置指令的时长不为零时,根据所述当前时刻与所述空置指令的时长,确定所述目标指令的发送时间,并在所述目标指令的发送时间到达时向所述存储器发送所述目标指令。
  12. 根据权利要求8所述的装置,其中,还包括查找模块,用于:
    获取所述存储器对应的时序约束文件;
    基于所述时序约束文件,查找出所述测试平台已向所述存储器发送的与所述目标指令存在时序约束的各个历史指令。
  13. 根据权利要求8所述的装置,其中,所述确定模块用于:
    根据所述存储器的配置信息,确定所述存储器当前的工作模式;
    根据所述存储器在当前的工作模式下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
  14. 根据权利要求8所述的装置,其中,所述确定模块用于:
    确定所述存储器当前的时序速率;
    根据所述存储器在当前的时序速率下各个指令之间的最小时间间隔,确定所述目标指令与所述各个历史指令之间的最小时间间隔。
  15. 一种测试平台,包括:至少一个处理器和存储器;
    所述存储器存储计算机执行指令;
    所述至少一个处理器执行所述存储器存储的计算机执行指令,使得所述至少一个处理器执行如权利要求1至7任一项所述的指令的测试方法。
  16. 一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机执行指令,当处理器执行所述计算机执行指令时,实现如权利要求1至7任一项所述的指令的测试方法。
PCT/CN2022/096076 2022-05-26 2022-05-30 指令的测试方法、装置、测试平台及可读存储介质 WO2023226061A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US17/899,056 US11977465B2 (en) 2022-05-26 2022-08-30 Method for testing a command, an apparatus for testing a command and a readable storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210583104.4 2022-05-26
CN202210583104.4A CN117174160A (zh) 2022-05-26 2022-05-26 指令的测试方法、装置、测试平台及可读存储介质

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/899,056 Continuation US11977465B2 (en) 2022-05-26 2022-08-30 Method for testing a command, an apparatus for testing a command and a readable storage medium

Publications (1)

Publication Number Publication Date
WO2023226061A1 true WO2023226061A1 (zh) 2023-11-30

Family

ID=88918292

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/096076 WO2023226061A1 (zh) 2022-05-26 2022-05-30 指令的测试方法、装置、测试平台及可读存储介质

Country Status (2)

Country Link
CN (1) CN117174160A (zh)
WO (1) WO2023226061A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101403958A (zh) * 2007-10-03 2009-04-08 佳能株式会社 存储器访问控制装置、命令发出装置和方法
WO2016113223A1 (en) * 2015-01-12 2016-07-21 The University Of Manchester Monitoring device
CN108139994A (zh) * 2016-05-28 2018-06-08 华为技术有限公司 内存访问方法及内存控制器
US20210278999A1 (en) * 2020-03-05 2021-09-09 SK Hynix Inc. Memory system for accurately predicting power required for sequential command operations performed in memory device, and operation method thereof
CN114297103A (zh) * 2020-10-07 2022-04-08 爱思开海力士有限公司 存储器控制器和包括其的存储系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101403958A (zh) * 2007-10-03 2009-04-08 佳能株式会社 存储器访问控制装置、命令发出装置和方法
WO2016113223A1 (en) * 2015-01-12 2016-07-21 The University Of Manchester Monitoring device
CN108139994A (zh) * 2016-05-28 2018-06-08 华为技术有限公司 内存访问方法及内存控制器
US20210278999A1 (en) * 2020-03-05 2021-09-09 SK Hynix Inc. Memory system for accurately predicting power required for sequential command operations performed in memory device, and operation method thereof
CN114297103A (zh) * 2020-10-07 2022-04-08 爱思开海力士有限公司 存储器控制器和包括其的存储系统

Also Published As

Publication number Publication date
CN117174160A (zh) 2023-12-05

Similar Documents

Publication Publication Date Title
US11010062B2 (en) Method for providing read data flow control or error reporting using a read data strobe
WO2020155074A1 (zh) 一种处理装置、方法及相关设备
WO2017092002A1 (zh) 应用于计算机系统的数据迁移方法和装置、计算机系统
US20210264999A1 (en) Method and apparatus for memory chip row hammer threat backpressure signal and host side response
US10481819B2 (en) Memory devices with multiple sets of latencies and methods for operating the same
US12009023B2 (en) Training for chip select signal read operations by memory devices
CN102117193A (zh) 一种实现预读式fifo的方法和预读式fifo
WO2019141050A1 (zh) 一种刷新处理方法、装置、系统及内存控制器
US8751853B2 (en) Quad-data rate controller and implementing method thereof
TW202031039A (zh) 應用在主裝置與從裝置之間的資料傳輸及處理方法、應用於從裝置的資料處理方法、以及用於資料處理的從裝置
US11977465B2 (en) Method for testing a command, an apparatus for testing a command and a readable storage medium
WO2023226061A1 (zh) 指令的测试方法、装置、测试平台及可读存储介质
WO2024027140A1 (zh) 一种数据处理方法、装置、设备、系统及可读存储介质
WO2021207972A1 (zh) 数据传输方法、数据传输装置、电子设备和存储介质
WO2017065802A1 (en) Scrubbing data in a memory device
CN116955240B (zh) 一种ddr控制器中phy电路的延时校准系统及方法
US20240329839A1 (en) Clock Domain Phase Adjustment for Memory Operations
TWI715294B (zh) 基於系統管理匯流排界面對i2c記憶體進行讀寫的方法
US10978133B2 (en) Memory device and memory system comprising the same
WO2024031798A1 (zh) 高带宽ddr双列直插式存储模块、存储系统及其操作方法
CN109582615B (zh) 一种ddr3控制系统
TW202044248A (zh) 記憶體儲存裝置及其運作方法
TW202427206A (zh) 用於互連協定於休眠運作時的組態資料處理方法、控制器以及電子裝置
TWI615853B (zh) 記憶體裝置、記憶體控制器與其控制方法
KR20240045649A (ko) 메모리 장치, 메모리 시스템 및 메모리 시스템의 동작 방법

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22943258

Country of ref document: EP

Kind code of ref document: A1