From 7d986ea35d26bbde3d8df8cc2580905b918aefef Mon Sep 17 00:00:00 2001 From: Alastair Bridgewater Date: Sat, 9 Jun 2012 11:50:49 -0400 Subject: [PATCH] mips: Revert remaining badness from 0.9.1.45. * There were two pieces of badness in 0.9.1.45, both to do with the call_into_lisp LRA handling, and each compensated for the other to a limited extent. One change (since reverted) was to decrease the alignment requirement on positioning the LRA header, allowing it to be placed on a non-doubleword boundary. The second change (being reverted here) was to change the LRA address calculation to subtract the entry point offset from the address of the header instead of adding OTHER_POINTER_LOWTAG. If the header wound up on a doubleword boundary (the correct alignment) then the LRA computed would have LIST_POINTER_LOWTAG, leading to badness when doing a backtrace. In any event, typechecking the resulting LRA would fail, and actually attempting to return to it would also fail. * Revert to computing the LRA by adding OTHER_POINTER_LOWTAG to the address of the header, bringing MIPS inline with all of the other RETURN-PC-HEADER (LRA) using backends. --- src/runtime/mips-assem.S | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/runtime/mips-assem.S b/src/runtime/mips-assem.S index 4eabf21..1982ee8 100644 --- a/src/runtime/mips-assem.S +++ b/src/runtime/mips-assem.S @@ -19,7 +19,6 @@ #include "genesis/fdefn.h" #include "genesis/closure.h" #include "genesis/funcallable-instance.h" -#include "genesis/return-pc.h" #include "genesis/simple-fun.h" #include "genesis/static-symbols.h" @@ -166,7 +165,7 @@ symbol: lw reg_A5, 20(reg_CFP) /* Calculate LRA */ - la reg_LRA, lra - RETURN_PC_RETURN_POINT_OFFSET + la reg_LRA, lra + OTHER_POINTER_LOWTAG /* Indirect closure */ lw reg_CODE, CLOSURE_FUN_OFFSET(reg_LEXENV) -- 1.7.10.4