FIFO circuit, method, chip and device based on register output of dual-port RAM

The FIFO circuit with a gated clock register module addresses routing delays by maintaining valid RAM read data output and simplifying layout, reducing power consumption and path delays in dual-port RAM-based circuits.

CN118606233BActive Publication Date: 2024-12-03CORE TREND (ZHUHAI) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411055212.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2024-12-03
Estimated Expiration
2044-08-02

AI Technical Summary

Technical Problem

Existing FIFO circuits using dual-port RAMs face significant routing delays that restrict the maximum clock frequency of chips and FPGAs, especially as FIFO depth increases, due to fixed RAM locations and inefficient register output modes that lead to invalid data and path delays.

Method used

A FIFO circuit utilizing a gated clock register module to control the output of dual-port RAM read data, ensuring continuous validity and reducing dynamic power consumption and path delays by filtering invalid data and simplifying layout and wiring.

Benefits of technology

The gated clock register module maintains valid RAM read data output, reduces dynamic flipping, and shortens path delays, improving the logic wiring effect and layout complexity of the FIFO circuit.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118606233B_ABST
    Figure CN118606233B_ABST
Patent Text Reader

Abstract

The present invention provides a FIFO circuit, method, chip and device based on the register output of a dual-port RAM, wherein the circuit includes: a write control module, a read control module, a dual-port RAM module, and a clock synchronization module, wherein the dual-port RAM module is respectively connected to the write control module and the read control module, the clock synchronization module is respectively connected to the write control module and the read control module, and the dual-port RAM module includes a RAM unit, wherein it also includes: a gated clock register module, the gated clock register module includes a gated clock unit and a register, the gated clock unit is respectively connected to the clock end of the read control module and the register, the data input end of the register is connected to the RAM unit, and the gated clock unit is used to obtain a RAM read enable signal and a RAM read clock signal from the read control module, and output a gated signal to the clock end of the register based on the RAM read enable signal and the RAM read clock signal. The present invention can continuously maintain the effectiveness of RAM read data and improve the logic wiring effect of the FIFO circuit.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data storage, and in particular to a FIFO circuit, method, chip and device based on register output of a dual-port RAM. Background Art

[0002] In the field of chip design or FPGA (Field Programmable Gate Array) development, the interface signal of FIFO (First Input First Output) is usually converted into the read and write interface timing of FIFO based on the control logic circuit of dual-port RAM (Random Access Memory). The data bit width of FIFO is the data bit width of RAM; the depth of FIFO is the depth of RAM. The read and write operations of FIFO are independent of each other, and they can be performed simultaneously according to the status of the read and write interfaces, so FIFO generally uses dual-port RAM.

[0003] See also Figure 1 The structure of the existing FIFO circuit is usually divided into four parts: write control logic circuit 101, dual-port RAM 102, read control logic circuit 103, and read-write synchronization circuit 104. The write control logic circuit 101 generates a write data pointer or a write count, controls the write enable, write address, write data, etc. of the dual-port RAM 102, and generates a full flag signal of the FIFO. The read control logic circuit 103 generates a read data pointer or a read count, controls the read enable, read address, read data, etc. of the dual-port RAM 102, and generates an empty flag signal of the FIFO. The read-write synchronization circuit 104 is used to synchronize the write data pointer or the write count to the read control clock domain so as to compare with the read data pointer or the read count to generate an empty flag signal, and is used to synchronize the read data pointer or the read count to the write control clock domain and compare with the write data pointer or the write count to generate a full flag signal.

[0004] When designing chips and developing FPGAs, the RAM standard unit IPs provided by IP (Intellectual Property) providers are all RAM blocks. A deep FIFO requires multiple standard unit RAM blocks to be spliced ​​together. When reading and writing RAM data in the FIFO, there is a routing delay, which will become larger and larger as the depth of the FIFO increases, which will seriously restrict the maximum clock frequency that the entire chip or FPGA can achieve. Especially for FPGAs, the location of its RAM in the chip is fixed, which leads to a greater read routing delay when reading data. See Figure 2,As the number n of RAM BLOCKs increases, the routing length of the output data q to the output selection circuit MUX_SEL becomes longer, resulting in a greater routing circuit delay.

[0005] In order to solve the problem of excessive delay in RAM read data routing, there are usually two ways. One is to add an extra level of read data register logic output outside the RAM IP core, and the other is to use the ready-made register mode provided by the RAM IP core provider, and the registers that come with the RAM IP core directly output the read data. The difference between the two register outputs lies in the routing distance between the register and the RAM read data. The registers in the IP's own register mode are adjacent to each RAM BLOCK module, and the routing distance is shorter, so theoretically a higher maximum clock frequency can be obtained.

[0006] When using the register output mode of RAM, including adding register output outside the RAM or using the register mode output of the RAM IP core. However, the existing RAM register output mode still has some disadvantages, such as the last read data of the RAM is fixed to be valid within one clock cycle after the read address and cannot remain valid all the time, and because certain data control logic needs to be set after the register output to adapt to the sequential logic or combinational logic of the subsequent use of the read data, it will bring a certain path delay. Summary of the invention

[0007] The first object of the present invention is to provide a FIFO circuit based on a register output of a dual-port RAM, which can maintain the continuous validity of RAM read data and improve the logic wiring effect of the FIFO circuit.

[0008] The second object of the present invention is to provide a FIFO control method based on register output of a dual-port RAM, which can maintain the continuous validity of RAM read data and improve the logic wiring effect of the FIFO circuit.

[0009] A third object of the present invention is to provide a chip comprising the above-mentioned FIFO circuit based on the register output of the dual-port RAM.

[0010] A fourth object of the present invention is to provide an electronic device comprising the above-mentioned FIFO circuit or chip based on the register output of the dual-port RAM.

[0011] In order to achieve the above-mentioned first purpose, the present invention provides a FIFO circuit based on the register output of a dual-port RAM, including a write control module, a read control module, a dual-port RAM module, and a clock synchronization module. The dual-port RAM module is respectively connected to the write control module and the read control module, the clock synchronization module is respectively connected to the write control module and the read control module, the dual-port RAM module includes a RAM unit, and further includes: a gated clock register module, the gated clock register module includes a gated clock unit and a register, the gated clock unit is respectively connected to the read control module and the clock end of the register, the data input end of the register is connected to the RAM unit, the gated clock unit is used to obtain a RAM read enable signal and a RAM read clock signal from the read control module, and output a gated signal to the clock end of the register based on the RAM read enable signal and the RAM read clock signal.

[0012] As can be seen from the above scheme, the present invention achieves the effect of register outputting RAM read data by gate-controlling the clock of the output register after the RAM data is read out. The beneficial effects achieved by the present invention include: (1) controlling the last read data of the RAM to keep the output at the register output end valid all the time, rather than being valid for a fixed clock cycle; (2) based on the data retention characteristics of the controlled register output end, the FIFO circuit constructed can filter the invalid data output by the RAM, reduce the dynamic flipping of the output data of the FIFO circuit, and reduce the dynamic power consumption; (3) the insertion of the gated clock register module adds a pipeline between the RAM output data and the sequential logic or combinational logic that uses the read data later, reducing the difficulty of RAM output data layout and wiring; (4) compared with the conventional data control enable signal control, although the logic complexity is the same, the control logic of the data after the register output is reduced, so that the path delay between the RAM read data and the sequential logic or combinational logic that uses the read data later is shorter, and the layout and wiring of the subsequent logic is easier.

[0013] A further embodiment is that the dual port RAM module includes a clock gated register module.

[0014] A further solution is that the gated clock unit includes a latch and an AND gate, the data input end of the latch and the control end of the latch are both connected to the read control module, the data input end of the latch is used to obtain the RAM read enable signal from the read control module, the control end of the latch is used to obtain the RAM read clock signal from the read control module, the data output end of the latch is connected to the first input end of the AND gate, the second input end of the AND gate is connected to the read control module, the second input end of the AND gate is used to obtain the RAM read clock signal from the read control module, and the output end of the AND gate is connected to the clock end of the register.

[0015] It can be seen that the gated clock unit is implemented by a low-level sensitive latch and an AND gate, which can eliminate the burrs generated by the gated signal caused by the deviation between the RAM clock enable signal and the clock edge.

[0016] In order to achieve the above-mentioned second purpose, the present invention provides a FIFO control method based on the register output of a dual-port RAM, which is applied to the above-mentioned FIFO circuit based on the register output of the dual-port RAM, and includes the following steps: a gated clock unit obtains a RAM read clock signal and a RAM read enable signal from a read control module, the gated clock unit outputs a gated signal to the clock end of the register, the gated signal is obtained according to the AND operation of the RAM read clock signal and the RAM read enable signal, the data input end of the register obtains the RAM output data from the RAM unit and saves the RAM read data, and the output end of the register stores and outputs the RAM read data based on the gated signal.

[0017] It can be seen from the above scheme that the present invention obtains a gating signal by performing an AND operation on a RAM read clock signal and a RAM read enable signal and inputs it into a register, and controls the output of the RAM read data in the register through the gating signal, so that the RAM read data finally read out can be maintained at the output end of the register and remain valid.

[0018] In order to achieve the above-mentioned second purpose, the present invention also provides a FIFO control method based on the register output of a dual-port RAM, which is applied to the above-mentioned FIFO circuit based on the register output of the dual-port RAM, wherein the following steps are included: the data input end of the latch obtains the RAM read enable signal from the read control module, the control end of the latch obtains the RAM read clock signal from the read control module, the data output end of the latch outputs a latch signal to the first input end of the AND gate based on the RAM read enable signal and the RAM read clock signal, the second input end of the AND gate is used to obtain the RAM read clock signal from the read control module, the output end of the AND gate outputs a gating signal to the clock end of the register, the gating signal is obtained according to the AND operation of the RAM read clock signal and the latch signal, the data input end of the register obtains the RAM output data from the RAM unit and saves the RAM read data, and the output end of the register registers and outputs the RAM read data based on the gating signal.

[0019] It can be seen from the above scheme that the present invention addresses the problem that when the RAM read clock signal and the RAM enable signal are directly subjected to a logical AND operation to output a gating signal, glitches may be generated in the timing signal due to the delay between the edge of the RAM read clock signal and the transition edge of the RAM read enable signal. By performing an AND operation on the latch signal and the RAM read clock signal, a gating signal with the glitches eliminated can be obtained.

[0020] In order to achieve the third objective mentioned above, the present invention provides a chip, which includes the above-mentioned FIFO circuit based on register output of dual-port RAM.

[0021] In order to achieve the fourth objective mentioned above, the present invention provides an electronic device, comprising a housing, wherein: the housing includes the above-mentioned FIFO circuit based on the register output mode of the dual-port RAM or the above-mentioned chip. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] Figure 1 It is a structural block diagram of a FIFO circuit in the prior art.

[0023] Figure 2 FIG. 1 is a schematic diagram of routing of multiple RAM blocks in the prior art.

[0024] Figure 3 It is a structural block diagram of an embodiment of a FIFO circuit based on register output of a dual-port RAM of the present invention.

[0025] Figure 4 yes Figure 3 The specific structural block diagram of the dual-port RAM module.

[0026] Figure 5 yes Figure 4 Circuit diagram of the gated clock unit in the MCU.

[0027] Figure 6 It is a flowchart of the write timing of the write control module in the embodiment of the FIFO control method based on the register output of the dual-port RAM of the present invention.

[0028] Figure 7 It is a flowchart of the reading timing of the reading control module in the embodiment of the FIFO control method based on the register output of the dual-port RAM of the present invention.

[0029] Figure 8 It is a timing diagram of the read and write timing of the FIFO circuit in the embodiment of the FIFO control method based on the register output of the dual-port RAM of the present invention.

[0030] The present invention is further described below in conjunction with the accompanying drawings and embodiments. DETAILED DESCRIPTION

[0031] The FIFO circuit based on the register output of the dual-port RAM of the present invention controls the register output of the RAM read data by gating the clock (Clock Enable, abbreviated as CE) of the output register after the RAM data is read out. The present invention also provides a FIFO control method, chip and electronic device based on the above circuit.

[0032] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.

[0033] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0034] FIFO circuit implementation example based on register output of dual-port RAM:

[0035] See also Figure 3 and Figure 4 The FIFO circuit based on the register output of the dual-port RAM of this embodiment includes a write control module 11, a read control module 12, a clock synchronization module 13 and a dual-port RAM module 14. The dual-port RAM module 14 includes a dual-port non-registered RAM unit 141 and a gated clock register module 142. The RAM unit 141 is a RAM IP core with independent read and write functions. The gated clock register module 142 includes a register 1421 and a gated clock unit 1422.

[0036] The write control module 11 is connected to the clock synchronization module 13 and the dual-port RAM module 14. The read control module 12 is connected to the clock synchronization module 13 and the dual-port RAM module 14. The gated clock register module 142 is connected to the read control module 12 and the clock terminal C1 of the register. The data input terminal D of the register 1421 is connected to the RAM unit 141.

[0037] The dual-port RAM module 14 may include a plurality of RAM units 141 and a plurality of gated clock register modules 142 , and one RAM unit 141 is connected to one gated clock register module 142 .

[0038] The write control module 11 is used to generate the RAM write enable signal ram_wren and the RAM write address signal ram_waddr of the RAM unit 141, as well as the write pointer wptr and the full state flag fifo_full of the FIFO circuit. The write control module 11 cyclically counts the number of the externally input FIFO write enable signal fifo_wren, and generates the write pointer wptr and the RAM write address signal ram_waddr according to the count value. The RAM write enable signal ram_wren is generated by the externally input FIFO write enable signal fifo_wren. If the write pointer wptr=the read synchronization pointer r2w_ptr+the maximum depth MAX_DEPTH of the FIFO circuit, it means that writing cannot be performed at this time, otherwise the data reading will be lost, and the full state flag fifo_full is pulled to a high level state at this time. The externally input FIFO write data signal fifo_wdat represents the specific data that needs to be written to the RAM unit 141, and the FIFO write data signal fifo_wdat is the same as the RAM write data signal ram_wdat. The externally input FIFO write clock signal fifo_wclk is the same as the RAM write clock signal ram_wclk.

[0039] The read control module 12 is used to generate the RAM read enable signal ram_rden and the RAM read address signal ram_raddr of the RAM unit 141, as well as the read pointer rptr and the empty state flag fifo_empty of the FIFO circuit. The read control module 12 cyclically counts the number of the externally input FIFO read enable signal fifo_rden, and generates the read pointer rptr and the RAM read address signal ram_raddr according to the count value. The RAM read enable signal ram_rden is generated by the externally input FIFO read enable signal fifo_rden. If the read pointer rptr=the write synchronization pointer w2r_ptr, it means that the reading of the write data has been completed at this time, and it is necessary to wait for the data to continue to be written. At this time, the empty state flag fifo_empty is pulled to a high level state. The externally input FIFO read clock signal fifo_rclk is the same as the RAM read clock signal ram_rclk.

[0040] The clock synchronization module 13 is used to synchronize the write pointer wptr from the write clock domain wclk to the read clock domain rclk to generate the write synchronization pointer w2r_ptr, and synchronize the read pointer rptr from the read clock domain rclk to the write clock domain wclk to generate the read synchronization pointer r2w_ptr. If the read clock domain wclk and the write clock domain rclk are synchronous clocks, the write pointer wptr and the read pointer rptr can be directly stored and synchronized into w2r_ptr and r2w_ptr; if the read clock domain wclk and the write clock domain rclk are asynchronous clocks, the write pointer and the read pointer need to be converted into Gray code first, and then stored and synchronized to the other party's clock domain, and then the synchronized Gray code is converted into a binary number to obtain the write synchronization pointer w2r_ptr and the read synchronization pointer r2w_ptr.

[0041] The dual-port RAM module 14 is used to obtain the corresponding RAM output data ram_dout from the RAM unit 141 according to the RAM read address signal ram_raddr, and transmit the RAM output data ram_dout to the data input terminal D1 of the register to be saved in the register 1421, so as to register the output RAM read data signal ram_rdat under the control of the gated clock unit 1422. Among them, the gated clock unit 1422 is used to obtain the RAM read enable signal ram_rden and the RAM read clock signal ram_rclk from the read control module 12, and based on the RAM read enable signal ram_rden and the RAM read clock signal ram_rclk, output the gated signal ram_rclk_gate to the clock terminal C1 of the register, and control the output terminal Q1 of the register to output the RAM read data signal ram_rdat through the gated signal ram_rclk_gate. The enable terminal EN of the register 1421 is fixed to logic 1.

[0042] See also Figure 5The gated clock unit 1422 specifically includes a latch U1 and an AND gate U2, and the data input terminal D2 of the latch and the control terminal C2 of the latch are both connected to the read control module 12. The data input terminal D2 of the latch is used to obtain the RAM read enable signal ram_rden from the read control module 12, and the control terminal C2 of the latch is used to obtain the RAM read clock signal ram_rclk from the read control module 12. The data output terminal Q2 of the latch is connected to the first input terminal of the AND gate U2, the second input terminal of the AND gate U2 is connected to the read control module 12, and the output terminal of the AND gate U2 is connected to the clock terminal C1 of the register. The first input end of the AND gate U2 is used to obtain the latch signal ram_rden_tmp from the data output end Q2 of the latch, and the second input end of the AND gate U2 is used to obtain the RAM read clock signal ram_rclk from the read control module 12. The output end of the AND gate U2 performs an AND operation on the latch signal ram_rden_tmp and the RAM read clock signal ram_rclk to output the gate signal ram_rclk_gate.

[0043] The FIFO circuit constructed in the RAM register output mode of the present invention includes but is not limited to a synchronous pre-read FIFO circuit, an asynchronous pre-read FIFO circuit, a synchronous AXIS interface FIFO circuit, an asynchronous AXIS interface FIFO circuit and the like.

[0044] FIFO control method embodiment based on register output of dual-port RAM:

[0045] This embodiment is based on the FIFO circuit implementation based on the register output of the dual-port RAM in the above embodiment, see Figure 6 and Figure 7 , Figure 6 The writing process of the FIFO circuit based on the register output of the dual-port RAM of this embodiment is shown. Figure 7 The reading process of the FIFO circuit based on the register output of the dual-port RAM of this embodiment is shown.

[0046] See also Figure 6 , the writing control module includes the following steps in the writing process:

[0047] S11: Determine whether the FIFO circuit is full.

[0048] Among them, when the write pointer wptr=read synchronization pointer r2w_ptr+the maximum depth MAX_DEPTH of the FIFO circuit, it is determined that the RAM unit is full and the FIFO circuit can no longer be written. It is necessary to jump to step S16 and obtain the read synchronization pointer r2w_ptr from the clock synchronization module to re-judge whether the FIFO circuit is full; when the write pointer wptr≠read synchronization pointer r2w_ptr+the maximum depth MAX_DEPTH of the FIFO circuit, it is determined that the RAM unit can continue to be written, and step S12 is continued.

[0049] S12: The write control module obtains a FIFO write enable signal and a FIFO write data signal from the outside.

[0050] S13: Based on the FIFO write enable signal, a RAM write address signal, a RAM write enable signal and a write pointer are generated.

[0051] S14: Write the RAM write enable signal, the RAM write address signal and the FIFO write data signal into the dual-port RAM module.

[0052] S15: The write pointer is transmitted to the clock synchronization module to be synchronized into a write synchronization pointer.

[0053] S16: Obtain a read synchronization pointer from the clock synchronization module.

[0054] See also Figure 6 , the read control module includes the following steps in the reading process:

[0055] S21: Determine whether the FIFO circuit is empty.

[0056] Among them, when the read pointer rptr=write synchronization pointer w2r_ptr, it is determined that the RAM unit is empty, and the FIFO circuit needs to wait for data to be written into the RAM unit. At this time, jump to step S27, obtain the write synchronization pointer w2r_ptr from the clock synchronization module, and re-judge whether the FIFO circuit is empty; when the read pointer rptr≠write synchronization pointer w2r_ptr, continue to execute step S22.

[0057] S22: The read control module obtains a FIFO read enable signal from the outside.

[0058] S23: Based on the FIFO read enable signal, generate a RAM read address signal, a RAM read enable signal and a read pointer.

[0059] S24: Write the RAM read enable signal and the RAM read address signal into the dual-port RAM module.

[0060] S25: The register of the dual-port module stores the output RAM read data.

[0061] S26: Transmit the read pointer to the clock synchronization module to synchronize it into a read synchronization pointer.

[0062] S27: Obtain a write synchronization pointer from the clock synchronization module.

[0063] See also Figure 7 In the write timing, when the full state flag fifo_full is at a low level, when the external input has the FIFO write enable signal fifo_wren and the FIFO write data signal fifo_wdat, the RAM write enable signal ram_wren, the RAM write address signal ram_waddr and the RAM write data signal ram_wdat can be generated in the same clock cycle.

[0064] See also Figure 8 In the read sequence, the read process is started after the write synchronization pointer w2r_ptr changes. When the FIFO read enable signal fifo_rden is obtained from the outside and is in a high state, the read enable signal ram_rden is in a high state, and the RAM read address signal ram_raddr starts to increase. After the address increases from A0 to A1, the first RAM output data ram_dout will be kept on the read data bus of the FIFO circuit through the register. Then, the empty state flag signal fifo_empty in a low state is output to allow data to be read from the FIFO circuit. Subsequently, when the FIFO circuit is not empty, each FIFO read enable signal fifo_rden (RAM read enable signal ram_rden) corresponds to reading a RAM read data ram_rdat, and the RAM read address signal ram_raddr will continue to increase. The output of the RAM read data signal ram_rdat is controlled by turning on and off the RAM read enable signal ram_rden. When the RAM read enable signal ram_rden is turned off, the RAM read data signal ram_rdat remains valid for multiple clock cycles. The RAM read data signal ram_rdat can be stably output in the third clock cycle after the RAM read enable signal ram_rden. Specifically, the read enable is the first clock cycle, the second clock cycle is for reading data from the RAM unit, and the third clock cycle is for outputting the stored data in the register.

[0065] Chip Example:

[0066] The chip of this embodiment includes the FIFO circuit of the FIFO control circuit embodiment based on the register output of the dual-port RAM.

[0067] Electronic device embodiment:

[0068] The electronic device of this embodiment includes the chip of the above chip embodiment.

[0069] In summary, the present invention achieves the effect of register outputting RAM read data by gated control of the clock of the output register after the RAM data is read out. The present invention realizes the control of the last read data of the RAM to keep the output at the register output end valid all the time, rather than just fixed in one clock cycle; the FIFO circuit constructed based on the data maintenance characteristics of the controlled register output end can filter the invalid data output by the RAM, reduce the dynamic flipping of the output data of the FIFO circuit, and reduce the dynamic power consumption; the setting of the gated clock register module of the present invention adds a pipeline between the RAM output data and the sequential logic or combinational logic that uses the read data later, reducing the difficulty of RAM output data layout and wiring; the control of the gated register clock module of the present invention is compared with the conventional data control enable signal control, although the logic complexity is the same, but the data control logic after the register output is reduced, so that the path delay between the RAM read data and the sequential logic or combinational logic that uses the read data later is shorter, and the layout and wiring of the subsequent logic is easier.

Claims

1. A FIFO circuit based on register output of a dual-port RAM, comprising a write control module, a read control module, a dual-port RAM module, and a clock synchronization module, wherein the dual-port RAM module is respectively connected to the write control module and the read control module, the clock synchronization module is respectively connected to the write control module and the read control module, and the dual-port RAM module comprises a RAM unit, characterized in that: Also includes: A gated clock register module, the gated clock register module includes a gated clock unit and a register, the gated clock unit is connected to the read control module and the clock end of the register respectively, the data input end of the register is connected to the RAM unit, the gated clock unit is used to obtain a RAM read enable signal and a RAM read clock signal from the read control module, and output a gated signal to the clock end of the register based on the RAM read enable signal and the RAM read clock signal; The gated clock unit includes a latch and an AND gate, wherein the data input end of the latch and the control end of the latch are both connected to the read control module, the data input end of the latch is used to obtain the RAM read enable signal from the read control module, the control end of the latch is used to obtain the RAM read clock signal from the read control module, the data output end of the latch is connected to the first input end of the AND gate, the second input end of the AND gate is connected to the read control module, the second input end of the AND gate is used to obtain the RAM read clock signal from the read control module, and the output end of the AND gate is connected to the clock end of the register.

2. The FIFO circuit based on the register output of the dual-port RAM as claimed in claim 1, characterized in that: The dual-port RAM module includes the gated clock register module.

3. A FIFO control method based on a register output of a dual-port RAM, applied to a FIFO circuit based on a register output of a dual-port RAM, characterized in that : The FIFO circuit based on the register output of the dual-port RAM includes a write control module, a read control module, a dual-port RAM module, and a clock synchronization module. The dual-port RAM module is respectively connected to the write control module and the read control module, and the clock synchronization module is respectively connected to the write control module and the read control module. The dual-port RAM module includes a RAM unit and further includes: a gated clock register module, the gated clock register module includes a gated clock unit and a register, the gated clock unit is respectively connected to the read control module and the clock end of the register, the data input end of the register is connected to the RAM unit, and the gated clock unit is used to obtain a RAM read enable signal and a RAM read clock signal from the read control module, and output a gated signal to the clock end of the register based on the RAM read enable signal and the RAM read clock signal; The following steps are involved: The gated clock unit obtains the RAM read clock signal and the RAM read enable signal from the read control module, and the gated clock unit outputs the gated signal to the clock end of the register, the gated signal is obtained according to the AND operation of the RAM read clock signal and the RAM read enable signal, the data input end of the register obtains the RAM output data from the RAM unit and saves the RAM read data, and the output end of the register stores and outputs the RAM read data based on the gated signal.

4. The FIFO control method based on the register output of the dual-port RAM as claimed in claim 3, characterized in that: The dual-port RAM module includes the gated clock register module.

5. A FIFO control method based on a register output of a dual-port RAM, applied to the FIFO circuit based on a register output of a dual-port RAM as claimed in claim 1 or 2, characterized in that: The following steps are involved: The data input end of the latch obtains the RAM read enable signal from the read control module, the control end of the latch obtains the RAM read clock signal from the read control module, the data output end of the latch outputs a latch signal to the first input end of the AND gate based on the RAM read enable signal and the RAM read clock signal, the second input end of the AND gate is used to obtain the RAM read clock signal from the read control module, the output end of the AND gate outputs the gating signal to the clock end of the register, the gating signal is obtained according to the AND operation of the RAM read clock signal and the latch signal, the data input end of the register obtains RAM output data from the RAM unit and saves it to obtain RAM read data, and the output end of the register registers and outputs the RAM read data based on the gating signal.

6. A chip, characterized in that: include: A FIFO circuit based on register output of a dual-port RAM as claimed in claim 1 or 2.

7. An electronic device, comprising a housing, characterized in that: The housing includes a FIFO circuit based on a register output of a dual-port RAM as described in claim 1 or 2 or a chip as described in claim 6.