Mon Jan 26 16:02:09 CET 2009 Simon Marlow * Fix #2961: we lost some of the generated code for stack args in genCCall A real bug in the x86_64 native code gen: nice! This bug would have been caught by -Wall, and I would have gone though and Walled this file but I know Ben is hacking on this file quite heavily and I don't want to create undue conflicts. Ben: it would be nice to enable -Wall here when you have time. diff -rN -u old-ghc/compiler/nativeGen/MachCodeGen.hs new-ghc/compiler/nativeGen/MachCodeGen.hs --- old-ghc/compiler/nativeGen/MachCodeGen.hs 2009-03-15 16:02:02.000000000 +0100 +++ new-ghc/compiler/nativeGen/MachCodeGen.hs 2009-03-15 16:02:04.000000000 +0100 @@ -3567,8 +3567,9 @@ (arg_op, arg_code) <- getOperand arg delta <- getDeltaNat setDeltaNat (delta-arg_size) - let code' = code `appOL` toOL [PUSH I64 arg_op, - DELTA (delta-arg_size)] + let code' = code `appOL` arg_code `appOL` toOL [ + PUSH I64 arg_op, + DELTA (delta-arg_size)] push_args rest code' where arg_rep = cmmExprType arg