From: sof Date: Thu, 28 Feb 2002 18:54:53 +0000 (+0000) Subject: [project @ 2002-02-28 18:54:53 by sof] X-Git-Tag: Approx_11550_changesets_converted~2329 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=76ad1b306c2db89146438547f63ab6e9fc1b62a3;p=ghc-hetmet.git [project @ 2002-02-28 18:54:53 by sof] stg_gc_unpt_r1_ret: if R1 isn't mapped to a real register, keep it on the stack. I confess to 'pushing symbols' here a bit, as the exact nature (and function) of stg_gc_unpt_r1_info isn't clear to me (documentation isn't abundant, for one.) However, it will now behave in a manner consistent with what the code generator emits in the unregisterised case. --- diff --git a/ghc/rts/HeapStackCheck.hc b/ghc/rts/HeapStackCheck.hc index c216cc9..55c3988 100644 --- a/ghc/rts/HeapStackCheck.hc +++ b/ghc/rts/HeapStackCheck.hc @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: HeapStackCheck.hc,v 1.24 2002/02/28 16:25:15 sof Exp $ + * $Id: HeapStackCheck.hc,v 1.25 2002/02/28 18:54:53 sof Exp $ * * (c) The GHC Team, 1998-1999 * @@ -669,9 +669,14 @@ INFO_TABLE_SRT_BITMAP(stg_gc_unpt_r1_info, stg_gc_unpt_r1_ret, 0/*BITMAP*/, EXTFUN(stg_gc_unpt_r1_ret) { FB_ +#ifdef REG_R1 R1.w = Sp[0]; Sp += 1; JMP_(ENTRY_CODE(Sp[0])); +#else + /* Keep R1 on the stack */ + JMP_(ENTRY_CODE(Sp[1])); +#endif FE_ }