# Borland's DOS compilers rebuilt from their own binaries, byte for byte

Original title: Borland's DOS compilers, rebuilt from their own binaries

> Hacker News story 50687448 · language: en · submitted 2026-11-29
> Web version: https://zeli.app/story/50687448
> About this feed: https://zeli.app/llms.txt · Agent guide: https://zeli.app/skill.md

▲ 147 · by [frostbyte7](<https://news.ycombinator.com/user?id=frostbyte7>) · 💬 57
[original](<https://github.com/abedegno/borland-reborn>) · [HN discussion](<https://news.ycombinator.com/item?id=50687448>)

## Summary

A project called borland-reborn recovers the source code of Borland C++ 2.0 from its published executables. All 22 binaries, including BCC.EXE, rebuild byte-identical with the original toolchain. The recovered C and assembly are then made readable with real names, named record fields, and comments. A modding build lets functions grow or shrink and is validated by 1,836 compiles compared against Borland's output.

## Key quote

> The last command compiles all 298 sources in DOS, checks every function against the original byte for byte, verifies every relocation and name, and links a new BCC.EXE that is identical to Borland's.

## HN discussion (57 comments)

### [noahbp](<https://news.ycombinator.com/item?id=50688317>)

> 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

### [humblefly](<https://news.ycombinator.com/item?id=50688350>)

> 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".

### [codazoda](<https://news.ycombinator.com/item?id=50687951>)

> 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

### [lp4v4n](<https://news.ycombinator.com/item?id=50689720>)

> 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.

### [Waraqa](<https://news.ycombinator.com/item?id=50688148>)

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

---

## Cite

- Page: https://zeli.app/story/50687448
- Date: 2026-11-29
- Source: github.com (https://github.com/abedegno/borland-reborn)
- Hacker News: https://news.ycombinator.com/item?id=50687448

## Other languages

- zh: https://zeli.app/zh/story/50687448 · markdown: https://zeli.app/zh/story/50687448.md
- ja: https://zeli.app/ja/story/50687448 · markdown: https://zeli.app/ja/story/50687448.md
- ko: https://zeli.app/ko/story/50687448 · markdown: https://zeli.app/ko/story/50687448.md
- de: https://zeli.app/de/story/50687448 · markdown: https://zeli.app/de/story/50687448.md
- es: https://zeli.app/es/story/50687448 · markdown: https://zeli.app/es/story/50687448.md
- ru: https://zeli.app/ru/story/50687448 · markdown: https://zeli.app/ru/story/50687448.md
