logoalt Hacker News

Borland's DOS compilers, rebuilt from their own binaries

201 points • by frostbyte7 • yesterday at 12:51 PM • 78 comments • view on HN

Comments

elvis70 • yesterday at 7:53 PM

While we're at it: Commented disassembly of Turbo Pascal 3.01A for DOS: https://pcengines.ch/tp3.htm Commented disassembly of Turbo Pascal 3 for CP/M Z80: https://mark-ogden.uk/mirrors/www.cirsovius.de/CPM/Projekte/... Disassembly/leak of TURBO.EXE (IDE + Compiler) from TP6. Written in TP6 and assembly, but without comments.

➕ show 2 replies
noahbp • yesterday at 2:37 PM

This is going to be very helpful for any project to decompile binaries that were compiled with these compilers.

I'm working on something similar though shot of a full decompilation for Microsoft Visual C++, to trace and report the knobs to tune in the internal register allocation algorithm (among other things) to make reversing and decompiling binaries that were compiled with MSVC a much easier task: https://github.com/NoahBPeterson/c2scope

➕ show 1 reply
diavelguru • yesterday at 7:36 PM

OMG I wrote code for these compilers on a 286 back in '94. wow I took a C++ class and my final project was a checkers game. I ended up getting my first technology job due to a printout of that code!

humblefly • yesterday at 2:41 PM

Sincere question: why? Source like this is a notch better than raw decompiler output in the pre-AI era, but what's the expectation / use case?

    if((ES_B(_BX,MEMB_FLAGS)&3)==3) {
        _DI=ES_W(_BX,MEMB_VALUE);
        _ES=SYMBOL_POOL_SEG;ES_W(0,SYM_TYPE)=base;
        if(ES_W(_DI,SYM_FUNC_KIND)==2) {
            while(!TYPES_COMPATIBLE(TYPE_W(SYM_W(_DI,SYM_TYPE),TYPE_TARGET),TYPE_W(base,TYPE_TARGET),0)) _DI=SYM_W(_DI,SYM_NEXT_OVERLOAD);
        } else {
            while(!SAME_SIGNATURE(SYM_W(_DI,SYM_TYPE),base)) _DI=SYM_W(_DI,SYM_NEXT_OVERLOAD);
        }
        if(_DI==0) {_DI=_DI;goto next_param;}
I grant you that it's a thing you can do with agents, and it's impressive that it works, but once the tokens are spent, what does anyone get out of it? I guess I wonder if AI projects are becoming a bit of a "social proof of money spent".
➕ show 7 replies
codazoda • yesterday at 1:58 PM

I've been building a web based editor inspired by the Borland Turbo Pascal/Basic editors. It uses an optional GitHub token to save files directly to your repo. You can try it here:

https://codazoda.github.io/blue

➕ show 3 replies
saturn_vk • yesterday at 3:06 PM

What’s up with ai titles of the format:

Short description, adjective more description

➕ show 3 replies
Waraqa • yesterday at 2:21 PM

To clarify, 'rebuilt' in the title means reverse-engineered and reconstructed by AI.

➕ show 5 replies
smallerfish • yesterday at 2:24 PM

Watch the use of the word "own" - it's an AI giveaway.

owlstuffing • yesterday at 3:11 PM

Impressive. But the critical missing feature is a step in the process that transforms the resulting source into readable source, using transforms that are provably identical in behavior.

➕ show 3 replies
abecedarius • yesterday at 2:40 PM

I'd love to run this for the nostalgia value, and I did buy the original software but left it behind long ago. Oh, well. ("You need the original Borland programs" -- very reasonably.)

➕ show 1 reply
whobre • yesterday at 7:08 PM

Borland’s fine, but I would really like to see some of the Digital Research compilers reverse engineered, including the legendary Kildall’s PL/I

pmkary • yesterday at 5:07 PM

Who would have thought abandonware gets to have a Christmas like this five years ago?

lp4v4n • yesterday at 4:54 PM

Can anyone who knows the mainframe domain explain why legacy COBOL applications are not being aggressively ported to modern java applications? It sounds like an obvious usage of AI to solve a real world problem and yet I barely hear about it.

➕ show 6 replies
Quitschquat • yesterday at 3:14 PM

Claude usually gives me some bullshit nannying when I try to reverse engineer stuff.

➕ show 3 replies
squarefoot • yesterday at 2:11 PM

Since we live in the age of vibe recompilation, reverse engineering etc where everything seems possible, let me drop a wish for a "Turbo Zig" CLI IDE + compiler that covers most well known microcontrollers.

airstrike • yesterday at 4:46 PM

I can tell this is Claude from the title alone

regnull • yesterday at 7:56 PM

Borland reborn could be Reborland. A missed opportunity there.

igravious • yesterday at 6:59 PM

OOF nostalgia increases

“You need the original Borland programs (not included: see NOTICE.md).”

i had these all on 3.5" 'floppy' disks back in the day (like many old fogies 'round here i'm sure) but god knows where they are now -- should have kept them safe and sound sigh :(

pykevlar • yesterday at 6:19 PM

[dead]

sovrius • yesterday at 8:59 PM

[dead]

Tenrion618 • yesterday at 2:35 PM

[dead]

magi-2-ai • yesterday at 4:21 PM

[dead]

swevo • yesterday at 6:09 PM

[dead]

theturtle • yesterday at 4:06 PM

[dead]

Skyfall106 • yesterday at 2:24 PM

[dead]

infralog77 • yesterday at 1:06 PM

[dead]

supersimpleguy • yesterday at 2:30 PM

[dead]