|
From: <sv...@va...> - 2012-02-16 12:41:28
|
Author: sewardj
Date: 2012-02-16 12:36:47 +0000 (Thu, 16 Feb 2012)
New Revision: 2251
Log:
Broadens the range on INT imm8 values that SIGSEGV, allowing Jikes RVM
to work.
Jikes RVM uses INT 0x3F through 0x49, assuming that they result in a
SIGSEGV. The x86 guest currently does this only for INT 0x40 through
0x43. The attached patch extends the range to 0x3F through 0x4F,
covering all existing Jikes RVM INTs and leaving room for it to add a
few more before it runs into this problem again.
Fixes #294185. (Eliot Moss, mo...@cs...)
Modified:
trunk/priv/guest_x86_toIR.c
Modified: trunk/priv/guest_x86_toIR.c
===================================================================
--- trunk/priv/guest_x86_toIR.c 2012-02-15 19:11:44 UTC (rev 2250)
+++ trunk/priv/guest_x86_toIR.c 2012-02-16 12:36:47 UTC (rev 2251)
@@ -13074,12 +13074,14 @@
end-of-block here, which forces any TempRegs caching ArchRegs
to be flushed. */
- /* Handle int $0x40 .. $0x43 by synthesising a segfault and a
+ /* Handle int $0x3F .. $0x4F by synthesising a segfault and a
restart of this instruction (hence the "-2" two lines below,
to get the restart EIP to be this instruction. This is
probably Linux-specific and it would be more correct to only
- do this if the VexAbiInfo says that is what we should do. */
- if (d32 >= 0x40 && d32 <= 0x43) {
+ do this if the VexAbiInfo says that is what we should do.
+ This used to handle just 0x40-0x43; Jikes RVM uses a larger
+ range (0x3F-0x49), and this allows some slack as well. */
+ if (d32 >= 0x3F && d32 <= 0x4F) {
jmp_lit(Ijk_SigSEGV,((Addr32)guest_EIP_bbstart)+delta-2);
dres.whatNext = Dis_StopHere;
DIP("int $0x%x\n", (Int)d32);
|