I am trying to batch disassemble and decompile 500 binaries using the IDA Pro 7.5 disassember and Hex rays decompiler. I can get the .i64 output from the disassembler, but I do not have a way to batch decompile this. Does anyone have an easy way to get the .c pseudocode directly from a binary, like one can do with Ghidra?

2 Answers 2


Please see Batch Operation In the decompiler’s manual.


@cal_decom hello, I wrote this script which may help you in your what you want to achieve.

import os
import sys

pwd = os.getcwd()
for dirpath, dirnames, filenames in sorted(os.walk(pwd)):
    for file in filenames:
        ext = os.path.splitext(file)[-1]
        name = os.path.splitext(file)[0]
        if os.path.splitext(file)[-1] == ".out":
            os.system(f"/mnt/d/idapro-7.5/idat64 -Ohexrays:{os.path.join(dirpath, name)}:ALL  -A {os.path.join(dirpath, file)} -nosave")
# you might want to change this for sub directories
os.system("rm *.i64")

You can change the path accordingly. This script scans through current directory and sub directories to find binaries with "out" extension and generates pseudocode if found. You can read the link provided by @Igor Skochinsky for other options available.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.