Artificial Intelligence1 min read

Legacy Modernization with LLMs, measured

By · Published by Everything Blog

In short

In an empirical test across more than 500,000 lines of legacy code, an LLM generated over one million lines of compilable Java for roughly $1,100 in initial API costs. However, running identical source inputs repeatedly produced varying functional outputs, types, and interfaces, sometimes deviating from the legacy application's original rules. In unexpected instances, the model autonomously constructed a deterministic Python transpiler to process portions of the workload. The multi-part study indicates that downstream verification, testing, and error-correction cycles will substantially increase the total modernization investment.

Key points

  • Successful Java compilation does not guarantee consistent runtime logic or preservation o…: Successful Java compilation does not guarantee consistent runtime logic or preservation of original program behavior.
  • Initial API expenditure figures exclude major downstream costs like test generation, debu…: Initial API expenditure figures exclude major downstream costs like test generation, debugging cycles, and manual verification.
  • Language models make unpredictable design decisions during migrations, including autonomo…: Language models make unpredictable design decisions during migrations, including autonomously generating separate deterministic transpilers.

Sources checked by our analysis pipeline: 1

Believe it or not, at the beginning of my career I worked in a research group on empirical software engineering. And yes, it is as boring as it sounds because the job consisted of measuring things and sharing the results. That is much less fun than following your instinct, waving your hands like a good Italian, and sharing your opinion. One does the empirical software thing with the goal of obtaining data because data is a useful way to contribute to the conversation. So I thought I could go back to the good old times and use an empirical approach to see how legacy modernization with LLMs works on real legacy systems.

Why inflict this pain on myself? Because I think we really need more data in this whole mess. There are a lot of bold claims and emotional statements out there, and they leave everybody confused. Or maybe it is just me. One day I read claims about migrations done with LLMs and their incredible results, and the other day I hear the opposite opinion, with someone explaining that…

Artificial Intelligence