Ethin wrote:kerravon wrote:Ethin wrote:Sorry, but I call BS about how your GCC version is supposedly superior. Particularly since you can't even take advantage of LTO or utilize more modern ISA features that have been introduced since 3.2.3. Can you even compile the latest Linux kernel with that fossil? Saying that your "superior product" is better than a modern GCC is incredibly arrogant and presumptuous of you.
My understanding is that the OP is trying to compile his own OS, not Linux. If Linux is C90-compliant it should compile on my GCC. I have no idea whether Linux is or not. I do know that my own OS is, so it works perfectly fine with my GCC.
I feel like your deliberately missing the point or trying to alter the narrative here with statements like this. Your not actually answering the question.
I believe I have answered every single one of your questions.
kerravon wrote:
Furthermore, Your code in 1990 C can be perfectly fine but still introduce undefined behavior or any number of other things.
I have no idea what you are talking about. My OS works fine. I don't know what further proof is required than that. That is the absolute litmus test. Not some theoretical disadvantage. Regardless, if you would like to make available a superior C compiler, that is C90-compliant so doesn't need the entire Unix baggage, and can be built using pdmake (ie not requiring "configure" which is a shell script that doesn't exist on Windows), that is great. Please point me to the source and Win32 binaries.
You do know that you have WSL now right? There is very little incentive for building an OS on Windows. The configure script isn't available for windows because, well, GCC wasn't made for Windows to begin with. You want a compiler that works on windows? I point you to LLVM/Clang.
Or I point you, and myself, to gccwin.
To your point about WSL - I don't know what that is and I don't care what it is. Certainly nothing by that name exists on PDOS/386, which is the environment I am most interested in. If someone adds that in the future, cool. Maybe I'll take a look at it. Maybe.
kerravon wrote:
That's what warnings and static analysis are for. GCC removed the S/370 target because nobody uses it. Emulation, perhaps, but there are very few, if any, S/370 computers in use in the real world.
Modern z/Arch computers run S/370 programs perfectly fine. Once again, GCCMVS 3.2.3 provides the best C compiler available for z/OS running on z/Arch.
And what do you define as "modern"? Last time I checked, S/370 and Z/arch had been discontinued over a decade ago. Therefore, not modern.
z/Arch has not been discontinued. z/Linux and z/OS still run on it today, and there is no easy way for the z/OS users to get off it, so they are stuck with IBM's monopoly. The first version of z/Arch has just gone out of any patents though, which may help.
kerravon wrote:
That's especially relevant considering that S/370 can't take advantage of all the technological advancements that ISAs have made since its inception. Even Linux dropped support for the majority of the old, deprecated processor architectures because maintaining them when nobody used them was a waist of time and that time could be spent on other things.
I don't consider old computers to be "deprecated".
I think that you'll find many people disagreeing with you on that point. Myself included. After all, you don't see AMD or Intel selling you 8086s anymore, do you?
No. But I was working with someone last night who was using an old computer that was working perfectly fine. But then she wasn't a bot trying to get fresh sales for AMD/Intel by insisting she stop working on her perfectly viable computer.
Kerravon wrote:
So, try again: how is your fork of GCC better than the up to date GCC which is actually receiving bug fixes, optimization improvements, security fixes, more modern language standards, quite good static analysis, and various other enhancements by experts in the field?
Because it works, instead of being a constant mess.
Again, I disagree. I don't find the cross-compilation setup to be a "constant mess" at all.
GCC has always been a mess. Finally someone has patiently sat down with a fork to make it a non-mess. That fork is now the most viable strain of GCC.
kerravon wrote:
I might be being harsh, perhaps, but telling someone to use GCC 3.2.3 -- or any ridiculously obsolete version of GCC -- is absurd.
It's not old or obsolete, it's less than a month old and in active use.
By whom, other than you?
Argumentum ad populum is a logical fallacy. Look it up. This is a question of technology, not who has the best marketing campaign to fool the most number of gullible people to upgrade their computers unnecessarily.
Its old and deprecated no matter how you spin it.
Nope. It's less than a month old, and produces executables, including itself that work almost anywhere. Nothing else comes close.
If it doesn't come on any software distribution anymore that's used by a large amount of users, its deprecated.
If you are using "deprecated" to mean "not popular", then that is true, so I will concede that.
If it isn't supported by its original authors, its deprecated and discontinued. Just because you maintain a fork of it does not alter that fact in any way.
Stallman still supports GCC does he? Ok, cool. Let's hope he never dies and the product becomes deprecated and discontinued.
kerravon wrote:
The *only* reason you should need to go back to such old software is if you want to target an architecture that isn't supported, and if its not, you should perhaps investigate as to why and reconsider your choice.
Or maybe you should reconsider your choice. Or maybe the OP should reconsider his choice. I've been considering my choice for 3 decades, and now have something I want, other than the fact that it isn't public domain, so will eventually try to replace it with something that is. It's just not the highest priority at the moment.
That's all fine and dandy, but stop throwing around misinformation, like a cross compiler being unnecessary.
kerravon wrote:
So, can you actually prove that your version of GCC is actually superior to GCC 11, especially given that your version doesn't even have LTO support?
Yes, mine works on both Freedos with HX and on PDOS/386. Out of the box. And is FAR more likely to work on the OP's OS than ANYTHING else.
Uh huh. And GCC 11 is just as likely to work on the OPs OS as well given that if they're on Windows they have WSL and if they're on Linux it just automatically works. You still haven't actually proved anything, other than making bold claims without any evidence.
Sorry for the confusion. The OP hasn't written his OS. As he develops it, my GCC will start working LONG before GCC 11 does. It's a far simpler product. And what I proved was that my GCC works on both Freedos/HX and PDOS/386. That much is beyond question.
kerravon wrote:
And can we stop perpetuating this nonsense about how a cross compiler is suddenly unnecessary for OS development?
It is not me who is perpetuating the nonsense. If you want to ask something, you can ask me why I didn't call BS on this nonsense long ago.
Yes, it is you and people who believe what you do who perpetuate the nonsense. The wiki explains quite clearly why a cross compiler is necessary. People like Korona have also explained why this is so. Throwing around supposed claims without proof does not change that.
kerravon wrote:
There's no reason other than pure laziness
No. A compiler is just a tool. You shouldn't need to get involved with it. It's not laziness. You should be working on your own OS, not the tools.
Who said anything about messing around with the compilers code? You hardly have to change anything in GCC to build a cross-compiler toolchain, and all of that can be trivially automated. Its still pure laziness.
kerravon wrote:
to not just do it now since you'll need it soon enough anyway.
No, you do not need it unless you are targeting a different processor, or changing the stack calling convention. The OP in this case doesn't appear to be doing either, so should have been given honest advice instead of being sent on a difficult road.
This is BS. If this is supposedly the case, then: why does SeaBIOS and Coreboot build a cross-compiler toolchain?
No idea. Maybe they were misinformed too. Or maybe their situation is different from both mine and probably the OPs. I can tell you that if you are using gccwin, and you suddenly have a desire to write your own OS, you can go right ahead with zero changes. Unless you want to change the stack calling convention. Or target a different processor.
After all, by that logic building firmware without a cross compiler should work perfectly fine. Why does my Rust toolchain build compiler-rt, core and alloc for my OS every time its built? After all, by that logic I should be able to use the ones that come with the compiler, right? Clearly, your wrong, because if you were right, people far more knowledgeable than you would've done what your claiming is possible long, long ago. You wouldn't need a cross-compiler for SEABios, or nasty hacks for OVMF to build. It would just "work".
gccwin "just works" for anyone who wants to build their own OS. If you insist on using an inferior product, or insist on being misinformed by these people who are supposedly more knowledgeable than me (I wonder what happens when these people boot up PDOS/386 and say "but isn't this impossible?"), or if you have some obscure situation, then please, go ahead and go down your necessarily difficult road.
When I see the OP's actual assembler output, I will be able to confirm that his existing compiler produces perfectly fine assembler suitable for building an OS, just as gccwin does. It's not that surprising.
Furthermore you go on to state that we're sending people down a difficult road. How, exactly, are we doing that? Building a cross-compiler toolchain for OS development is quite simple. The fact that it doesn't work on Windows is completely irrelevant, and always has been. And now that we have WSL its even more irrelevant.
If you think that processes that don't work on Windows, or Freedos, or PDOS/386, or the OP's new OS are "completely irrelevant", that's up to you and the OP to decide. I don't care. He's welcome to go and build 50 million cross-compilers for all I care. He needs 0 though. That's the only technical point I am interested in.
kerravon wrote:
So I still can't spot the logic behind "avoid a cross-compiler", unless you enjoy reverse-engineering your toolchain because it did something unexpected *every time* you update it.
It is not needed. It is a waste of time. Two good reasons from my perspective.
Alright then. Build SeaBios and Coreboot with a host compiler if its not needed. We'll see how far you get on that. Its computer firmware but the same cross-compiler infrastructure is necessary. So if its not needed you should be able to build it with your host GCC, regardless of whether its firmware or an operating system.
How about you build PDOS/386 instead? You're the one claiming that that is impossible. And give me a bit more time with the OP, and you'll see what he can do with his existing compiler. Then you can forward this chain to the Seabios people and say "hey guys, this might interest you".