harpoon.IR.Tree
Class NATIVECALL
java.lang.Object
harpoon.IR.Tree.Tree
harpoon.IR.Tree.Stm
harpoon.IR.Tree.INVOCATION
harpoon.IR.Tree.NATIVECALL
- All Implemented Interfaces:
- HCodeElement
public class NATIVECALL
- extends INVOCATION
NATIVECALL
objects are statements which stand for
function calls using standard C calling convention. These are
typically used to implement parts of the runtime system
(for example, to invoke the garbage collector) and not
for java native method calls (which must use the standard java
method calling convention).
- Version:
- $Id: NATIVECALL.java,v 1.4 2002/04/10 03:05:45 cananian Exp $
- Author:
- Duncan Bryce <duncan@lcs.mit.edu>, based on
Modern Compiler Implementation in Java by Andrew Appel.
- See Also:
CALL
,
CALL
,
INVOCATION
Methods inherited from class harpoon.IR.Tree.Tree |
clone, clone, getChild, getFactory, getFirstChild, getID, getLineNumber, getParent, getSibling, getSourceFile, hashCode, rename, replace, setChild, unlink |
NATIVECALL
public NATIVECALL(TreeFactory tf,
HCodeElement source,
TEMP retval,
Exp func,
ExpList args)
- Constructor.
isNative
public boolean isNative()
- Specified by:
isNative
in class INVOCATION
kind
public int kind()
- Description copied from class:
Tree
- Return an integer enumeration of the kind of this
Tree
. The enumerated values are defined in
TreeKind
.
- Specified by:
kind
in class Tree
build
public Stm build(TreeFactory tf,
ExpList kids)
- Specified by:
build
in class Stm
accept
public void accept(TreeVisitor v)
- Accept a visitor
- Specified by:
accept
in class INVOCATION
rename
public Tree rename(TreeFactory tf,
TempMap tm,
Tree.CloneCallback cb)
- Description copied from class:
Tree
- Rename while cloning a subtree. This node and all child nodes
are cloned; the 'temp' information of all
TEMP
nodes
are renamed according to the supplied TempMap
.
Note that Temp
s not belonging to
this.getFactory().tempFactory()
are not affected.
The callback()
method of the supplied
CloneCallback
is invoked once on each subtree cloned,
starting from the leaves and working back to the root in a
post-order depth-first manner.
- Specified by:
rename
in class Tree
toString
public String toString()
- Overrides:
toString
in class Object