File: README

package info (click to toggle)
babel 0.10.2-1
  • links: PTS
  • area: contrib
  • in suites: sarge
  • size: 43,932 kB
  • ctags: 29,707
  • sloc: java: 74,695; ansic: 73,142; cpp: 40,649; sh: 18,411; f90: 10,062; fortran: 6,727; python: 6,406; makefile: 3,866; xml: 118; perl: 48
file content (363 lines) | stat: -rw-r--r-- 12,957 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363

                     BABEL 0.10.2 README

                ****  Released 28 March 2005 ****


Contents
========

  Introduction
  Contact Information
  Overview for the Impatient
  Running Tests
  Supported Platforms
  Directories
  Features
  Outstanding Issues
  Future Work
  Further Information
  Project Team


Introduction
============

  Babel is a language interoperability tool intended for use by
the high-performance scientific computing community.  Developed
by the Components project (http://www.llnl.gov/CASC/components)
at Lawrence Livermore National Laboratory, Babel supports the
Scientific Interface Definition Language (SIDL) for the language-
independent declaration of interfaces associated with scientific
software packages.

  The Babel tool, applied to a SIDL file, results in the automatic
generation of the associated skeleton and stub source files.  The
Babel user then need only add the necessary code to the _Impl source
files to complete the provision of a language-independent interface
to the package described by the SIDL file.  The languages currently
supported by Babel on the server-side are C, C++, F77, F90, and Python.  
On the client-side, Babel supports C, C++, F77, F90, Python and Java.

  The remainder of this document provides basic information about
Babel including features, outstanding issues, and future work.


Contact Information
===================

  If you have any questions or concerns with the installation 
process or usage of Babel, feel free to contact the project team 
at components@llnl.gov.  To report bugs or suggest feature 
enhancements, please submit a report in the bug database at 
https://www.cca-forum.org/bugs/babel/ or send email to
babel-bugs@cca-forum.org.


Overview for the Impatient
==========================

  Once you have completed the installation process (see the INSTALL 
file in this directory), you are ready to proceed with using Babel.  
A complete tutorial that steps you through the process of building 
the ubiquitious "Hello World!" example for a single client and server 
is available at ./doc/manuals/users_guide/html/users_guide.html

  Briefly, now that you have the Babel compiler available, you'll 
need to have a sidl file defined before running the compiler.  
Below is a skeleton of the command line required to build the stubs, 
skeletons, and Makefile fragment.  

    $ ./<babel>/bin/babel -s<lang> <name>.sidl

      where <lang> is the desired language,
            <name> is the name of the SIDL file, and
            <babel> is the installation's top directory

  Now you'll need to add the appropriate code within the splicer 
pairs in the _Impl files.  Once you've finished filling in the 
implementation details, you can simply compile and link the 
appropriate libraries.  Again, refer to the tutorial for more
information.


Running Tests
=============

  If you are interested in running the regression tests that
are packaged in this distribution you will need to build them
since they are excluded from the basic installation process.
As in the example in the INSTALL file, given that the Babel 
distribution is in $HOME/babel, the process for building and 
running the regression tests is as follows:

    $ cd $HOME/babel
    $ make check

Various diagnostics and results (e.g., PASS, XFAIL) will be
displayed to indicate the number and status of each set of
tests.  At this time, there are three sets of tests each with
three instances (9 total) that are expected to fail (i.e., XFAIL)
These are for arrays in Python, arrays in Java, and exceptions in
Java.


Supported Platforms
===================

  The Babel compiler has been successfully run on the platform/
compiler pairs listed below.

    Linux             / Intel Compiler Suite 7.0 (icc, ifc & g77)
    Linux             / GCC & Absoft F90
    Linux             / GCC & Lahey F90
    Linux             / GCC 4.0 & gfortran

    AIX               / GCC
    AIX               / IBM compiler suite


    Sparc-Solaris2.9  / gcc 2.95 or higher (not 3.0)
    Sparc-Solaris2.9  / g77 0.5.25 or higher
    Sparc-Solaris2.9  / f77 (Sun WorkShop 5.0)
    Sparc-Solaris2.9  / f95 (SUNSWspro)


Directories
===========

  The following represents the source directory tree 
associated with this release, relative to the top
level of the installation directory, and a brief
description of the contents of each:

    bin/                    # The Babel compiler
    compiler/               # The compiler source
    doc/                    # Supplemental documentation
    doc/manuals/users_guide # PS, PDF, and HTML documentation
    examples/               # Simple examples:
    examples/hello/         #   Hello World examples
    examples/cca            #   CCA-0.5 framework implementation
    lib/                    # Supporting libraries
    regression/             # Regression tests:
    regression/args/        #   Data Type+Passing Mode 
    regression/arrays/      #   Arrays
    regression/assertions/  #   Assertions
    regression/enums/       #   Enumerations
    regression/exceptions/  #   Exceptions 
    regression/inherit/     #   Inheritance 
    regression/objarg/      #   Passing objects as arguments
    regression/ordering/    #   Array ordering test
    regression/overload/    #   Function name overloading
    regression/sort/        #   Abstract class and interface args
    regression/strings/     #   Strings
    runtime/                # Runtime support files 
                              (e.g., sidl.sidl)
    share/                  # Shared config files


Features
========

  Key features, or capabilities, of the Babel toolkit 
are described in this section. 

o SIDL Data Types
  SIDL defines the following data types:
    arrays      double        interface
    bool        enum          long
    char        fcomplex      opaque
    class       float         string
    dcomplex    int

  All data types are currently supported in C, C++, F77, F90,
  and Python with the additional exception of long in
  Python.  It is important, however, to note that the
  binding for enum in F77 and F90 is currently INTEGER due to
  Babel's dependence upon C for its internal object
  representation (IOR).

  Refer to ./regression/args for clients and/or servers in 
  C, C++, F77, F90, Python, and Java that exploit most data types.  
  Use of arrays can be found in ./regression/arrays (including 
  in Python), enums in ./regression/enums, and strings 
  in ./regression/strings.  A crash course in SIDL
  arrays can be found in the users guide.

o SIDL Data Passing Modes
  The following data passing modes are defined:

    in      inout      out      return

  Note that return values in F77 and F90 are translated to out 
  arguments.  Refer to ./regression/args for clients and 
  servers in C, C++, F77, and F90 that exploit these modes.

o SIDL Exceptions
  SIDL provides support for exceptions.  Clients are, 
  however, required to check the return values.  A set 
  of macros are defined in ./runtime/sidl/SIDL_Exception.h 
  to facilitate throwing and catching exceptions in C.  
  Refer to ./regression/exceptions for C, C++, F77, F90, and 
  Python servers and C, C++, F77, F90, Java, and Python clients.

o SIDL Inheritance
  SIDL supports Java-like inheritance.  Refer to 
  ./regression/inherit for servers in C, C++, F77, and F90 
  and clients in C, C++, F77, F90, Java, and Python that exploit 
  these features.

o SIDL Method Overloading
  SIDL supports method overloading on the client and server 
  side for object-oriented languages using an exact match of
  the arguments.  Languages that support method overloading 
  make use of the method name from the SIDL file; whereas, 
  those that do not support overloading rely on the optional 
  method name extension to build unique method names.  Refer 
  to ./regression/overload for examples of the specification 
  and use of overloaded methods in C, C++, F77, and F90 servers and 
  C, C++, F77, F90, Java, and Python clients that exploit these 
  features.

o Makefile Generation
  Babel generates a lot of code.  To assist the developer
  in managing the code, Babel will generate fragments of
  makefiles.  These files are called "babel.make" and 
  define standard macros that list all the relevant source 
  code generated in that directory.  

o Code Splicing
  Although Babel generates a lot of code, some code (notably)
  "impl" files, require hand editing to produce useful 
  libraries.  Babel preserves your previous edits in certain
  files.  This is done with some special CodeSplicer directives 
  embedded in comments in the generated code.  All code 
  nested between matching CodeSplicer directives will be
  preserved by the Babel compiler.

o Direct Access to Numerics in Fortran 77
  "Pointers" are provided for direct access to numeric 
  data types (i.e., dcomplex, double, fcomplex, float, 
  int, and long).  There is a potential for an alignment
  problem with arrays of dcomplex and double, in
  particular, so check the return value of the pointer
  before using it.

o Array Element Access in Fortran 77 and Fortran 90
  Array elements are accessible via subroutine calls.  For
  more information, see the users manual.

o Strings in Fortran 77
  When implementing a method with an inout or out 
  string, the size of the outgoing string is at least 
  512 characters long.

o Enums in Fortran 77 and Fortran 90
  Due to Babel's dependence upon C for its internal object
  representation, the binding for an enumerated type is
  INTEGER.  The good news is that if your Fortran and C compilers
  use the same word size for C int and Fortran INTEGER, everything
  should work fine.  However, if the sizes are different, then
  you may have problems with using enums.


Outstanding Issues
==================

  There are several aspects of the distribution that still 
need work.  The outstanding issues that need to be addressed
include features as well as documentation.

o Python 'long' Data Type
  Arrays of long are treated as arrays of int32_t in Python.
  Outside of arrays, SIDL long is mapped to Python's indefinite
  precision integer data type.

o Support for Multiple Fortran XX Compilers
  In order to use SIDL with multiple Fortran compilers, there
  currently must be a separate Babel installation for each 
  compiler.  You will also need different versions of the 
  runtime library.

o Build Processing
  A mechanism for simplifying the build process needs to be 
  explored, especially to facilitate user builds.

o Documentation
  The documentation set is still minimal at this point, but 
  it is improving.  We've removed the antiquated specification
  and added a DRAFT Users' Guide.

o C++ Shared Libraries and libtool
  In general, the creation of shared libraries in C++ seems to
  be problematic.  It was necessary to make compiler-specific
  modifications to libtool.  Consequently, this distribution
  includes our modified libtool.

o Overloaded Functions and Type Inheritance
  Babel compiler support for overloaded functions is currently
  limited to an exact match of the argument list in terms of
  types and ordering.  Hence, implicit type conversions within 
  Babel are not supported.  


Future Work
===========

  The following is a list of key activities that will be 
explored for incorporation into subsequent releases:

o Test for arrays of enums (still more work could be done here)
o Java server support
o Expanded platform and compiler support
o Simplified Build processing 
o Distributed (i.e., Remote) Object support
o Data Redistribution
o Implicit argument type conversions in overloaded methods


Further Information
===================

  The following files are available at the top of the 
release directory structure provide additional information 
on the Babel release:

    BUGS       Lists known bugs
    COPYRIGHT  University of California Copyright notice
    INSTALL    Provides installation instructions
    README     This file

  Additional background information can be found in the 
./doc/papers and ./doc/talks subdirectories including the 
outdated specification (./doc/papers/specification.ps).  
More recent papers and talks can be found at our web site
at 

    http://www.llnl.gov/CASC/components/

  Additional documentation including a tutorial, command
line arguments, SIDL grammar, and crash courses on SIDL 
arrays and Fortran can be found in ./doc/babel101.


Project Team
============

The following individuals are current members of the
development team on the LLNL Components Project:

  Tammy Dahlgren              Tom Epperly                 
  Gary Kumfert

Community code contributors:
  Boyana Norris

Our alpha testers are:
  Bill Bosl                   Jeff Painter
  Andy Cleary                 Steve Smith

and our alumni are:
  Melvina Blackgoat           Nathan Dykman
  Kevin Durrenberger          Scott Kohn
  Brent Smolinski             Sarah Knoop