4 ms·
>> I guess my main concern versus C is portability and ease of integrating libraries or exporting a usable C API, and secondarily the quality of the optimizer.
by thesuperbigfrog 3y ago
>> I guess my main concern versus C is portability and ease of integrating libraries or exporting a usable C API, and secondarily the quality of the optimizer.
Interfacing with C APIs / libraries is really easy and portable across Ada implementations:
https://learn.adacore.com/courses/intro-to-ada/chapters/interfacing_with_c.html https://learn.adacore.com/courses/intro-to-ada/chapters/inte...
http://www.ada-auth.org/standards/22rm/html/RM-B-3.html http://www.ada-auth.org/standards/22rm/html/RM-B-3.html
The quality of the optimizer depends on the Ada implementation.
GNAT, the free software Ada implementation, uses the GCC backend so it is pretty good:
https://www.getadanow.com/ https://www.getadanow.com/
https://www.adacore.com/gnatpro https://www.adacore.com/gnatpro
- binary132 3y agoThanks for showing me that, I agree it looks pretty convenient.
- glacia01 3y ago>GNAT, the free software Ada implementation, uses the GCC backend so it is pretty good: GNAT also has LLVM Backend: https://github.com/AdaCore/gnat-llvm https://github.com/AdaCore/gnat-llvm It's stable and Adacore plans to ship it in GNAT Pro 24, i.e. next release. Note that it's the same front-end, so you get best of both worlds basically.