X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fghci%2FByteCodeFFI.lhs;fp=ghc%2Fcompiler%2Fghci%2FByteCodeFFI.lhs;h=78cfa610b2a4affef1f2d0e45204e37d45af493d;hb=271502ff37a81fb5292056a1885c705192ef76c5;hp=4db270747461f9a706add39b3a090c9c0f803e53;hpb=56bcfea3a498c945ef223ecab8f415ee18580724;p=ghc-hetmet.git diff --git a/ghc/compiler/ghci/ByteCodeFFI.lhs b/ghc/compiler/ghci/ByteCodeFFI.lhs index 4db2707..78cfa61 100644 --- a/ghc/compiler/ghci/ByteCodeFFI.lhs +++ b/ghc/compiler/ghci/ByteCodeFFI.lhs @@ -463,7 +463,7 @@ mkMarshalCode_wrk cconv (r_offW, r_rep) addr_offW arg_offs_n_reps parameterArea = sum [ getPrimRepSize a_rep * bytes_per_word | (_, a_rep) <- arg_offs_n_reps ] savedRegisterArea = 4 - frameSize = padTo16 (linkageArea + min parameterArea 32 + savedRegisterArea) + frameSize = padTo16 (linkageArea + max parameterArea 32 + savedRegisterArea) padTo16 x = case x `mod` 16 of 0 -> x y -> x - y + 16 @@ -475,7 +475,7 @@ mkMarshalCode_wrk cconv (r_offW, r_rep) addr_offW arg_offs_n_reps offsetW' = offsetW + getPrimRepSize a_rep pass_word w - | w < 8 = + | offsetW + w < 8 = [0x801f0000 -- lwz rX, src(r31) .|. (fromIntegral src .&. 0xFFFF) .|. (fromIntegral (offsetW+w+3) `shiftL` 21)]