RSS
Логотип
Баннер в шапке 1
Баннер в шапке 2
2011/12/27 13:27:02

Functional stream computer with parallel computings

Whether the universal digital computer, as well as analog, calculating in superposition of functions each of them and her arguments in parallel (at the same time) is possible, but it is not consecutive: in turn arguments and then function. – Whether it is possible, having refused tiresome declarative structures like if … then … else, for and dr, naturally – without special means of language to combine posledovatelnostny and parallel programming with access synchronization in parallel of the executed functions and arguments to the general data. It especially is relevant when high-speed performance of processors (microminiaturization) approached the limit determined by Einstein. P.S. Having recovered sight, now (to 15.08-2013 years) could review almost for 100% this project, having cut statement by half and having repeatedly enhanced result (PhD in Technological Sciences V. Patrikeev, Luhansk)

Content

Links to all sections of the project:

1. Functional Stream Mashina with parallel computings. Introduction (http://tadviser.ru/a/121275)
2. Uniform data structure and programs (http://tadviser.ru/a/149691)
3. Functioning of FPM. Expressions of language of programming (http://tadviser.ru/a/149691)
4. Flows and their processing in structure of expression (http://tadviser.ru/a/150588)
5. Micro programming of functions (http://tadviser.ru/a/153069)
6. The program as the managed flow of expressions (http://tadviser.ru/a/153069)
7. Macro definitions of the user functions (http://tadviser.ru/a/157631)

1. Introduction


Work purpose: Creation of a universal computer parallel to calculating function f:

      f(f1,f2,...,fN) (1-1)   

and her arguments of f1, f2..., fN - generally also functions with in parallel the calculated arguments, etc. down hierarchy of expression (1-1)

The accompanying and not less important purpose at the same time use of a high-level programming language of such computer on the basis of expressions (1-1), operating with large objects and, at least simplifying, if NE of in parallel proceeding removing a problem of synchronization computation and information processes.

  Unsuccessful attempts of the solution of this problem at many [1] raised doubts in basic and its practical resolvability. And still there is one of solutions, simple so what not just to understand owing to the traditions which took roots in our consciousness and a mentality, the limited track of languages laid by the author of Fortran'a who sincerely regretted about this when leaving from us. For this purpose it was necessary, having saved accepted lisp unity of structure (and memories!) data and expressions - superpositions of functions to extend indexing of elements of multidimensional matrixes on any treelike (lisp, tree) structure, and even hierarchical, including with cycles.
  On this basis, having integrated (still unification) concepts of a variable, elements of dynamic arrays Jscript (Perl language hash), expressions of language and even their macro definitions to review traditional determinations of a variable as object, having fixed the problems mentioned still by Barron [2], remaining even in the L-languages operating with links. - And all this within being subject to complete revision of the organization and management data streams and expressions, including their synchronization and processing.
  At last, review of concepts of macrogeneration and micro programming of the functions processing flows and also generation by them in flows elements of a hierarchical structure forced to determine architecture of a computer (collective of a micro computer) by a sample, it is visible dynamically (in the course calculations) built on structure of the calculated expressions and samples in similar structures.

  Proposed solutions are under construction in the system of almost naturally adopted concepts:

1.1. Uniform data structure, programs, space of their memory and computer

1) Uniform (only) flexible construction (1-1) of expressions of a programming language – the superposition of functions usual to us since school years, displaying the calculations (computer) implementing it structure from microprocessors (a micro computer, transputers). Each of them executes in parallel with other one of f1 functions, …, fn which exits contact inputs of function f performed by also separate micro computer. In language there are no if declarations … then … else, the cycles for, while, switch, etc.

2) As well as in lisp syntactically data have the same structure (1-1) in which now f, f1, …, fN can be atoms – numbers, lines, dates, names, etc.

3) Coding of structure (1-1) differs from accepted in lisp: in the most general case it is defined as a node which code – couple of links:

  UKA – the pointer of atom f
  UKS – the pointer of a layer from elements - f1 nodes (...), f2(...)..., fN (...)

Layer - codes of its elements (nodes) are placed in Blok (dynamically distributed) Memory (BP), allowing direct access (indexing) to nodes by their indexes 0, 1, 2, … as their following in a layer

4) The element of any layer optional can receive a name, unique within a layer, for example
  Bob: f2 (...) in (1-1)
along with the numerical index used similar to an element of a dynamic array (hash) for access to this element.

5) Area space (…) the memory which is dynamically distributed under BP of layers and atoms – an essence the same uniform structure (1-1). Element Area layer (…) is defined as a subspace - an equivalent of determination of a variable in traditional language. A variable name with values of a type: data, expression or macro definition – an essence Area layer node name (…). However indexed (see further) elements same subspaces can be values of all listed types and everyone with structure (1-1)

6) Syntactically the structure (1-1) is treelike. However use of copies (secondary) links in a storage space allows implement the hierarchical structure which is beyond treelike and even with links to top levels (cycles)

7) We already noted that the implementing expression (1-1) the structure of the interconnected micro computers is adequate to structure of this expression and as in structure of expression identical functions can meet, we will define the relevant structure of a micro computer as Structure Aktivatsy functions, in abbreviated form, SA. Therefore speaking about flows on inputs (arguments) and exits of functions, of course, we will mean these flows between the micro computers corresponding to them in similar structure of SA

1.2. Flows and management concepts them

Certainly language of the developed machine should operate with large objects - sets and it is even better in the movement, and, therefore with flows. And here the efficiency of means, generally is defined by two factors:

1) unification, simplicity and power of management tools flows, including separation of their elements - separation into separately processed flows

2) unification of determination of a flow

1.2.1. Management concepts flows

1) The first and main concept consists that each element of a flow is supplied with rather small set of static properties determined by its structure, atom type, coding, provision in a layer, a flow, etc. factors. These properties accompany an element in a flow and actually are also a basis for their selection in separate subflows or for processing. The single system of the description of these is for this purpose introduced properties and this description bracketed by %... the % is used also at the description of functions, their arguments and different elements lexical units of language and data. At last, these determinations can be used both in language, and as data structure atoms.

2) In processing of elements of a flow there is an opportunity to supply flow elements dynamic, thought out by users properties - most often the characters of the latin alphabet simplifying classification and selection of the necessary elements of flows

3) In addition to the main thing - syntactically the defined exit of any function it is possible to enter any quantity of additional with unique names function exits, as usual for each such exit having determined (the analysis of properties) elements by the created stream function, directed to each exit. Besides at each such exit, as well as on the basic (with the fixed name Out) an exit it is possible standard means of the connected calculator (a micro computer) of _Calc to process the element received at the exit, to transform it before issue to day off the flow or to refuse such issue. Additional exits of function contact the channels (Chanal) of the same name announced on inputs of other functions and thus the real structure of expression considerably extends in comparison with announced (1-1)

4) Entrance flows of any function can be processed by the same means of the _Calc calculator, as output flows. And in the same way the received next element of a flow can be transformed before transfer of its function on processing or is actually excluded from an entrance flow. The input flow can be closed by similar means (is interrupted), as well as day off

5) For the entrance and created by function output flows the concept "Adder", differing from numerical in the fact that equally is entered can be not only number (Amount), but also to have any structure of type (1-1) and the method of its formation determined by the user. Value this Adder it is possible to send to a function exit upon termination of processing of a flow or automatically (tuning property of any function) receive in the specified subspace (variable). Thus it is possible to call the machine created by us not just functional stream (FPM), but also "summing up"

P.S. The management tools flows described above actually are implemented out of functions by inclusion of standard primitives of the _Calc setup as "transparent" (in any place) additional function arguments.

6) The unified generation functions (sources) of flows, their synchronous and asynchronous processing allowing making changes are entered in algorithms of their work of the same _Calc calculator as connection and all with the same set of standard means

1.2.2. Unification of determination of flows

Can be elements of flows:

1) The atoms transferred directly between the micro computers implementing specific functions in SA

2) Couple of links UKA and UKS (R-value) to the relevant structure in the Dynamically Distributed Memory (DDM). The specified structure can be both to data, and expression. The program is entered here as a flow of expressions (links to them) besides in which each expression can process in passing structure, synchronously with a flow of expressions arriving from a data stream

3) Integer or the Name index (see item 1.3)

4) V-value - UKS (a) pair and the index (3) determining an element (2) in a layer by UKS (a).

The V-value is that there is no NE in a stream type in any of the existing languages even and the otsustviye creates there still mentioned Barron ([2]) problems. V-values allows transaction of X type: = to execute X+1 repeatedly moreover in flows, without looking on statements [4] about impossibility of their repetition ('substitutions' in terminology of authors [4]) in stream computers. Therefore, except atoms, indexes and links to elements of structures (R-value) V-values also can move to DRP in flows. Moreover, the majority of generators create flow of V-values.

1.3. Indexing of structure members of data, programs and space

  As usual, indexing aims at simplification and reduction of time of access to structure members and here unlike multidimensional matrixes it is performed naturally and visibly:

1) The sequence of indexes i, j, …, k in M [i, j, …, k] is a flow now and sets a way on a tree structure (1-1): In a layer subspaces of M there is a node with index i – its sequence number (0, 1, 2, …) in a layer, then in a layer of this node (the following lower than the level hierarchies) a node with index j, etc. Moreover, transaction of indexing allows to select all tops (nodes) of a way, and not just final. But the main thing, this way forms in the form of V-values (item 1.2.2) that gives the chance to check and even Not only to change this way in the course of indexing but also to process the elements of a way indexed on the course, to check correctness of a task of indexes and in absence the structure members determined by them to make the decision on its expansion or suspension of indexing. The indexed element can have same structure (1-1).

P.S. Thus, the way created as a result of indexing on structure - the same flow which others can process synchronously (and NOT one!) a flow, for example to correct atoms of elements (tops) of the indexing of a way undergone in result. Such NE allows any of the existing languages and programming systems

2) In addition to certainly it is possible for the existing integer index of an element of any layer on any hierarchy level of structure (1-1) enter his name unique within this layer. Layer member name "space" - an essence a subspace name. Now in M [i, j, …, k] any index i, j, …, k can be both integer, and member name in the corresponding layer. It is indexed by a flow of indexes not only subspace elements, but also elements of any dynamically created (calculated) structure of a type (1-1)

3) Expressions allow record of transaction of indexing, usual for traditional languages, in the form of M [i, j, …, k] which automatically expression of a view (1-1) with the flow generated by functions is substituted for the built-in macro definition in normal (implemented by the connected micro computers) indexes. At the same time actually substitution of source recording expression of a type (1-1) of NE is made: this substitution is implemented only in structure of SA from a micro computer

1.4. Processing of structure flows in one expression of FPM

Layered hierarchical structure (1-1) or its elements on gorizonal (selectively layer elements) or down hierarchy levels (item 1.3, indexing) can be processed data streams. Moreover, it is possible to organize a bypass of the processed structure on a circuit from top to down and from left to right in the course of which to create a flow of V-values of passable tops. Further this flow can be processed synchronously or asynchronously other flows or to be limited to collecting of statistics and in principle any information on structure.

1.5. Program implementation of FPM

1) The program - a flow of expressions (1-1) of functions is implemented by the function of $Eval (a core of FPM) creating for each next expression of a flow similar structure collective of a micro computer - The Structure Aktivatsy (SA) of functions and creating a storage space in DRP with own subspaces. The structure of SA can differ from structure of the calculated expression for the account as the macro definitions which are built in (item 1.2), so and determined by the user in subspaces.

2) In implementable $Eval (1) expression can there is another $Eval, creating own space with subspaces, which names can match names of separate subspaces (1) of $Eval. Anyway the subspace set in expression is looked for in the beginning in $Eval performing this expression and only for lack of like that in $Eval (1) performing expression with the considered $Eval, etc. up hierarchies of $Eval.

3) Expressions of the program (1) are executed consistently, however flows in each of expressions, generally processed in parallel. In the same way parallel processing of entrance and output flows will be organized by different copies of the _Calc calculator (item 1.2.1), made in parallel with work of the function (implementing it a micro computer)

4) Considerably the efficiency of FPM dostgatsya by combination of two levels of programming - expressions (1-1) with use the built-in functions of FPM (a micro computer in SA) and micro programming - means of the _Calc calculator involved by a separate copy (a micro computer) to change of an algorithm of calculations (actions by default) the most often used functions. In these cases the calculator it is limited to specific transactions with a separate element arrived from an entrance flow or to trains of synchronously arrived elements from different flows, and at the same time, perhaps, with formation of results of processing of a flow (flows). Having a large number transactions (than feature set) language of the calculator is rather high on the level of programming and, in particular, uses constructions the If type of classical languages and at the same time a possibility of reduction of the processed structure members to the necessary type on a basis the unified language of the description of required properties according to item 1.2.1(1), what NET in one of the existing languages. At last, the _Calc programming language operates with parameters of functions (their arguments) with a possibility of their control and processing before function start, has the whole set of the built-in high-speed registers allowing to do without memory of DRP. A part from such registers is conducted automatically, displaying characteristics of the arrived and processed flow, a train of the processed values, etc.

5) Including generators, the user enters own functions focused on a class of tasks in space as macro definitions the user functions in the form of expressions (1-1) using _Calc calculators with own user microprograms, with use in macro definitions of own functions (macrocalls or macroes) which are earlier similarly entered by it with their macro definitions. At the same time it is possible to avoid the actual replacement in expression of macrocalls (macroes, the user functions) macro expansions on a basis macro definitions and dead times connected with it: by the beginning of expression evaluations only SA is rebuilt as appropriate (already without macrocalls). These processes of macrogeneration for the macrocalls which are not on one way (in a tree of initial expression with macrocalls) are executed in parallel (at the same time) – one more level of parallelism of calculations

The used literature



1. V.G. Horoshevsky. Reverse engineering of functioning of computers and systems. M, 'Radio and communication', 1987
2. D. Barron. Introduction to programming languages, 'M.Mir', 1980
3. V. Zhirov. Software and design of structures of a computer. 'M.Nauka', 1979
4. K. Futi, N. of Suzuki. Programming languages and circuit engineering of GSI, 'M.Mir', 1988

The used reductions:

FPM	-functional stream machine
p. 5	-Section 5 of the FPM project
item 2.3	-point 3 of Section 2
SA	-Structure Aktivatsy – implementing expression of language (superposition
 	  functions) collective of appropriately connected micro computers, 
 	  each of which implements separate function or a primitive 
 	 (calculator) of _Calc
DRP	-dynamically distributed memory over which funkutsionirut 
 	  micro EVM SA
BP	-the DRP block selected under atom or a layer of structure
UKA	-pointer (link to BP) of atom (item 2.3)
UKS	-pointer (link to BP) of a layer (river 2)

See Also