last in the current series.
so i managed to lift some modules to 90+ similarity but it was not working as expected: too many tokens burn. Some more clever way needs to be used for the last mile. I tried using permutator, but it didn't help.
so, where llm did help: initial reconstruction, producing workable executable, and recovering additional passes as we go. exact reconstruction is possible but expensive. also llm don't generalize solutions usually, so there are many repeating stuff. i guess reconstruction should go in tick-tock phases: reconstruct-generalize.
what else helped: ghidra, local tool to track progress and dependency (you can do it through ghidra, I assume, but just sqlite3+python is much easier). also good tactics was to reconstruct leaf functions based on call count.
now I will manually try to lift functions and clean code base to see how the last mile could be done better, more automatic.
shout out to this blog posts: