260
M. Sato et al.
4.2 XcalableMP as a DSL for Stencil Applications
The Domain Specific Language (DSL) is a promising approach to make the
programing easy in a specific domain. Many DSLs such as OpenFOAM in CFD
are successful.
Many DSLs are proposed to describe the typical stencil computation. On the
other hand, we propose the mixed-language programming with XcalableMP in
Chap. 5. Using this model, the main kernel of the computation can be written
in XcalableMP and other controls, input/output and house-keeping operation are
written by other familiar languages such as Python. In this case, a part of XMP
is thought as a kind of DSL to write the stencil computation with global view
programming.
The advantages of this approach are as follows:
• By using the XMP global view programming model, the stencil computation can
be described in a simple loop based on its original sequential program.
• The stencil communication can be done by the XMP optimized stencil communication runtime [13].
• The advanced optimization of the stencil operations is enabled by a set of the
directives for the extended stencil optimization such as a loop unrolling and
temporal blocking, added in the latest XcalableMP specification, version 1.4 [14].
4.3 XcalableMP API: Compiler-Free Approach
Although many PGAS languages, such as UPC and Chapel, CAF, have proposed,
it is hard to say that they are fully accepted by the community of parallel programming. Recently, the libraries supporting the PGAS model, such as OpenShmem [15],
GlobalArray [16], even MPI3 RMA, are getting popular for programming some
specific applications. Furthermore, many C++ template-based design for PGAS,
such as UPC++ [17], DASH [18], are proposed as a compiler-free approach, as C++
template provides powerful abstraction mechanism. This approach may increase
portability, clean separation from base compiler optimization, but a problem is that
it is sometimes hard to debug in C++ template once a programmer writes wrong
programs.
The approach of extending the language given by the support of the compiler, the
compiler-approach, may give:
• A new language, or language extension provides easy-to-use and intuitive feature
resulting in better productivity.
• This approach enables the compiler analysis for further optimization, such as
removal of redundant sync and selection of efficient communication.
In reality, the compiler-approach is not easy to be accepted for deployment and
supports in many sites, resulting in the failure of wide dissemination.
M. Sato et al.
4.2 XcalableMP as a DSL for Stencil Applications
The Domain Specific Language (DSL) is a promising approach to make the
programing easy in a specific domain. Many DSLs such as OpenFOAM in CFD
are successful.
Many DSLs are proposed to describe the typical stencil computation. On the
other hand, we propose the mixed-language programming with XcalableMP in
Chap. 5. Using this model, the main kernel of the computation can be written
in XcalableMP and other controls, input/output and house-keeping operation are
written by other familiar languages such as Python. In this case, a part of XMP
is thought as a kind of DSL to write the stencil computation with global view
programming.
The advantages of this approach are as follows:
• By using the XMP global view programming model, the stencil computation can
be described in a simple loop based on its original sequential program.
• The stencil communication can be done by the XMP optimized stencil communication runtime [13].
• The advanced optimization of the stencil operations is enabled by a set of the
directives for the extended stencil optimization such as a loop unrolling and
temporal blocking, added in the latest XcalableMP specification, version 1.4 [14].
4.3 XcalableMP API: Compiler-Free Approach
Although many PGAS languages, such as UPC and Chapel, CAF, have proposed,
it is hard to say that they are fully accepted by the community of parallel programming. Recently, the libraries supporting the PGAS model, such as OpenShmem [15],
GlobalArray [16], even MPI3 RMA, are getting popular for programming some
specific applications. Furthermore, many C++ template-based design for PGAS,
such as UPC++ [17], DASH [18], are proposed as a compiler-free approach, as C++
template provides powerful abstraction mechanism. This approach may increase
portability, clean separation from base compiler optimization, but a problem is that
it is sometimes hard to debug in C++ template once a programmer writes wrong
programs.
The approach of extending the language given by the support of the compiler, the
compiler-approach, may give:
• A new language, or language extension provides easy-to-use and intuitive feature
resulting in better productivity.
• This approach enables the compiler analysis for further optimization, such as
removal of redundant sync and selection of efficient communication.
In reality, the compiler-approach is not easy to be accepted for deployment and
supports in many sites, resulting in the failure of wide dissemination.
