Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
idapro / opt / ida90 / libexec / idapro / cfg / dwarf.cfg
Size: Mime:
// DWARF plugin

// if set to NO - disable the DWARF plugin
// YES: try to detect & parse DWARF data
// Alternatively, it is possible to disable the DWARF plugin
// in the command line:
//      ida -Odwarf:off input_file
DWARF_ENABLED = YES

// Should the "Load DWARF info?" dialog be displayed at all?
// Set to NO to always load automatically (if present)
DWARF_PROMPT_USER = YES

// Apply types & names for global variables
DWARF_GLOBAL_NAMES = YES

// Apply functions information
// (include DWARF_FUNCTION_BOUNDS)
DWARF_FUNCTIONS = YES

// Override IDA's algorithm for determining functions
// boundaries with information from DWARF
DWARF_FUNCTION_BOUNDS = NO

// Import type information (slow)
// (include DWARF_CC_APPLY, DWARF_CC_ALLOW_USERCALL
//  and DWARF_FPROTS_ARE_DEFINITIVE)
DWARF_TYPES = YES

// Should the DWARF plugin try and guess function calling
// conventions?
// Set this to 'NO' to use the default platform's calling convention.
DWARF_CC_APPLY = YES

// In case the calling convention for a function appears to
// be a __usercall, should the DWARF plugin allow it?
//
// Some versions of some DWARF producers (I'm looking at you,
// GCC 3.2.2. But not only) can generate information for
// function parameters that are misleading for the DWARF plugin.
// For example, they state that the parameter is in EDI
// (and that that location is valid throughout the whole function)
// while in fact the parameter is passed on the stack, and right
// after the prologue, placed in EDI.
// While this makes sense for a program such as GDB, this
// leads the DWARF plugin to think that the parameter is indeed
// passed to the function through EDI and that, consequently, the
// calling convention is a __usercall.
//
// By setting this to 'NO', you instruct the plugin that whenever
// a function appears to have a __usercall calling convention, the
// default calling convention for the platform should be used instead.
DWARF_CC_ALLOW_USERCALL = YES

// Should the DWARF-deduced function prototypes be considered definitive?
// Many recent DWARF producers produce DWARF information of a quality high
// enough for us to reliably trust the function prototypes derived from it.
// But, if the DWARF producer is buggy (as are many versions of GCC < 4),
// it may do more harm than good to blindly rely on that information.
//
// If an erroneous function prototype is marked as definitive, it
// will have an unfortunate impact on the Hex-Rays decompiler output,
// so use this with care.
DWARF_FPROTS_ARE_DEFINITIVE = YES

// Should the DWARF plugin import file names & line numbers information
// into the database?
// Can be overriden in the command line:
//      ida -Odwarf:import_lnnums=1 input_file
DWARF_IMPORT_LNNUMS = NO

// Experimental: Should the DWARF plugin try and use data that's split across
// the main file, and a 'dwz' file (referenced through the '.gnu_debugaltlink'
// section)?
DWARF_USE_DWZ_FILE = YES

// GCC < 4.4.1 suffers from a typedef name qualification bug:
// http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36266
// That means files produced with such versions of GCC will contain
// typedefs that might be erroneously placed as children of types
// to which they don't belong.
// This can be problematic, because of the duplication of information
// in DWARF compile units. Consider the following:
// struct sa_t { typedef int foo_t; foo_t foo; };
// struct sb_t { sa_t *sa; };
// If GCC erroneously puts the 'foo_t' typedef in two (or more) different
// places across compile units, there will be two (or more) variations
// of sa_t (named sa_t_0, sa_t_1, etc...).
// But any type that depends on it will also be duplicated (e.g., sb_t).
//
// To work around this, since the name qualification for those typedefs
// might be broken, we break it ourselves, but in a coherent manner: by
// removing the qualification. Thus 'sa_t::foo_t' becomes 'foo_t', and
// that will be so across all compile units, enabling the DWARF
// plugin to recognize and avoid duplicate types.
DWARF_UNQUALIFY_BROKEN_GCC_TYPEDEFS = YES

#ifdef __PC__                           // INTEL 80x86 PROCESSORS

// Every line represents a DWARF register (starting at
// register #0), and contains an array of mapping for
// that DWARF register, to the corresponding processor
// module's register (and possible flags to hint the DWARF
// plugin); possibly in multiple sizes.
// For example, since the 'pc' processor module handles
// both x86, and x64 architectures, we specify mappings
// for cases where the processor module is working in
// 32-bit or 64-bit mode. E.g.,
// {{in-32-bit-mode, {maps-to-register-0, with-name-eax}}, {in-64-bit-mode, {maps-to-register-0, with-name-rax}}}
// An entry can have a '-1' bit-mode. In which case,
// it means that the number of the register it maps to, and its
// name are valid in all processor module bit modes
// (e.g., ARM register definitions below.)
REGISTERS =
{
  // From: http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/config/i386/Attic/tm-i386.h?rev=1.1&content-type=text/x-cvsweb-markup&cvsroot=src
  // According to: http://sourceware.org/ml/binutils/1999-q2/msg00338.html
  //
  // Also: http://lxr.free-electrons.com/source/tools/perf/arch/x86/util/dwarf-regs.c
  // Also: https://llvm.org/svn/llvm-project/llvm/branches/release_21/lib/Target/X86/X86RegisterInfo.td
  // 0
  {{32, {0, "eax"}}, {64, {0, "rax"}}},
  {{32, {1, "ecx"}}, {64, {2, "rdx"}}},
  {{32, {2, "edx"}}, {64, {1, "rcx"}}},
  {{32, {3, "ebx"}}, {64, {3, "rbx"}}},
  // 4
  {{32, {4, "esp", STACK_POINTER}}, {64, {6, "rsi"}}},
  {{32, {5, "ebp", STACK_FRAME}}, {64, {7, "rdi"}}},
  {{32, {6, "esi"}}, {64, {5, "rbp", STACK_FRAME}}},
  {{32, {7, "edi"}}, {64, {4, "rsp", STACK_POINTER}}},
  // 8
  {{32, {28, "eip"}},    {64, {8, "r8"}}},
  {{32, {44, "eflags"}}, {64, {9, "r9"}}},
  {{32, {30, "cs"}},     {64, {10, "r10"}}},
  {{32, {31, "ss"}},     {64, {11, "r11"}}},
  // 12
  {{32, {32, "ds"}}, {64, {12, "r12"}}},
  {{32, {29, "es"}}, {64, {13, "r13"}}},
  {{32, {33, "fs"}}, {64, {14, "r14"}}},
  {{32, {34, "gs"}}, {64, {15, "r15"}}},
  // 16
  {{32, {45, "st0"}}, {64, {64, "xmm0"}}},
  {{32, {46, "st1"}}, {64, {65, "xmm1"}}},
  {{32, {47, "st2"}}, {64, {66, "xmm2"}}},
  {{32, {48, "st3"}}, {64, {67, "xmm3"}}},
  // 20
  {{32, {49, "st4"}}, {64, {68, "xmm4"}}},
  {{32, {50, "st5"}}, {64, {69, "xmm5"}}},
  {{32, {51, "st6"}}, {64, {70, "xmm6"}}},
  {{32, {52, "st7"}}, {64, {71, "xmm7"}}},
  // 24
  {{64, {72, "xmm8"}}},
  {{64, {73, "xmm9"}}},
  {{64, {74, "xmm10"}}},
  {{64, {75, "xmm11"}}},
  // 28
  {{64, {76, "xmm12"}}},
  {{64, {77, "xmm13"}}},
  {{64, {78, "xmm14"}}},
  {{64, {79, "xmm15"}}},
};

#endif // __PC__

#ifdef __ARM__
REGISTERS =
{
  // From: http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/config/i386/Attic/tm-i386.h?rev=1.1&content-type=text/x-cvsweb-markup&cvsroot=src
  // According to: http://sourceware.org/ml/binutils/1999-q2/msg00338.html
  // 0
  {{32, {0, "R0"}}, {64, {129, "X0"}}},
  {{32, {1, "R1"}}, {64, {130, "X1"}}},
  {{32, {2, "R2"}}, {64, {131, "X2"}}},
  {{32, {3, "R3"}}, {64, {132, "X3"}}},
  // 4
  {{32, {4, "R4"}}, {64, {133, "X4"}}},
  {{32, {5, "R5"}}, {64, {134, "X5"}}},
  {{32, {6, "R6"}}, {64, {135, "X6"}}},
  {{32, {7, "R7"}}, {64, {136, "X7"}}},
  // 8
  {{32, {8, "R8"}}, {64, {137, "X8"}}},
  {{32, {9, "R9"}}, {64, {138, "X9"}}},
  {{32, {10, "R10"}}, {64, {139, "X10"}}},
  {{32, {11, "R11", STACK_FRAME}}, {64, {140, "X11"}}},
  // 12
  {{32, {12, "R12"}}, {64, {141, "X12"}}},
  {{32, {13, "R13", STACK_POINTER}}, {64, {142, "X13"}}},
  {{32, {14, "R14"}}, {64, {143, "X14"}}},
  {{32, {15, "R15"}}, {64, {144, "X15"}}},
  // 16
  {{32, {16, "R16"}}, {64, {145, "X16"}}},
  {{32, {17, "R17"}}, {64, {146, "X17"}}},
  {{32, {18, "R18"}}, {64, {147, "X18"}}},
  {{32, {19, "R19"}}, {64, {148, "X19"}}},
  // 20
  {{32, {20, "R20"}}, {64, {149, "X20"}}},
  {{32, {21, "R21"}}, {64, {150, "X21"}}},
  {{32, {22, "R22"}}, {64, {151, "X22"}}},
  {{32, {23, "R23"}}, {64, {152, "X23"}}},
  // 24
  {{32, {24, "R24"}}, {64, {153, "X24"}}},
  {{32, {25, "R25"}}, {64, {154, "X25"}}},
  {{32, {26, "R26"}}, {64, {155, "X26"}}},
  {{32, {27, "R27"}}, {64, {156, "X27"}}},
  // 28
  {{32, {28, "R28"}}, {64, {157, "X28"}}},
  {{32, {29, "R29"}}, {64, {158, "X29", STACK_FRAME}}},
  {{32, {30, "R30"}}, {64, {159, "X30"}}},
  {{32, {31, "R31"}}, {64, {161, "X31", STACK_POINTER}}},
};
#endif // __ARM__

#ifdef __PPC__
REGISTERS =
{
  // 0
  {{32, {0, "r0"}}, {64, {0, "r0"}}},
  {{32, {1, "r1", STACK_POINTER}}, {64, {1, "r1", STACK_POINTER}}},
  {{32, {2, "r2"}}, {64, {2, "r2"}}},
  {{32, {3, "r3"}}, {64, {3, "r3"}}},
  // 4
  {{32, {4, "r4"}}, {64, {4, "r4"}}},
  {{32, {5, "r5"}}, {64, {5, "r5"}}},
  {{32, {6, "r6"}}, {64, {6, "r6"}}},
  {{32, {7, "r7"}}, {64, {7, "r7"}}},
  // 8
  {{32, {8, "r8"}}, {64, {8, "r8"}}},
  {{32, {9, "r9"}}, {64, {9, "r9"}}},
  {{32, {10, "r10"}}, {64, {10, "r10"}}},
  {{32, {11, "r11"}}, {64, {11, "r11"}}},
  // 12
  {{32, {12, "r12"}}, {64, {12, "r12"}}},
  {{32, {13, "r13"}}, {64, {13, "r13"}}},
  {{32, {14, "r14"}}, {64, {14, "r14"}}},
  {{32, {15, "r15"}}, {64, {15, "r15"}}},
  // 16
  {{32, {16, "r16"}}, {64, {16, "r16"}}},
  {{32, {17, "r17"}}, {64, {17, "r17"}}},
  {{32, {18, "r18"}}, {64, {18, "r18"}}},
  {{32, {19, "r19"}}, {64, {19, "r19"}}},
  // 20
  {{32, {20, "r20"}}, {64, {20, "r20"}}},
  {{32, {21, "r21"}}, {64, {21, "r21"}}},
  {{32, {22, "r22"}}, {64, {22, "r22"}}},
  {{32, {23, "r23"}}, {64, {23, "r23"}}},
  // 24
  {{32, {24, "r24"}}, {64, {24, "r24"}}},
  {{32, {25, "r25"}}, {64, {25, "r25"}}},
  {{32, {26, "r26"}}, {64, {26, "r26"}}},
  {{32, {27, "r27"}}, {64, {27, "r27"}}},
  // 28
  {{32, {28, "r28"}}, {64, {28, "r28"}}},
  {{32, {29, "r29"}}, {64, {29, "r29"}}},
  {{32, {30, "r30"}}, {64, {30, "r30"}}},
  {{32, {31, "r31"}}, {64, {31, "r31"}}},

  // 32
  {{32, {32, "f0"}}, {64, {32, "f0"}}},
  {{32, {33, "f1"}}, {64, {33, "f1"}}},
  {{32, {34, "f2"}}, {64, {34, "f2"}}},
  {{32, {35, "f3"}}, {64, {35, "f3"}}},
  // 36
  {{32, {36, "f4"}}, {64, {36, "f4"}}},
  {{32, {37, "f5"}}, {64, {37, "f5"}}},
  {{32, {38, "f6"}}, {64, {38, "f6"}}},
  {{32, {39, "f7"}}, {64, {39, "f7"}}},
  // 40
  {{32, {40, "f8"}},  {64, {40, "f8"}}},
  {{32, {41, "f9"}},  {64, {41, "f9"}}},
  {{32, {42, "f10"}}, {64, {42, "f10"}}},
  {{32, {43, "f11"}}, {64, {43, "f11"}}},
  // 44
  {{32, {44, "f12"}}, {64, {40, "f12"}}},
  {{32, {45, "f13"}}, {64, {41, "f13"}}},
  {{32, {46, "f14"}}, {64, {42, "f14"}}},
  {{32, {47, "f15"}}, {64, {43, "f15"}}},
  // 48
  {{32, {48, "f16"}}, {64, {40, "f16"}}},
  {{32, {49, "f17"}}, {64, {41, "f17"}}},
  {{32, {50, "f18"}}, {64, {42, "f18"}}},
  {{32, {51, "f19"}}, {64, {43, "f19"}}},
  // 52
  {{32, {52, "f20"}}, {64, {52, "f20"}}},
  {{32, {53, "f21"}}, {64, {53, "f21"}}},
  {{32, {54, "f22"}}, {64, {54, "f22"}}},
  {{32, {55, "f23"}}, {64, {55, "f23"}}},
  // 56
  {{32, {56, "f24"}}, {64, {56, "f24"}}},
  {{32, {57, "f25"}}, {64, {57, "f25"}}},
  {{32, {58, "f26"}}, {64, {58, "f26"}}},
  {{32, {59, "f27"}}, {64, {59, "f27"}}},
  // 60
  {{32, {60, "f28"}}, {64, {60, "f28"}}},
  {{32, {61, "f29"}}, {64, {61, "f29"}}},
  {{32, {62, "f30"}}, {64, {62, "f30"}}},
  {{32, {63, "f31"}}, {64, {63, "f31"}}},
  // 64
  {{32, {64, "cr"}}, {64, {64, "cr"}}},
  {{32, {65, "fpscr"}}, {64, {64, "lr"}}},
  {{32, {66, "msr"}}, {64, {66, "ctr"}}},

};
#endif // __PPC__