-\subsubsection[pre-closure-code-stuff]{Pre-closure-code code}
-%* *
-%************************************************************************
-
-The argument-satisfaction check code is placed after binding
-the arguments to their stack locations. Hence, the virtual stack
-pointer is pointing after all the args, and virtual offset 1 means
-the base of frame and hence most distant arg. Hence
-virtual offset 0 is just beyond the most distant argument; the
-relative offset of this word tells how many words of arguments
-are expected.
-
-\begin{code}
-argSatisfactionCheck :: ClosureInfo -> [MagicId] {-GRAN-} -> Code
-
-argSatisfactionCheck closure_info arg_regs
-
- = nodeMustPointToIt (closureLFInfo closure_info) `thenFC` \ node_points ->
-
--- let
--- emit_gran_macros = opt_GranMacros
--- in
-
- -- HWL ngo' ngoq:
- -- absC (CMacroStmt GRAN_FETCH []) `thenC`
- -- forceHeapCheck [] node_points (absC AbsCNop) `thenC`
- --(if opt_GranMacros
- -- then if node_points
- -- then fetchAndReschedule arg_regs node_points
- -- else yield arg_regs node_points
- -- else absC AbsCNop) `thenC`
-
- getSpRelOffset 0 `thenFC` \ (SpRel sp) ->
- let
- off = iBox sp
- rel_arg = mkIntCLit off
- in
- ASSERT(off /= 0)
- if node_points then
- absC (CMacroStmt ARGS_CHK [rel_arg]) -- node already points
- else
- absC (CMacroStmt ARGS_CHK_LOAD_NODE [rel_arg, set_Node_to_this])
- where
- -- We must tell the arg-satis macro whether Node is pointing to
- -- the closure or not. If it isn't so pointing, then we give to
- -- the macro the (static) address of the closure.
-
- set_Node_to_this = CLbl (closureLabelFromCI closure_info) PtrRep
-\end{code}
-
-%************************************************************************
-%* *