Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I’ve always wondered what your first paragraph would look like, if it was shifted into the actual visible address space. I’m imagining a bit like white noise static but with colour? Anyone tried it and had a screenshot?


Kind of, ASCII isn't really random. You can give it a try yourself in your terminal:

  $ text="Back in the day, one of IBM's early databases worked by storing memory into the graphics buffer, outside the field of view of the monitor, because writing directly to that memory space was faster on the hardware than anywhere else. (My dad wrote it when working for National Mutual)." && printf "P6\n$((${#text} / 3)) 1\n255\n$text" > test.ppm
The result is kind of dim because none of the characters are greater than 0x80. You can brighten it by changing the 255 to, say, 127.

The resulting file should open in most image viewing programs, though somewhat amusingly while writing this I messed up the format accidentally found a denial-of-service in Apple's ImageIO NetPBM parser :P


The effect of seeing a program run in visible video RAM was actually pretty common on the C64.

Memory was really tight and every byte was valuable. Also external memory was slow. Programs were often loaded in a compressed form and then uncompressed. Since the uncompressed version filled the available memory to the last byte it raised the question where to put the unpackers code.

A natural choice was to run it from video ram, which would be overwritten when the game started and the unpacker was not needed anymore. As slow as the C64 was, you could clearly identify the unpackers loop counters.

I have also heard the story that this trick was especially popular for pirated games. The crackers used to add their intros and they had to fit in somewhere into already filled to the brim memory. So they used compression to squeeze their intros in.


There's a lot of 0s for preallocated space. And all-0 bitmap is just white. So mostly like white snow, with pickles of random colours in short blocks here and there, for headers.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: