217 |
|
#define SIGSEGV_FAULT_ADDRESS sip->si_addr |
218 |
|
#if (defined(i386) || defined(__i386__)) |
219 |
|
#define SIGSEGV_FAULT_INSTRUCTION (((struct sigcontext *)scp)->sc_eip) |
220 |
< |
#define SIGSEGV_REGISTER_FILE ((unsigned int *)&(((struct sigcontext *)scp)->sc_edi)) |
220 |
> |
#define SIGSEGV_REGISTER_FILE ((unsigned int *)&(((struct sigcontext *)scp)->sc_edi)) /* EDI is the first GPR (even below EIP) in sigcontext */ |
221 |
> |
/* (gb) Disable because this would hang configure script for some reason |
222 |
> |
* though standalone testing gets it right. Any idea why? |
223 |
|
#define SIGSEGV_SKIP_INSTRUCTION ix86_skip_instruction |
224 |
+ |
*/ |
225 |
|
#endif |
226 |
|
#if defined(__linux__) |
227 |
|
#if (defined(i386) || defined(__i386__)) |
466 |
|
// Decode instruction |
467 |
|
switch (eip[0]) { |
468 |
|
case 0x0f: |
469 |
< |
if (eip[1] == 0xb7) { // MOVZX r32, r/m16 |
469 |
> |
switch (eip[1]) { |
470 |
> |
case 0xb6: // MOVZX r32, r/m8 |
471 |
> |
case 0xb7: // MOVZX r32, r/m16 |
472 |
|
switch (eip[2] & 0xc0) { |
473 |
|
case 0x80: |
474 |
|
reg = (eip[2] >> 3) & 7; |
484 |
|
break; |
485 |
|
} |
486 |
|
len += 3 + ix86_step_over_modrm(eip + 2); |
487 |
+ |
break; |
488 |
|
} |
489 |
|
break; |
490 |
|
case 0x8a: // MOV r8, r/m8 |