The reason for that is that demo programming is the coding equivalent of watch making: extremely precise, technical work that takes deep knowledge and long hours to achieve something notable. Knowing your tools and platform inside out is a necessity - and the more modern your CPU/GPU are, the less realistic that is. When I was writing assembly for my 8MHz z80, I could easily hold the full instruction set + CPU register layout etc in working memory. When you're working on a modern i7 + GTX780, that's pretty much impossible, and you have to resort to abstraction layers and tools that inevitably lead to the situation described by the author of the article. It's a classic case of extreme restraints working in the favor of creativity.
Interestingly enough, my few friends who are still into coding demos don't do it on modern architectures - they're mostly sticking to the C64.
The demoscene is an international computer art subculture that specializes
in producing demos: small, self-contained computer programs that produce
audio-visual presentations. The main goal of a demo is to show off
programming, artistic, and musical skills.
Basically, these programs are extremely small, but produce interesting and impressive visual or audio experiences. A popular example would be "fr-041: debris. by farbrausch": https://www.youtube.com/watch?v=mxfmxi-boyoThe point is, too many people don't spend any* time thinking of how what they write is inefficient or not... Even mobile devices are becoming mobile powerhouses. It's a bit of a shame really.
We still advocate going down to A lower language for the fast boys, but we can more or less forget about having to write ASM for all but the most complicated algorithms.
We still fight platform differences, and DirectX is still one of the most powerful and developer friendly frameworks.
Low level knowledge is still mocked by some individuals, yet C++ is still the God of graphics and video games.
DirectX was interesting in that age because of exactly the thing in article: you can allocate sound buffer and one surface and view that two COM objects as hardware and not care much about performance implications of the abstraction in between. Once you start drawing to (to borrow X11 terms, as I'm not too familiar with GDI/DirectX) IndexColor surface that is shown on TrueColor display, you get slowdowns in the abstraction layer on the order of "2005 highend Windows NT workstation renders at 2FPS what random office computer from '94 on DOS rendered at 60FPS" (see OpenTTD for example of exactly this performance regression).
For last 25 years hardware acceleration for graphics is readily available for all performance tiers but still, you need to have quite low-level understanding of how the hardware works to get reasonable performance (and as for working-around hardware and driver bugs, we are currently in mostly same situation as 25 years ago and it was better in the meantime).
Except, you know, that part about running on the open web. The web is a deployment platform. Developers want to write the least amount of code to be able to support the most users possible. That was supposed to be Java, but it didn't work out that way. Deployment is still a platform-specific issue in Java, because users--for whatever reason--hate WebStart and its ilk. Add to that the fact that smartphones just plain don't support Java in that way and suddenly the browser makes for the only pragmatic cross-platform toolkit for building applications.
Yeah, JS sucks. Yeah, DOM sucks. Objectively, they are terrible. But for as bad as they are, there aren't any good alternatives. And no, building from source is not an alternative.
I don't know about you, but I'd much rather write a simple web service application in python than in assembly.
(this has to do with both performance as with various walled gardens that do not allow general purpose scripting)
For those not in the demoscene, this is written by one of the members of the demogroup Farbrausch:
http://en.wikipedia.org/wiki/Farbrausch
I think this is one of their most impressive demos:
also, ryg from Farbrausch (who works for RAD Game Tools) blogs regularly [2]. A story about their crazy .kkrieger code sprints at [3] (submitted about a year ago [4])
[1] http://www.pouet.net/prod.php?which=12036
[2] https://fgiesen.wordpress.com/
[3] https://fgiesen.wordpress.com/2012/04/08/metaprogramming-for...
In the menu at the start, cursor-down works,
but cursor-up doesn’t (he never hit cursor-up
in menus during the test run).
The small enemies at the start can hit you, but
he didn’t get hit by any enemy shots, so in the
released version of .kkrieger enemy shots deal
no damage.Super cool, and in an executable of 177kB.
> 111398, г. Москва, ул. Перовская, 20
Found the vegan :)
A minor but important point in its favour is that it didn't require a Gravis Ultrasound, those things were annoyingly expensive.
A lot of friends who were devs got free Gravis boards by writing to Gravis directly which is why so many demos and shareware supported it.
the principles remain good though, basically
* know your shit
* measure your work and make sure you really do know your shit
i do constantly cry and bleed inside over the tremendous waste of bountiful computing resources we have today. someone once tried to tell me an xbox 360 was a memory constrained environment... jesus wept.
Depends on what one is used to and what needs to be done. If you're used to PCs that have at least as much GPU RAM and bandwidth as an entire 360, then sure, a 360 is memory constrained.
Like everything else, this has changed as we've gotten closer and closer to photorealism and games that are glorified tech demos constitute less and less of the overall market; the current generation consoles have substantially changed their profile to generalize and be more like PCs - the 360 had only 512MB at a time where gaming PCs were going for 1-2GB, while Xbox One and PS4 are roughly in the same ballpark(5GB and 8GB) as current-spec gaming PCs.
I think the anti-intellectual aspersions cast towards computer science students is a good indicator of this. The techniques he holds dear are only possible because of computer science. Computer Science is a field of applied mathematics that some people dream will one day be treated like a field of theoretical mathematics, to gain standing and respect in the world of mathematics that traditionally looks down upon the applied fields like CS, statistics, cryptography, etc., in much the same way that "aht" artists look down on illustrators. I think he writes off an entire field of study just because occasionally, specific people--caught in this cultural divide between applied and theoretical mathematics--write some shitty code.
Let's see him come up with IEEE floats on his own. Let's see him conceive of 2's compliment signed integers on his own. Let's see him come up with an assembler on his own. Without prior exposure to the concept.[1] You don't get Dijkstra's path finding algorithm with an ivory-tower attitude that doesn't care about the practicalities of implementation.
It's not like people are or were getting paid to do this. People did it for fun. If you don't like something that people do for fun, just walk away. The reason these things happen, that we see "bad" examples is not because people are getting worse at doing this stuff, it's because new people are finding it easier to get started. Angry diatribes like this are just attacks at new people when they need encouragement and guidance.
[0] Well, to a degree. His field is "clever hacking of X86 assembly". A similarly "clever hacking of dynamic programming languages" exists that necessitates completely different techniques. I'm reminded of the 30-LOC spreadsheet in JavaScript that showed up about a year ago: https://news.ycombinator.com/item?id=6725387
[1] I'm reminded of a joke. Some years in the future, a man goes to God and says, "God, science has progressed so far that we don't need you anymore." God smirks a little and replies, "Oh really?". Man says, "Yeah, and to prove it, I challenge you to a duel. Anything you make, I will make, too." And God answers, "Okay, well, how about a man?" And the man replied, "No problem. We know chemistry and biology and genetics, we can synthesize everything we need to make a man." He bends down and starts to pick up some dirt and some other materials to start making amino acids when God interrupts him, "Hey now, go get your own dirt."
> [0] Well, to a degree.
Well, parts of the high level strokes are anyways. Nowadays his inline assembly block example is likely to just interfere with the optimizer's own code analysis and do more harm than good.
The time spent suggesting trivial rewrites that optimizers are now capable of doing on their own would be better replaced with discussing how the CPU cache or branch prediction works, and it's implications.
Any modern discussion of optimization worth it's salt would mention profiling - entirely lacking here.
But that's the nature of our job. We have to constantly be learning new things. If we don't, we end up wasting time screaming at newbies in their sputtering jalopies for "doing things wrong" as they pass us by.
At least as far as the assembler, well, that's something that anybody who is sick of hand-keying in machine code and patching up addresses will probably think of.
As for the rest--well, modern CS folks (nor electrical engineers!) aren't coming up with 754 or 2's complement either.