Skip to main content
U.S. Department of Energy
Office of Scientific and Technical Information

Automated Fortran–C++ Bindings for Large-Scale Scientific Applications

Journal Article · · Computing in Science and Engineering
Although many active scientific codes use modern Fortran, most contemporary scientific software libraries are implemented in C and C++. Providing their numerical, algorithmic, or data management features to Fortran codes requires writing and maintaining substantial amounts of glue code. This paper introduces a tool that automatically generates native Fortran 2003 interfaces to C and C++ libraries. The tool supports C++ features that have no direct Fortran analog, such as templated functions and exceptions. Finally, a set of simple examples demonstrates the utility and scope of the tool, and timing measurements with a mock numerical library illustrate the minimal performance impact of the generated wrapper code.
Research Organization:
Oak Ridge National Laboratory (ORNL), Oak Ridge, TN (United States)
Sponsoring Organization:
USDOE National Nuclear Security Administration (NNSA)
Grant/Contract Number:
AC05-00OR22725
OSTI ID:
1649607
Journal Information:
Computing in Science and Engineering, Journal Name: Computing in Science and Engineering Journal Issue: 5 Vol. 22; ISSN 1521-9615
Publisher:
IEEECopyright Statement
Country of Publication:
United States
Language:
English

References (12)

Optimizing real world applications with GCC Link Time Optimization text January 2010
Introspective Sorting and Selection Algorithms journal August 1997
A high-performance, portable implementation of the MPI message passing interface standard journal September 1996
Automated scientific software scripting with SWIG journal July 2003
The NETL MFiX Suite of multiphase flow models: A brief review and recent applications of MFiX-TFM to fossil energy Technologies journal September 2017
Shadow-object interface between Fortran 95 and C++ journal January 1999
Why Fortran? journal July 2007
This Isn't Your Parents' Fortran: Managing C++ Objects with Modern Fortran journal March 2012
Compiler Support for the Fortran 2003, 2008, TS29113, and 2018 Standards Revision 24 journal August 2018
Exploring Capabilities within ForTrilinos by Solving the 3D Burgers Equation journal January 2012
High-performance language interoperability for scientific computing through Babel journal July 2011
The Met Office Global Coupled model 2.0 (GC2) configuration journal January 2015

Similar Records

Documenting automated Fortran-C++ bindings with SWIG
Technical Report · Sat Jun 01 00:00:00 EDT 2019 · OSTI ID:1557490

Five years of ForTrilinos ECP
Technical Report · Mon Aug 01 00:00:00 EDT 2022 · OSTI ID:1909128

Users manual for bfort: Producing Fortran interfaces to C source code
Technical Report · Tue Feb 28 23:00:00 EST 1995 · OSTI ID:93504