error recovery via decompile?

error recovery via decompile?

Today, while creating a new module, I opened an existing module's source code to use as a template, and ended up saving the new code before realizing I hadn't renamed the new file. So, of course, it saved over the old source code file. And I had neglected to backup the original file before starting this adventure (I know - cardinal sin for a programmer!). I have not yet recompiled the new module, so the compiled module is still from the original file, and I am wondering if there is a way to recover the original source file from the compiled module. It is a small module, containing only some global variable declarations, so I can recreate it (if I have to!) but I was hoping to not have to type it all in again. Any ideas?

4 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Not that I know of.


Steve - Intel Developer Support

I knew that would be the answer, but I had to ask! I have now re-entered all the data from an old printout, then recompiled and noted which variables were missing from the old printout and added them back in. Not as tedious as I thought it would be, since I had the printout anyway. Oh, and I won't forget those backups now! Thanks.

Several "decompilers" exist, but all result in some obscure but correct assembler code.

Another solution for overwriting files is to avoid any filesaving and disc writing afterwards (impossible) and use a tool to capture lost non-consecutive file segments on non-file disk sections.
In other words:

Bad luck for you.

So if you lost a goldmine, keep your hands off from mouse and keyboard, don't shutdown your computer and call a data-recover-specialist (find his telephone number right now).

If it was just a silvermine, you still made a serious error.
Not a programmers one as you mentioned, but one any computer user should avoid.

What you didn't do:
- Automatic full-backups, daily or periodically
- If necessary, important intraday copies in between
- Have your backup procedure checked, are you able to recover any existing backup ?
- Backups removed from your building and store elsewhere


Leave a Comment

Please sign in to add a comment. Not a member? Join today