Programmable logic circuit, information processing device, information processing system, and program
The programmable logic circuit addresses memory contention by predicting and distributing access timings, reducing conflicts and enhancing processing efficiency through reconfigurable logic blocks and delay circuits.
Patent Information
- Application Number
- JP2020163989
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2020-09-29
- Publication Date
- 2024-10-08
- Estimated Expiration
- 2040-09-29
AI Technical Summary
In programmable logic circuits, memory contention occurs when multiple modules simultaneously access shared memory, leading to processing delays and conflicts.
A programmable logic circuit with reconfigurable logic blocks and modules that predict and distribute access timings to avoid overlapping memory access, using delay circuits to adjust the start times of modules based on initial delay times and priority orders.
This approach effectively distributes memory access timings, reducing waiting times and improving processing speed by preventing conflicts and maintaining stable operation.
Smart Images

Figure 0007563082000001 
Figure 0007563082000002 
Figure 0007563082000003
Abstract
Description
[Technical field]
[0001] The present invention relates to a programmable logic circuit, an information processing device, an information processing system, and a program. [Background technology]
[0002] In a programmable logic circuit, simultaneous access to a memory shared by multiple modules can cause processing delays. Regarding the measurement of memory contention time, for example, Patent Document 1 discloses a memory contention time measurement device capable of accurately measuring memory contention time. Patent Document 2 discloses a digital memory system that measures the maximum delay time based on the maximum number of clock pulses required for response in at least two memory devices and delays data output in response to the measurement. Patent Document 3 discloses an information processing device that acquires measurements of data transfer amounts of multiple logic circuits configured and operating in a reconfiguration area, and increases the number of parallel operations of each of multiple logic circuits configured in a reconfiguration area within a range in which the total of the acquired data transfer amounts does not exceed the upper limit of the data transfer amount of the bus of the programmable logic circuit device. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] JP 2005-258617 A [Patent Document 2] Patent No. 3860842 [Patent Document 3] JP 2018-101359 A Summary of the Invention [Problem to be solved by the invention]
[0004] An object of the present invention is to distribute the timing at which a plurality of modules reconfigured in a programmable logic circuit access a shared memory. [Means for solving the problem]
[0005] A programmable logic circuit according to claim 1 of the present invention has a plurality of logic blocks connected in a communicative manner, a plurality of modules are reconfigured in any of the plurality of logic blocks, and among the plurality of modules, 1 or more A first timing at which a first module accesses a memory does not overlap with a second timing at which a second module that is not being executed accesses the memory, Depending on the combination of the first module and the second module, The start of execution of the second module is Either It is a programmable logic circuit that creates a delay from the beginning of execution.
[0006] A programmable logic circuit according to claim 2 of the present invention is the programmable logic circuit according to the aspect of claim 1, which predicts the first timing and the second timing.
[0007] A programmable logic circuit according to claim 3 of the present invention is a programmable logic circuit according to the aspect of claim 1 or 2, wherein the memory is reconfigured to any one of the plurality of logic blocks.
[0011] Claims of the invention 4 The programmable logic circuit according to the present invention comprises the steps of: 3 In the embodiment described in any one of the above, when any two or more of the plurality of modules compete with each other to access the memory, the programmable logic circuit permits each of the two or more modules to access the memory according to a ranking assigned to each of the plurality of modules.
[0012] Claims of the invention 5 The information processing device according to the present invention includes a processor connected to a programmable logic circuit, the processor reconfiguring a plurality of modules in the programmable logic circuit, and detecting a currently running module among the plurality of modules. 1 or morepredicting a first timing at which a first module accesses a memory, and predicting a second timing at which a second module, which is not currently running, among the plurality of modules accesses the memory, such that the second timing does not overlap with the first timing; Depending on the combination of the first module and the second module, The start of execution of the second module is Either The information processing device causes a delay from the start of execution.
[0013] Claims of the invention 6 The information processing device according to the present invention is 5 In the aspect described above, the processor is an information processing device that reconfigures the memory into the programmable logic circuit.
[0014] Claims of the invention 7 The information processing system according to the present invention includes a programmable logic circuit and a processor connected to the programmable logic circuit, the processor reconfiguring a plurality of modules in the programmable logic circuit and detecting a currently running module among the plurality of modules. 1 or more predicting a first timing at which a first module accesses a memory, and predicting a second timing at which a second module, which is not currently running, among the plurality of modules accesses the memory, such that the second timing does not overlap with the first timing; Depending on the combination of the first module and the second module, The start of execution of the second module is Either It is an information processing system that delays execution from the start.
[0015] Claims of the invention 8 The program according to the present invention includes a programmable logic circuit and a processor connected to the programmable logic circuit, the programmable logic circuit being programmed to reconfigure a plurality of modules, and a programmable logic circuit being programmed to execute a programmable logic circuit program. 1 or more predicting a first timing at which a first module accesses a memory; and predicting a second timing at which a second module, which is not currently being executed, among the plurality of modules accesses the memory, so that the second timing does not overlap with the first timing; Depending on the combination of the first module and the second module,The start of execution of the second module is determined by the first module. Either A step of delaying from the start of execution is a program to execute the above steps. Effect of the Invention
[0016] Claim 1, 7 , 8 According to the present invention, it is possible to distribute the timing at which a plurality of modules reconfigured in a programmable logic circuit access a shared memory. Furthermore, according to these inventions, the delay time for delaying the second module is determined according to the combination of one or more first modules and the second module. According to the invention as defined in claim 2, the programmable logic circuit can predict the first timing and the second timing by itself, and delay the second timing so as not to overlap with the first timing. Claim 3, 6 According to the present invention, there is no need to provide an in-device memory in a programmable logic circuit. Claim 4 According to the invention, when two or more modules compete with each other to access the memory, it is possible to determine in advance which module is to be given priority. Claim 5 According to the present invention, the timing at which a first module and a second module reconfigured in a programmable logic circuit access a shared memory can be predicted and distributed. [Brief description of the drawings]
[0017] [Figure 1] FIG. 1 shows an example of the configuration of an information processing system 9. [Diagram 2] FIG. 4 is a diagram showing an example of a module DB121. [Diagram 3] FIG. 13 is a diagram showing an example of a delay time DB 122. [Figure 4] FIG. 4 is a diagram showing an example of a program DB 123. [Diagram 5] FIG. 13 is a diagram showing an example of a priority order table 124. [Figure 6] FIG. 2 is a diagram showing an example of the configuration of a logical device 2. [Figure 7]FIG. 2 is a diagram showing an example of the configuration of a programmable logic circuit 21 in the present embodiment. [Figure 8] FIG. 2 is a diagram showing an example of an area of a programmable logic circuit 21. [Figure 9] FIG. 13 is a diagram for explaining a circuit included in a reconfigured module. [Figure 10] FIG. 2 is a diagram showing an example of a logical device 2 in which two processes are executed in parallel. [Figure 11] FIG. 2 is a diagram showing an example of the functional configuration of a processor 11. [Figure 12] 4 is a flowchart showing an example of the operation flow of the processor 11. [Figure 13] FIG. 11 is a flowchart showing an example of the operation flow of the logical device 2. [Figure 14] FIG. 4 is a diagram for explaining a processing cycle of a module. [Figure 15] FIG. 13 is a diagram for explaining an increase in memory access time due to contention. [Figure 16] FIG. 13 is a diagram for explaining a second module M2 whose start of execution is delayed. [Figure 17] FIG. 13 is a diagram for explaining a module having a period that is an integer multiple of another module. [Figure 18] FIG. 13 is a diagram showing an example of delaying the start of a module having an integer multiple period. [Figure 19] FIG. 13 is a diagram showing an example of a delay time DB 122a in a modified example. [Figure 20] FIG. 13 is a diagram showing an example of a functional configuration of a processor 11 in a modified example. [Figure 21] FIG. 13 is a diagram showing an example of a programmable logic circuit 21 according to a modified example. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0018] <Embodiment> <Configuration of information processing system> Fig. 1 is a diagram showing an example of the configuration of an information processing system 9. The information processing system 9 shown in Fig. 1 includes an information processing device 1 and a logical device 2. The information processing device 1 is a device that processes information such as image data showing an image, various computer programs (hereinafter simply referred to as programs), and modules. The information processing device 1 also controls the logical device 2 and instructs the logical device 2 to execute processing. The logical device 2 is a device that reconfigures an internal circuit under the control of the information processing device 1 and executes the instructed processing.
[0019] The information processing device 1 has a clock 10, a processor 11, a memory 12, an operation unit 14, a display unit 15, an image reading unit 17, and an image forming unit 18. These components are connected to each other so as to be able to communicate with each other via a bus 19. In addition, a logical device 2 is connected to the bus 19 and is able to communicate with each component of the information processing device 1.
[0020] The bus 19 includes a host bus that connects the processor 11 to a chipset (not shown), and a memory bus that connects a memory controller (not shown) included in the chipset to the memory 12. The bus 19 also includes a PCI (Peripheral Component Interconnect) bus that connects the processor 11 to the logical device 2 and the like, and a host-PCI bus bridge that connects the PCI bus to the host bus. The bus 19 may also include an image bus that is used by the image reading unit 17 and the image forming unit 18 to exchange image data.
[0021] The clock 10 is configured to supply a clock signal to the processor 11 or the logic device 2, and includes an oscillation circuit that uses, for example, a crystal oscillator.
[0022] The processor 11 reads and executes a program stored in the memory 12 to control each part of the information processing device 1. The processor 11 is, for example, a CPU (Central Processing Unit).
[0023] The operation unit 14 includes operation devices such as operation buttons, a keyboard, a mouse, and a touch panel for inputting various instructions, and upon receiving an operation, sends to the processor 11 a signal corresponding to the content of the operation.
[0024] The display unit 15 displays a specified image under the control of the processor 11 or the logical device 2. The display unit 15 shown in Fig. 1 has a liquid crystal display which is a display screen for displaying the above-mentioned image. A transparent touch panel of the operation unit 14 may be disposed on top of the liquid crystal display.
[0025] The image reading unit 17 includes an irradiation device such as an LED (light emitting diode), an optical system such as a lens and a prism, and an imaging element such as a CMOS (Complementary Metal Oxide Semiconductor) image sensor or a CCD (Charge Coupled Device) image sensor. Under the control of the processor 11 or the logic device 2, the image reading unit 17 reads an image formed on a medium such as paper, generates image data indicating the read image, and supplies the image data to the processor 11.
[0026] The image forming unit 18, under the control of the processor 11 or the logical device 2, forms an image on a medium such as paper by, for example, an electrophotographic method.
[0027] The memory 12 is a storage means for storing an operating system, various programs, data, etc., which are read into the processor 11. The memory 12 also stores modules to be supplied to the logical device 2. The memory 12 has a RAM (Random Access Memory) and a ROM (Read Only Memory). The memory 12 may also have a solid state drive, a hard disk drive, etc. The memory 12 also stores a module DB 121, a delay time DB 122, a program DB 123, and a priority order table 124.
[0028] Fig. 2 is a diagram showing an example of the module DB 121. In this module DB 121, the module ID column is a column for storing a "module ID" which is identification information for identifying the above-mentioned module. The data column is a column for storing data (also called configuration data) used when reconfiguring a module identified by the corresponding module ID into the logical device 2. In the module DB 121 shown in Fig. 2, one module is configured by one configuration data.
[0029] Fig. 3 is a diagram showing an example of the delay time DB 122. The delay time DB 122 shown in Fig. 3 has a second module ID list 1221 and a delay time table 1222. The second module ID list 1221 is a list that lists module IDs (referred to as second module IDs) that are identification information of a module (referred to as second module) that starts execution while another module (referred to as first module) is being executed.
[0030] The delay time table 1222 is a table provided for each second module ID listed in the second module ID list 1221. The delay time table 1222 stores an initial value (called an initial delay time) of the time (called a delay time) for delaying the start of execution of a second module identified by a corresponding second module ID. This initial delay time is determined in advance according to a combination of one or more first modules that are already being executed.
[0031] 3, and notifies the logic device 2 in which the first module and the second module have been reconfigured of this initial delay time. A programmable logic circuit 21 of the logic device 2, which will be described later, delays the start of execution of the second module from the point in time at which any one of the one or more first modules starts execution (referred to as a start point) in accordance with the notified initial delay time. For example, the programmable logic circuit 21 starts execution of the second module with a delay of the initial delay time from the latest of the start points of the one or more first modules.
[0032] In other words, the programmable logic circuit 21 of this logic device 2 is an example of a programmable logic circuit that delays the start of execution of a second module from the start of execution of any one of one or more first modules depending on the combination of the second module and one or more first modules.
[0033] Fig. 4 is a diagram showing an example of program DB 123. Program DB 123 shown in Fig. 4 stores program IDs, modules used, and data in association with each other. The program ID column shown in Fig. 4 is a column that stores identification information of a program that can be instructed by information processing device 1. The module used column shown in Fig. 4 is a column that stores identification information of one or more modules used in a program identified by the corresponding program ID. The data column shown in Fig. 4 is data that indicates the content of the program identified by the corresponding program ID.
[0034] FIG. 5 is a diagram showing an example of the priority order table 124. The priority order table 124 is a table that determines which module's access is to be prioritized when two or more modules executed in parallel in the logical device 2 compete to access a common memory. The priority order table 124 shown in FIG. 5 stores memory access priorities in association with the areas in which the modules are reconfigured. For example, the priority order table 124 shown in FIG. 5 determines that memory access is to be prioritized for modules reconfigured in areas identified by the respective area IDs in the order of area IDs "R1a" -> "R1b" -> "R1c" -> "R1d".
[0035] The logical device 2 is a logical circuit capable of reconfiguring modules that realize functions under the control of the processor 11, and is, for example, an FPGA (Field Programmable Gate Array). The logical device 2 shown in Fig. 1 controls at least one of the display unit 15, the image reading unit 17, and the image forming unit 18. However, the objects controlled by the logical device 2 are not limited to these. Also, the logical device 2 does not have to control these.
[0036] <Logical device configuration> Fig. 6 is a diagram showing an example of the configuration of a logic device 2. The logic device 2 shown in Fig. 6 has an in-device memory 20 and a programmable logic circuit 21. The in-device memory 20 shown in Fig. 6 is a storage device built into the logic device 2, such as a DDR SDRAM (Double-Data-Rate Synchronous Dynamic Random Access Memory). The programmable logic circuit 21 shown in Fig. 6 is a semiconductor chip that can reconfigure the structure of the internal logic circuit.
[0037] Fig. 7 is a diagram showing an example of the configuration of the programmable logic circuit 21 in this embodiment. The programmable logic circuit 21 shown in Fig. 7 is a so-called island-style FPGA.
[0038] This programmable logic circuit 21 has a plurality of logic blocks 211, switch blocks 212, connection blocks 213, and input / output terminals 214, each of which is arranged in a grid pattern. In other words, this programmable logic circuit 21 is an example of a programmable logic circuit having a plurality of logic blocks arranged in a grid pattern. Note that the programmable logic circuit 21 shown in FIG. 7 is a schematic diagram, and the number of logic blocks 211, etc. is not limited to that shown in FIG. 7.
[0039] The logic block 211 is a block that serves as a unit for constituting a module that realizes various functions, such as logic, arithmetic circuits, memory circuits, etc., using a truth table circuit or the like.
[0040] The switch block 212 and the connection block 213, together with the wiring that connects them, form a wiring area.
[0041] The switch block 212 is a block that switches the connection between the wires. The connection block 213 is a block that switches the connection between the input / output of the logic block 211 and the wiring area described above.
[0042] The switch block 212 and the connection block 213 are configured, for example, with a switch using a bus transistor and a configuration memory for controlling the switch.
[0043] The input / output terminal 214 is a block that connects the programmable logic circuit 21 and the processor 11 so that they can communicate with each other, and serves as an interface for input from the processor 11 and output to the processor 11 .
[0044] Further, any one of the input / output terminals 214 is connected to the above-mentioned in-device memory 20, and relays access to the in-device memory 20 requested by a module reconfigured in the programmable logic circuit 21. The input / output terminals 214 shown in Fig. 7 are connected to the above-mentioned wiring area.
[0045] The programmable logic circuit 21 may include, for example, a DSP (digital signal processor) used to execute a predetermined process.
[0046] The processor 11 reconfigures the programmable logic circuit 21 by writing the configuration data stored in the memory 12 to the logic blocks 211 , the switch blocks 212 , and the connection blocks 213 of the programmable logic circuit 21 .
[0047] Fig. 8 is a diagram showing an example of regions of a programmable logic circuit 21. As shown in Fig. 8, the programmable logic circuit 21 divides a plurality of logic blocks 211 arranged in a lattice pattern into a plurality of regions according to their respective positions. The programmable logic circuit 21 shown in Fig. 8 has at least one static region R0 and a plurality of reconfiguration regions R1a, R1b, R1c.... When there is no particular need to distinguish between the reconfiguration regions R1a, R1b, R1c..., they will be referred to as the reconfiguration region R1.
[0048] The static area R0 is an area that is reconfigured at the time of start-up when power supply to the information processing device 1 is started. In this static area R0, for example, frequently called modules and memories that store data commonly referenced between modules are reconfigured at the time of startup.
[0049] The reconfiguration region R1 is a region that is reconfigured when instructed by the processor 11. In each of the multiple reconfiguration regions R1, one module is reconfigured.
[0050] Fig. 9 is a diagram for explaining the circuits included in the reconfigured module. In one reconfigurable region R1 shown in Fig. 9, the input / output circuit C1, the measurement circuit C2, the delay circuit C3, and the processing circuit C4 included in the module are reconfigured.
[0051] The processing circuit C4 is a circuit that performs a predetermined process, such as a rotation calculation process that rotates image data representing an image by a specified angle, an image sharpening process that adjusts the gradation of each pixel so that the image becomes clear, and an edge detection process that detects the shape of a subject from an image.
[0052] The input / output circuit C1 is a circuit that inputs and outputs data used by the processing circuit C4 to the in-device memory 20. The input / output circuit C1 is reconfigured based on the priority read from the priority table 124 along with the module configuration data. As a result, when memory access timing conflicts between multiple modules, the input / output circuit C1 instructs waiting and arbitrates memory access using the priority of the area in which those modules are reconfigured.
[0053] The measurement circuit C2 is a circuit that measures the time (called a waiting time) that the input / output circuit C1 is made to wait for input / output of data by another module.
[0054] The delay circuit C3 is a circuit that delays the start of processing by the processing circuit C4 according to the waiting time measured by the measurement circuit C2. The delay circuit C3 is reconfigured based on the initial delay time read from the delay time DB 122 together with the configuration data of the module. As a result, when the processing circuit C4 executes processing for the first time after startup, the delay circuit C3 delays the execution based on the initial delay time.
[0055] In other words, the programmable logic circuit 21 in which a module having an input / output circuit C1, a measurement circuit C2, a delay circuit C3, and a processing circuit C4 is reconfigured is an example of a programmable logic circuit having a processing circuit that performs a predetermined processing, an input / output circuit that inputs and outputs data used by the processing circuit to a memory, a measurement circuit that measures the waiting time that the input / output circuit is kept waiting for input / output of data by the first module, and a delay circuit that delays the start of processing by the processing circuit in accordance with the waiting time measured by the measurement circuit.
[0056] 9, the module reconfigured in the reconfiguration area R1 reads data from the in-device memory 20 by the input / output circuit C1 and supplies the data to the processing circuit C4. The measurement circuit C2 monitors the input / output circuit C1 to measure the waiting time and transmits the result to the delay circuit C3.
[0057] The delay circuit C3 predicts the timing when the input / output circuit C1 should next access the device memory 20 according to the measured wait time, and determines the timing to make the processing circuit C4 start processing next according to the result. This timing is expressed by calculating the delay time from the start timing of another module being executed. In other words, the delay circuit C3 is an example of a delay circuit that calculates the delay time by which the start of processing by the processing circuit is delayed according to the wait time.
[0058] The processing circuit C4 delays the execution of the process until the timing determined by the delay circuit C3. When the processing circuit C4 finishes the process, the input / output circuit C1 writes the result of the process into the device memory 20.
[0059] Fig. 10 is a diagram showing an example of a logic device 2 in which two processes are executed in parallel. In the programmable logic circuit 21 of the logic device 2 shown in Fig. 10, a first module M1 is reconfigured in a reconfiguration area R1a, and a second module M2 is reconfigured in a reconfiguration area R1b. In the logic device 2 shown in Fig. 10, the process of the first module M1 is started first, and then the process of the second module M2 is started. Then, both the first module M1 and the second module M2 access the in-device memory 20, which is a common storage device.
[0060] <Processor Functional Configuration> 11 is a diagram illustrating an example of a functional configuration of the processor 11. The processor 11 of the information processing device 1 functions as a reconstructing unit 111 and an instruction unit 112 by executing a program stored in the memory 12.
[0061] The reconfiguration unit 111 reads the configuration data from the memory 12, and writes it to any area of the programmable logic circuit 21 of the logic device 2, thereby reconfiguring the module.
[0062] When the reconfiguration by the reconfiguration unit 111 is completed, the instruction unit 112 instructs the circuit realized by the reconfigured module to execute processing. When instructing the execution of processes of multiple modules in parallel, the processor 11 shown in Fig. 11 does not arbitrate access to the device memory 20 by these multiple modules. This arbitration is performed by the programmable logic circuit 21.
[0063] <Operation of the information processing device> 12 is a flow diagram showing an example of the flow of operations of the processor 11. When the information processing device 1 is started, the processor 11 controls the logic device 2 via the bus 19 and reconfigures the static area R0 of the programmable logic circuit 21 (step S101). This reconfiguration is done once at boot time.
[0064] Next, the processor 11 monitors the operation unit 14 to determine whether or not a command to execute the selected program has been issued by the user (step S102). As long as it is determined that no command has been issued by the user (step S102; NO), the processor 11 continues this determination.
[0065] On the other hand, if it is determined that a user instruction has been given (step S102; YES), the processor 11 refers to the program DB 123, and from the program ID, which is the identification information of the specified program, identifies the module IDs of the modules used in that program, and allocates areas of the programmable logic circuit 21 to those modules (step S103).
[0066] Then, the processor 11 reconfigures these modules in the respective allocated areas (step S104), and instructs the logical device 2 to execute the process (step S105). When the execution of the process by the logical device 2 is completed, the processor 11 returns the process to step S102.
[0067] <Logical device operation> 13 is a flow diagram showing an example of the flow of operations of the logic device 2. When the programmable logic circuit 21 of the logic device 2 is instructed by the processor 11 of the information processing device 1 to execute processing, it delays the start of execution for each of the one or more reconfigured modules according to a determined delay time (step S201), and then executes the processing (step S202).
[0068] When the input / output circuit C1 accesses the in-device memory 20 in step S202, the measurement circuit C2 of the programmable logic circuit 21 measures the waiting time (step S203). Then, the delay circuit C3 uses the measured waiting time to predict the timing of the next memory access (step S204).
[0069] This prediction may be performed in parallel with a memory access or while waiting for a memory access. If the timing of the next memory access is predicted in parallel with a memory access, the module is running. On the other hand, if the timing of the next memory access is predicted while waiting for a memory access, the module is not running.
[0070] Based on the result of the prediction, the delay circuit C3 of the programmable logic circuit 21 judges whether the delay time needs to be updated (step S205). For example, when the timing when the module not currently running next accesses the memory and the timing when the module currently running next accesses the memory overlap, the programmable logic circuit 21 judges that the delay time needs to be updated. Here, when two or more timings overlap, it means that the time difference between these two or more timings is less than a predetermined threshold value.
[0071] The programmable logic circuit 21 may determine that it is not necessary to update the delay time after the number of times the delay time has been calculated for updating has reached a threshold value or more. If it is determined that updating is not necessary, the programmable logic circuit 21 delays the start of processing by using the delay time that has already been used. This prevents the delay time from being updated a number of times equal to or greater than the threshold value, stabilizing the operation of the information processing system.
[0072] In this case, this delay circuit C3 is an example of a delay circuit that calculates a delay time to delay the start of processing by the processing circuit depending on the waiting time, and after the number of times this delay time has been calculated reaches or exceeds a threshold, delays the start of processing using the already calculated delay time without calculating a new delay time.
[0073] If it is determined that the delay time needs to be updated (step S205; YES), the delay circuit C3 updates the delay time written therein (step S206) and advances the process to step S209. In this case, the updated delay time is referred to the next time step S201 is performed by the programmable logic circuit 21, and the start of execution of the module is delayed according to this delay time.
[0074] In other words, this programmable logic circuit 21 is an example of a programmable logic circuit having a plurality of logic blocks connected to enable communication, in which a plurality of modules are reconfigured into any of the plurality of logic blocks, and in which the start of execution of a second module is delayed from the start of execution of a first module so that a first timing at which a first module that is currently running accesses memory does not overlap with a second timing at which a second module that is not currently running accesses memory.
[0075] On the other hand, when it is determined that the delay time does not need to be updated (step S205; NO), the processing circuit C4 of the programmable logic circuit 21 determines whether or not there is a possibility of a conflict in the access request to the device memory 20 between the programmable logic circuit 21 and another module due to the overlap in the timing of the access (step S207).
[0076] When it is determined that there is a conflict (step S207; YES), the processing circuit C4 determines whether to wait or not according to the priority written to itself based on the priority table 124 at the time of reconfiguration (step S208), and proceeds to the process at step S209. For example, when the processing circuit C4 refers to the priority table 124 and a higher priority than the priority of the module including itself is assigned to another module that is being executed, the processing circuit C4 makes the input / output circuit C1 wait until the memory access by that module is completed, and permits the memory access after completion.
[0077] In this case, the programmable logic circuit 21 in which the above-mentioned modules are reconfigured is an example of a programmable logic circuit that, when any two or more of the multiple modules compete with each other to access the memory, allows each of the two or more modules to access the memory in accordance with the rank assigned to each of the multiple modules.
[0078] On the other hand, when it is determined that there is no conflict (step S207; NO), the processing circuit C4 skips step S208 and advances the process directly to step S209.
[0079] The programmable logic circuit 21 determines whether a termination condition, such as an interrupt request from the processor 11 or the end of an operation, is satisfied (step S209), and if it is determined that the termination condition is satisfied (step S209; YES), the programmable logic circuit 21 terminates the process. On the other hand, if it is determined that the termination condition is not satisfied (step S209; NO), the programmable logic circuit 21 returns the process to step S201.
[0080] If the processing cycle of each module is not affected by disturbances, etc., and there is no need to update the delay time from the initial delay time, the programmable logic circuit 21 does not need to predict the memory access timing in step S204. In this case, the programmable logic circuit 21 does not need to make the decisions in steps S205 and S207.
[0081] <Case of modules with a common period> The start of execution of a module is adjusted by the above-mentioned operation as follows. FIG. 14 is a diagram for explaining the processing cycle of a module. In FIG. 14, the horizontal direction indicates the flow of time, which flows from left to right. One cycle of processing of a module is composed of three stages: reading → processing without memory access → writing, which are performed in this order. In the programmable logic circuit 21, the area where this module has been reconfigured first reads data that will be the initial value from the in-device memory 20, and executes processing without memory access using the read data. This area then writes data indicating the results of the executed processing to the in-device memory 20.
[0082] Fig. 15 is a diagram for explaining an increase in memory access time due to contention. As shown in Fig. 15(a), in the programmable logic circuit 21, when the first module M1 alone repeatedly executes the process of cycle P1, the above-mentioned read and write stages, that is, the time T1 required for memory access, is a fixed length. This is because there is no competition with other modules for the right to access the device memory 20, and only the time spent on memory access itself is reflected.
[0083] 15(b), in the programmable logic circuit 21, when the first module M1 and the second module M2 having a common cycle are started at the same time, the timing of their memory accesses overlap. That is, the memory accesses compete with each other between the two modules. In this case, the in-device memory 20 cannot respond to the accesses requested by the first module and the second module at the same time, so the access commands are delayed, and the time T3 required for both memory accesses becomes longer than when each module is executed independently (T3>T1).
[0084] Therefore, the programmable logic circuit 21 delays the processing of the second module M2 that starts while the first module M1 is being executed. Fig. 16 is a diagram for explaining the second module M2 whose start of execution is delayed. For example, the programmable logic circuit 21 specifies an initial delay time according to the combination of the second module M2 and the first module M1, and uses this initial delay time as a delay time D1 to delay the start of execution of the second module M2 from the start of execution of the first module M1.
[0085] This prevents the timing (referred to as the first timing) at which the first module M1 accesses the device memory 20 from overlapping with the timing (referred to as the second timing) at which the second module M2 accesses the device memory 20. Therefore, the time T1 required for the first module M1 to access the memory and the time T2 required for the second module M2 to access the memory both remain the same length as when each module is executed independently.
[0086] <The case of a module with a period that is an integer multiple of the period of another module> Also, the cycles of two or more modules that are reconfigured and executed in parallel may differ in the programmable logic circuit 21. However, when the following conditions are met: the cycle of one module is an integer multiple of the cycle of the other module, and the time required for memory access of the other module is shorter than the time required for processing of the one module that does not involve memory access, memory access contention may be avoided by delaying the start of execution of one module.
[0087] 17A and 17B are diagrams for explaining a module having a period that is an integer multiple of other modules. A first module M1 shown in Fig. 17A repeats processing with a period P1, and requires time T1 for memory access.
[0088] 17B, the second module M2 repeats the process of the period P2 and requires time T2 for memory access. The period P2 is half the period P1 (=P1 / 2). In other words, the period P1 is twice the period P2.
[0089] In this case, if the first module M1 and the second module M2 are started at the same time, for example, as shown in Fig. 17(c), when the number of repetitions of the second module M2 is an even number, memory access conflicts with the first module M1. In this case, the time T3 required for memory access is longer than both the time T1 required for the first module M1 to access memory alone and the time T2 required for the second module M2 to access memory alone. As a result, the time required for the entire process is longer than the time required when each module is executed alone.
[0090] 18 is a diagram showing an example of delaying the start of a module having an integer multiple period. The programmable logic circuit 21 delays the start of the second module M2 by a delay time D2 with respect to the start of the first module M1 having twice the period P1. As a result, the first timing, which is the timing of memory access of the first module M1, falls within the processing of the second module M2 that does not involve memory access. Also, the second timing, which is the timing of memory access of the second module M2, falls within the processing of the first module M1 that does not involve memory access. In other words, there is no contention in memory access between the first module M1 and the second module M2.
[0091] As described above, the delay time D1 and the delay time D2 are updated according to the wait time measured during actual processing. As a result, even if a memory access conflict occurs due to a delay of the initial delay time, the start of execution of the second module M2 is delayed again so that the wait time caused by the conflict is reduced.
[0092] Through the above-mentioned operation, the programmable logic circuit 21 of the logic device 2 distributes the timing at which the multiple modules reconfigured in the logic device 2 access the shared in-device memory 20. As a result, the occurrence of wait times due to memory access contention is suppressed, and the processing speed of the logic device 2 is improved.
[0093] <Modification> The above is a description of the embodiment, but the contents of this embodiment may be modified as follows. In addition, the following modifications may be combined with each other.
[0094] <1> In each of the above embodiments, the term "processor" refers to a processor in a broad sense, including general-purpose processors (e.g., CPU: Central Processing Unit, etc.) and dedicated processors (e.g., GPU: Graphics Processing Unit, ASIC: Application Specific Integrated Circuit, FPGA: Field Programmable Gate Array, programmable logic device, etc.). In addition, the operations of the processor in each of the above embodiments may be performed not only by one processor, but also by multiple processors located at physically separate locations working together. Furthermore, the order of the operations of the processor is not limited to the order described in each of the above embodiments, and may be changed as appropriate.
[0095] <2> In the above-described embodiment, the delay time DB 122 has the second module ID list 1221 and the delay time table 1222, but may have other configurations. For example, the delay time DB 122 may associate an initial delay time with each combination of two or more modules. FIG. 19 is a diagram showing an example of a delay time DB 122a in a modified example. The delay time DB 122a shown in FIG. 19 stores an initial delay time associated with each combination of modules used in a program. In this case, for modules included in this combination that are not being executed, the initial delay time associated with this combination is used.
[0096] <3> In the above-described embodiment, the programmable logic circuit 21 reconfigured a module having an input / output circuit C1, a measurement circuit C2, a delay circuit C3, and a processing circuit C4, but the functions of the measurement circuit C2 and the delay circuit C3 may be realized by the processor 11.
[0097] 20 is a diagram showing an example of a functional configuration of the processor 11 in the modified example. The processor 11 functions as a measurement unit 113 and a prediction unit 114. The measurement unit 113 shown in FIG. 20 monitors the logic device 2, measures the waiting time of each of the one or more modules reconfigured in the programmable logic circuit 21, and transmits the result to the prediction unit 114.
[0098] The prediction unit 114 predicts a first timing when the first module currently being executed will next access the intra-device memory 20, according to the measured wait time. The prediction unit 114 also predicts a second timing when the second module currently not being executed will next access the intra-device memory 20, according to the wait time. Then, the prediction unit 114 informs the instruction unit 112 of the predicted first timing and second timing.
[0099] The instruction unit 112 calculates a delay time for causing the second module to start executing the process so that the predicted second timing does not overlap with the first timing. Then, the instruction unit 112 may instruct the programmable logic circuit 21 to delay the start of the process according to the calculated delay time.
[0100] Processor 11 in this modified example is an example of a processor that is connected to a programmable logic circuit, reconfigures a plurality of modules in the programmable logic circuit, predicts a first timing at which a first module among the plurality of modules that is currently running will access memory, predicts a second timing at which a second module among the plurality of modules that is not currently running will access memory, and delays the start of execution of the second module from the start of execution of the first module so that the second timing does not overlap with the first timing.
[0101] <4> In the above-described embodiment, each module reconfigured in the programmable logic circuit 21 accesses the common in-device memory 20 provided in the logic device 2, but this is not limited to the above. For example, each module may access the memory 12 of the information processing device 1. Also, each module may access a memory reconfigured in the static area R0 of the programmable logic circuit 21.
[0102] FIG. 21 is a diagram showing an example of a programmable logic circuit 21 in a modified example. The programmable logic circuit 21 shown in FIG. 21 reconfigures a reconfigurable memory M0 in a static region R0. The first module M1 reconfigured in the reconfigurable region R1a and the second module M2 reconfigured in the reconfigurable region R1b both access the reconfigurable memory M0, which is a common memory reconfigured in the static region R0. The static region R0 also includes a plurality of logic blocks 211. That is, the reconfigurable memory M0 is an example of a memory reconfigured to any one of a plurality of logic blocks. In this case, the programmable logic circuit 21 may delay the execution of processing in the second module M2 so that the second timing does not overlap with the first timing.
[0103] <5> In the above-described embodiment, the program executed by the processor 11 of the information processing device 1 is an example of a program that causes a computer having a processor connected to a programmable logic circuit to execute the following steps: reconfiguring a plurality of modules in the programmable logic circuit; predicting a first timing at which a first module among the plurality of modules that is currently running will access a memory; and predicting a second timing at which a second module among the plurality of modules that is not currently running will access the memory, and delaying the start of execution of the second module from the start of execution of the first module so that the second timing does not overlap with the first timing.
[0104] This program may be provided in a state where it is stored in a computer-readable recording medium, such as a magnetic recording medium such as a magnetic tape or a magnetic disk, an optical recording medium such as an optical disk, a magneto-optical recording medium, a semiconductor memory, etc. This program may also be downloaded via a communication line such as the Internet. [Explanation of symbols]
[0105] 1...information processing device, 10...clock, 11...processor, 111...reconstruction unit, 112...instruction unit, 113...measurement unit, 114...prediction unit, 12...memory, 121...module DB, 122, 122a...delay time DB, 1221...second module ID list, 1222...delay time table, 123...program DB, 124...priority table, 14...operation unit, 15...display unit, 17...image reading unit, 18...image forming unit, 19...bus, 2...logical device, 20...device memory, 21 ...programmable logic circuit, 211...logic block, 212...switch block, 213...connection block, 214...input / output terminal, 9...information processing system, C1...input / output circuit, C2...measurement circuit, C3...delay circuit, C4...processing circuit, D1, D2...delay time, M0...reconfigurable memory, M1...first module, M2...second module, P1, P2...period, R0...static area, R1, R1a, R1b, R1c, R1d...reconfiguration area, T1, T2, T3...time.
Claims
1. A plurality of logic blocks communicatively connected to each other, A plurality of modules are reconfigured in any one of the plurality of logic blocks; In order to prevent a first timing at which one or more first modules currently being executed among the plurality of modules access a memory from overlapping with a second timing at which a second module not currently being executed accesses the memory, a start of execution of the second module is delayed from a start of execution of any of the first modules according to a combination of the first module and the second module. Programmable logic circuits.
2. Predicting the first timing and the second timing 2. The programmable logic circuit of claim 1.
3. The memory is reconfigured into any one of the plurality of logical blocks.
3. A programmable logic circuit according to claim 1 or 2.
4. When two or more of the plurality of modules compete with each other to access the memory, the two or more modules are permitted to access the memory according to the rank assigned to each of the plurality of modules.
4. A programmable logic circuit according to claim 1.
5. a processor coupled to the programmable logic circuit, the processor comprising: Reconfiguring a plurality of modules in the programmable logic circuit; predicting a first timing at which one or more first modules currently being executed among the plurality of modules will access a memory; predicting a second timing at which a second module that is not currently running among the plurality of modules will access the memory; A start of execution of the second module is delayed from a start point of execution of any one of the first modules in accordance with a combination of the first module and the second module so that the second timing does not overlap with the first timing. Information processing device.
6. The processor, Reconfiguring the memory into the programmable logic circuit. The information processing device according to claim 5 .
7. A programmable logic circuit; a processor coupled to the programmable logic circuit; The processor, Reconfiguring a plurality of modules in the programmable logic circuit; predicting a first timing at which one or more first modules currently being executed among the plurality of modules will access a memory; predicting a second timing at which a second module that is not currently running among the plurality of modules will access the memory; A start of execution of the second module is delayed from a start point of execution of any one of the first modules in accordance with a combination of the first module and the second module so that the second timing does not overlap with the first timing. Information processing system.
8. a processor connected to a programmable logic circuit, reconfiguring a plurality of modules in the programmable logic device; predicting a first timing at which one or more first modules among the plurality of modules currently being executed will access a memory; predicting a second timing at which a second module that is not currently being executed among the plurality of modules will access the memory, and delaying a start of execution of the second module from a start of execution of any one of the first modules in accordance with a combination of the first module and the second module so that the second timing does not overlap with the first timing; A program that executes the following.
Citation Information
Patent Citations
Memory contention time measuring device, memory contention time measuring method and program
JP2005258617A
Processor device
JP2007241918A
Multi-task system
JP2013089165A
Conflict-free memory configuration
JP2015506025A
Systems and methods for resolving dram page contention based on memory access patterns
JP2017502421A
