CN100465884C - Method for function converting higher language into hardware component picture - Google Patents

Method for function converting higher language into hardware component picture Download PDF

Info

Publication number
CN100465884C
CN100465884C CNB2006100016077A CN200610001607A CN100465884C CN 100465884 C CN100465884 C CN 100465884C CN B2006100016077 A CNB2006100016077 A CN B2006100016077A CN 200610001607 A CN200610001607 A CN 200610001607A CN 100465884 C CN100465884 C CN 100465884C
Authority
CN
China
Prior art keywords
hardware component
nextport
letter formula
nextport hardware
component nextport
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.)
Expired - Fee Related
Application number
CNB2006100016077A
Other languages
Chinese (zh)
Other versions
CN101000540A (en
Inventor
郑福炯
张书铭
陈建一
颜宽裕
游心慧
周锦泰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Datong University
Tatung Co Ltd
Original Assignee
Tatung Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tatung Co Ltd filed Critical Tatung Co Ltd
Priority to CNB2006100016077A priority Critical patent/CN100465884C/en
Publication of CN101000540A publication Critical patent/CN101000540A/en
Application granted granted Critical
Publication of CN100465884C publication Critical patent/CN100465884C/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

A method for converting high-level language function to be hardware component map includes analyzing classification information object and temporary hardware component map, generating a function calling table by I/O connection line of a function calling node and function information in classification information object, changing connection of connection line connected to function calling node to function start-up node by utilizing function calling table to present function calling in high-level language program code for converting temporary hardware map to be hardware component map corresponding to hardware component.

Description

The letter formula of higher level lanquage is converted to the method for nextport hardware component NextPort figure
Technical field
The invention relates to a kind of conversion of letter formula of higher level lanquage, refer to that especially a kind of letter formula of higher level lanquage is converted to nextport hardware component NextPort figure (Hardware Component Graphic, method HCG).
Background technology
Traditional hardware description language (for example: VHDL, Verilog) also can't directly be used for describing the programmed logic of program language in higher and carry out flow process, therefore, must convert program language in higher to UML (Unified Modeling Language earlier, UML) defined activity diagram (ActivityDiagram in, AD), because AD is a kind of description figure of flow process, can be in order to the programmed logic and the execution flow process of expression program language in higher, but AD follows between the actual nextport hardware component NextPort without any connection, therefore, also can't directly convert AD to hardware description language.So need earlier activity diagram (AD) to be converted to nextport hardware component NextPort figure (Hardware Component Graph, HCG).
Yet in converting nextport hardware component NextPort figure (HCG) process to, (Method calls) still can't effectively expressing corresponding to the function call in the higher level lanquage.That is the letter formula of known higher level lanquage is converted to the method for nextport hardware component NextPort figure (HCG), and can't correctly the letter formula of higher level lanquage be converted to the assembly of nextport hardware component NextPort figure (HCG).So also can't further convert traditional hardware description language to by nextport hardware component NextPort figure (HCG).Therefore, the method that the letter formula of known higher level lanquage is converted to nextport hardware component NextPort figure (HCG) still has many disappearances, and gives improved necessity.
Summary of the invention
The object of the present invention is to provide a kind of letter formula of higher level lanquage to be converted to the method for nextport hardware component NextPort figure.
For achieving the above object, the method for the letter formula conversion hardware component drawings of higher level lanquage provided by the invention, this higher level lanquage comprises at least one classification, the method comprising the steps of:
(A) read a high-level language programs code;
(B) analyze this high-level language programs code, to collect the classification information of this high-level language programs code, classification information is stored in the classification information object, and produces a temporary transient nextport hardware component NextPort figure, wherein, this classification information object includes letter formula object, parameter object and passback value object;
(C) analyze this classification information object and from temporary transient nextport hardware component NextPort figure, obtaining corresponding to all open and privately owned letter formula, parameter and passback values among the temporary transient nextport hardware component NextPort figure;
(D) the disclosure letter formula, parameter and the passback value that step C is obtained is connected to the classification start node of this temporary transient nextport hardware component NextPort figure, and privately owned letter formula, parameter and passback value are not then received the classification start node;
(E) analyze this classification information object and temporary transient nextport hardware component NextPort figure, and by at least one output/input connecting line of a function call node among this temporary transient nextport hardware component NextPort figure, and the letter formula information object in this classification information object and produce a function call table; And
(F) utilize this function call table the connecting line that is connected to this function call node among this temporary transient nextport hardware component NextPort figure, be connected to this letter formula start node instead, represent function call in this high-level language programs code, and should temporary transient nextport hardware component NextPort figure convert to can with nextport hardware component NextPort corresponding hardware component drawings.
The method of the letter formula conversion hardware component drawings of described higher level lanquage, wherein, in step D, when disclosed letter formula, parameter and passback value are connected to this classification start node, are to use multiplexer and separate the connecting line of multiplexer control linkage to this classification start node.
The method of the letter formula conversion hardware component drawings of described higher level lanquage wherein, is to use multiplexer and separates the connecting line of multiplexer control linkage to this function call node in step F.
The method of the letter formula conversion hardware component drawings of described higher level lanquage, wherein this nextport hardware component NextPort figure is the annexation between expression nextport hardware component NextPort and the nextport hardware component NextPort.
The method of the letter formula conversion hardware component drawings of described higher level lanquage, wherein this higher level lanquage is the Java program language.
The method of the letter formula conversion hardware component drawings of described higher level lanquage, wherein this at least one classification and comprise following one of them letter formula: open letter formula, privately owned letter formula, protection letter formula, an and friendship letter formula.
By method provided by the invention the letter formula of this higher level lanquage can be converted to can with nextport hardware component NextPort corresponding hardware component drawings.
Description of drawings
Fig. 1 is the process flow diagram of the letter formula conversion hardware component drawings of higher level lanquage of the present invention.
Fig. 2 is the synoptic diagram of the java applet code of an addition of the present invention.
Fig. 3 is the synoptic diagram of the temporary transient nextport hardware component NextPort figure that produced according to the Java program code of Fig. 2.
Fig. 4 is the synoptic diagram of modification connecting line of the present invention.
Fig. 5 is the synoptic diagram that node is called out in modification of the present invention.
Fig. 6 is the synoptic diagram of the circuit diagram after the VHDL program code of Fig. 2 correspondence synthesizes.
Fig. 7 is the program code synoptic diagram of another Java subtracter of the present invention.
Fig. 8 and Fig. 9 be nextport hardware component NextPort figure makeover process of the present invention synoptic diagram.
Figure 10 is the synoptic diagram of the circuit diagram after the VHDL program code of Fig. 7 correspondence synthesizes.
Embodiment
Letter formula in higher level lanquage of the present invention is converted in the method for nextport hardware component NextPort figure, the letter formula of this higher level lanquage can be converted to can with nextport hardware component NextPort corresponding hardware component drawings.Fig. 1 is converted to the process flow diagram of the method for nextport hardware component NextPort figure for the letter formula of higher level lanquage of the present invention.At first, read a high-level language programs code in step S101, wherein, this higher level lanquage comprises at least one classification.In present embodiment, this higher level lanquage is one to be the Java program language.The letter formula of this higher level lanquage can be divided into: open letter formula (Public Method), privately owned letter formula (Private Method), protection letter formula (Protected Method) and friendship letter formula (Friend Method).This letter formula is declared to be when open, can be by the access of any letter formula institute.And be declared to be when privately owned when the letter formula; can only be by the access of member function institute; as be declared to be protection letter formula then only by same parcel (Package) or inherit letter formula institute access in the subclass (subclass) of its letter formula; as be declared to be friendship letter formula then only by the letter formula institute access in the same parcel (Package), therefore will protect letter formula and friendship letter formula all to range in the privately owned classification.
Fig. 2 is the program code of a Java program language, wherein comprises an open classification Math, and the disclosure classification Math comprises a privately owned letter formula add and an open letter formula test.
In step S103, analyze this high-level language programs code, to collect the classification information of this high-level language programs code, it is stored in the classification information object (classinfo object), and produces a temporary transient nextport hardware component NextPort figure (HCG).This classification information object includes item name (class name) object, letter formula (method) object, parameter (parameter) object and passback value (return value) object.Fig. 3 is the temporary transient nextport hardware component NextPort figure (HCG) that the Java program code according to Fig. 2 is produced.As shown in Figure 3, in this temporary transient nextport hardware component NextPort figure, mark " Math " 310 pairs of circles should the Java program code open classification Math, and should mark Math circle 310 expression classification start nodes (class startnode).
A mark " add " 320 pairs of circles should the Java program code privately owned letter formula add, and should mark add circle 320 expression letter formula start nodes (method start node).A mark " test " 330 pairs of circles should the Java program code open letter formula test, and should mark test circle 330 expression letter formula start nodes (method start node).Because in this Java program code, open letter formula test calls out this privately owned letter formula add, so have a mark at temporary transient nextport hardware component NextPort figure (HCG) " Callthis add " node 340.
In open classification function test, can call out this privately owned letter formula add as shown in Figure 2, and parameter c, d are passed to parameter a, the b of this privately owned letter formula add, so the part that 1 frame of square frame is lived among Fig. 3 is the part that parameter is transmitted, and the part that 2 frames of square frame are lived is the function call (methodcall) of this privately owned function add.
In this temporary transient nextport hardware component NextPort figure (HCG) process of generation, not only produce this temporary transient nextport hardware component NextPort figure (HCG), also collect classification information in this Java program code (class info) simultaneously.This classification packets of information contains item name (class name), letter formula title (method name), parameter (parameter) and passback value information such as (return value).And classification information is stored in this classification information object.
In step S105, analyze this classification information object and this temporary transient nextport hardware component NextPort figure (HCG), to obtain corresponding to temporary transient nextport hardware component NextPort figure and disclosed letter formula (method), parameter (parameter) and passback value (return value).
In step S107, the disclosure letter formula (method), parameter (parameter) and the passback value (return value) that step S105 is obtained is connected to the classification start node (class start node) of this temporary transient nextport hardware component NextPort figure HCG.By this classification information object and this temporary transient nextport hardware component NextPort figure (HCG), which letter formula (method), parameter (parameter) and the passback value (return value) corresponding to this temporary transient nextport hardware component NextPort figure (HCG) is disclosed as can be known.The disclosure letter formula (method), parameter (parameter) and passback value (returnvalue) are connected to the classification start node (class start node) of this mark Math circle 310.Represent that these the disclosure letter formulas (method), parameter (parameter) and passback value (return value) have corresponding hardware interfaces at last and can supply outside signal output/input.Handling when online,, then must add multiplexer (Multiplexer) and separate multiplexer (De-multiplexer) and come the connecting line of control linkage to this classification start node (class start node) if having how fashionablely to reading or writing.
As shown in Figure 3, because mark " test " circle 330 be to open letter formula test that should the Java program code, so the letter formula start node (method start node) of open letter formula test and parameter c and d and passback node (return node) all will be connected to the classification start node (class start node) of this mark Math circle 310, shown in the thick line of Fig. 4.Because mark " add " circle 320 be to privately owned letter formula add that should the Java program code, so the letter formula start node (method startnode) of privately owned letter formula add and parameter c and d and return the classification start node (class start node) that node (returnnode) all need not be connected to this mark Math circle 310.
In step S109, to analyze this classification information object, reach this temporary transient nextport hardware component NextPort figure HCG, and by at least one output/input connecting line (in/out edges) of a function call node (method call node) among this temporary transient nextport hardware component NextPort figure HCG, and letter formula information (methodinfo.) object in this classification information object and produce a function call table (method call table).By the information in Fig. 4 and this classification information object, can collect the information of function call (method call), for example: which letter formula where is it function call (method call), the letter formula that will call out are, by which function call node (methodcall node) are called out.With relevant information records in a function call table (method call table).
In step S111, utilize this function call table (method call table) the connecting line that is connected to this function call node (method call node) among this temporary transient nextport hardware component NextPort figure HCG, be connected to this letter formula start node (method start node) instead, represent function call in this high-level language programs code (method call), and should temporary transient nextport hardware component NextPort figure HCG convert to can with nextport hardware component NextPort corresponding hardware component drawings.If when when processing is online, having a plurality of function call nodes (method call node) to call out a letter formula, then must add multiplexer (Multiplexer) and separate multiplexer (De-multiplexer).
In Fig. 4, linking this mark " Call this add " the req4p_read connecting line of node 340 link the letter formula start node (method start node) of this mark add circle 320, with the calling of expression to this add letter formula.And the RxN_retaddzizi node of representing this add letter formula passback value linked the RxN_rettestzizi of this test letter formula, expression returns the result of this add letter formula computing to this test letter formula.Promptly represent the part of in step S111, handling function call as the thick line of Fig. 5.Behind the nextport hardware component NextPort figure that obtains Fig. 5, represent that function call (method call) is handled in this Java high-level language programs code, so the nextport hardware component NextPort of the nextport hardware component NextPort figure of Fig. 5 and VHDL program language can be one by one in correspondence with each other.The nextport hardware component NextPort figure of Fig. 5 can be changed into the VHDL program code that function call (method call) can should be arranged relatively.Fig. 6 is the circuit diagram after corresponding VHDL program code synthesizes (synthesis).
Fig. 7, Fig. 8, and Fig. 9 be another embodiment of the present invention.It uses another disclosed sub letter formula of a disclosed test function call.Figure 10 then is the circuit diagram after corresponding VHDL program code synthesizes (synthesis).Fig. 8, Fig. 9, and Figure 10 in mark F circle correspond to a block form assembly (fork-element) in the nextport hardware component NextPort.Mark OR circle correspond in the nextport hardware component NextPort or door (OR gate).Mark Q ellipse is a progressive control circuit, and the controlling signal of two-phase (2-Phase) is changed into four phases (4-Phase) signal access data.Mark sub circle corresponds to the subtracter in the nextport hardware component NextPort.The assembly that RxN_a, RxN_b etc. are started by RxN then corresponds to the n position buffer (n-bitsRegister) in the nextport hardware component NextPort.The oval node of mark reqMuxDemux, writeMuxDemux and readMuxDemux then is respectively multiplexer and anti-multiplexer, and it reads, writes and nextport hardware component NextPort that the requirement (request) of control circuit is set up at buffer.
In sum, the present invention will utilize function call table (method call table) the connecting line that is connected to function call node (method call node) among the temporary transient nextport hardware component NextPort figure HCG, be connected to letter formula start node (method start node) instead, represent function call in the high-level language programs code (method call).And this temporary transient nextport hardware component NextPort figure HCG can be converted to can with nextport hardware component NextPort corresponding hardware component drawings.
The present invention with function call (method call) in the java applet language convert to can with nextport hardware component NextPort corresponding hardware component drawings.This nextport hardware component NextPort figure can with the VHDL assembly one to one, so can convert the VHDL program code easily to.The problem that can avoid the function call (Method calls) in the known higher level lanquage still can't effectively express with nextport hardware component NextPort, and solve the problem that known technology can't correctly convert nextport hardware component NextPort figure (HCG) to traditional hardware description language.
The foregoing description is only given an example for convenience of description, and the interest field that the present invention advocated should be as the criterion so that claim is described certainly, but not only limits to the foregoing description.

Claims (6)

1. one kind is converted to the method for nextport hardware component NextPort figure with the letter formula of higher level lanquage, and this higher level lanquage comprises at least one classification, and the method comprising the steps of:
(A) read a high-level language programs code;
(B) analyze this high-level language programs code, to collect the classification information of this high-level language programs code, classification information is stored in the classification information object, and produces a temporary transient nextport hardware component NextPort figure, wherein, this classification information object includes letter formula object, parameter object and passback value object;
(C) analyze this classification information object and from temporary transient nextport hardware component NextPort figure, obtaining corresponding to all open and privately owned letter formula, parameter and passback values among the temporary transient nextport hardware component NextPort figure;
(D) the disclosure letter formula, parameter and the passback value that only step (C) is obtained is connected to the classification start node of this temporary transient nextport hardware component NextPort figure;
(E) analyze this classification information object and temporary transient nextport hardware component NextPort figure, and by at least one output/input connecting line of a function call node among this temporary transient nextport hardware component NextPort figure, and the letter formula information object in this classification information object and produce a function call table; And
(F) utilize this function call table the connecting line that is connected to this function call node among this temporary transient nextport hardware component NextPort figure, be connected to this letter formula start node instead, represent function call in this high-level language programs code, and should temporary transient nextport hardware component NextPort figure convert to can be corresponding with nextport hardware component NextPort nextport hardware component NextPort figure.
2. the method that the letter formula of higher level lanquage is converted to nextport hardware component NextPort figure as claimed in claim 1, it is characterized in that, in step D, when disclosed letter formula, parameter and passback value are connected to this classification start node, are to use multiplexer and separate the connecting line of multiplexer control linkage to this classification start node.
3. as claimed in claim 1 the letter formula of higher level lanquage is converted to the method for nextport hardware component NextPort figure, it is characterized in that, in step F, be to use multiplexer and separate the connecting line of multiplexer control linkage to this function call node.
4. as claimed in claim 1 the letter formula of higher level lanquage is converted to the method for nextport hardware component NextPort figure, it is characterized in that this nextport hardware component NextPort figure is the annexation between expression nextport hardware component NextPort and the nextport hardware component NextPort.
5. as claimed in claim 1 the letter formula of higher level lanquage is converted to the method for nextport hardware component NextPort figure, it is characterized in that this higher level lanquage is the Java program language.
6. as claimed in claim 5 the letter formula of higher level lanquage is converted to the method for nextport hardware component NextPort figure, it is characterized in that this at least one classification also comprises following one of them letter formula: open letter formula, privately owned letter formula, protection letter formula, an and friendship letter formula.
CNB2006100016077A 2006-01-13 2006-01-13 Method for function converting higher language into hardware component picture Expired - Fee Related CN100465884C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006100016077A CN100465884C (en) 2006-01-13 2006-01-13 Method for function converting higher language into hardware component picture

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006100016077A CN100465884C (en) 2006-01-13 2006-01-13 Method for function converting higher language into hardware component picture

Publications (2)

Publication Number Publication Date
CN101000540A CN101000540A (en) 2007-07-18
CN100465884C true CN100465884C (en) 2009-03-04

Family

ID=38692529

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006100016077A Expired - Fee Related CN100465884C (en) 2006-01-13 2006-01-13 Method for function converting higher language into hardware component picture

Country Status (1)

Country Link
CN (1) CN100465884C (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102609251B (en) * 2012-01-13 2015-12-16 瑞典爱立信有限公司 A kind ofly realize the method judging example

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6226776B1 (en) * 1997-09-16 2001-05-01 Synetry Corporation System for converting hardware designs in high-level programming language to hardware implementations
US6564354B1 (en) * 2000-06-01 2003-05-13 Hewlett Packard Development Company, L.P. Method for translating conditional expressions from a non-verilog hardware description language to verilog hardware description language while preserving structure suitable for logic synthesis
CN1422406A (en) * 2000-02-24 2003-06-04 斯坦利·M·海杜克 Digital circuit implementation by means of parallel sequencers
WO2004017232A2 (en) * 2002-08-16 2004-02-26 Coware, Inc. Method and apparatus for translating to a hardware description language from an architecture description language
CN1656447A (en) * 2002-05-23 2005-08-17 阿尔卡特公司 Software development tool for ensuring links between UML models and the implementation thereof in a CORBA environment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6226776B1 (en) * 1997-09-16 2001-05-01 Synetry Corporation System for converting hardware designs in high-level programming language to hardware implementations
CN1422406A (en) * 2000-02-24 2003-06-04 斯坦利·M·海杜克 Digital circuit implementation by means of parallel sequencers
US6564354B1 (en) * 2000-06-01 2003-05-13 Hewlett Packard Development Company, L.P. Method for translating conditional expressions from a non-verilog hardware description language to verilog hardware description language while preserving structure suitable for logic synthesis
CN1656447A (en) * 2002-05-23 2005-08-17 阿尔卡特公司 Software development tool for ensuring links between UML models and the implementation thereof in a CORBA environment
WO2004017232A2 (en) * 2002-08-16 2004-02-26 Coware, Inc. Method and apparatus for translating to a hardware description language from an architecture description language

Also Published As

Publication number Publication date
CN101000540A (en) 2007-07-18

Similar Documents

Publication Publication Date Title
US7685604B2 (en) Business process execution language (BPEL) application generator for legacy interfaces
Kindler et al. Inter-operability of workflow applications: Local criteria for global soundness
CN103294600B (en) Based on the automatic design for Measurability method of the automatic design for Measurability system of the EDIF net table level circuit of Perl
CN102012954B (en) Subsystem integration method and subsystem integration system for integration design of system-on-chip
CN1924800A (en) Control-based insert management system and method for secondary development platform
Carlson et al. SaveCCM: An analysable component model for real-time systems
CN101739258A (en) Automatic code generation method of architecture analysis and design language (AADL) model
US7426716B2 (en) Recovery and representation of object interaction in an object oriented program
CN100465884C (en) Method for function converting higher language into hardware component picture
Dörr et al. A Behavior Specification and Simulation Methodology for Embedded Real-Time Software
TWI297855B (en)
Jing et al. AC2-ADL: Architectural description of aspect-oriented systems
Wiklander et al. Enabling component-based design for embedded real-time software
Insaurralde et al. System requirements in industrial automation
Dietterle et al. Mapping of high-level SDL models to efficient implementations for TinyOS
CN111309558A (en) Method, device, equipment and storage medium for collecting vue event data in frame
Egyed et al. Automatically detecting mismatches during component-based and model-based development
WO2008075087A1 (en) Code translator and method of automatically translating modelling language code to hardware language code
Kenter et al. Designing digital video systems: Modeling and scheduling
JP2551935B2 (en) Graphical language processing method
Lee et al. Feature-oriented engineering of PBX software
CN113204331B (en) Business process model-based micro-service design method and system
Liu Feature interactions and software derivatives.
da Silva et al. Matisse: A concurrent and object-oriented system specification language
Hallin et al. Towards a framework for integrated information management in mechatronic product development

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20090717

Address after: Taiwan, Taipei, China

Co-patentee after: Datong University

Patentee after: Tatung Company

Address before: Taipei City, Taiwan, China

Patentee before: Datong Co., Ltd.

CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20090304

Termination date: 20130113

CF01 Termination of patent right due to non-payment of annual fee