
IDA Config
Hi!
This is my IDA config with few tweaks that I found useful.
Both are located in <ida_directory>/cfg/
hexrays.cfg - Decompiler Config
BLOCK_INDENT = 4
default = 2
// OLDif (statement) do_smth();
// NEWif (statement) do_smth();
RIGHT_MARGIN = 80
default = 120, as above
MAX_NCOMMAS = 1
default = 8
// OLDif ( cond || ( x = *p, y = func(), x + y > 0 ) ) body;
// NEWif ( cond ) goto LABEL;x = *p;y = func();if ( x + y > 0 )LABEL: body;
DEFAULT_RADIX = 16
default = 0
// OLDif (var != 10) /* code */
// NEWif (var != 0xA) /* code */
GENERATE_EMPTY_LINES = YES
default = NO
// OLDLABEL_23:if (v19 >= enva || !*v19) break;LABEL_25:v13 = v19;
// NEWLABEL_23:if (v19 >= enva || !*v19) break;
LABEL_25:v13 = v19;
#define HEXOPTONS = 0x831FF // Combination of HO_... bits#define HO_KEEP_CURLIES 0x000200 // Keep curly braces for single-statement blocks
HEXOPTIONS = 0x833FF
which is equal to HEXOPTIONS | HO_KEEP_CURLIES
// OLDif (state) return 1;
// NEWif (state){ return 1;}
ida.cfg - IDA Config
OPCODE_BYTES = 16
default = 0
GRAPH_OPCODE_BYTES = 16
default = 0
; OLDtest cl, cljz short loc_4010FEmov dl, [eax+1]
; NEW84 C9 test cl, cl74 16 jz short loc_4010FE8A 50 01 mov dl, [eax+1]