LLM-Assisted Translation of Legacy FORTRAN Codes to C++: A Cross-Platform Study
Fuente:
arXiv
Saved in:
| Main Authors: | , , , , , , , |
|---|---|
| Format: | Preprint |
| Published: |
2025
|
| Subjects: | |
| Online Access: | |
| Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
| _version_ | 1866913802679746560 |
|---|---|
| author | Ranasinghe, Nishath Rajiv Jones, Shawn M. Kucer, Michal Biswas, Ayan O'Malley, Daniel Most, Alexander Buschmann Wanna, Selma Liliane Sreekumar, Ajay |
| author_facet | Ranasinghe, Nishath Rajiv Jones, Shawn M. Kucer, Michal Biswas, Ayan O'Malley, Daniel Most, Alexander Buschmann Wanna, Selma Liliane Sreekumar, Ajay |
| contents | Large Language Models (LLMs) are increasingly being leveraged for generating and translating scientific computer codes by both domain-experts and non-domain experts. Fortran has served as one of the go to programming languages in legacy high-performance computing (HPC) for scientific discoveries. Despite growing adoption, LLM-based code translation of legacy code-bases has not been thoroughly assessed or quantified for its usability. Here, we studied the applicability of LLM-based translation of Fortran to C++ as a step towards building an agentic-workflow using open-weight LLMs on two different computational platforms. We statistically quantified the compilation accuracy of the translated C++ codes, measured the similarity of the LLM translated code to the human translated C++ code, and statistically quantified the output similarity of the Fortran to C++ translation. |
| format | Preprint |
| id |
arxiv_https___arxiv_org_abs_2504_15424 |
| institution | arXiv |
| publishDate | 2025 |
| record_format | arxiv |
| spellingShingle | LLM-Assisted Translation of Legacy FORTRAN Codes to C++: A Cross-Platform Study Ranasinghe, Nishath Rajiv Jones, Shawn M. Kucer, Michal Biswas, Ayan O'Malley, Daniel Most, Alexander Buschmann Wanna, Selma Liliane Sreekumar, Ajay Software Engineering Artificial Intelligence I.2.2; I.2.7; D.2.3; D.2.4 Large Language Models (LLMs) are increasingly being leveraged for generating and translating scientific computer codes by both domain-experts and non-domain experts. Fortran has served as one of the go to programming languages in legacy high-performance computing (HPC) for scientific discoveries. Despite growing adoption, LLM-based code translation of legacy code-bases has not been thoroughly assessed or quantified for its usability. Here, we studied the applicability of LLM-based translation of Fortran to C++ as a step towards building an agentic-workflow using open-weight LLMs on two different computational platforms. We statistically quantified the compilation accuracy of the translated C++ codes, measured the similarity of the LLM translated code to the human translated C++ code, and statistically quantified the output similarity of the Fortran to C++ translation. |
| title | LLM-Assisted Translation of Legacy FORTRAN Codes to C++: A Cross-Platform Study |
| topic | Software Engineering Artificial Intelligence I.2.2; I.2.7; D.2.3; D.2.4 |
| url | https://arxiv.org/abs/2504.15424 |