From cd680c6d4bb37213e1dbe0df5c87c6f8ea1b04eb Mon Sep 17 00:00:00 2001 From: Drahflow Date: Sun, 29 Sep 2013 13:19:43 +0200 Subject: 13% faster with (some) inline arithmetics --- compiler/elymasGlobalSysOpt.ey | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'compiler') diff --git a/compiler/elymasGlobalSysOpt.ey b/compiler/elymasGlobalSysOpt.ey index b3128bf..49d9282 100644 --- a/compiler/elymasGlobalSysOpt.ey +++ b/compiler/elymasGlobalSysOpt.ey @@ -104,6 +104,22 @@ :retn ]] /eyreplace defv + # returns internalAllocateInteger into userspace + # 0 <- ::internalAllocateInteger as integer + [[ + /rbx :popqReg + + ::internalAllocateInteger /rax :movqImmReg + /rax :callqReg + /rax :pushqReg + + ::internalAllocateInteger /rdx :movqImmReg + /rdx 8 /rax :movqRegMemDisp8 + + /rbx :pushqReg + :retn + ]] /eyinternalAllocateInteger defv + # returns internalAllocateScope into userspace # 0 <- ::internalAllocateScope as integer [[ -- cgit v1.2.3