Mercurial > hg > graal-jvmci-8
diff c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotXirGenerator.java @ 1424:1ea65e9d943c
updated prologue/epilogue code
author | Lukas Stadler <lukas.stadler@oracle.com> |
---|---|
date | Mon, 16 Aug 2010 20:00:59 -0700 |
parents | 760213a60e8b |
children | 98fffb304868 |
line wrap: on
line diff
--- a/c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotXirGenerator.java Mon Aug 16 18:59:36 2010 -0700 +++ b/c1x4hotspotsrc/HotSpotVM/src/com/sun/hotspot/c1x/HotSpotXirGenerator.java Mon Aug 16 20:00:59 2010 -0700 @@ -121,6 +121,7 @@ asm.restart(CiKind.Void); XirOperand sp = asm.createRegister("stack pointer", CiKind.Word, registerConfig.getStackPointerRegister()); XirOperand temp = asm.createRegister("temp (rax)", CiKind.Int, AMD64.rax); + XirOperand frame_pointer = asm.createRegister("frame pointer", CiKind.Word, AMD64.rbp); asm.align(config.codeEntryAlignment); asm.mark(MARK_UNVERIFIED_ENTRY); @@ -133,8 +134,7 @@ asm.align(config.codeEntryAlignment); } asm.mark(MARK_VERIFIED_ENTRY); - // stack banging - asm.pstore(CiKind.Word, sp, asm.i(-config.stackShadowPages * config.vmPageSize), temp, true); + asm.push(frame_pointer); asm.pushFrame(); return asm.finishTemplate(staticMethod ? "static prologue" : "prologue"); @@ -142,7 +142,9 @@ private XirTemplate buildEpilogue() { asm.restart(CiKind.Void); + XirOperand frame_pointer = asm.createRegister("frame pointer", CiKind.Word, AMD64.rbp); asm.popFrame(); + asm.pop(frame_pointer); // TODO safepoint check return asm.finishTemplate("epilogue"); }