Efficient automated translation of procedures in constraint-based language

a technology of constraint-based language and automatic translation, applied in the field of automatic translation of computer languages, can solve the problems of affecting software development, and affecting the development of softwar

Active Publication Date: 2012-07-03
OPTUMSOFT
View PDF12 Cites 14 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Benefits of technology

[0012]The main capability provided by embodiments of the present invention differs from the example of FIG. 1 in two significant respects. The first of these is to specialize to the case of constraints as the declarative statements. This removes the above-described conceptual difficulty, because a constraint is a purely declarative construct. The second of these is to significantly expand the automatic imperative code generation capability to accommodate situations where constraints are in different contexts and / or different program units from their corresponding data members.
[0082]More specifically, an input source program can be expressed in a constraint programming language that also provides for specification of event-sequenced imperative procedures. The input source program can be automatically translated to an intermediate imperative representation, where notification and callback code for constraints in the intermediate representation provides efficient implementation of constraints, and where notification and callback code for events in the intermediate representation provides efficient implementation of event-sequenced imperative procedures. This imperative intermediate representation can be automatically translated to a computer executable imperative output representation, which in turn can be provided as an output (e.g., to a user).

Problems solved by technology

In particular, when the declarative statement is in the same program unit and same context as the input being changed, as shown, then code to perform A can be automatically inserted by the compiler immediately after every line that alters X. However, there are troublesome conceptual aspects of this construct.
Therefore, such constructs have the potential to complicate software development.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Efficient automated translation of procedures in constraint-based language
  • Efficient automated translation of procedures in constraint-based language
  • Efficient automated translation of procedures in constraint-based language

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0091]In an embodiment of the invention, a programming language includes one or more constructs for specifying a set of constraints, referred to as a constraint set. By “constraint” is meant a declarative specification of a relationship between data members that is required to hold, either at all times or at a special time or times. In the former case, a constraint is equivalent in nature to an invariant. An example of the latter is a relationship that only holds on initialization of some data member. Another example is a constraint that refers to a data member in another object; the constraint can only hold when that other object is known. By “active constraint” is meant a constraint where imperative actions are taken to establish and maintain that relationship as state relevant to the relationship changes. In contrast to an active constraint, a passive or checking constraint simply generates an error or exception indication when the relationship is detected not to hold. The nature...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

A method is provided for translating sets of constraint declarations to imperative code sequences based on defining an instantiatable object per set, inserting calls to a notification callback mechanism on state modification and defining calls in the constraint context as imperative code sequences that, in response to these callbacks, take actions to maintain these constraints. This notification and callback mechanism can also be employed in connection with external events, thereby providing for efficient implementation of event-sequenced imperative procedures in a constraint programming language.

Description

FIELD OF THE INVENTION[0001]This invention relates to automatic translation of computer languages.BACKGROUND[0002]In the development of computer technology, various programming paradigms have been developed. Two of these paradigms are imperative programming and declarative programming. Imperative programming entails providing step by step imperative instructions (e.g., set a equal to 2, increment c, call procedure f( )) which are combined by a programmer to solve the problem of interest. Declarative programming entails providing top level information (e.g., a set of logical constraints to be enforced), which can often be specified in a manner that more transparently relates to the problem of interest. Imperative programming tends to provide improved execution performance, but imperative programs can be very complex and difficult to develop and maintain. Declarative programs tend to be relatively easy to develop and maintain, but declarative programming also tends to provide relative...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Patents(United States)
IPC IPC(8): G06F9/44
CPCG06F9/4438G06F9/4496
Inventor CHERITON, DAVID R.
Owner OPTUMSOFT
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products