* Writing Linux Kernel Modules in Ada
@ 2016-10-23 13:49 artium
2016-10-24 11:12 ` Brian Drummond
2016-10-29 2:19 ` Coyo T Stormcaller
0 siblings, 2 replies; 15+ messages in thread
From: artium @ 2016-10-23 13:49 UTC (permalink / raw)
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.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-23 13:49 Writing Linux Kernel Modules in Ada artium
@ 2016-10-24 11:12 ` Brian Drummond
2016-10-29 2:19 ` Coyo T Stormcaller
1 sibling, 0 replies; 15+ messages in thread
From: Brian Drummond @ 2016-10-24 11:12 UTC (permalink / raw)
On Sun, 23 Oct 2016 06:49:14 -0700, artium 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.
Interesting work, I've thought about trying it in the past.
One small nitpick : It's not November yet...
Try
http://www.nihamkin.com/2016/10/23/writing-linux-modules-in-ada-part-1/
-- Brian
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-23 13:49 Writing Linux Kernel Modules in Ada artium
2016-10-24 11:12 ` Brian Drummond
@ 2016-10-29 2:19 ` Coyo T Stormcaller
2016-10-29 14:11 ` Hadrien G.
1 sibling, 1 reply; 15+ messages in thread
From: Coyo T Stormcaller @ 2016-10-29 2:19 UTC (permalink / raw)
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.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 2:19 ` Coyo T Stormcaller
@ 2016-10-29 14:11 ` Hadrien G.
2016-10-29 20:16 ` Simon Clubley
2016-10-29 21:09 ` Coyo T Stormcaller
0 siblings, 2 replies; 15+ messages in thread
From: Hadrien G. @ 2016-10-29 14:11 UTC (permalink / raw)
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
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 14:11 ` Hadrien G.
@ 2016-10-29 20:16 ` Simon Clubley
2016-10-29 21:12 ` Coyo T Stormcaller
2016-10-29 21:09 ` Coyo T Stormcaller
1 sibling, 1 reply; 15+ messages in thread
From: Simon Clubley @ 2016-10-29 20:16 UTC (permalink / raw)
On 2016-10-29, Hadrien G. <knights_of_ni@gmx.com> wrote:
>
> 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.
>
In addition, Ada has the advantage of actually being readable.
Simon.
--
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980s technology to a 21st century world
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 14:11 ` Hadrien G.
2016-10-29 20:16 ` Simon Clubley
@ 2016-10-29 21:09 ` Coyo T Stormcaller
1 sibling, 0 replies; 15+ messages in thread
From: Coyo T Stormcaller @ 2016-10-29 21:09 UTC (permalink / raw)
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.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 20:16 ` Simon Clubley
@ 2016-10-29 21:12 ` Coyo T Stormcaller
2016-10-29 21:25 ` Simon Clubley
0 siblings, 1 reply; 15+ messages in thread
From: Coyo T Stormcaller @ 2016-10-29 21:12 UTC (permalink / raw)
Simon Clubley wrote:
> On 2016-10-29, Hadrien G. <knights_of_ni@gmx.com> wrote:
>>
>> 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.
>>
>
> In addition, Ada has the advantage of actually being readable.
>
> Simon.
>
Looking over code examples, I do notice that I can immediately understand
what's going on in Ada, even if I have to guess at some of the conventions.
I want to say Python is very slightly more readable, but I'm not sure if
that's simply because I'm actually decent at Python, or if I was always able
to read Python before learning how to program in it.
Both Python and Ada seem infinitely more readable than C, which is often
only readable with heavy commenting. I've gotten better at
reading/programming in C, but not all programs have lots of helpful comments
in the source code.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 21:12 ` Coyo T Stormcaller
@ 2016-10-29 21:25 ` Simon Clubley
2016-10-29 22:09 ` Dennis Lee Bieber
2016-10-29 22:54 ` Jeffrey R. Carter
0 siblings, 2 replies; 15+ messages in thread
From: Simon Clubley @ 2016-10-29 21:25 UTC (permalink / raw)
On 2016-10-29, Coyo T Stormcaller <coyo@darkdna.net> wrote:
> Simon Clubley wrote:
>>
>> In addition, Ada has the advantage of actually being readable.
>>
>
> Looking over code examples, I do notice that I can immediately understand
> what's going on in Ada, even if I have to guess at some of the conventions.
> I want to say Python is very slightly more readable, but I'm not sure if
> that's simply because I'm actually decent at Python, or if I was always able
> to read Python before learning how to program in it.
>
> Both Python and Ada seem infinitely more readable than C, which is often
> only readable with heavy commenting. I've gotten better at
> reading/programming in C, but not all programs have lots of helpful comments
> in the source code.
Actually, I was thinking about Rust when I said that which I find
to be more unreadable than C (and even C++).
On the plus side, at least Rust is more readable than TECO. :-)
My readable scale (left to right for readable to less readable):
Ada > C > C++ > Rust > TECO
(Knowledge of the last one is as the result of a certain career
development path and I don't expect you to know the language. :-))
Simon.
--
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980s technology to a 21st century world
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 21:25 ` Simon Clubley
@ 2016-10-29 22:09 ` Dennis Lee Bieber
2016-10-29 22:48 ` Simon Clubley
2016-11-19 18:15 ` Dirk Heinrichs
2016-10-29 22:54 ` Jeffrey R. Carter
1 sibling, 2 replies; 15+ messages in thread
From: Dennis Lee Bieber @ 2016-10-29 22:09 UTC (permalink / raw)
On Sat, 29 Oct 2016 21:25:27 -0000 (UTC), Simon Clubley
<clubley@remove_me.eisner.decus.org-Earth.UFP> declaimed the following:
>
>(Knowledge of the last one is as the result of a certain career
>development path and I don't expect you to know the language. :-))
>
I think I spent a trimester with TECO during my operating systems class
in the late 70s.
I think I'd rather program the basic ED editor on the Amiga via
AREXX...
--
Wulfraed Dennis Lee Bieber AF6VN
wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 22:09 ` Dennis Lee Bieber
@ 2016-10-29 22:48 ` Simon Clubley
2016-11-05 22:31 ` artium
2016-11-19 18:15 ` Dirk Heinrichs
1 sibling, 1 reply; 15+ messages in thread
From: Simon Clubley @ 2016-10-29 22:48 UTC (permalink / raw)
On 2016-10-29, Dennis Lee Bieber <wlfraed@ix.netcom.com> wrote:
> I think I spent a trimester with TECO during my operating systems class
> in the late 70s.
>
> I think I'd rather program the basic ED editor on the Amiga via
> AREXX...
:-)
I used TECO in my youth for a few years because I started on PDP-11s
but thankfully I have not had to use it for over a couple of decades...
Anyway, back to the subject at hand. :-)
It would be nice to see more examples about using Ada within Linux
(and maybe even *BSD) kernel modules and if the OP wishes to continue
with his research, I encourage him to continue to update us on
the results of that research.
Simon.
--
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980s technology to a 21st century world
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 21:25 ` Simon Clubley
2016-10-29 22:09 ` Dennis Lee Bieber
@ 2016-10-29 22:54 ` Jeffrey R. Carter
1 sibling, 0 replies; 15+ messages in thread
From: Jeffrey R. Carter @ 2016-10-29 22:54 UTC (permalink / raw)
On 10/29/2016 02:25 PM, Simon Clubley wrote:
>
> My readable scale (left to right for readable to less readable):
>
> Ada > C > C++ > Rust > TECO
There's no way C should be that close to Ada. More like
Ada > Pascal > Erlang > Python > FORTRAN 66 > BASIC > languages that will
compile/execute line noise
> (Knowledge of the last one is as the result of a certain career
> development path and I don't expect you to know the language. :-))
You're talking about the macro language of the TECO text editor? Certainly way
up there on the write-only scale.
--
Jeff Carter
"When danger reared its ugly head, he bravely
turned his tail and fled."
Monty Python and the Holy Grail
60
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 22:48 ` Simon Clubley
@ 2016-11-05 22:31 ` artium
2016-11-06 9:39 ` Simon Wright
0 siblings, 1 reply; 15+ messages in thread
From: artium @ 2016-11-05 22:31 UTC (permalink / raw)
On Sunday, October 30, 2016 at 1:49:04 AM UTC+3, Simon Clubley wrote:
> On 2016-10-29, Dennis Lee Bieber <*> wrote:
> > I think I spent a trimester with TECO during my operating systems class
> > in the late 70s.
> >
> > I think I'd rather program the basic ED editor on the Amiga via
> > AREXX...
>
> :-)
>
> I used TECO in my youth for a few years because I started on PDP-11s
> but thankfully I have not had to use it for over a couple of decades...
>
> Anyway, back to the subject at hand. :-)
>
> It would be nice to see more examples about using Ada within Linux
> (and maybe even *BSD) kernel modules and if the OP wishes to continue
> with his research, I encourage him to continue to update us on
> the results of that research.
>
> Simon.
>
> --
> Simon Clubley, *
> Microsoft: Bringing you 1980s technology to a 21st century world
Part 2, incorporating the secondary stack into the run time.
http://www.nihamkin.com/2016/11/05/writing-linux-modules-in-ada-part-2/
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-11-05 22:31 ` artium
@ 2016-11-06 9:39 ` Simon Wright
0 siblings, 0 replies; 15+ messages in thread
From: Simon Wright @ 2016-11-06 9:39 UTC (permalink / raw)
artium@nihamkin.com writes:
> Part 2, incorporating the secondary stack into the run time.
>
> http://www.nihamkin.com/2016/11/05/writing-linux-modules-in-ada-part-2/
Interesting!
What about elaboration? Have you considered the restriction
No_Elaboration_Code? (would it help?)
(On a purely personal note, I find heavy grey (and black) backgrounds
painful to read.)
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-10-29 22:09 ` Dennis Lee Bieber
2016-10-29 22:48 ` Simon Clubley
@ 2016-11-19 18:15 ` Dirk Heinrichs
2016-12-21 14:47 ` Lucretia
1 sibling, 1 reply; 15+ messages in thread
From: Dirk Heinrichs @ 2016-11-19 18:15 UTC (permalink / raw)
Dennis Lee Bieber wrote:
> I think I'd rather program the basic ED editor on the Amiga via
> AREXX...
Yeah, AREXX was fun. Speaking of Amiga: Anybody remember the Cluster
language?
Bye...
Dirk
--
Dirk Heinrichs <dirk.heinrichs@altum.de>
GPG Public Key CB614542 | Jabber: dirk.heinrichs@altum.de
Tox: heini@toxme.se
Sichere Internetkommunikation: http://www.retroshare.org
Privacy Handbuch: https://www.privacy-handbuch.de
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Writing Linux Kernel Modules in Ada
2016-11-19 18:15 ` Dirk Heinrichs
@ 2016-12-21 14:47 ` Lucretia
0 siblings, 0 replies; 15+ messages in thread
From: Lucretia @ 2016-12-21 14:47 UTC (permalink / raw)
On Saturday, 19 November 2016 18:15:05 UTC, Dirk Heinrichs wrote:
> Dennis Lee Bieber wrote:
>
> > I think I'd rather program the basic ED editor on the Amiga via
> > AREXX...
>
> Yeah, AREXX was fun. Speaking of Amiga: Anybody remember the Cluster
> language?
Nope, but I did do a lot of AmigaE.
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2016-12-21 14:47 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-10-23 13:49 Writing Linux Kernel Modules in Ada artium
2016-10-24 11:12 ` Brian Drummond
2016-10-29 2:19 ` Coyo T Stormcaller
2016-10-29 14:11 ` Hadrien G.
2016-10-29 20:16 ` Simon Clubley
2016-10-29 21:12 ` Coyo T Stormcaller
2016-10-29 21:25 ` Simon Clubley
2016-10-29 22:09 ` Dennis Lee Bieber
2016-10-29 22:48 ` Simon Clubley
2016-11-05 22:31 ` artium
2016-11-06 9:39 ` Simon Wright
2016-11-19 18:15 ` Dirk Heinrichs
2016-12-21 14:47 ` Lucretia
2016-10-29 22:54 ` Jeffrey R. Carter
2016-10-29 21:09 ` Coyo T Stormcaller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox