From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Coyo T Stormcaller Newsgroups: comp.lang.ada Subject: Re: Writing Linux Kernel Modules in Ada Date: Sat, 29 Oct 2016 16:09:08 -0500 Organization: A noiseless patient Spider Message-ID: References: Reply-To: coyo@darkdna.net Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8Bit Injection-Date: Sat, 29 Oct 2016 21:08:24 -0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="c06af2c6f3056f381b15db0024074a3b"; logging-data="20560"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19CnWHOO6AAZAvYZ+Gx/H78gGqqnUogLAs=" User-Agent: KNode/4.14.10 Cancel-Lock: sha1:9RxCG+voRaezZaKF3VH1opiHx88= Xref: news.eternal-september.org comp.lang.ada:32202 Date: 2016-10-29T16:09:08-05:00 List-Id: Hadrien G. wrote: > Le 29/10/2016 à 04:19, Coyo T Stormcaller a écrit : >> artium@nihamkin.com wrote: >> >>> I am experimenting with writing Linux kernel modules in Ada and document >>> my attempts. >>> >>> Thought some here would be interested to read about this: >>> >>> http://www.nihamkin.com/2016/11/23/writing-linux-modules-in-ada-part-1/ >>> >>> https://github.com/alkhimey/Ada_Kernel_Module_Toolkit >>> >>> >>> Any kind of criticism is welcomed. >> >> This is a fascinating concept. It would make sense, given how security >> and stability focused Ada is. I wonder how Ada and Rust would compare on >> various aspects. >> > > I would say that Rust is a relatively recent newcomer in the large > family of languages that try to remain C-like while addressing the main > flaws of C and C++, and bringing a couple of nice functional features > from ML along the way, whereas Ada has a more original take on language > design. > > For an example, consider integer types. In Rust, you are expected to use > signed or unsigned integer types with power-of-2 sizes ranging from 8 > bits to 64 bits. To a C99/C++11 developer, that's nothing new: they > essentially took the sized int types from stdint.h and made them the > default because they are much more portable than the legacy > short/int/long trio. > > In contrast, Ada tried to go further by decoupling the interface of > integers from their implementation. When you define an integer type in > Ada, you specify its range and leave it up to the implementation to > decide which machine type will be used. This design leaves more room for > hardware-specific compiler optimizations, like C's legacy short/int/long > types, while still remaining perfectly portable. > > Cheers, > Hadrien Fascinating! I didn't know that about Rust.