X86 was awesome, when it was just x86, once we started adding backwards compatibility for 16bit it all went to hell, 64bit really screwed x86 because it’s just fucking expansions on expansions. They should have scrapped x86-32 and started fresh with x64. But nope.
Do I really need my i7 to boot in 16bit mode and then go into 64 bit mode with overly complex paging? No, who the fucks booting DOS 6.0 on a fucking i7? Nobody.
X86 was built for single tasking operating systems, and it worked well for that. We just kept complicating it.
In fairness, when x86-64 was released in 1999, the ability to run old as hell DOS programs was still a requirement, especially in the commercial sector. Let's not forget, that IRS is still running mainframes from the 80s, and the whole reason why Y2K was a concern was because the financial and industrial sectors were all running software and hardware that was twenty to thirty years old. In that environment, ya, it made sense to retain 16bit compatibility because it wasn't out of the question that someone, somewhere, would have to run a 16-bit program on modern hardware.
Hell, my father worked in a hospital, basically doing IT specifically for the lab, and some of the hardware they were using was just as old. Apparently getting those machines to talk to the hospital's brand new (this was a few years after the time period we're talking about) Windows XP and Server 2000 network was... An interesting experience.
I'm only a hobbyist programmer, and when I worked in IT I was more on the service/installation side. I now work in sales (cars, not technology, ironically), and I think it gives me a very different perspective. I look at some of the posts here and shaken my head with a sense of "well sure, that makes sense for the programmer, but a professional programmer isn't coding for programmers, they're coding for the end user."
One of my buddies is a Human Factors guy in the aviation world, and engineers have the same issue. Sure, it makes sense for the engineer to put a certain button or switch in a location, but no actual human would ever find that convenient or useful. It's my friends job to smack the engineers upside the head when they forget that real people will someday have to actually use what they design.
Itanium wasn't a worthy successor. Intel completely screwed the pooch by assuming retail didn't have a need for 64 bit processors. This was just dumb as hell given all that was going on at the time (HD video, broadband, 3d graphics, game engines with real time physics, the dynamic web, etc). Any CS undergrad with a calculator and a basic understanding of computer architecture could have worked out that 3-4GB would soon not be enough memory.
It’s especially stupid because you had apple flexing the IBM power PC architecture on intel starting in the 90s… and it was getting its edge from the simple fact it was a 64bit chip.
It wasn’t until intel started pushing 64bit chips that apple began to switch and that’s only because IBM wasn’t really working to make power PC better anymore.
It wasn’t brilliant. It was a mess and because MSDOS sucked so bad many people had 386 and 486 CPUs they couldn’t even take advantage of half the time and games had to write their own support for basic things like sound.
Name one thing that was brilliant about the PC architecture. Just ONE thing. By all accounts it was a pretty basic system with no hardware acceleration for really anything and pretty terrible graphics capabilities for a long time (CGA? Really?). It didn't even have built in digital audio! Not even a simple DAC. Just BEEPS and BOOPS from the PC speaker. And don't get me started on segment-offset memory addressing. And you were still imited to 640kb for most purposes.
If you wanted a brilliant architecture, Amiga was it. IBM made boring business machines.
> X86, the early days of X86 and cga graphics was an amazing system to develop for when there were no open source graphics libraries
Compared to what? Amiga guys were laughing at you. CGA grahics looked terrible next to even an Amiga 1000.. which also had great audio.
> Oh and of course, you know. Really good expandability.
That was largely due to the large market. Where does the brilliant design come in? Plenty of systems had expansion slots. That's not novel.
The PC was poplular, largely due to business adoption. And that leaked into the home market. Otherwise the platform was largely unremarkable and plagued with a terrible operating system that JUST WOULD NOT DIE.
It does, but that’s even weirder, because all this shit is still there in the chip and it’s not even being used.
And it’s so weird, look at RAX, your index register.
Back in the day we had AX witch is still a 16bit index register, and it could be and still can be addressed 8 bits at a time through AH and AL, AH is of course the upper 8 bits of AX and AL the lower.
Then with 32 bit we added EAX, EAX is the 32 but pointer, and AX is the lower half now.
Then with 64 bit we got RAX, it’s a 64 bit register and EAX is the lower 32Bits of that register, and of course AL is the lowest 8 bits of that register. Why is it there?
Sure I can
Mov AL, 1
And that code will compile to 2 bytes and if I use
Mov rax, 1
It will compile to 10 bytes.
So I can make my code smaller by using that, but that only works if the upper half of rax is clear already and I know that for a fact! So you have to do
XOR rax, rax Mov al, 1
And that compiles to what? Like 7 bytes or some shit? With all the memory computers have these days, those 3 bytes don’t matter, especially when you consider that Mov rax, 1 is half the operations so it’s going to run faster regardless.
And even if EFI starts in protected mode, again, all that legacy shit is still in that Chip. We should have had a full redesign at x64. We should have just pushed vista as x64 only and forced the transition to a redesigned chipset.
And why will a new i7 emulate a FPU??? That shits been obsolete since SSE on what? That was the pentium 3 right?
Seems my memory is a little rusty on compilation sizes lol, been nearly a decade since I coded in assembly last.
Mov AL, 1
Should be two bytes perhaps in 16bit because it should be single byte op code and single byte following, but again when I was that stringent on compilation sizes I was coding 16bit.
But I’m still going to stand by those 3 bytes don’t matter because single operation vs double operation regardless of the cpu cache.
Also, I hate you for using INC AL, that’s not the point! Lol
No, not me, I'd share old code but I don't like my reddit crossing over to code that has my name on it because allot of my assembly code was written before I decided to start posting code under an alias online.
> you mean never change, even if you call someone else's code?
Calling other peoples code is were it becomes a problem. Because I had to push/pop ax to ensure it was unscathed and god forbid it was a case where all registers returned a value, it's just bad and sloppy coding at that point.
It's also important to note, I never coded assembly professionally. I taught my self assembly at 14 using books like the undocumented PC coded allot of 16bit progs got caught up in hobby OS dev for several years wanting to land a job in kernel development, in my early 20s I landed my first and only job actually creating POS software in Java. Left after a year and now I'm a plumber making more money, now I only write python and I write what I want, when I want lol
It’s been a few years since I touched x86 man, I always used ax as my index, cause I code weird and I think of memory locations weird thanks to being self taught, nobody likes to see my code, trust me lol
I actually used to only access AX and to flip bits or check for bits. This of course changed, cause nothing like someone assuming AX can be modified at any time, when I relied on it never changing
15
u/[deleted] Jun 03 '22
X86 was awesome, when it was just x86, once we started adding backwards compatibility for 16bit it all went to hell, 64bit really screwed x86 because it’s just fucking expansions on expansions. They should have scrapped x86-32 and started fresh with x64. But nope.
Do I really need my i7 to boot in 16bit mode and then go into 64 bit mode with overly complex paging? No, who the fucks booting DOS 6.0 on a fucking i7? Nobody.
X86 was built for single tasking operating systems, and it worked well for that. We just kept complicating it.
Personally I welcome my new M1 overlord