dbghelp: For codeview/bprel symbols force the register to be EBP, other CPUs should use regrel symbol instead of bprel.

oldstable
Eric Pouech 2011-04-11 20:47:13 +02:00 committed by Alexandre Julliard
parent 3e54f6b5d9
commit 2dd45a12c1
1 changed files with 6 additions and 3 deletions

View File

@ -1692,7 +1692,8 @@ static int codeview_snarf(const struct msc_debug_info* msc_dbg, const BYTE* root
*/
case S_BPREL_V1:
loc.kind = loc_regrel;
loc.reg = 0; /* FIXME */
/* Yes, it's i386 dependent, but that's the symbol purpose. S_REGREL is used on other CPUs */
loc.reg = CV_REG_EBP;
loc.offset = sym->stack_v1.offset;
symt_add_func_local(msc_dbg->module, curr_func,
sym->stack_v1.offset > 0 ? DataIsParam : DataIsLocal,
@ -1702,7 +1703,8 @@ static int codeview_snarf(const struct msc_debug_info* msc_dbg, const BYTE* root
break;
case S_BPREL_V2:
loc.kind = loc_regrel;
loc.reg = 0; /* FIXME */
/* Yes, it's i386 dependent, but that's the symbol purpose. S_REGREL is used on other CPUs */
loc.reg = CV_REG_EBP;
loc.offset = sym->stack_v2.offset;
symt_add_func_local(msc_dbg->module, curr_func,
sym->stack_v2.offset > 0 ? DataIsParam : DataIsLocal,
@ -1712,7 +1714,8 @@ static int codeview_snarf(const struct msc_debug_info* msc_dbg, const BYTE* root
break;
case S_BPREL_V3:
loc.kind = loc_regrel;
loc.reg = 0; /* FIXME */
/* Yes, it's i386 dependent, but that's the symbol purpose. S_REGREL is used on other CPUs */
loc.reg = CV_REG_EBP;
loc.offset = sym->stack_v3.offset;
symt_add_func_local(msc_dbg->module, curr_func,
sym->stack_v3.offset > 0 ? DataIsParam : DataIsLocal,