Free Republic
Browse · Search
General/Chat
Topics · Post Article

Skip to comments.

International Obfuscated C Code Contest Winners Posted
hackaday ^ | January 4, 2014 | Brian Benchoff

Posted on 01/05/2014 1:29:47 AM PST by Bobalu

One of the most impressive entries for this (last?) year’s contest is a tiny 8086 PC emulator/virtual machine written in only 4043 bytes of code. It’s a fully functional 80s-era PC emulator that can run vintage copies of AutoCAD, Windows, Lotus 1-2-3, and SimCity.

(Excerpt) Read more at hackaday.com ...


TOPICS: Computers/Internet
KEYWORDS: obfuscated
This odd contest is always amazing.

The entries are harder to read than a long Free Republic post without paragraphs :-)

1 posted on 01/05/2014 1:29:47 AM PST by Bobalu
[ Post Reply | Private Reply | View Replies]

To: Lazamataz

Ping


2 posted on 01/05/2014 1:31:29 AM PST by FreedomPoster (Islam delenda est)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Bobalu

Link to the 8086 emulator entry
http://www.ioccc.org/2013/cable3/hint.html


3 posted on 01/05/2014 1:35:58 AM PST by Bobalu (The true secret to genius is in creativity, not in technical mechanics)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Bobalu

Now THAT’S efficient code!


4 posted on 01/05/2014 1:51:50 AM PST by ArmstedFragg (hoaxy dopey changey)
[ Post Reply | Private Reply | To 3 | View Replies]

To: Bobalu
I occasionally go overboard with nasty nested indexes to give things like this: –64[T=1[O=32[L=(X=*Y&7)&1,o=X/2&1,l]=0,t=(c=y)&7,a=c/8&7,Y]>>6,g=~-T?y:(n)y,d=BX=y,l]

LOL!

5 posted on 01/05/2014 2:44:07 AM PST by Talisker (One who commands, must obey.)
[ Post Reply | Private Reply | To 1 | View Replies]

To: Bobalu
This hack must be some slick code.

Back in the day I remember doing a class assignment to write a Z80 emulator that ran on a CDC Cyber 7600 in COMPASS assembly language. It took most of a semester and took a lot more than 4 KB to run.

6 posted on 01/05/2014 4:58:42 AM PST by InABunkerUnderSF (Because two terms with Jerry Brown with governor was all I could take.)
[ Post Reply | Private Reply | To 1 | View Replies]

To: InABunkerUnderSF

Wow, COMPASS assembly language. I took a class in COMPASS back in 1981. Those CDC machines were pretty fast for their time, and I think the one we used had a 60 bit word size, which was different.


7 posted on 01/05/2014 5:08:29 AM PST by Stevenc131
[ Post Reply | Private Reply | To 6 | View Replies]

To: InABunkerUnderSF

4k is the max allowed length of C source code for the contest.

This weighed in at 4043 bytes of C source.

No idea what it compiles to.


8 posted on 01/05/2014 5:09:31 AM PST by Bobalu (The true secret to genius is in creativity, not in technical mechanics)
[ Post Reply | Private Reply | To 6 | View Replies]

To: Stevenc131

60 bit FIXED WORD LENGTH (bytes? what’s bytes? :o) When I took the class I’d already been programming in 808x assembly languages for a couple of years. It was not an easy transition. Fortunately I never had to make a living programming in COMPASS.


9 posted on 01/05/2014 5:19:03 AM PST by InABunkerUnderSF (Because two terms with Jerry Brown with governor was all I could take.)
[ Post Reply | Private Reply | To 7 | View Replies]

To: Bobalu

Unfortunately, 4043 bytes would be too big for my first PC. It was a Digital Equipment corp. PDP-11S, which had only 4096 bytes of core memory (albeit, they were 12 bit bytes). Adding the 17 byte bootstrap loader, would leave only 36 bytes for some kind of output device driver and formatting for it. At best, it would only output a string of numbers on a teletype.


10 posted on 01/05/2014 5:23:19 AM PST by norwaypinesavage (Galileo: In science, the authority of a thousand is not worth the humble reasoning of one individual)
[ Post Reply | Private Reply | To 1 | View Replies]

To: norwaypinesavage
A good ol DEC. Once an all powerful multi-billion dollar company. Now just a memory the remnants of which are at HP.

The company that was never fully committed to the PC. Actually, IBM wasn't either.

11 posted on 01/05/2014 10:55:08 AM PST by dhs12345
[ Post Reply | Private Reply | To 10 | View Replies]

To: Bobalu

I’ll bet it can run Obamacare better than what the feds came up with.


12 posted on 01/05/2014 3:59:09 PM PST by Organic Panic
[ Post Reply | Private Reply | To 1 | View Replies]

Disclaimer: Opinions posted on Free Republic are those of the individual posters and do not necessarily represent the opinion of Free Republic or its management. All materials posted herein are protected by copyright law and the exemption for fair use of copyrighted works.

Free Republic
Browse · Search
General/Chat
Topics · Post Article

FreeRepublic, LLC, PO BOX 9771, FRESNO, CA 93794
FreeRepublic.com is powered by software copyright 2000-2008 John Robinson