Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
language:langs:refine [2022/09/16 08:54]
rajit
language:langs:refine [2022/09/16 08:57] (current)
rajit
Line 35: Line 35:
          
 </code> </code>
 +At this point, a tool can select the level of abstraction/detail for the process by picking one of the two sub-languages provided.
  
-Now imagine that instead of writing the production rules directly, you'd like to instantiate a set of gates to implement the circuit. If you wrote:+Now imagine that instead of writing the production rules directly, you'd like to instantiate a set of gates to implement the circuit. Suppose we write the following:
 <code act> <code act>
 defproc example(...) defproc example(...)
Line 49: Line 50:
 } }
 </code> </code>
-then this means that the process has a CHP definition, and //in addition// it has the specified instances! This is not what was intended; we'd like to use the CHP definition //or// the instances. To provide support for this, the ''refine'' body is used. The example would be written:+As written, this means that the process has a CHP definition, and //in addition// it has the specified instances! This is not what we intended to specify; we'd like to use the CHP definition //or// the instances.  
 + 
 +To provide support for this, the ''refine'' body is used. The example would be written:
 <code act> <code act>
 defproc example(...) defproc example(...)
Line 64: Line 67:
 } }
 </code> </code>
-Now you can //pick// the refined version of the process by using the ACT command-line option ''-ref=1''. This approach is used in the ''chp2prs'' tool to provide an implementation of the CHP. This is the standard convention used in any tool that takes CHP and generates a circuit-level description. By augmenting the definition of the process in this manner, you can model the process at both the CHP level of abstraction as well as a more detailed representation containing a collection of instances that implement the CHP.+Now you can //pick// the refined version of the process by using the ACT command-line option ''-ref=1'', and so a tool can pick either the ''chp'' or the ''refine'' sub-language, giving us the desired effect. 
 + 
 +This approach is used in the ''chp2prs'' tool to provide an implementation of the CHP. This is the standard convention used in any tool that takes CHP and generates a circuit-level description. By augmenting the definition of the process in this manner, you can model the process at both the CHP level of abstraction as well as a more detailed representation containing a collection of instances that implement the CHP.