 |
What is GNAT
GNAT is a complete, open-source, multi-target development environment for Ada95. The GNAT system includes compilers, libraries, debugging and monitoring tools, for a larget number of hardware/operating system configurations, as well as cross-compilers for the most popular embedded systems. GNAT uses the back-end of GCC for its code generation, and derives its portability from it. All components of GNAT are open-source, and distributed under the modified GPL.
GNAT is maintained and fully supported by Ada Core Technologies.
For more information contact sales@gnat.com.
Public versions of GNAT are available at a number of ftp sites around the world. New releases of GNAT appear on the average twice a year.
A Bit of Ancient History
The origins of GNAT coincide with the design and adoption of the Ada95 standard. Prior to the standardization of what was then known as Ada9X, circa 1993, the Ada Joint Program Office funded the developement of a prototype compiler for the new language. This project took place at New York University, and involved the team that had designed Ada-Ed, the first validated Ada83 compiler, a full decade earlier. The goal of the new project was twofold: to test the design an implementability of the new language, and to produce a high-quality, freely distributable compiler that would help spread knowledge of the language. The GCC model of compilation and software distribution was the natural choice to insure portability, code quality, and universal availability. The name GNAT (which stood for the Gnu NYU Ada Translator) was chosen for the project, because of its academic location and its use of GCC. This acronym lost its meaning long ago, and now stands for itself, and for the tongue-in-cheek remark that there is only one bug in GNAT.
A Bit of Architecture
The GNAT compiler includes an Ada95 front-end, a code generator, a binder, a linker, and a run-time library. All of these components, except for the code generator, are written in Ada95, and are completely target-independent. The code generator is the GCC back-end. The interface between the front-end and the GCC back-end is a tree transducer, written in C, which translates the language-specific intermediate representation produced by the front-end into the language-independent tree language that GCC expects.
The GCC Back-End
The GCC back-end is a multi-language, multi-target code generator that
produces high quality code for a large variety of machines. GCC
achieves its remarkable portability by being mostly target-independent:
it consists of a number of generalized pattern-matching phases that
perform successive transformations on a general-purpose
register-transfer language. The patterns themselves are the only
target-dependent component, and consist of compact descriptions of
the instruction set of a particular processor. Porting the GCC back-end,
which comprises more than half-a-milion lines of code, requires only the
creation of a machine description file for the new target, which typically
requires no more than 5000 lines of patterns.
On a number of machines, GCC is the most efficient compiler available
in terms of speed of the generated code, and on all machines it is highly
competitive with commercial C compilers. It is used as the back-end for
a number of languages: C, C++, Fortran77, Pascal, Modula2, CHill, and
Ada95.
The GNAT Runtime
The most important part of an Ada95 runtime is the implementation of
the concurency features of the language: tasks, protected types and
objects, asynchronous transfer of control, requeueing facilities, and the
real-time annex. The design of the runtime consists of a high-level
interface from the compiler-generated code to this runtime, and a
low-level interface from the runtime to the target environment. The
low-level interface is suitable for implementation on top of an operating
system, such as one that supports POSIX threads; the low-level
interface can also be easily supported by compact real-time executives
such as VXWorks or LynxOS. This design simplifies the porting of
GNAT to new targets and environments, and provides GNAT users with
a uniform environment for multi-platform development.
The Software License
GNAT sources are distributed under the General Public License:
The most important part of an Ada95 runtime is the implementation of the concurency features of the language: tasks, protected types and objects, asynchronous transfer of control, requeueing facilities, and the real-time annex. The design of the runtime consists of a high-level interface from the compiler-generated code to this runtime, and a low-level interface from the runtime to the target environment. The low-level interface is suitable for implementation on top of an operating system, such as one that supports POSIX threads; the low-level interface can also be easily supported by compact real-time executives such as VXWorks or LynxOS. This design simplifies the porting of GNAT to new targets and environments, and provides GNAT users with a uniform environment for multi-platform development.
The Software License
GNAT sources are distributed under the General Public License:
"GNAT is free software; you can redistribute it and/or modify it under terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. GNAT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License distributed with GNAT; see file COPYING. If not, write to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
As a special exception, if other files instantiate generics from this unit, or you link this unit with other files to produce an executable, this unit does not by itself cause the resulting executable to be covered by the GNU General Public License. This exception does not however invalidate any other reasons why the executable file might be covered by the GNU Public License. "
Free download of the public version of GNAT:
US sites:
European sites:
GNAT Professional
For commercial users of GNAT - fully supported by Ada Core Technologies - the original GNAT developers.
List of projects currently using GNAT and their stories.
|
|