Ateji PX
Encyclopedia
Ateji PX is an object-oriented
programming language
extension for Java
. It is intended to facilliate parallel computing
on multi-core processors, GPU, Grid and Cloud.
Ateji PX can be integrated with the Eclipse IDE, requires minimal learning of the additional parallel constructs and does not alter the development process.
Each
or
depending on how the parallel branches happen to be scheduled.
The quantification
More complex quantifications are possible. The following example quantifies over the upper left triangle of a square matrix:
Code that performs a similar and typically small operation on a large collection of elements is called data parallel
, and appears often in high-performance scientific applications. A typical representative of data-parallel languages for the C/C++ or Fortran ecosystems is OpenMP
.
Data parallelism features can also be implemented by libraries using dedicated data structures, such as parallel arrays
.
Task parallelism is implemented in languages such as Cilk
, and in libraries similar to the
In this example, two parallel branches communicate via explicit message passing:
when computation is initiated and synchronized by the availability of data in a flow. A typical example is an adder: it has two inputs, one output, and whenever the two inputs are ready, it sends their sum on the output.
Note the parallel read
The adder by itself doesn't do anything, since it reacts on input data. It needs to be put in a context where other parts feed input values and read output values. The way to express this is to compose all pices in a large parallel block:
Anything that can be thought of as a combination of logical gates or electrical circuits can readily be expressed in this way as a data-flow program.
Object-oriented programming
Object-oriented programming is a programming paradigm using "objects" – data structures consisting of data fields and methods together with their interactions – to design applications and computer programs. Programming techniques may include features such as data abstraction,...
programming language
Programming language
A programming language is an artificial language designed to communicate instructions to a machine, particularly a computer. Programming languages can be used to create programs that control the behavior of a machine and/or to express algorithms precisely....
extension for Java
Java (programming language)
Java is a programming language originally developed by James Gosling at Sun Microsystems and released in 1995 as a core component of Sun Microsystems' Java platform. The language derives much of its syntax from C and C++ but has a simpler object model and fewer low-level facilities...
. It is intended to facilliate parallel computing
Parallel computing
Parallel computing is a form of computation in which many calculations are carried out simultaneously, operating on the principle that large problems can often be divided into smaller ones, which are then solved concurrently . There are several different forms of parallel computing: bit-level,...
on multi-core processors, GPU, Grid and Cloud.
Ateji PX can be integrated with the Eclipse IDE, requires minimal learning of the additional parallel constructs and does not alter the development process.
Hello World
Each
||
symbol introduces a parallel branch. Running this program will print either
Hello
World
or
World
Hello
depending on how the parallel branches happen to be scheduled.
Data parallelism
The quantification
(int i : N)
creates one parallel branch for each value of i
. The effect of this code is to increment all elements of array
in parallel. This code is equivalent toMore complex quantifications are possible. The following example quantifies over the upper left triangle of a square matrix:
Code that performs a similar and typically small operation on a large collection of elements is called data parallel
Data parallelism
Data parallelism is a form of parallelization of computing across multiple processors in parallel computing environments. Data parallelism focuses on distributing the data across different parallel computing nodes...
, and appears often in high-performance scientific applications. A typical representative of data-parallel languages for the C/C++ or Fortran ecosystems is OpenMP
OpenMP
OpenMP is an API that supports multi-platform shared memory multiprocessing programming in C, C++, and Fortran, on most processor architectures and operating systems, including Linux, Unix, AIX, Solaris, Mac OS X, and Microsoft Windows platforms...
.
Data parallelism features can also be implemented by libraries using dedicated data structures, such as parallel arrays
Parallel array
In computing, a parallel array is a data structure for representing arrays of records. It keeps a separate, homogeneous array for each field of the record, each having the same number of elements. Then, objects located at the same index in each array are implicitly the fields of a single record....
.
Task parallelism
The term task parallelism is used when work can conceptually be decomposed into a number of logical tasks. In this example, tasks are created recursively:Task parallelism is implemented in languages such as Cilk
Cilk
Cilk is a general-purpose programming language designed for multithreaded parallel computing. The commercial instantiation is Intel Cilk Plus.-Design:...
, and in libraries similar to the
fork/join
pair of Unix system calls.Message-passing
Parallel branches have two ways of communicating; either by concurrently reading and writing shared variables, or by sending explicit messages. The operators!
and ?
respectively send and receive a message on a channel.In this example, two parallel branches communicate via explicit message passing:
Data-flow
A program is said to be data-flowDataflow
Dataflow is a term used in computing, and may have various shades of meaning. It is closely related to message passing.-Software architecture:...
when computation is initiated and synchronized by the availability of data in a flow. A typical example is an adder: it has two inputs, one output, and whenever the two inputs are ready, it sends their sum on the output.
Note the parallel read
[ in1 ? value1; || in2 ? value2; ]
. It means that the two input values can come in any order. Without it, the code may deadlock if values where coming in the wrong order. This shows that parallel primitives in a programming language are not only about performance, but also about the behavior of programs.The adder by itself doesn't do anything, since it reacts on input data. It needs to be put in a context where other parts feed input values and read output values. The way to express this is to compose all pices in a large parallel block:
Anything that can be thought of as a combination of logical gates or electrical circuits can readily be expressed in this way as a data-flow program.
External links
- The Ateji PX white-paper A gentle introduction to the language features
- The Ateji PX language manual
- Think Parallel, Think Java article at Dr. DobbsDr. Dobb's JournalDr. Dobb's Journal was a monthly journal published in the United States by CMP Technology. It covered topics aimed at computer programmers. DDJ was the first regular periodical focused on microcomputer software, rather than hardware. It later became a monthly section within the periodical...
- French Firm Brews Parallel Java Offering