US8386973B2 - Behavioral synthesis apparatus, method, and program having test bench generation function - Google Patents
Behavioral synthesis apparatus, method, and program having test bench generation function Download PDFInfo
- Publication number
- US8386973B2 US8386973B2 US13/336,328 US201113336328A US8386973B2 US 8386973 B2 US8386973 B2 US 8386973B2 US 201113336328 A US201113336328 A US 201113336328A US 8386973 B2 US8386973 B2 US 8386973B2
- Authority
- US
- United States
- Prior art keywords
- input
- output
- test bench
- signal
- behavioral
- Prior art date
- Legal status (The legal status 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 status listed.)
- Active
Links
- 230000003542 behavioural effect Effects 0.000 title claims abstract description 163
- 238000012360 testing method Methods 0.000 title claims abstract description 133
- 230000015572 biosynthetic process Effects 0.000 title claims abstract description 38
- 238000003786 synthesis reaction Methods 0.000 title claims abstract description 33
- 238000000034 method Methods 0.000 title description 11
- 238000012545 processing Methods 0.000 claims description 16
- 238000001308 synthesis method Methods 0.000 claims description 4
- 238000004088 simulation Methods 0.000 abstract description 53
- 230000007274 generation of a signal involved in cell-cell signaling Effects 0.000 abstract description 11
- 238000010586 diagram Methods 0.000 description 23
- 230000006870 function Effects 0.000 description 22
- 230000006399 behavior Effects 0.000 description 13
- 238000004458 analytical method Methods 0.000 description 5
- 238000013461 design Methods 0.000 description 4
- 238000012986 modification Methods 0.000 description 4
- 230000004048 modification Effects 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 238000012546 transfer Methods 0.000 description 3
- 230000007704 transition Effects 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 230000008901 benefit Effects 0.000 description 2
- 238000010276 construction Methods 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 230000010365 information processing Effects 0.000 description 2
- QIVUCLWGARAQIO-OLIXTKCUSA-N (3s)-n-[(3s,5s,6r)-6-methyl-2-oxo-1-(2,2,2-trifluoroethyl)-5-(2,3,6-trifluorophenyl)piperidin-3-yl]-2-oxospiro[1h-pyrrolo[2,3-b]pyridine-3,6'-5,7-dihydrocyclopenta[b]pyridine]-3'-carboxamide Chemical compound C1([C@H]2[C@H](N(C(=O)[C@@H](NC(=O)C=3C=C4C[C@]5(CC4=NC=3)C3=CC=CN=C3NC5=O)C2)CC(F)(F)F)C)=C(F)C=CC(F)=C1F QIVUCLWGARAQIO-OLIXTKCUSA-N 0.000 description 1
- 238000010420 art technique Methods 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- XULSCZPZVQIMFM-IPZQJPLYSA-N odevixibat Chemical compound C12=CC(SC)=C(OCC(=O)N[C@@H](C(=O)N[C@@H](CC)C(O)=O)C=3C=CC(O)=CC=3)C=C2S(=O)(=O)NC(CCCC)(CCCC)CN1C1=CC=CC=C1 XULSCZPZVQIMFM-IPZQJPLYSA-N 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/30—Circuit design
- G06F30/32—Circuit design at the digital level
- G06F30/327—Logic synthesis; Behaviour synthesis, e.g. mapping logic, HDL to netlist, high-level language to RTL or netlist
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/30—Circuit design
- G06F30/32—Circuit design at the digital level
- G06F30/33—Design verification, e.g. functional simulation or model checking
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/30—Circuit design
- G06F30/32—Circuit design at the digital level
- G06F30/33—Design verification, e.g. functional simulation or model checking
- G06F30/3308—Design verification, e.g. functional simulation or model checking using simulation
Definitions
- the present invention relates to a behavioral synthesis apparatus, a behavioral synthesis method, and a behavioral synthesis program that generate an RTL (Register Transfer Level) circuit description, which describes specific functions (circuits), from a behavior level circuit description that describes the behavior of a semiconductor integrated circuit, and more particularly to a behavioral synthesis apparatus, a behavioral synthesis method, and a behavioral synthesis program that can output a test bench for verifying the generated RTL circuit.
- RTL Registered Transfer Level
- the behavioral description which implements the desired behavior of a system LSI, is designed first.
- the behavior simulation is performed to confirm if the designed behavioral description achieves the desired circuit behavior, that is, if the design is correct.
- the behavior description is transformed into an RTL description through behavioral synthesis.
- test vector used in the behavioral simulation is used also in the RTL simulation after the behavioral synthesis.
- this requirement has first and second purposes described below.
- the first purpose is to confirm if the behavioral description before behavioral synthesis and the RTL description after behavioral synthesis implement the same function.
- the behavioral simulation if performed to confirm that the behavioral description achieves the desired behavior of the circuit, is meaningless. This is because the designed circuit does not eventually implement the desired behavior.
- the second purpose is to confirm the performance of the circuit after the behavioral synthesis.
- the RTL simulation reveals how much time is required to achieve a function, that is, the RTL simulation shows the circuit performance.
- the related art technique checks whether or not the designed behavioral description achieves the desired performance by using the same test vector in both the behavioral simulation and the RTL simulation and evaluating the circuit performance measured in the RTL simulation.
- test vector used in the behavioral simulation cannot be used directly in the RTL simulation.
- the reason is that the input application timing and the output observation timing differ between the behavioral simulation and the RTL simulation.
- timing clock
- the granularity of timing in the behavioral description is different from that of the RTL description. Therefore, the sequence of data that is used as the test vector in the behavioral simulation, if applied at each clock cycle during the RTL simulation, does not produce the same result as that produced by the behavioral simulation. Similarly, the output of the RTL simulation, if observed at each clock cycle, is not the same as that produced by the behavioral simulation.
- Patent Document 1 Japanese Patent Kokai Publication No. JP-P2005-78402A discloses a behavioral synthesis system that solves the problems described above.
- the behavioral synthesis system described in Patent Document 1 is proposed primarily to solve the first problem described above (the sequence of data that is used as the test vector in the behavioral simulation, if applied at each clock cycle during the RTL simulation, does not produce the same result as that produced by the behavioral simulation).
- This conventional behavioral synthesis system assumes that the file read function, which reads the sequence of input from a file, and the file write function, which writes the sequence of output to a file, are described in the behavioral description.
- the file read function and the file write function are generically called a file function.
- This conventional behavioral synthesis system comprises syntax analysis means, control data flow graph construction means, scheduling/binding means, test bench generation means, and RTL generation means.
- the behavioral synthesis system having this configuration operates as follows.
- syntax analysis means and the control data flow graph construction means leave the file functions, which are included in the behavioral description, undeleted.
- Resource binding and scheduling are performed to create an RTL description based on the constructed control data flow graph.
- the file input for a file function is represented in the created RTL description using the select signal of the multiplexer for input data.
- the file output condition is represented using the select signal of the multiplexer for output data.
- Patent Document 2 Japanese Patent Kokai Publication No. JP-P2004-145712A.
- the equivalence verification method disclosed in Patent Document 2 is proposed primarily to solve the first problem described above.
- This equivalence verification method finds a comparison time based on the number of delay cycles from the time the input signal is determined to the time the output signal is determined in the RTL simulation result and compares the value of the output signal of the RTL simulation result with the value of the output signal of the behavioral simulation at the comparison time.
- the problem with this method is that the kind of circuit to which this method is can be applied is limited.
- Patent Document 3 U.S. Pat. No. 6,845,341 B2 discloses a performance analysis system.
- the general operation of this performance analysis system is as follows. That is, a test bench for executing the behavioral simulation and the RTL simulation at the same time is created. A module for absorbing the difference in the input time and the output time of the behavioral simulation and the RTL simulation is inserted between the behavioral description and the test bench and between the RTL description and the test bench. In this configuration, the behavioral simulation and the RTL simulation receive the same test vector and the number of clocks required for the RTL description to execute simulation is measured to evaluate the performance.
- test vector used in the behavioral simulation cannot be used directly in the RTL simulation.
- a still another reason for the above problem is a behavior that cannot be represented by a behavioral description.
- the behavior of the input/output during a reset is not specified (there is also behavioral description language, such as SystemC language, in which the input/output behavior during a reset is specified).
- a still another reason for the above problem is an external model (shared memory model, memory model, operation unit model, etc.).
- an array in the behavioral description is implemented by a memory in the RTL description, and a variable in the behavioral description is implemented by a register outside the module in the RTL description.
- a system comprising: input application/output observation timing signal generation means that creates an input application timing signal and an output observation timing signal for each input and output of a circuit and creates respective logic circuits for the input application timing signal and the output observation timing signal; and test bench generation means that generates a test bench that applies an input to, and observes an output from, the circuit according to values of the input application timing signal and the output observation timing signal.
- a system comprising: test bench generation means that recognizes an input application timing signal and an output observation timing signal in a behavioral description of a circuit and generates a test bench that applies an input to, and observes an output from, the circuit according to values of the input application timing signal and the output observation timing signal.
- a system comprising: test bench generation means that generates a test bench that counts a number of clocks after a reset is released and, when the number of clocks matches a predetermined value, applies an input or observes an output.
- a system comprising: the test bench generation means that generates the test bench that does not apply an input or observe an output when a reset signal or a stall signal is effective.
- a system comprising: the test bench generation means that outputs the test bench that has a simulation model for a hardware resource that is output as a black box in an RTL (Register Transfer Level) description.
- the present invention allows the same test vector to be used in a behavioral simulation and an RTL simulation. This is because, in the present invention, a test bench is output in such a way that a test vector used before behavioral synthesis can be used also in a circuit generated after behavioral synthesis.
- FIG. 1 is a block diagram showing the configuration of a first embodiment of the present invention.
- FIG. 2 is a block diagram showing an example of the configuration of the first embodiment of the present invention.
- FIG. 3 is a flowchart showing the operation of the first embodiment of the present invention.
- FIG. 4 is a diagram showing an example of a behavioral description.
- FIG. 5 is a diagram showing an example of the result of scheduling.
- FIGS. 6A , 6 B, 6 C, 6 D, 6 E and 6 F are diagrams showing an example of the result of binding.
- FIGS. 7A , 7 B, 7 C, 7 D, 7 E and 7 F are diagrams showing an example of the result of binding.
- FIGS. 8A and 8B are diagrams showing an example of a description after FSM generation.
- FIGS. 9A and 9B are diagrams showing an example of a description in which an input application timing signal, an output observation timing signal, and their logic circuits are created.
- FIG. 10 is a diagram showing an example of a test bench.
- FIG. 11 is a block diagram showing an example of the configuration of a second embodiment of the present invention.
- FIG. 12 is a flowchart showing the operation of the second embodiment of the present invention.
- FIG. 13 is a diagram showing an example of a behavioral description.
- FIG. 14 is a block diagram showing an example of the configuration of a third embodiment of the present invention.
- FIG. 15 is a diagram showing an example of a behavioral description used in an example.
- FIG. 16 is a diagram showing an example of the result of scheduling.
- FIGS. 17A and 17B are diagrams showing an example of a description after FSM generation.
- FIGS. 18A and 18B are diagrams showing an example of a description in which the input application timing and the output observation timing are recorded.
- FIG. 19 is a diagram showing an example of a test bench.
- FIG. 20 is a diagram showing an example of a test bench.
- FIG. 21 is a diagram showing an example of a test bench.
- FIG. 22 is a diagram showing an example of a behavioral description.
- FIGS. 23A and 23B are diagrams showing an example of an RTL description.
- FIG. 24 is a diagram showing an example of a test bench.
- a behavioral synthesis system (apparatus) according to a first example of the present invention, comprises a computer (central processing device; processor; data processing device) 100 that operates under program control and data storage means (data storage device) 110 .
- the computer (central processing device; processor; data processing device) 100 comprises scheduling means 101 , binding means 102 , FSM (finite state machine) generation means 103 , input application/output observation timing signal generation means 104 , HDL (Hardware Description Language) generation means (RTL generation means) 105 for generating an HDL description such as an RTL (Register Transfer Level) description, and test bench generation means 106 .
- scheduling means 101 binding means 102
- FSM finite state machine
- HDL generation means HDL (Hardware Description Language) generation means (RTL generation means) 105 for generating an HDL description such as an RTL (Register Transfer Level) description
- RTL Registered Transfer Level
- the scheduling means 101 assigns a behavioral description to an associated state. That is, the scheduling means 101 assigns arithmetic operation, conditional operation, read operation from an input terminal, write operation to an output terminal, an array read operation, and an array write operation, included in the behavioral description, respectively to states that will be executed.
- the binding means 102 maps a behavioral description to hardware resources. That is, the binding means 102 maps:
- multiple input signals in the behavioral description are allowed to be mapped to one input signal in the RTL description and multiple output signals in the behavioral description are allowed to be mapped to one output signal in the RTL description.
- multiple operations in the behavioral description are allowed to be mapped to one operation unit in the RTL description. Those are called “hardware resource sharing”.
- the finite state machine (FSM) generation means 103 creates a finite state machine (FSM) that controls state transitions and control logic circuits that control the hardware resources.
- the control logic circuits that control the hardware resources are logic circuits for controlling the hardware resources according to the assignment of the behavioral description to the states executed by the scheduling means 101 and the mapping of the behavioral description to the hardware resources executed by the binding means 102 .
- control logic circuits include the following logic circuits: a logic circuit that makes an operation in the behavioral description executed with a mapped hardware resource in an assigned state; a logic circuit that makes a conditional operation executed with a mapped hardware source in an assigned state; a logic circuit that controls a read operation from an input terminal, a write operation to an output terminal, an array read operation, and an array write operation to be executed in an assigned state, with an mapped hardware resource, respectively.
- the input application/output observation timing signal generation means 104 creates a new signal terminal corresponding to each of input terminals and output terminals. This signal is called an “input application/output observation timing signal”.
- the input application/output observation timing signal generation means 104 creates a logic circuit that outputs a predetermined value (called an “active value”) to an input application/output observation timing signal only under the state and the condition in which a value is input from, or output to, the corresponding input signal/output signal.
- a predetermined value called an “active value”
- the RTL generation means 105 converts the FSM and control logic circuits created by the finite state machine (FSM) generation means 103 , the logic circuits created by the input application/output observation timing signal generation means 104 , and the hardware resources into the HDL description and stores the converted description into the storage device 110 .
- FSM finite state machine
- the test bench generation means 106 creates a test bench. In the test bench, logic is created that observes the input application/output observation timing signal and, when an active value is output to this signal, applies an input or observes an output and compares the output value with an expected value.
- the test bench generation means 106 stores the created test bench in the storage device 110 .
- the behavioral synthesis apparatus in this example may be configured by an LSI or a logic circuit that implements the functions of the components shown in FIG. 1 or may be implemented by an information processing device (computer) such as the one shown in FIG. 2 .
- the information processing device shown in FIG. 2 comprises a processing device 100 including a CPU, a storage device 110 , and a recording medium (also called a storage medium) 500 .
- the processing device 100 reads a behavioral synthesis program from the recording medium 500 and, based on the behavioral synthesis program, causes the CPU to execute the processing of the scheduling means 101 and the binding (attendant information conversion) means 102 in this example which will be described below.
- the storage device 110 has its area divided into a behavioral description storage unit 111 , an RTL storage unit 112 , and a test bench storage unit 113 .
- a behavioral description is included in the behavioral description storage unit 111 in advance.
- the behavioral description is coded in hardware description language (HDL) such as Verilog-HDL, VHDL, and SystemVerilog or in programming language such as the C language, C++ language, C# language, SystemC, SpecC, Java (registered trademark), Pert, Scheme, and Lisp.
- HDL hardware description language
- the behavioral description is sometimes coded in language created by extending the C language, C++ language, or Java (registered trademark) for coding circuits.
- the behavioral description is prepared, for example, by a designer.
- the computer 100 reads a behavioral description from the behavioral description storage unit 111 in the storage device 110 and assigns the behavioral description to states with the use of scheduling means 101 included in the computer 100 . That is, the computer 100 assigns arithmetic operations, conditional operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, included in the behavioral description, to the states (step A 1 in FIG. 3 ).
- the binding means 102 maps the behavioral description to the hardware resources. That is, the binding means 102 maps the following elements in the behavioral description to the respective hardware resources:
- the FSM generation means 103 creates a finite state machine (FSM) that controls the state transition and logic circuits that control the hardware resources (step A 3 in FIG. 3 ).
- FSM finite state machine
- the input application/output observation timing signal generation means 104 creates the input application timing signal and the output observation timing signal and logic circuits for the input application timing signal and the output observation timing signal (step A 4 in FIG. 3 ).
- the RTL generation means 105 converts the FSM and the control logic circuits, created by the finite state machine generation means 103 in step A 3 , the logic circuits created by the input application/output observation timing signal generation means 104 in step A 4 , and the hardware resources to an HDL description, and stores it in the storage device 110 (step A 5 in FIG. 3 ).
- the HDL one of VHDL, Verilog-HDL, SystemVerilog, SystemC, SpecC, C language, C++ language, and C# language is used.
- the test bench generation means 106 generates a test bench.
- the test bench generation means 106 stores the created test bench in the storage device 110 (step A 6 ).
- the test bench is coded in one of VHDL, Verilog-HDL, SystemVerilog, SystemC, SpecC, C language, C++ language, and C# language.
- This example is configured in such a way that the input application/output observation timing signal generation means 104 generates signals for externally notifying a state and a condition under which a value is read from an input terminal, or is written to an output terminal, and that the test bench generation means 106 creates a test bench either applies an input or observes an output and compares the output value with an expected value according to the signals.
- test bench can be created which can apply an input at the appropriate timing, and observe an output to be compared with an expected value at the appropriate timing.
- FIG. 11 is a diagram showing the configuration of the second example of the present invention.
- FIG. 12 is a flowchart showing the operation of the second example of the present invention.
- the second example of the present invention has a computer (central processing device; processor; data processing device) 100 that operates under program control, but this computer 100 does not include the input application/output observation timing signal generation means 104 provided in the first example shown in FIG. 1 and, instead of the test bench generation means 106 , includes another test bench generation means 107 .
- steps A 4 and A 6 are deleted from the flowchart in FIG. 3 and step A 7 is added.
- test bench generation means 107 in this example differs from the test bench generation means 106 in the first example in the following points.
- the test bench generation means 107 recognizes the signals in the behavioral description as the input application timing signal and output observation timing signal, respectively. And, the test bench generation means 107 creates logic that observes the signals and, when an active value is output to the signals, either applies an input or observes an output and compares the output value with an expected value (step A 7 in FIG. 12 ). The test bench generation means 107 stores the created test bench in a storage device 110 .
- a third example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100 that operates under program control has input application/output observation timing recording means 108 instead of the input application/output observation timing signal generation means 104 in the first example shown in FIG. 1 and in that the computer 100 has test bench generation means 109 instead of the test bench generation means 106 .
- a computer central processing device; processor; data processing device
- the general operation of the input application/output timing recording means 108 is as follows.
- the input application/output observation timing recording means 108 references the control data flow graph and, for each input, records two items of information for each input signal.
- the first information includes the number of clocks from the time the reset is released to the time a first input value is applied.
- the second information includes the interval period from the time an input is once applied to the time the next input is applied.
- the input application/output observation timing recording means 108 records two items of information.
- the first information includes the number of clocks from the time the reset is released to the time the first output value becomes effective.
- the second information includes the interval period from the time the output value once becomes effective to the time the next output value becomes effective.
- the general operation of the test bench generation means 109 is as follows.
- the test bench generation means 109 creates a test bench that reads the input/output timing, recorded by the input application/output observation timing recording means 108 , counts the number of clocks from the time the reset signal is released, and applies an input when the number of clocks matches either the number of clocks at which an input is to be applied or the interval period at which an input is to be applied.
- the test bench generation means 109 creates a test bench that observes an output and compares it with an expected value when the number of clocks from the time the reset is released matches either the number of clocks when the output becomes effective or the interval period at which the output becomes effective.
- the created test bench is stored in the storage device 110 .
- This example differs from the technology, disclosed in Patent Document 2, in the following point. That is, in this example, the output observation timing is decided based not on the number of delay cycles from the input but on the number of cycles from the time the reset is released.
- the present invention can be applied even to a circuit, to which the invention disclosed in Patent Document 2 cannot be applied, because the input is applied, or the output is observed, based on the number of cycles after the reset is released.
- the fourth example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100 , which operates under program control, has the test bench generation means 106 in the first example shown in FIG. 1 that has the following function.
- test bench created by the test bench generation means 106 observes not only the input application/output observation timing signals but also the reset signal and neither applies an input nor observes an output while the reset signal is effective even if an active value is output to the input application/output observation signal.
- the created test bench is stored in a storage device 110 .
- the test bench generation means 106 also operates as follows. That is, a test bench created by the test bench generation means 106 observes not only the input application/output observation timing signals but also the stall signal and neither applies an input nor observes an output while the stall signal is effective even if an active value is output to the input application/output observation signal.
- the created test bench is stored in the storage device 110 .
- the fifth example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100 , which operates under program control, has the test bench generation means 106 in the first example shown in FIG. 1 that has the function described below.
- the general operation of the test bench generation means 106 is as follows.
- the test bench generation means 106 generates a test bench that has a necessary simulation model if simulation cannot be performed by an RTL description alone generated by RTL generation means 105 .
- test bench generation means 106 creates a test bench that includes a simulation model for the memory.
- test bench generation means 106 creates a test bench that includes a simulation model for the corresponding operation.
- FIG. 4 shows an example of a behavioral description.
- the behavioral description in FIG. 4 is coded in the C language.
- the input terminals of the function func( ) are the variables a, b, c, and d of type int, and the output terminal is the variable o of type int.
- the output value o of this function is:
- the behavioral description is stored in advance in the behavioral description storage unit 111 in the storage device 110 .
- a behavioral synthesis apparatus in the first example reads the behavioral description in FIG. 4 from the behavioral description storage unit 111 in the storage device 110 , the RTL generation means 105 creates an RTL description shown in FIGS. 9A and 9B , the test bench generation means 106 creates a test bench shown FIG. 10 , and they store the created RTL description and the test bench, respectively, in the RTL storage unit 112 and the test bench storage unit 113 of the storage device 110 .
- the scheduling means 101 in the computer 100 assigns the behavioral description to the states (step A 1 in FIG. 3 ). That is, the scheduling means 101 assigns arithmetic operations, conditional operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, included in the behavioral description, to the states.
- FIG. 5 shows an example of how the scheduling means 101 assigns operations in the behavioral description to states.
- FIG. 5 shows that the scheduling means 101 assigns:
- the binding means 102 in the computer 100 maps elements in the behavioral description to the hardware resources (step A 2 in FIG. 3 ).
- binding means 102 maps:
- FIGS. 6A , 6 B, 6 C, 6 D, 6 E and 6 F show schematic examples of how the binding means 102 maps the operations to the operation units.
- FIGS. 7A , 7 B, 7 C, 7 D, 7 E and 7 F show an example of how the binding means 102 maps the inputs and the output in the behavior level to the input terminals and the output terminal in the RTL.
- FIGS. 7A , 7 B, 7 C, 7 D, 7 E and 7 F show that the input a on the fifth line and the input c on the sixth line and the seventh line in FIG. 7A are mapped to the input terminal iport 1 ( FIG. 7B ), that the input b on the fifth line and the input d on the seventh line in FIG. 7A are mapped to the input terminal iport 2 ( FIG. 7C ), and that the output o on the tenth line in FIG. 7A is mapped to the output terminal oport 1 ( FIG. 7F ), respectively.
- the finite state machine (FSM) generation means 103 creates a finite state machine (FSM) that controls the state transition and the control logic circuits that control the hardware resources (step A 3 in FIG. 3 ).
- FIGS. 8A and 8B show an example of a finite state machine and a control logic circuit as well as the hardware resources controlled by the control logic circuit. This example is coded in Verilog-HDL.
- the finite state machine and the control logic circuit are represented by the state register “state” and the case( ) statement.
- FIGS. 8A and 8B are divided for the sake of creating the drawing, and the range from “module (input/output terminal list)” to “endmodule” constitutes one circuit module.
- the input terminals, output terminals, operation units, and storage devices are used as the hardware resources.
- the terminals iport 1 and iport 2 are used as the input terminals.
- the terminal oport 1 is used as the output terminal.
- the terminals v 0 and v 1 are used as the storage devices (registers).
- the reset signal rst and clock signal clk are used.
- the general operation of the module ‘main’ is as follows.
- the value of the state register ‘state’ is T_STATE 1
- the values are read from the input terminals iport 1 and iport 2 respectively
- the sum of the values is calculated by the adder ADD
- the calculation result is stored in the register v 0 .
- the value of the state register ‘state’ is updated to T_STATE 2 .
- the values are read from the input terminals iport 1 and iport 2 respectively, and the value read from iport 1 is compared with 0 by the comparator EQ. If the value read from the input terminal iport 1 is 0, the sum of the values read from the input terminals is calculated by the adder ADD and the calculation result is stored in the register v 1 . After that, the value of the state register ‘state’ is updated to T_STATE 3 .
- the value of the state register ‘state’ is updated sequentially in order of T_STATE 1 , T_STATE 2 , T_STATE 3 , T_STATE 1 , and so on.
- the module implements the function func( ) in the behavioral description.
- the input application/output observation timing signals generation means 104 creates the input application/output observation timing signals and the logical circuits for those signals (step A 4 in FIG. 3 ).
- FIGS. 9A and 9B show an example in which the input application/output observation timing signals and the logic circuits for those signals are added to the description shown in FIGS. 8A and 8B .
- the behavioral description in FIG. 4 includes the input terminals a, b, c, and d and the output terminal o.
- the input application timing signal a_e, b_e, c_e, and d_e are added corresponding to the inputs a, b, c, and d, respectively.
- the output observation timing signal o_e is added corresponding to the output signal o.
- the logic circuits that determine the output values of the signals a_e, b_e, c_e, d_e and o_e are also added.
- the RTL generation means 105 converts the FSM, control logic circuits, input application/output observation timing signals and respective logical circuits for input application/output observation timing signals, and hardware resources to the HDL description and stores the generated HDL description in the storage device 110 (step A 5 in FIG. 3 ).
- FIGS. 9A and 9B show an example of the HDL (Verilog-HDL) description generated by the RTL generation means 105 .
- test bench generation means 106 generates a test bench.
- the test bench observes the input application timing signal and at the timing when the signal has an active value applies an input value to the corresponding input terminal.
- the test bench also observes the output timing signal and at the timing when the signal has an active value reads a value from the corresponding output terminal and compares the value with an expected value.
- FIG. 10 shows a test bench created by the test bench generation means 106 .
- the example in FIG. 10 is coded in pseudo-code similar to Verilog-HDL.
- the general operation of the generated test bench is as follows.
- the input value of the input signal a is applied to the input terminal iport 1 assuming that the value of the input signal a is acquired from the input terminal iport 1 when the input application timing signal a_e has the active value (1(High)).
- the input value of the input signal b is applied to the input terminal iport 1 assuming that the value of the input signal b is acquired from the input terminal iport 1 when the input application timing signal b_e has the active value (1(High)).
- the input value of the input signal c is applied to the input terminal iport 2 assuming that the value of the input signal c is acquired from the input terminal iport 2 when the input application timing signal c_e has the active value (1(High)).
- the input value of the input signal d is applied to the input terminal iport 2 assuming that the value of the input signal d is acquired from the input terminal iport 2 when the input application timing signal d_e has the active value (1(High)).
- the module ‘main’ dut (input/output terminal list) in FIG. 10 is a test target module.
- FIG. 13 shows an example of a behavioral description.
- the behavioral description in FIG. 13 differs from the behavioral description in FIG. 4 in that the output signals a_e, b_e, c_e, d_e, and o_e are provided and that the write operations for the output signals a_e and b_e, output signal c_e, output signal d_e, and output signal o_e are specified respectively on line 16 , line 17 , line 20 , and line 23 .
- the output signals a_e, b_e, c_e, d_e, and o_e are output signals indicating the input timing and the output timing of a, b, c, d, and o.
- write operation is also coded in the behavioral description. The write operation writes an active value (1) when an input/output access is made to an associated signal.
- a behavioral synthesis apparatus in the second example of the present invention reads the behavioral description in FIG. 13 from a behavioral description storage unit 111 of the storage device 110 in FIG. 11 and, through the execution of scheduling means 101 , binding means 102 , FSM generation means 103 , and RTL generation means 105 , generates the module ‘main’ shown in FIGS. 9A and 9B .
- the operation of the module ‘main’ is as described above.
- test bench generation means 107 in FIG. 11 generates a test bench.
- the test bench observes the input application timing signals and at the timing when the signal has an active value applies an input value to the corresponding input terminal.
- the test bench also observes the output timing signals and at the timing when the signal has an active value reads a value from the corresponding output terminal and compares the value with an expected value.
- the signals originally included in the behavioral description are used for the input application/output observation timing signals.
- FIG. 10 shows the created test bench.
- the test bench in this example is coded in pseudo code similar to Verilog-HDL.
- the signal a_e is used for the input application timing signal of the signal a. This is determined based on the similarity in the signal names.
- the signal b_e is used for the input application timing signal of the signal b. This is determined based on the comment (pragma) (see FIG. 13 ) of the signal b.
- the signal c_e is used for the input application timing signal of the signal c. This is determined based on the comment (pragma) (see FIG. 13 ) of the signal c.
- the signal d_e is used for the input application timing signal of the signal d. This is determined based on the description in which the reference to the signal d and the output to the signal d_e are described continuously in the behavioral description (see lines 19 and 20 in FIG. 13 ).
- test bench in FIG. 10 The operation of the test bench in FIG. 10 is as described above.
- FIG. 15 shows an example of a behavioral description.
- the input to the function func( ) is variables a, b, c, and d of type int
- the output is variables o 1 and o 2 of type int.
- the output of the function func( ) is the sum of the inputs a and b
- the output o 2 is the total sum of the inputs a, b, c, and d.
- the behavioral description is stored in advance in a behavioral description storage unit 111 of a storage device 110 shown in FIG. 14 .
- a behavioral synthesis apparatus in the third example of the present invention reads the behavioral description in FIG. 15 from the behavioral description storage unit 111 of the storage device 110 in FIG. 14 .
- RTL generation means 105 creates an RTL description shown in FIGS. 18A and 18B
- test bench generation means 109 creates a test bench shown in FIG. 19 , and they store the created RTL description and the test bench, respectively, in an RTL storage unit 112 and a test bench storage unit 113 of the storage device 110 .
- scheduling means 101 in the computer 100 assigns the behavioral description to the stages. That is, the scheduling means 101 assigns the arithmetic operations, condition operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, which are included in the behavioral description, to associated states (stages).
- FIG. 16 shows an example of how the scheduling means 101 assigns a behavioral description to stages.
- FIG. 16 shows that the scheduling means 101 assigns the read operations from the inputs a and b and the addition+on the eleventh line to STAGE 1 , the read operations from the inputs b and c and the addition+on the twelfth line to STAGE 2 , the write operation to the output o 1 on the thirteenth line and the addition+on the fourteenth line to STAGE 3 , and the write operation to the output o 2 on the fifteenth line to STAGE 4 .
- FIGS. 17A and 17B show the module ‘main’ generated after the execution of the binding means 102 and the FSM generation means 103 .
- the example shown in FIGS. 17A and 17B is coded in Verilog-HDL.
- This module is synthesized as a pipeline circuit. All stages, STAGE 1 -STAGE 4 , operate in each clock period in synchronization with the clock signal.
- the input application/output observation timing recording means 108 references the control data flow graph and records two items of information for each input signal.
- the first information includes the number of clock cycles from the time when the reset is released to the time when the first input value is applied.
- the second information includes the interval period of input application.
- the input application/output observation timing recording means 108 records two items of information for each output signal.
- the first information includes the number of clock cycles from the time when the reset is released to the time when the first effective value is written into the signal.
- the second information includes the interval period of output observation.
- FIGS. 18A and 18B show the module ‘main’ in which this information is recorded in the module ‘main’ shown in FIGS. 17A and 17B .
- the output value of the output signal o 1 becomes effective in each cycle beginning with the third clock after the reset is released and, so, the information is recorded in the module. That is, “3, 1” on the comment line of the output signal of in the declaration part, such as the one shown in FIG. 18A , indicates that the signal becomes effective three clocks after the reset is released and that the interval period is one clock cycle.
- the output value of the output signal o 2 becomes effective in each cycle beginning with the fourth clock after the reset is released and, so, the information is recorded in the module. That is, “4, 1” on the comment line of the output signal o 2 in the declaration part, such as the one shown in FIG. 18A , indicates that the signal becomes effective four clocks after the reset is released and that the interval period is one clock cycle.
- the RTL generation means 105 and the test bench generation means 109 shown in FIG. 14 create an RTL description and a test bench and store them in the storage device 110 .
- FIG. 19 shows an example of a test bench created by the test bench generation means 109 shown in FIG. 14 .
- the example in FIG. 19 is coded in pseudo code similar to Verilog-HDL.
- the general operation of the generated test bench is as follows. Beginning with the first clock cycle after the reset is released and in each clock period, input values are applied to the input terminals a and b respectively.
- FIG. 20 shows an example of a test bench created by test bench generation means 106 in the fourth example of the present invention.
- FIG. 20 shows the general operation of the generated test bench.
- the input value of the input signal a is applied to the input terminal iport 1 assuming that the value of the input signal a is acquired from the input terminal iport 1 when the value of the input application timing signal a_e is an active value (1(High)) and when the reset is not effective.
- the input value of the input signal b is applied to the input terminal iport 1 assuming that the value of the input signal b is acquired from the input terminal iport 1 when the value of the input application timing signal b_e is an active value (1(High)) and when the reset is not effective.
- the input value of the input signal c is applied to the input terminal iport 2 assuming that the value of the input signal c is acquired from the input terminal iport 2 when the value of the input application timing signal c_e is an active value (1(High)) and when the reset is not effective.
- the input value of the input signal d is applied to the input terminal iport 2 assuming that the value of the input signal d is acquired from the input terminal iport 2 when the value of the input application timing signal d_e is an active value (1(High)) and when the reset is not effective.
- the value of the output terminal oport 1 is observed and is compared with the expected value of the output signal o assuming that the value of the output signal o is written to the output terminal oport 1 when the value of the output observation timing signal o_e is an active value (1(High)) and when the reset is not effective.
- FIG. 21 shows another example of a test bench created by the test bench generation means 106 in the fourth example.
- the values of the input signals a and b are applied respectively to the input terminals a and b beginning with the first clock cycle after the reset is released, in each clock period, and when the stall signal is not effective.
- the values of the input signals c and d are applied to the input terminals c and d beginning with the second clock cycle after the reset is released, in each clock period, and when the stall signal is not effective.
- the values of the output terminals o 1 and o 2 are observed and compared respectively the expected values beginning with the third clock cycle or fourth clock cycle after the reset is released, in each clock period, and when the stall signal is not effective.
- FIG. 22 shows an example of the behavioral description.
- the general operation of this behavioral description is as follows.
- the values are read from the input signals a and b, and the value of the input signal b is written at the address in the array ary [ ] indicated by the value of the input signal a.
- the value is read from the input signal c, and the value at the address in the array ary[ ], indicated by the value of the input signal c, is read and is output to the output signal o 1 .
- FIGS. 23A and 23B show examples of an RTL description that is generated by the execution of scheduling means 101 , binding means 102 , FSM generation means 103 , and RTL generation means 105 in the fifth example of the present invention.
- the description shown in FIGS. 23A and 23B include a memory interface circuit for accessing the array ary[ ].
- the signals ad, rd, wd, and we correspond, respectively, to the address, read data, write data, and write enable flag.
- the general operation of the module ‘main’ is as follows. The following operation is performed when the clock signal clk rises. If the input to the reset terminal rst is 1, the value of the state register ‘state’ is set to T_STATE 1 and the registers v 0 , v 1 , and o_t are initialized to 0.
- the module ‘main’ operates as follows if the input to the reset terminal rst is not 1 when the clock signal clk rises.
- the module reads the input signals a and b, stores the values of those signals respectively in the registers ad_t and wd_t, stores 1 in we_t, and updates the value of the state register ‘state’ to T_STATE 2 .
- the module When the value of the state register ‘state’ is T_STATE 2 , the module reads the input signal c, stores its value in ad_t, stores 0 in we_t, and updates the value of the state register ‘state’ to T_STATE 3 .
- the module updates the value of the state register ‘state’ to T_STATE 4 .
- the module stores the read data rd in the register o_t and updates the value of the state register ‘state’ to T_STATE 1 .
- the value of the state register ‘state’ is updated in order of T_STATE 1 , T_STATE 2 , and so on.
- FIG. 24 shows a test bench generated by the test bench generation means 106 .
- this test bench not only the test target module (main dut( . . . )) but also the memory simulation model m 1 (memory m 1 ( . . . )) corresponding to the array ary[ ] is created and the necessary wire connection is made.
- the present invention can be used to make sure that a behavioral description is equivalent to an RTL description generated by behavioral synthesis.
- the present invention can also be used to make sure that the RTL description generated by behavioral synthesis gives full performance.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Hardware Design (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Evolutionary Computation (AREA)
- Geometry (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Tests Of Electronic Circuits (AREA)
- Test And Diagnosis Of Digital Computers (AREA)
Abstract
Disclosed is a behavioral synthesis apparatus for generating a test bench where the same test vector can be used in both the behavioral simulation and the RTL simulation. The apparatus includes input application/output signal observation timing signal generation means that generates an input application timing signal, an output observation timing signal, and logic circuits for the input application timing signal and the output observation timing signal; and test bench generation means that generates a test bench that observes the signals, applies inputs, and observes outputs.
Description
This application is based upon and claims the benefit of the priority of Japanese patent application No. 2007-019451, filed on Jan. 30, 2007, and is a divisional of U.S. Ser. No. 12/022,573 filed Jan. 30, 2008, the disclosure of which is incorporated herein in its entirety by reference thereto.
The present invention relates to a behavioral synthesis apparatus, a behavioral synthesis method, and a behavioral synthesis program that generate an RTL (Register Transfer Level) circuit description, which describes specific functions (circuits), from a behavior level circuit description that describes the behavior of a semiconductor integrated circuit, and more particularly to a behavioral synthesis apparatus, a behavioral synthesis method, and a behavioral synthesis program that can output a test bench for verifying the generated RTL circuit.
The recent trend in designing a system LSI is that a system LSI is designed first at a high abstraction level and then an RTL description is generated through behavioral synthesis.
In this design method, the behavioral description, which implements the desired behavior of a system LSI, is designed first.
Next, the behavior simulation is performed to confirm if the designed behavioral description achieves the desired circuit behavior, that is, if the design is correct.
If the design is correct, the behavior description is transformed into an RTL description through behavioral synthesis.
When an LSI is designed using the design method described above, there is a requirement that the test vector used in the behavioral simulation is used also in the RTL simulation after the behavioral synthesis. For example, this requirement has first and second purposes described below.
The first purpose is to confirm if the behavioral description before behavioral synthesis and the RTL description after behavioral synthesis implement the same function.
If the behavioral description and the RTL description do not implement the same function, the behavioral simulation, if performed to confirm that the behavioral description achieves the desired behavior of the circuit, is meaningless. This is because the designed circuit does not eventually implement the desired behavior.
Conventionally, whether or not the behavioral description and the RTL description implement the same function is confirmed by using the same test vector for the behavioral simulation and the RTL simulation and comparing the results of both simulations.
The second purpose is to confirm the performance of the circuit after the behavioral synthesis.
Because time information is not usually included in the behavioral description, the circuit performance, for example, how much time is required to achieve a function, cannot be confirmed.
In contrast, the RTL simulation reveals how much time is required to achieve a function, that is, the RTL simulation shows the circuit performance.
Therefore, the related art technique checks whether or not the designed behavioral description achieves the desired performance by using the same test vector in both the behavioral simulation and the RTL simulation and evaluating the circuit performance measured in the RTL simulation.
The problem here is that the test vector used in the behavioral simulation cannot be used directly in the RTL simulation.
The reason is that the input application timing and the output observation timing differ between the behavioral simulation and the RTL simulation.
In general, there is no concept of timing (clock) in the behavioral description. Even if there is the concept of timing, the granularity of timing in the behavioral description is different from that of the RTL description. Therefore, the sequence of data that is used as the test vector in the behavioral simulation, if applied at each clock cycle during the RTL simulation, does not produce the same result as that produced by the behavioral simulation. Similarly, the output of the RTL simulation, if observed at each clock cycle, is not the same as that produced by the behavioral simulation.
Patent Document 1 (Japanese Patent Kokai Publication No. JP-P2005-78402A) discloses a behavioral synthesis system that solves the problems described above. The behavioral synthesis system described in Patent Document 1 is proposed primarily to solve the first problem described above (the sequence of data that is used as the test vector in the behavioral simulation, if applied at each clock cycle during the RTL simulation, does not produce the same result as that produced by the behavioral simulation). This conventional behavioral synthesis system assumes that the file read function, which reads the sequence of input from a file, and the file write function, which writes the sequence of output to a file, are described in the behavioral description. The file read function and the file write function are generically called a file function. This conventional behavioral synthesis system comprises syntax analysis means, control data flow graph construction means, scheduling/binding means, test bench generation means, and RTL generation means. The behavioral synthesis system having this configuration operates as follows.
That is, the syntax analysis means and the control data flow graph construction means leave the file functions, which are included in the behavioral description, undeleted.
Resource binding and scheduling are performed to create an RTL description based on the constructed control data flow graph.
The file input for a file function is represented in the created RTL description using the select signal of the multiplexer for input data. The file output condition is represented using the select signal of the multiplexer for output data.
However, the behavioral synthesis system described in Patent Document 1, which operates on the premise that the file functions are used in the behavioral description, is applicable only to a behavioral description satisfying this premise.
An example of the equivalence verification method is disclosed in Patent Document 2 (Japanese Patent Kokai Publication No. JP-P2004-145712A). The equivalence verification method disclosed in Patent Document 2 is proposed primarily to solve the first problem described above. This equivalence verification method finds a comparison time based on the number of delay cycles from the time the input signal is determined to the time the output signal is determined in the RTL simulation result and compares the value of the output signal of the RTL simulation result with the value of the output signal of the behavioral simulation at the comparison time. The problem with this method is that the kind of circuit to which this method is can be applied is limited.
This is because no consideration is made in this method for a circuit whose input value application time differs according to the input signal.
In addition, no consideration is made in this method for a case in which the comparison time cannot be determined based on “the number of delay cycles”, for example, when the number of delay cycles depend on the input data.
Patent Document 3 (U.S. Pat. No. 6,845,341 B2) discloses a performance analysis system. The general operation of this performance analysis system is as follows. That is, a test bench for executing the behavioral simulation and the RTL simulation at the same time is created. A module for absorbing the difference in the input time and the output time of the behavioral simulation and the RTL simulation is inserted between the behavioral description and the test bench and between the RTL description and the test bench. In this configuration, the behavioral simulation and the RTL simulation receive the same test vector and the number of clocks required for the RTL description to execute simulation is measured to evaluate the performance.
[Patent Document 1]
-
- Japanese Patent Kokai Publication No. JP-P2005-78402A
[Patent Document 2]
-
- Japanese Patent Kokai Publication No. JP-P2004-145712A
[Patent Document 3]
-
- U.S. Pat. No. 6,845,341 B2 (FIG. 2)
The above mentioned patent documents are incorporated by reference. The analysis on the related arts given by the present invention will be described in the below.
In the related art system, there is a problem that the test vector used in the behavioral simulation cannot be used directly in the RTL simulation.
This is because of the input application timing and the output observation timing as described above. The above discussion shows that various propositions for solving this problem are not satisfactory.
Another reason for the above problem is the sharing of input terminals and output terminals. In general, there is not always a one-to-one correspondence between the input/output terminals of a behavioral description and the input/output terminals of an RTL description.
A still another reason for the above problem is a behavior that cannot be represented by a behavioral description. There are many behavioral descriptions where the input/output behavior during a reset is not specified. For example, when the C language is used for behavioral description, the behavior of the input/output during a reset is not specified (there is also behavioral description language, such as SystemC language, in which the input/output behavior during a reset is specified).
This means that the application of an input value, or the observation of an output value, if performed during the reset period at RTL simulation, does not give the same result as that produced by the behavioral simulation.
A still another reason for the above problem is an external model (shared memory model, memory model, operation unit model, etc.). In behavioral synthesis, an array in the behavioral description is implemented by a memory in the RTL description, and a variable in the behavioral description is implemented by a register outside the module in the RTL description.
When an operation in the behavioral description is implemented by an operation unit in the RTL description, the operation is sometimes output as a black box whose detailed internal logic is omitted.
This means that, to perform the RTL simulation, a memory simulation model, a register outside the module, and an operation unit simulation model that is output as a block box must be prepared.
Accordingly, it is an object of the present invention to provide a behavioral synthesis apparatus, a behavioral synthesis method, and a behavioral synthesis program that allow a test vector, which is used before the behavioral synthesis, to be used also for a circuit obtained after the behavioral synthesis.
According to a first aspect of the present invention, there is provided a system (apparatus) comprising: input application/output observation timing signal generation means that creates an input application timing signal and an output observation timing signal for each input and output of a circuit and creates respective logic circuits for the input application timing signal and the output observation timing signal; and test bench generation means that generates a test bench that applies an input to, and observes an output from, the circuit according to values of the input application timing signal and the output observation timing signal.
According to a second aspect of the present invention, there is provided a system (apparatus) comprising: test bench generation means that recognizes an input application timing signal and an output observation timing signal in a behavioral description of a circuit and generates a test bench that applies an input to, and observes an output from, the circuit according to values of the input application timing signal and the output observation timing signal.
According to a third aspect of the present invention, there is provided a system (apparatus) comprising: test bench generation means that generates a test bench that counts a number of clocks after a reset is released and, when the number of clocks matches a predetermined value, applies an input or observes an output.
According to a fourth aspect of the present invention, there is provided a system (apparatus) comprising: the test bench generation means that generates the test bench that does not apply an input or observe an output when a reset signal or a stall signal is effective.
According to a fourth aspect of the present invention, there is provided a system (apparatus) comprising: the test bench generation means that outputs the test bench that has a simulation model for a hardware resource that is output as a black box in an RTL (Register Transfer Level) description.
Also provided are the invention of methods and the invention of programs for the first to fifth aspects of systems (devices) described above.
The meritorious effects of the present invention are summarized as follows.
The present invention allows the same test vector to be used in a behavioral simulation and an RTL simulation. This is because, in the present invention, a test bench is output in such a way that a test vector used before behavioral synthesis can be used also in a circuit generated after behavioral synthesis.
Still other features and advantages of the present invention will become readily apparent to those skilled in this art from the following detailed description in conjunction with the accompanying drawings wherein examples of the invention are shown and described, simply by way of illustration of the mode contemplated of carrying out this invention. As will be realized, the invention is capable of other and different examples, and its several details are capable of modifications in various obvious respects, all without departing from the invention. Accordingly, the drawing and description are to be regarded as illustrative in nature, and not as restrictive.
The present invention will be described more in detail with reference to the attached drawings.
Referring to FIG. 1 , a behavioral synthesis system (apparatus) according to a first example of the present invention, comprises a computer (central processing device; processor; data processing device) 100 that operates under program control and data storage means (data storage device) 110.
The computer (central processing device; processor; data processing device) 100 comprises scheduling means 101, binding means 102, FSM (finite state machine) generation means 103, input application/output observation timing signal generation means 104, HDL (Hardware Description Language) generation means (RTL generation means) 105 for generating an HDL description such as an RTL (Register Transfer Level) description, and test bench generation means 106. The following describes the general operation of those means.
The scheduling means 101 assigns a behavioral description to an associated state. That is, the scheduling means 101 assigns arithmetic operation, conditional operation, read operation from an input terminal, write operation to an output terminal, an array read operation, and an array write operation, included in the behavioral description, respectively to states that will be executed.
The binding means 102 maps a behavioral description to hardware resources. That is, the binding means 102 maps:
an arithmetic/conditional operation in the behavioral description to an arithmetic/conditional operation unit,
an input terminal in the behavioral description to an input terminal in the RTL description,
an output terminal in the behavioral description to an output terminal in the RTL description, and
an array in the behavioral description to a memory or a register file in the RTL description.
At this time, multiple input signals in the behavioral description are allowed to be mapped to one input signal in the RTL description and multiple output signals in the behavioral description are allowed to be mapped to one output signal in the RTL description. Similarly, multiple operations in the behavioral description are allowed to be mapped to one operation unit in the RTL description. Those are called “hardware resource sharing”.
The finite state machine (FSM) generation means 103 creates a finite state machine (FSM) that controls state transitions and control logic circuits that control the hardware resources. The control logic circuits that control the hardware resources are logic circuits for controlling the hardware resources according to the assignment of the behavioral description to the states executed by the scheduling means 101 and the mapping of the behavioral description to the hardware resources executed by the binding means 102. That is, the control logic circuits include the following logic circuits: a logic circuit that makes an operation in the behavioral description executed with a mapped hardware resource in an assigned state; a logic circuit that makes a conditional operation executed with a mapped hardware source in an assigned state; a logic circuit that controls a read operation from an input terminal, a write operation to an output terminal, an array read operation, and an array write operation to be executed in an assigned state, with an mapped hardware resource, respectively.
The input application/output observation timing signal generation means 104 creates a new signal terminal corresponding to each of input terminals and output terminals. This signal is called an “input application/output observation timing signal”.
In addition, the input application/output observation timing signal generation means 104 creates a logic circuit that outputs a predetermined value (called an “active value”) to an input application/output observation timing signal only under the state and the condition in which a value is input from, or output to, the corresponding input signal/output signal.
The RTL generation means 105 converts the FSM and control logic circuits created by the finite state machine (FSM) generation means 103, the logic circuits created by the input application/output observation timing signal generation means 104, and the hardware resources into the HDL description and stores the converted description into the storage device 110.
The test bench generation means 106 creates a test bench. In the test bench, logic is created that observes the input application/output observation timing signal and, when an active value is output to this signal, applies an input or observes an output and compares the output value with an expected value. The test bench generation means 106 stores the created test bench in the storage device 110.
The behavioral synthesis apparatus in this example may be configured by an LSI or a logic circuit that implements the functions of the components shown in FIG. 1 or may be implemented by an information processing device (computer) such as the one shown in FIG. 2 .
The information processing device shown in FIG. 2 comprises a processing device 100 including a CPU, a storage device 110, and a recording medium (also called a storage medium) 500. The processing device 100 reads a behavioral synthesis program from the recording medium 500 and, based on the behavioral synthesis program, causes the CPU to execute the processing of the scheduling means 101 and the binding (attendant information conversion) means 102 in this example which will be described below.
The storage device 110 has its area divided into a behavioral description storage unit 111, an RTL storage unit 112, and a test bench storage unit 113.
Next, the following describes the general operation of this example in detail with reference to FIG. 1 and the flowcharts in FIG. 3 .
A behavioral description is included in the behavioral description storage unit 111 in advance. The behavioral description is coded in hardware description language (HDL) such as Verilog-HDL, VHDL, and SystemVerilog or in programming language such as the C language, C++ language, C# language, SystemC, SpecC, Java (registered trademark), Pert, Scheme, and Lisp. The behavioral description is sometimes coded in language created by extending the C language, C++ language, or Java (registered trademark) for coding circuits. The behavioral description is prepared, for example, by a designer.
First, the computer 100 reads a behavioral description from the behavioral description storage unit 111 in the storage device 110 and assigns the behavioral description to states with the use of scheduling means 101 included in the computer 100. That is, the computer 100 assigns arithmetic operations, conditional operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, included in the behavioral description, to the states (step A1 in FIG. 3 ).
Next, the binding means 102 maps the behavioral description to the hardware resources. That is, the binding means 102 maps the following elements in the behavioral description to the respective hardware resources:
an arithmetic/conditional operation to an arithmetic/conditional operation unit,
an input terminal in the behavioral level to an input terminal in the RTL,
an output terminal in the behavioral level to an output terminal in the RTL, and
an array to a memory or a register file (step A2 in FIG. 3 ).
After that, the FSM generation means 103 creates a finite state machine (FSM) that controls the state transition and logic circuits that control the hardware resources (step A3 in FIG. 3 ).
After that, the input application/output observation timing signal generation means 104 creates the input application timing signal and the output observation timing signal and logic circuits for the input application timing signal and the output observation timing signal (step A4 in FIG. 3 ).
After that, the RTL generation means 105 converts the FSM and the control logic circuits, created by the finite state machine generation means 103 in step A3, the logic circuits created by the input application/output observation timing signal generation means 104 in step A4, and the hardware resources to an HDL description, and stores it in the storage device 110 (step A5 in FIG. 3 ). For the HDL, one of VHDL, Verilog-HDL, SystemVerilog, SystemC, SpecC, C language, C++ language, and C# language is used.
The test bench generation means 106 generates a test bench. The test bench generation means 106 stores the created test bench in the storage device 110 (step A6). As with the RTL description, the test bench is coded in one of VHDL, Verilog-HDL, SystemVerilog, SystemC, SpecC, C language, C++ language, and C# language.
The effect of this example is as follows.
This example is configured in such a way that the input application/output observation timing signal generation means 104 generates signals for externally notifying a state and a condition under which a value is read from an input terminal, or is written to an output terminal, and that the test bench generation means 106 creates a test bench either applies an input or observes an output and compares the output value with an expected value according to the signals.
Therefore, a test bench can be created which can apply an input at the appropriate timing, and observe an output to be compared with an expected value at the appropriate timing.
Next, a second example of the present invention will be described. FIG. 11 is a diagram showing the configuration of the second example of the present invention. FIG. 12 is a flowchart showing the operation of the second example of the present invention. Referring to FIG. 11 , the second example of the present invention has a computer (central processing device; processor; data processing device) 100 that operates under program control, but this computer 100 does not include the input application/output observation timing signal generation means 104 provided in the first example shown in FIG. 1 and, instead of the test bench generation means 106, includes another test bench generation means 107. Referring to FIG. 12 , steps A4 and A6 are deleted from the flowchart in FIG. 3 and step A7 is added.
The test bench generation means 107 in this example differs from the test bench generation means 106 in the first example in the following points.
That is, the test bench generation means 107 recognizes the signals in the behavioral description as the input application timing signal and output observation timing signal, respectively. And, the test bench generation means 107 creates logic that observes the signals and, when an active value is output to the signals, either applies an input or observes an output and compares the output value with an expected value (step A7 in FIG. 12 ). The test bench generation means 107 stores the created test bench in a storage device 110.
Referring to FIG. 14 , a third example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100 that operates under program control has input application/output observation timing recording means 108 instead of the input application/output observation timing signal generation means 104 in the first example shown in FIG. 1 and in that the computer 100 has test bench generation means 109 instead of the test bench generation means 106.
The general operation of the input application/output timing recording means 108 is as follows.
The input application/output observation timing recording means 108 references the control data flow graph and, for each input, records two items of information for each input signal. The first information includes the number of clocks from the time the reset is released to the time a first input value is applied. The second information includes the interval period from the time an input is once applied to the time the next input is applied. At the same time, for each output signal, the input application/output observation timing recording means 108 records two items of information. The first information includes the number of clocks from the time the reset is released to the time the first output value becomes effective. The second information includes the interval period from the time the output value once becomes effective to the time the next output value becomes effective.
The general operation of the test bench generation means 109 is as follows. The test bench generation means 109 creates a test bench that reads the input/output timing, recorded by the input application/output observation timing recording means 108, counts the number of clocks from the time the reset signal is released, and applies an input when the number of clocks matches either the number of clocks at which an input is to be applied or the interval period at which an input is to be applied. At the same time, the test bench generation means 109 creates a test bench that observes an output and compares it with an expected value when the number of clocks from the time the reset is released matches either the number of clocks when the output becomes effective or the interval period at which the output becomes effective. The created test bench is stored in the storage device 110.
This example differs from the technology, disclosed in Patent Document 2, in the following point. That is, in this example, the output observation timing is decided based not on the number of delay cycles from the input but on the number of cycles from the time the reset is released.
Thus, for both an input and an output, the present invention can be applied even to a circuit, to which the invention disclosed in Patent Document 2 cannot be applied, because the input is applied, or the output is observed, based on the number of cycles after the reset is released.
Next, the following describes a fourth example of the present invention. The fourth example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100, which operates under program control, has the test bench generation means 106 in the first example shown in FIG. 1 that has the following function.
A test bench created by the test bench generation means 106 observes not only the input application/output observation timing signals but also the reset signal and neither applies an input nor observes an output while the reset signal is effective even if an active value is output to the input application/output observation signal. The created test bench is stored in a storage device 110.
The test bench generation means 106 also operates as follows. That is, a test bench created by the test bench generation means 106 observes not only the input application/output observation timing signals but also the stall signal and neither applies an input nor observes an output while the stall signal is effective even if an active value is output to the input application/output observation signal. The created test bench is stored in the storage device 110.
Next, the following describes a fifth example of the present invention. The fifth example of the present invention differs from the first example in that a computer (central processing device; processor; data processing device) 100, which operates under program control, has the test bench generation means 106 in the first example shown in FIG. 1 that has the function described below. The general operation of the test bench generation means 106 is as follows.
The test bench generation means 106 generates a test bench that has a necessary simulation model if simulation cannot be performed by an RTL description alone generated by RTL generation means 105.
Simulation cannot be performed by an RTL description alone, for example, when the behavioral description includes an array for which an interface circuit for accessing the memory is generated in the RTL description. In this case, the test bench generation means 106 creates a test bench that includes a simulation model for the memory.
Simulation cannot be performed either, for example, when the behavioral description includes a complex operation such as multiplication and division for which a black box is output for this operation part in the RTL description. In this case, the test bench generation means 106 creates a test bench that includes a simulation model for the corresponding operation.
The following describes the present invention using specific examples.
First, a first specific example of the present invention will be described. This specific example corresponds to the first example of the present invention described above. FIG. 4 shows an example of a behavioral description. The behavioral description in FIG. 4 is coded in the C language.
The input terminals of the function func( ) are the variables a, b, c, and d of type int, and the output terminal is the variable o of type int. The output value o of this function is:
the total sum of all inputs (a, b, c, d) when the value of the input c is 0 and
the sum of the input a and b when the value of the input c is not 0. The behavioral description is stored in advance in the behavioral description storage unit 111 in the storage device 110.
A behavioral synthesis apparatus in the first example reads the behavioral description in FIG. 4 from the behavioral description storage unit 111 in the storage device 110, the RTL generation means 105 creates an RTL description shown in FIGS. 9A and 9B , the test bench generation means 106 creates a test bench shown FIG. 10 , and they store the created RTL description and the test bench, respectively, in the RTL storage unit 112 and the test bench storage unit 113 of the storage device 110.
First, the scheduling means 101 in the computer 100 assigns the behavioral description to the states (step A1 in FIG. 3 ). That is, the scheduling means 101 assigns arithmetic operations, conditional operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, included in the behavioral description, to the states.
In the behavioral description in FIG. 4 , there are described the following:
read operations from a and b and addition+on the fifth line,
read operation from c and conditional operation==on the sixth line,
read operations from c and d and addition+on the seventh line, and
addition+and write operation to an output o on the ninth line.
read operations from a and b and addition+on the fifth line to state STATE1,
read operation from c and conditional operation==on the sixth line and read operations from c and d and addition+on the seventh line to state STATE2, respectively, and
addition+and write operation to the output o on the ninth line to state STATE3.
Next, the binding means 102 in the computer 100 maps elements in the behavioral description to the hardware resources (step A2 in FIG. 3 ).
That is, the binding means 102 maps:
an operation in the behavioral description to an operation unit,
an input terminal in the behavioral description to an input terminal in the RTL description
an output terminal in the behavioral description to an output terminal in the RTL description and
an array in the behavioral description to an RTL memory or a register file.
Next, the finite state machine (FSM) generation means 103 creates a finite state machine (FSM) that controls the state transition and the control logic circuits that control the hardware resources (step A3 in FIG. 3 ).
The input terminals, output terminals, operation units, and storage devices (registers) are used as the hardware resources. The terminals iport1 and iport2 are used as the input terminals. The terminal oport1 is used as the output terminal. The adder ADD and the comparator EQ are used as the operation units, and they are represented as the addition+and comparison==in the example in FIGS. 8A and 8B . The terminals v0 and v1 are used as the storage devices (registers). In addition, the reset signal rst and clock signal clk are used. The general operation of the module ‘main’ is as follows.
The following operations are performed when the clock signal clk rises. If the input of the reset terminal rst is 1, the value of the state register ‘state’ is set to T_STATE1 and the registers v0, v1, and o_t are initialized to 0.
If the input of the reset terminal rst is not 1 when the clock signal clk rises, the following operation is performed. When the value of the state register ‘state’ is T_STATE1, the values are read from the input terminals iport1 and iport2 respectively, the sum of the values is calculated by the adder ADD, the calculation result is stored in the register v0. After that, the value of the state register ‘state’ is updated to T_STATE2.
When the value of the state register ‘state’ is T_STATE2, the values are read from the input terminals iport1 and iport2 respectively, and the value read from iport1 is compared with 0 by the comparator EQ. If the value read from the input terminal iport1 is 0, the sum of the values read from the input terminals is calculated by the adder ADD and the calculation result is stored in the register v1. After that, the value of the state register ‘state’ is updated to T_STATE3.
When the value of the state register ‘state’ is T_STATE3, the sum of the values of the registers v0 and v1 is calculated by the adder ADD and the calculation result is written to the output terminal oport1. After that, the value of the state register ‘state’ is updated to T_STATE1.
The value of the state register ‘state’ is updated sequentially in order of T_STATE1, T_STATE2, T_STATE3, T_STATE1, and so on.
If a test bench applies the values of inputs a, b, c, and d to the input terminals iport1 and iport2 at appropriate timing, respectively, and observes the value of the output terminal oport1 at appropriate timing, the module implements the function func( ) in the behavioral description.
Next, the input application/output observation timing signals generation means 104 creates the input application/output observation timing signals and the logical circuits for those signals (step A4 in FIG. 3 ).
The behavioral description in FIG. 4 includes the input terminals a, b, c, and d and the output terminal o. Referring to FIGS. 9A and 9B , the input application timing signal a_e, b_e, c_e, and d_e are added corresponding to the inputs a, b, c, and d, respectively. The output observation timing signal o_e is added corresponding to the output signal o. The logic circuits that determine the output values of the signals a_e, b_e, c_e, d_e and o_e are also added.
In the RTL description generated as a result of behavioral synthesis by the scheduling means and the binding means, the value of the input signal a corresponding to the fifth line in the behavioral description is acquired from the input terminal iport1 in the state STATE1. Therefore, the logic circuit (assign a_e=(state==T_STATE1)? 1′b1:1′b0;) is created so that the input application timing signal a_e also has the active value (1(High)) only in the state STATE1.
Similarly, the value of the output signal o is written into the output terminal oport1 in the state STATE3. Therefore, the logic circuit (assign o_e=(state==T_STATE3)?1′b1:1′b0;) is created so that the output observation timing signal 0_e has the active value (1(High)) only in the state STATE3.
Next, the RTL generation means 105 converts the FSM, control logic circuits, input application/output observation timing signals and respective logical circuits for input application/output observation timing signals, and hardware resources to the HDL description and stores the generated HDL description in the storage device 110 (step A5 in FIG. 3 ). FIGS. 9A and 9B show an example of the HDL (Verilog-HDL) description generated by the RTL generation means 105.
Next, the test bench generation means 106 generates a test bench. The test bench observes the input application timing signal and at the timing when the signal has an active value applies an input value to the corresponding input terminal. The test bench also observes the output timing signal and at the timing when the signal has an active value reads a value from the corresponding output terminal and compares the value with an expected value.
The input value of the input signal a is applied to the input terminal iport1 assuming that the value of the input signal a is acquired from the input terminal iport1 when the input application timing signal a_e has the active value (1(High)). The input value of the input signal b is applied to the input terminal iport1 assuming that the value of the input signal b is acquired from the input terminal iport1 when the input application timing signal b_e has the active value (1(High)). The input value of the input signal c is applied to the input terminal iport2 assuming that the value of the input signal c is acquired from the input terminal iport2 when the input application timing signal c_e has the active value (1(High)). The input value of the input signal d is applied to the input terminal iport2 assuming that the value of the input signal d is acquired from the input terminal iport2 when the input application timing signal d_e has the active value (1(High)).
Similarly, the value of the output terminal oport1 is observed and compared with the expected value of the output signal o assuming that the value of the output signal o is written to the output terminal oport1 when the output observation timing signal o_e has the active value (1(High)). The module ‘main’ dut (input/output terminal list) in FIG. 10 is a test target module.
Next, a second specific example of the present invention will be described. This example corresponds to the second example described with reference to FIG. 11 and FIG. 12 . FIG. 13 shows an example of a behavioral description. The behavioral description in FIG. 13 differs from the behavioral description in FIG. 4 in that the output signals a_e, b_e, c_e, d_e, and o_e are provided and that the write operations for the output signals a_e and b_e, output signal c_e, output signal d_e, and output signal o_e are specified respectively on line 16, line 17, line 20, and line 23.
In the behavioral description in FIG. 13 , the output signals a_e, b_e, c_e, d_e, and o_e are output signals indicating the input timing and the output timing of a, b, c, d, and o. For each signal of a_e, b_e, c_e, d_e, and o_e, write operation is also coded in the behavioral description. The write operation writes an active value (1) when an input/output access is made to an associated signal.
In the declaration part of the behavioral description, as a comment (pragma) for the signal b, it is specified that the signal b_e corresponds to the input signal b and that b_e is an input application timing signal of b. The phrase “pragma enable_signal_is b_e” immediately following the comment symbol “//” on the second line is an instruction (pragma) to the simulator specifying that the input application timing signal of b is b_e.
Conversely, as a comment (pragma), it is specified that the signal c_e corresponds to the input signal c and c_e is an input application timing signal of c. The phrase “pragma enable_signal_for c” immediately following the comment symbol “//” on the seventh line is an instruction (pragma) to the simulator specifying that c_e is an input application timing signal of c.
A behavioral synthesis apparatus in the second example of the present invention reads the behavioral description in FIG. 13 from a behavioral description storage unit 111 of the storage device 110 in FIG. 11 and, through the execution of scheduling means 101, binding means 102, FSM generation means 103, and RTL generation means 105, generates the module ‘main’ shown in FIGS. 9A and 9B . The operation of the module ‘main’ is as described above.
After that, test bench generation means 107 in FIG. 11 generates a test bench. The test bench observes the input application timing signals and at the timing when the signal has an active value applies an input value to the corresponding input terminal. The test bench also observes the output timing signals and at the timing when the signal has an active value reads a value from the corresponding output terminal and compares the value with an expected value. At this time, the signals originally included in the behavioral description are used for the input application/output observation timing signals.
The signal a_e is used for the input application timing signal of the signal a. This is determined based on the similarity in the signal names.
The signal b_e is used for the input application timing signal of the signal b. This is determined based on the comment (pragma) (see FIG. 13 ) of the signal b.
The signal c_e is used for the input application timing signal of the signal c. This is determined based on the comment (pragma) (see FIG. 13 ) of the signal c.
The signal d_e is used for the input application timing signal of the signal d. This is determined based on the description in which the reference to the signal d and the output to the signal d_e are described continuously in the behavioral description (see lines 19 and 20 in FIG. 13 ).
The operation of the test bench in FIG. 10 is as described above.
Next, a third specific example of the present invention will be described. The third example of the present invention corresponds to the third example described with reference to FIG. 14 . FIG. 15 shows an example of a behavioral description. In FIG. 15 , the input to the function func( ) is variables a, b, c, and d of type int, and the output is variables o1 and o2 of type int. The output of the function func( ) is the sum of the inputs a and b, and the output o2 is the total sum of the inputs a, b, c, and d.
The behavioral description is stored in advance in a behavioral description storage unit 111 of a storage device 110 shown in FIG. 14 .
A behavioral synthesis apparatus in the third example of the present invention reads the behavioral description in FIG. 15 from the behavioral description storage unit 111 of the storage device 110 in FIG. 14. RTL generation means 105 creates an RTL description shown in FIGS. 18A and 18B , test bench generation means 109 creates a test bench shown in FIG. 19 , and they store the created RTL description and the test bench, respectively, in an RTL storage unit 112 and a test bench storage unit 113 of the storage device 110.
First, scheduling means 101 in the computer 100 assigns the behavioral description to the stages. That is, the scheduling means 101 assigns the arithmetic operations, condition operations, read operations from inputs, write operations to outputs, array read operations, and array write operations, which are included in the behavioral description, to associated states (stages).
In the behavioral description in FIG. 15 , there are described the following:
read operations from inputs a and b and addition+on eleventh line,
read operations from inputs b and c and addition+on twelfth line,
write operation to output o1 on thirteenth line,
addition+on fourteenth line, and
write operation to output o2 on fifteenth line.
After that, through binding means 102 and FSM generation means 103 of the computer 100, the module ‘main’ shown in FIGS. 17A and 17B is generated.
After that, the input application/output observation timing recording means 108 references the control data flow graph and records two items of information for each input signal. The first information includes the number of clock cycles from the time when the reset is released to the time when the first input value is applied. The second information includes the interval period of input application. In addition the input application/output observation timing recording means 108 records two items of information for each output signal. The first information includes the number of clock cycles from the time when the reset is released to the time when the first effective value is written into the signal. The second information includes the interval period of output observation. FIGS. 18A and 18B show the module ‘main’ in which this information is recorded in the module ‘main’ shown in FIGS. 17A and 17B .
An input is applied to each of the input signals a and b of the module ‘main’ in each cycle beginning with the next clock after the reset is released and, so, the information is recorded in the module. That is, “1, 1” on the comment lines of the input signals a and b in the declaration part, such as the one shown in FIG. 18A , indicates that the signals become effective one clock after the reset is released and that the interval period is one clock cycle.
An input is applied to each of the input signals c and d in each cycle beginning with the second clock after the reset is released and, so, the information is recorded in the module. That is, “2, 1” on the comment lines of the input signals c and d in the declaration part, such as the one shown in FIG. 18A , indicates that the signals become effective two clocks after the reset is released and that the interval period is one clock cycle.
The output value of the output signal o1 becomes effective in each cycle beginning with the third clock after the reset is released and, so, the information is recorded in the module. That is, “3, 1” on the comment line of the output signal of in the declaration part, such as the one shown in FIG. 18A , indicates that the signal becomes effective three clocks after the reset is released and that the interval period is one clock cycle.
The output value of the output signal o2 becomes effective in each cycle beginning with the fourth clock after the reset is released and, so, the information is recorded in the module. That is, “4, 1” on the comment line of the output signal o2 in the declaration part, such as the one shown in FIG. 18A , indicates that the signal becomes effective four clocks after the reset is released and that the interval period is one clock cycle.
After that, the RTL generation means 105 and the test bench generation means 109 shown in FIG. 14 create an RTL description and a test bench and store them in the storage device 110.
The general operation of the generated test bench is as follows. Beginning with the first clock cycle after the reset is released and in each clock period, input values are applied to the input terminals a and b respectively.
Beginning with the second clock cycle after the reset is released and in each clock period, input values are applied to the input terminals c and d respectively.
Beginning with the third clock cycle after the reset is released and in each clock period, the value of the output terminal o1 is observed and compared with the expected value.
Beginning with the fourth clock cycle after the reset is released and in each clock period, the value of the output terminal o2 is observed and compared with the expected value.
Next, a fourth specific example of the present invention will be described. The fourth example of the present invention corresponds to the fourth example described above. FIG. 20 shows an example of a test bench created by test bench generation means 106 in the fourth example of the present invention.
The input value of the input signal a is applied to the input terminal iport1 assuming that the value of the input signal a is acquired from the input terminal iport1 when the value of the input application timing signal a_e is an active value (1(High)) and when the reset is not effective. The input value of the input signal b is applied to the input terminal iport1 assuming that the value of the input signal b is acquired from the input terminal iport1 when the value of the input application timing signal b_e is an active value (1(High)) and when the reset is not effective. The input value of the input signal c is applied to the input terminal iport2 assuming that the value of the input signal c is acquired from the input terminal iport2 when the value of the input application timing signal c_e is an active value (1(High)) and when the reset is not effective. The input value of the input signal d is applied to the input terminal iport2 assuming that the value of the input signal d is acquired from the input terminal iport2 when the value of the input application timing signal d_e is an active value (1(High)) and when the reset is not effective.
The value of the output terminal oport1 is observed and is compared with the expected value of the output signal o assuming that the value of the output signal o is written to the output terminal oport1 when the value of the output observation timing signal o_e is an active value (1(High)) and when the reset is not effective.
The values of the input signals a and b are applied respectively to the input terminals a and b beginning with the first clock cycle after the reset is released, in each clock period, and when the stall signal is not effective. The values of the input signals c and d are applied to the input terminals c and d beginning with the second clock cycle after the reset is released, in each clock period, and when the stall signal is not effective.
The values of the output terminals o1 and o2 are observed and compared respectively the expected values beginning with the third clock cycle or fourth clock cycle after the reset is released, in each clock period, and when the stall signal is not effective.
Next, a fifth specific example of the present invention will be described. The fifth example of the present invention corresponds to the fifth example described above. FIG. 22 shows an example of the behavioral description. The general operation of this behavioral description is as follows.
First, the values are read from the input signals a and b, and the value of the input signal b is written at the address in the array ary [ ] indicated by the value of the input signal a.
Next, the value is read from the input signal c, and the value at the address in the array ary[ ], indicated by the value of the input signal c, is read and is output to the output signal o1.
The general operation of the module ‘main’ is as follows. The following operation is performed when the clock signal clk rises. If the input to the reset terminal rst is 1, the value of the state register ‘state’ is set to T_STATE1 and the registers v0, v1, and o_t are initialized to 0.
The module ‘main’ operates as follows if the input to the reset terminal rst is not 1 when the clock signal clk rises. When the value of the state register ‘state’ is T_STATE1, the module reads the input signals a and b, stores the values of those signals respectively in the registers ad_t and wd_t, stores 1 in we_t, and updates the value of the state register ‘state’ to T_STATE2.
When the value of the state register ‘state’ is T_STATE2, the module reads the input signal c, stores its value in ad_t, stores 0 in we_t, and updates the value of the state register ‘state’ to T_STATE3.
When the value of the state register ‘state’ is T_STATE3, the module updates the value of the state register ‘state’ to T_STATE4. When the value of the state register ‘state’ is T_STATE4, the module stores the read data rd in the register o_t and updates the value of the state register ‘state’ to T_STATE1. The value of the state register ‘state’ is updated in order of T_STATE1, T_STATE2, and so on.
The present invention can be used to make sure that a behavioral description is equivalent to an RTL description generated by behavioral synthesis. The present invention can also be used to make sure that the RTL description generated by behavioral synthesis gives full performance.
While the present invention has been described with reference to the examples above, it is to be understood that the present invention is not limited to the configuration of the examples above and that modifications and changes that may be made by those skilled in the art within the scope of the present invention are included.
It should be noted that other objects, features and aspects of the present invention will become apparent in the entire disclosure and that modifications may be done without departing the gist and scope of the present invention as disclosed herein and claimed as appended herewith.
Also it should be noted that any combination of the disclosed and/or claimed elements, matters and/or items may fall under the modifications aforementioned.
Claims (5)
1. A behavioral synthesis apparatus comprising:
storage means that stores a behavioral description of a circuit; and
test bench generation means that generates a test bench that counts a number of clocks after a reset of said circuit is released and, when the number of clocks matches a predetermined value, applies an input to, and observes an output from, said circuit, respectively.
2. The behavioral synthesis apparatus according to claim 1 , further comprising:
input application/output observation timing recording means that references a control data flow graph and records timing information for each of input signals, said timing information being composed of a number of clocks from a time a reset is released to a time a first input value is applied and an interval period from a time an input is once applied to a time a next input is applied, and
records timing information for each of output signals, said timing information including of a number of clocks from a time a reset is released to a time a first output value becomes effective and an interval period from a time the output value once becomes effective to a time a next output value becomes effective; wherein
said test bench generation means reads the input and output timing information recorded by said input application/output observation timing recording means and creates the test bench and stores the created test bench in a storage device, wherein said test bench counts a number of clocks from a time a reset signal that is input to said circuit is released and applies an input when the number of clocks matches either a number of signal clocks at which an input is to be applied or the interval period at which an input is to be applied, and
observes an output and compares the output with an expected value when a number of clocks from a time the reset signal is released matches either a number of clocks until the output becomes effective or the interval period at which the output becomes effective.
3. The behavioral synthesis apparatus according to claim 1 , wherein, for an input signal and an output signal, timing information, which indicates a number of clocks from a time a reset is released to a time a first input value or a first output value becomes effective and an input application period or an output observation period, are added in respective comment fields of the input signal and the output signal in a declaration part of the behavioral description; and
said test bench generation means generates the test bench that counts a number of clocks from a time a reset is released and, when the number of clocks matches the timing information on the input signal and the output signal, applies an input to said circuit or observes an output from said circuit.
4. A behavioral synthesis method comprising:
reading a behavioral description of a circuit from a storage; and
creating, using a computer, a test bench that counts a number of clocks after a reset of said circuit is released, and, when the number of clocks matches a predetermined value, applies an input to, and observes an output from, said circuit, respectively.
5. A computer readable storage device having a program causing a computer to perform:
reading a behavioral description of a circuit from a storage; and
test bench generation processing for creating a test bench that counts a number of clocks after a reset of the circuit is released, when the number of clocks matches a predetermined value, applies an input to, and observes an output from, said circuit, respectively.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US13/336,328 US8386973B2 (en) | 2007-01-30 | 2011-12-23 | Behavioral synthesis apparatus, method, and program having test bench generation function |
Applications Claiming Priority (4)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007019451A JP4853312B2 (en) | 2007-01-30 | 2007-01-30 | Behavioral synthesis apparatus, method, and program having test bench generation function |
JP2007-019451 | 2007-01-30 | ||
US12/022,573 US8091051B2 (en) | 2007-01-30 | 2008-01-30 | Behavioral synthesis apparatus, method, and program having test bench generation function |
US13/336,328 US8386973B2 (en) | 2007-01-30 | 2011-12-23 | Behavioral synthesis apparatus, method, and program having test bench generation function |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US12/022,573 Division US8091051B2 (en) | 2007-01-30 | 2008-01-30 | Behavioral synthesis apparatus, method, and program having test bench generation function |
Publications (2)
Publication Number | Publication Date |
---|---|
US20120096418A1 US20120096418A1 (en) | 2012-04-19 |
US8386973B2 true US8386973B2 (en) | 2013-02-26 |
Family
ID=39669394
Family Applications (2)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US12/022,573 Active 2030-06-26 US8091051B2 (en) | 2007-01-30 | 2008-01-30 | Behavioral synthesis apparatus, method, and program having test bench generation function |
US13/336,328 Active US8386973B2 (en) | 2007-01-30 | 2011-12-23 | Behavioral synthesis apparatus, method, and program having test bench generation function |
Family Applications Before (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US12/022,573 Active 2030-06-26 US8091051B2 (en) | 2007-01-30 | 2008-01-30 | Behavioral synthesis apparatus, method, and program having test bench generation function |
Country Status (2)
Country | Link |
---|---|
US (2) | US8091051B2 (en) |
JP (1) | JP4853312B2 (en) |
Families Citing this family (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7825684B2 (en) | 2005-03-15 | 2010-11-02 | Tabula, Inc. | Variable width management for a memory of a configurable IC |
US7930666B1 (en) * | 2006-12-12 | 2011-04-19 | Tabula, Inc. | System and method of providing a memory hierarchy |
US9477802B1 (en) | 2009-06-09 | 2016-10-25 | Cadence Design Systems, Inc. | Isolating differences between revisions of a circuit design |
US8572527B1 (en) * | 2011-09-13 | 2013-10-29 | Jasper Design Automation, Inc. | Generating properties for circuit designs |
US8516421B1 (en) | 2012-01-10 | 2013-08-20 | Jasper Design Automation, Inc. | Generating circuit design properties from signal traces |
US8739092B1 (en) | 2012-04-25 | 2014-05-27 | Jasper Design Automation, Inc. | Functional property ranking |
US10311188B2 (en) * | 2015-04-08 | 2019-06-04 | Mitsubishi Electric Corporation | Circuit design support apparatus, circuit design support method, and computer readable medium |
US11550980B1 (en) * | 2021-06-14 | 2023-01-10 | Cadence Design Systems, Inc. | System and method for generating power-aware electronics |
US11790143B2 (en) * | 2021-06-15 | 2023-10-17 | International Business Machines Corporation | Collateral correlated regression in version control repository |
Citations (27)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5177440A (en) * | 1989-12-27 | 1993-01-05 | Lsi Logic Corporation | Testing of integrated circuits using clock bursts |
US5710711A (en) * | 1992-10-21 | 1998-01-20 | Lucent Technologies Inc. | Method and integrated circuit adapted for partial scan testability |
US5920490A (en) | 1996-12-26 | 1999-07-06 | Adaptec, Inc. | Integrated circuit test stimulus verification and vector extraction system |
JP2000242684A (en) | 1999-02-23 | 2000-09-08 | Nec Corp | Function synthesis method, function synthesis device and recording medium therefor |
JP2000310667A (en) * | 1999-04-27 | 2000-11-07 | Mitsubishi Electric Corp | Semiconductor integrated circuit device |
JP2001060210A (en) | 1999-08-20 | 2001-03-06 | Nec Corp | Lsi verification method and device and recording medium |
US6212489B1 (en) * | 1996-05-14 | 2001-04-03 | Mentor Graphics Corporation | Optimizing hardware and software co-verification system |
US6216252B1 (en) | 1990-04-06 | 2001-04-10 | Lsi Logic Corporation | Method and system for creating, validating, and scaling structural description of electronic device |
JP2004145712A (en) | 2002-10-25 | 2004-05-20 | Matsushita Electric Ind Co Ltd | Equivalence verification method of motion description in semiconductor design |
JP2004145670A (en) | 2002-10-24 | 2004-05-20 | Osaka Industrial Promotion Organization | Method and device for generating test bench, and computer program |
US6810373B1 (en) * | 1999-08-13 | 2004-10-26 | Synopsis, Inc. | Method and apparatus for modeling using a hardware-software co-verification environment |
US6845341B2 (en) | 2002-05-14 | 2005-01-18 | Cadence Design Systems, Inc. | Method and mechanism for improved performance analysis in transaction level models |
JP2005078402A (en) | 2003-09-01 | 2005-03-24 | Nec Engineering Ltd | Action composite method for electronic circuit |
US6985840B1 (en) | 2000-07-31 | 2006-01-10 | Novas Software, Inc. | Circuit property verification system |
US20060015313A1 (en) | 2003-06-16 | 2006-01-19 | Wang Ming Y | Method of programming a co-verification system |
US7137087B1 (en) | 2003-08-20 | 2006-11-14 | Adaptec, Inc. | Integrated circuit verification scheme |
JP2007019451A (en) | 2005-06-10 | 2007-01-25 | National Institute Of Advanced Industrial & Technology | Nano imprint method and equipment therefor |
US20070106488A1 (en) | 2005-11-04 | 2007-05-10 | Ying-Tsai Chang | Incremental circuit re-simulation system |
US20070156378A1 (en) | 2005-12-30 | 2007-07-05 | Cadence Design Systems, Inc. | System and method for verification aware synthesis |
US20070250799A1 (en) | 2006-04-21 | 2007-10-25 | Lucent Technologies Inc. | Test case generation algorithm for a model checker |
US20070277130A1 (en) * | 2003-12-03 | 2007-11-29 | Evan Lavelle | System and method for architecture verification |
US20070294651A1 (en) | 2006-06-16 | 2007-12-20 | Kuen-Yang Tsai | Active trace assertion based verification system |
US20080077379A1 (en) | 2004-12-02 | 2008-03-27 | Baumgartner Jason R | Computer Program Product for Verification of Digital Designs Using Case-Splitting via Constrained Internal Signals |
US20080092092A1 (en) | 2004-10-04 | 2008-04-17 | Damian Jude Dalton | Method and Processor for Power Analysis in Digital Circuits |
US7444277B2 (en) | 2002-04-18 | 2008-10-28 | International Business Machines Corporation | Facilitating simulation of a model within a distributed environment |
US7653849B1 (en) * | 2005-09-12 | 2010-01-26 | Virage Logic Corporation | Input-output device testing including embedded tests |
US7904857B2 (en) | 2001-03-30 | 2011-03-08 | Syntest Technologies, Inc. | Computer-aided design system to automate scan synthesis at register-transfer level |
-
2007
- 2007-01-30 JP JP2007019451A patent/JP4853312B2/en not_active Expired - Fee Related
-
2008
- 2008-01-30 US US12/022,573 patent/US8091051B2/en active Active
-
2011
- 2011-12-23 US US13/336,328 patent/US8386973B2/en active Active
Patent Citations (28)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5177440A (en) * | 1989-12-27 | 1993-01-05 | Lsi Logic Corporation | Testing of integrated circuits using clock bursts |
US6216252B1 (en) | 1990-04-06 | 2001-04-10 | Lsi Logic Corporation | Method and system for creating, validating, and scaling structural description of electronic device |
US5710711A (en) * | 1992-10-21 | 1998-01-20 | Lucent Technologies Inc. | Method and integrated circuit adapted for partial scan testability |
US6212489B1 (en) * | 1996-05-14 | 2001-04-03 | Mentor Graphics Corporation | Optimizing hardware and software co-verification system |
US5920490A (en) | 1996-12-26 | 1999-07-06 | Adaptec, Inc. | Integrated circuit test stimulus verification and vector extraction system |
JP2000242684A (en) | 1999-02-23 | 2000-09-08 | Nec Corp | Function synthesis method, function synthesis device and recording medium therefor |
JP2000310667A (en) * | 1999-04-27 | 2000-11-07 | Mitsubishi Electric Corp | Semiconductor integrated circuit device |
US6810373B1 (en) * | 1999-08-13 | 2004-10-26 | Synopsis, Inc. | Method and apparatus for modeling using a hardware-software co-verification environment |
JP2001060210A (en) | 1999-08-20 | 2001-03-06 | Nec Corp | Lsi verification method and device and recording medium |
US6985840B1 (en) | 2000-07-31 | 2006-01-10 | Novas Software, Inc. | Circuit property verification system |
US20110197171A1 (en) | 2001-03-30 | 2011-08-11 | Syntest Technologies, Inc. | Computer-aided design system to automate scan synthesis at register-transfer level |
US7904857B2 (en) | 2001-03-30 | 2011-03-08 | Syntest Technologies, Inc. | Computer-aided design system to automate scan synthesis at register-transfer level |
US7444277B2 (en) | 2002-04-18 | 2008-10-28 | International Business Machines Corporation | Facilitating simulation of a model within a distributed environment |
US6845341B2 (en) | 2002-05-14 | 2005-01-18 | Cadence Design Systems, Inc. | Method and mechanism for improved performance analysis in transaction level models |
JP2004145670A (en) | 2002-10-24 | 2004-05-20 | Osaka Industrial Promotion Organization | Method and device for generating test bench, and computer program |
JP2004145712A (en) | 2002-10-25 | 2004-05-20 | Matsushita Electric Ind Co Ltd | Equivalence verification method of motion description in semiconductor design |
US20060015313A1 (en) | 2003-06-16 | 2006-01-19 | Wang Ming Y | Method of programming a co-verification system |
US7137087B1 (en) | 2003-08-20 | 2006-11-14 | Adaptec, Inc. | Integrated circuit verification scheme |
JP2005078402A (en) | 2003-09-01 | 2005-03-24 | Nec Engineering Ltd | Action composite method for electronic circuit |
US20070277130A1 (en) * | 2003-12-03 | 2007-11-29 | Evan Lavelle | System and method for architecture verification |
US20080092092A1 (en) | 2004-10-04 | 2008-04-17 | Damian Jude Dalton | Method and Processor for Power Analysis in Digital Circuits |
US20080077379A1 (en) | 2004-12-02 | 2008-03-27 | Baumgartner Jason R | Computer Program Product for Verification of Digital Designs Using Case-Splitting via Constrained Internal Signals |
JP2007019451A (en) | 2005-06-10 | 2007-01-25 | National Institute Of Advanced Industrial & Technology | Nano imprint method and equipment therefor |
US7653849B1 (en) * | 2005-09-12 | 2010-01-26 | Virage Logic Corporation | Input-output device testing including embedded tests |
US20070106488A1 (en) | 2005-11-04 | 2007-05-10 | Ying-Tsai Chang | Incremental circuit re-simulation system |
US20070156378A1 (en) | 2005-12-30 | 2007-07-05 | Cadence Design Systems, Inc. | System and method for verification aware synthesis |
US20070250799A1 (en) | 2006-04-21 | 2007-10-25 | Lucent Technologies Inc. | Test case generation algorithm for a model checker |
US20070294651A1 (en) | 2006-06-16 | 2007-12-20 | Kuen-Yang Tsai | Active trace assertion based verification system |
Non-Patent Citations (8)
Title |
---|
Andrews et al., "RIBASTEM: A Method for Testing VHDL Behavioral Models", Eighth IEEE International Symposium on High Assurance Systems Engineering, Mar. 25-26, 2004, pp. 187-196. * |
Japanese Official Action dated Jan. 8, 2013 from related application JP 2011-192362 together with a partial English language abstract. |
Japanese Official Action dated Jul. 5, 2011 in connection with corresponding Japanese Application No. JP 2007-019451. |
Lee et al., "Behavioral Synthesis for Easy Testability in Data Path Allocation", IEEE 1992 International Conference on Computer Design: VLSI in Computers and Processors, Oct. 11-14, 1992, pp. 29-32. |
NN8912354, "Design for Input and Output Verification", IBM Technical Disclosure Bulletin, Dec. 1989, vol. 32, No. 7, pp. 354-357 (5 pages). * |
Riazati et al., "Improved Assertion Lifetime via Assertion-Based Testing Methodology", 2006 International Conference on Microelectronics, Dec. 16-19, 2006, pp. 48-51. * |
U.S. Office Action dated May 11, 2011 from U.S. Appl. No. 12/022,573. |
U.S. Office Action dated Nov. 9, 2010 from U.S. Appl. No. 12/022,573. |
Also Published As
Publication number | Publication date |
---|---|
JP2008186252A (en) | 2008-08-14 |
US20120096418A1 (en) | 2012-04-19 |
US20080184180A1 (en) | 2008-07-31 |
US8091051B2 (en) | 2012-01-03 |
JP4853312B2 (en) | 2012-01-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8386973B2 (en) | Behavioral synthesis apparatus, method, and program having test bench generation function | |
US7331024B2 (en) | Power-consumption calculation method and apparatus | |
US6496972B1 (en) | Method and system for circuit design top level and block optimization | |
US7472361B2 (en) | System and method for generating a plurality of models at different levels of abstraction from a single master model | |
US6678644B1 (en) | Integrated circuit models having associated timing exception information therewith for use with electronic design automation | |
US9652570B1 (en) | Automatic implementation of a customized system-on-chip | |
US20070294647A1 (en) | Transferring software assertions to hardware design language code | |
US7231627B2 (en) | Merging a hardware design language source file with a separate assertion file | |
Kranitis et al. | Hybrid-SBST methodology for efficient testing of processor cores | |
US6438731B1 (en) | Integrated circuit models having associated timing exception information therewith for use in circuit design optimizations | |
JP4654203B2 (en) | Method for creating HDL description file for digital system and resulting system | |
JP3899104B2 (en) | System development method and data processing system | |
US9081930B1 (en) | Throughput during high level synthesis | |
US9223910B1 (en) | Performance and memory efficient modeling of HDL ports for simulation | |
US8230263B2 (en) | Automated specification based functional test generation infrastructure | |
US9003339B2 (en) | Synthesis of clock gated circuit | |
US10162917B1 (en) | Method and system for implementing selective transformation for low power verification | |
US8418095B1 (en) | Compilation and simulation of a circuit design | |
US6813599B1 (en) | Efficient memory structure simulation for sequential circuit design verification | |
WO2022198447A1 (en) | Synthesis method and synthesis device for digital circuit | |
US7447621B1 (en) | PLI-less co-simulation of ISS-based verification systems in hardware simulators | |
Ferro et al. | Runtime verification of typical requirements for a space critical SoC platform | |
US8813005B1 (en) | Debugging using tagged flip-flops | |
US10635769B1 (en) | Hardware and software event tracing for a system-on-chip | |
JP3838756B2 (en) | Circuit design support device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
STCF | Information on status: patent grant |
Free format text: PATENTED CASE |
|
FPAY | Fee payment |
Year of fee payment: 4 |
|
MAFP | Maintenance fee payment |
Free format text: PAYMENT OF MAINTENANCE FEE, 8TH YEAR, LARGE ENTITY (ORIGINAL EVENT CODE: M1552); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY Year of fee payment: 8 |
|
FEPP | Fee payment procedure |
Free format text: MAINTENANCE FEE REMINDER MAILED (ORIGINAL EVENT CODE: REM.); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY |