The historical transition from Assembly to higher level languages in demo programming
category: code [glöplog]
Historical transition from Assembly to higher level languages in demo programming...
On which platforms it has happened? When and why?
And why it didn't happen on other platforms.
Is something going on today regarding to this issue?
On which platforms it has happened? When and why?
And why it didn't happen on other platforms.
Is something going on today regarding to this issue?
Anything since early-mid 32bit computers when it made sense or even game development already started moving there partially in the early 90s?
Compilers got better, memory got cheaper, CPUs got faster (and caches got bigger as well as more transistors meant more complex dispatch pipelines got possible) and then it got possible to use higher level languages to write semi-efficient code.
There's obvious benefits on using higher level constructs to express algorithms and shit.
There's obvious benefits on using higher level constructs to express algorithms and shit.
Quote:
game development already started moving there partially in the early 90s
Wolfenstein 3D and Doom are mostly C with some assembly for hot loops.
Turbo-C was released 1987 - that pretty much marks the point in time when ppl started using C (with inline asm obviously) imho.
Turbo Pascal was also popular and supported inline assembly, so I guess there never was much reason to write in 100% assembly on PC, other than size-limited intros.
The situation was different on the Amiga, where the dominant Lattice/SAS C compiler didn't support inline assembly, and early demos were often made without a hard disk.
In short, I'd say it was mostly about what was possible and convenient on the platform.
The situation was different on the Amiga, where the dominant Lattice/SAS C compiler didn't support inline assembly, and early demos were often made without a hard disk.
In short, I'd say it was mostly about what was possible and convenient on the platform.
Even on the ZX Spectrum there were games that were written in compiled BASIC + assembly routines. And a contrary example - even in modern high performance software you can find parts (tiny compared to overall volume of code) written if not in assembly then using intrinsics, which is very close to assembly except for the register management.
The situation on Amiga in the 1980s was that you needed serious investments to program in C. I started with the K&R book and the Aztec C compiler, two disk drives and some serious RAM upgrade. You needed to master complex separate programs such as editor, shell, compiler. Getting into the "cool stuff" (hardware programming) in Assembler was easier and cheaper - mainly thanks to integrated tools like Seka assembler, very accessible 68000 and fewer hardware requirements.
Quote:
The situation on Amiga in the 1980s was that you needed serious investments to program in C. I started with the K&R book and the Aztec C compiler, two disk drives and some serious RAM upgrade. You needed to master complex separate programs such as editor, shell, compiler. Getting into the "cool stuff" (hardware programming) in Assembler was easier and cheaper - mainly thanks to integrated tools like Seka assembler, very accessible 68000 and fewer hardware requirements.
Interesting testimony. I didn't realise that, back then ... but now you mention it, I started C as a student in 1992 and got, quite easily, a free copy of SAS/C. I remember building times on my A1200 without a HDD were quite long, no to mention the disk swap... all this to compile a couple of basic C programs using only stdio.h :)
I can figure out how difficult it could have been 6 or 7 years earlier.
It was a lot of fun and a good idea to learn C on the Amiga, even with the disk swapping. I got the compiler as a "free copy" as well. But costs, time and dedication were considerable. It took me four to six weeks to work through the K&R. Hugely motivating and certainly a better book than the C64 manual which ended with the balloon sprite.
Inline assembly wasn't a problem really, you could mix C and asm modules from the beginning. However assembly+hardware coding was an even better fun package than C+serious programming. C felt more like it was in the way here.
Inline assembly wasn't a problem really, you could mix C and asm modules from the beginning. However assembly+hardware coding was an even better fun package than C+serious programming. C felt more like it was in the way here.
Far back in time (probably late 80s) I remember trying a Pascal compiler on a Z80 machine which required booting CP/M from two disks and the compiler from a third disk. Same procedure after every crash. Didn't make any sense.
Later (early 90s) on the PC all early Borland products (which were rather wide-spread and easy to get your hands on) were basically non-optimizing compilers (except very trivial loop-hole rules) which produced 286-code and every loop you did in assembly ran significantly faster.
That was a very motivating starting point for learning x86-assembly, though ;)
A radical change came with Watcom C which actually optimized, gave you 32 bits and protected mode and you had to make some effort to produce better code.
Later (early 90s) on the PC all early Borland products (which were rather wide-spread and easy to get your hands on) were basically non-optimizing compilers (except very trivial loop-hole rules) which produced 286-code and every loop you did in assembly ran significantly faster.
That was a very motivating starting point for learning x86-assembly, though ;)
A radical change came with Watcom C which actually optimized, gave you 32 bits and protected mode and you had to make some effort to produce better code.
.png)