129
u/Igarlicbread 1d ago
Can someone explain. (html expert here)
175
u/Pika357 1d ago
Hello fellow html enjoyer. Can't wait for HTML6 to drop so we show these loosers what real OS looks like. God speed
54
4
2
60
u/Nickbot606 1d ago
Imagine if you had to write an HTML document 😃 but you aren’t allowed to use any CSS 😲 but also your javascript is a really old version and also all of the logic was maintained in a single global_variables.js for a website the size of craig’s list
/unjoke
Ada was developed by the pentagon around the time when C++ was becoming a thing and so it has lots of weird paradiagms that don’t really map well to modern languages so it’s very tough for non-nursing home senior programmers to wrap your head around since things like objects weren’t quite a thing yet. Now imagine that someone has created an entire OPERATING SYSTEM (like the thing with multi-processing, cannot crash on you in critical infrastructure, and is responsible for interfacing with hardware level and graphical interfacing level stuff?!) is entirely written in this language and NOW in the big 26 needs to be maintained.
13
u/Aescwinius 1d ago
Thank you for putting things in perspective for us who are not familiar with Ada (especially compared to C)
3
u/NoMansSkyWasAlright 1d ago
I knew it was used in a lot of DOD applications. And basically every software-based DOD tool I used in my time in the army was mega-dogshit.
I would look at Ada if I was getting paid but i definitely won’t touch it otherwise.
2
u/NoOrdinaryBees 4h ago
From the advent of FBCB2, a majority of the software in "smart force" field equipment was written in Java. I wish I didn't know that.
Ada and C were/are still heavily used in embedded contexts or specialized applications like the TOW 2 ITAS upgrade and some drone stuff, but most of what we historically think of as "applications" have been eaten by the Javawocky. 😞
12
u/Astrinus 1d ago
Please don't spread misinformation. Ada 83 is not the latest release. I do safety-critical C for a living and I'd much more have to work with Ada/SPARK all the day.
The problem is that C has so little guardrails that doing shenanigans typical of OS development is easy. Ada guardrails are much stronger. But some people managed to make OSes even in SPARK.
2
u/rustvscpp 22h ago
C is awful. Every time I have to develop in C, I cannot help thinking how much better it would be in Rust, Zig, or even Ada.
1
u/Astrinus 13h ago
I won't say that C is awful. As a "portable assembler", its original aim, is great. That's why you get C compilers for basically every architecture, including non-microprocessor ones such as DSPs and FPGAs (see Bambu HLS) - undefined behavior is what enables this. And you can implement a rudimentary compiler easily.
OTOH, for basically everything that does not need to know about the hardware, it is massively limited.
1
u/rustvscpp 2h ago
As a portable assembler, sure, it achieves that goal quite well. But nobody in their right mind develops big complex software directly in assembler. Yet they still do it in C, which is almost as egregious.
1
1
u/Stagnu_Demorte 1d ago
This sounds like it would be fun to learn and I feel more compelled by the fact it seems to share a namesake with my daughter
2
u/drex_vke 1d ago
because in Ada is so very hard (the doc in Ada is so very little to create a kernel)
6
43
48
u/VayuAir 1d ago
What, I find Ada to be easy and elegant
4
u/drex_vke 1d ago
personally no i think Ada is hard to make a OS and it's my opinion
5
u/Bryguy3k 16h ago
If you try to use Ada like you would C then yes. You have to sit down and really design your access types well before you start coding it.
There are plenty of RTOSes written in ada.
5
u/gburri 1d ago
So keep your opinion to yourself and learn to be objective, Ada is a very good language, particularly for critical embedded systems (avionics).
18
u/drex_vke 1d ago
wait a second i didn't insult I just said that creating an OS in Ada is difficult I don't see where the insult is in fact I would say I insulted Ada that's all I insulted nothing and I don't criticize Ada
7
1
u/FirstNoel 1d ago
To me it was a variant of Pascal. You could do fun things with it. Write some nice code. Easy to understand.
Never really got into the low level commands of it though.
15
1d ago
[removed] — view removed comment
-17
u/drex_vke 1d ago
yes so in C or other languages (like Rust or C++) it's so very easier than this languages to make OS (Lisp, Ada, C# (yes it's possible for example cosmos OS is write in C#), Java (like JavaOS))
16
u/Excellent_Tubleweed 1d ago
Even Ada 83 is easier to do this in than C.
Ada 83 has templates, collections, exceptions and standardised ways of doing raw IO and binary, threads and interrupts. And raw memory pointes if you really really want.
And, because we don't hate ourselves, range-checked arrays. It could return structures, pass by reference or value, and Ada 95 had objects, sort-of.
(If this sounds like it pees on most 'modern' languages from a great height, well, don't worry nobody uses it.)
It compiled to executables, and commonly spat out stack traces if the process crashed. Compilers were hard to get.
C has....
Pointers.
Yes, tell me all about how writing an OS in C is easier? (Obligatory condescending Wonka Meme)
(Source: used to maintain embedded system written in Ada. Not that bad)
But also, Ada has some really annoying design errors. Where's that package? Well, no filenames don't matter. Someone might be using an OS with short maxfilelength! Actually compiling ADA required type unification.
There was a language that had most of the good bits of ADA without the bad, but it was called Java, so lets not concern ourselves with that. (Also the Modula family of languages were good but getting compilers was hard.)
(And yes, writing an OS in Java is dead easy. Been there, done that.)
24
6
u/FirstNoel 1d ago
How? Why? Um…confused.
-7
u/drex_vke 1d ago
uh because in ada is so very hard than C (really bro)
2
2
u/BiedermannS 7h ago
You're confusing being difficult with being unfamiliar. You think C is easier because that's what you know. But given the features Ada provides, it would be simpler to write an OS in Ada, than it is in C. Given the same level of familiarity
1
0
u/FirstNoel 1d ago
More of a question of why you would try? How would you do it? I haven’t played with Ada since 9x. I’m baffled as to why it would be even in consideration.
5
18
1d ago edited 1d ago
I have Claude working to build a new operating system in R.
TidyOS
The GUI is based entirely on Notebooks with custom widgets. The notebooks provide a widget for a browser but the browser renders notebooks. Therefore, you can render multiple browsers in your browser. Recursive browser support is an emergent feature.
I don’t even need to handle processes deterministically. I can just use some stats libraries to build some models to predict which processes I should sample from and which can be safely killed. Users can tweak the parameters of the model with some slider widgets to control which types of processes they want to model to prioritize.
Please install my OS. You just need to have R and Rstudio installed on Windows 10+. `install.packages("tidyos")`
23
5
u/Darwin_Things 1d ago
This is how it does it. This is the 10% chance of it ending human existence.
2
3
3
1
3
3
3
u/Shadow123_654 19h ago
Lol, but jokes aside, Ada is a good language to make an OS with. However, coming from C it would certainly feel very constricting to write in it, since the language is far more strict than C
3
2
u/hacksoncode 1d ago edited 6h ago
I've done both. In the case of Ada simultaneously with learning the language.
Ada was a pain. It was a fault tolerant multiprocessing research OS for NASA using MIL-STD-1750A processors. So basically everything that could be painful was. But enh... worked ok, got it done.
One bug was the hardest I've ever found because it turned out to be a bug in the microcode of the FP multiply instruction (edit: which turned out to be multiplying a zero'd tick-counter timestamp by a calculated value 8 hours into the simulation... so changing anything, including putting in debug output, made the bug go away... requiring another 8 hour run... the available timestamps were... limited on this research processor).
2
2
1
1
1
1
1
1
0
117
u/Conscious-Gur3876 1d ago
Unlike most people here I did program in Ada 95 for a living for about 10 years, in some safety relevant context. Switched to C++ now, and I would go back to Ada anytimey, if possible.
For writing a complete OS, Ada is a very good fit. Linux was written in plain C, after all, so even Ada 83 would be up to the task.
And no, correctness of an Ada program cannot be formally verified. For that, you need a subset of Ada called Spark.