harpoon.Backend.StrongARM
Class CodeGen
java.lang.Object
harpoon.Backend.Generic.CodeGen
harpoon.Backend.Generic.MaxMunchCG
harpoon.Backend.StrongARM.CodeGen
public class CodeGen
- extends MaxMunchCG
StrongARM.CodeGen
is a code-generator for the ARM architecture.
- Version:
- $Id: CodeGen.spec,v 1.6 2004/02/08 01:57:59 cananian Exp $
- Author:
- Felix S. Klock II <pnkfelix@mit.edu>
- See Also:
- "Jaggar, ARM Architecture Reference Manual"
Fields inherited from class harpoon.Backend.Generic.CodeGen |
frame |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CodeGen
public CodeGen(Frame frame,
boolean is_elf)
procFixup
public Instr procFixup(HMethod hm,
Instr instr,
int stackspace,
Set usedRegisters)
- Description copied from class:
CodeGen
- Fixes up the procedure entry and exit code for a list of instrs, once
it is known how many registers and how much stack space is used.
- Specified by:
procFixup
in class CodeGen
cgg_genCode
public final List cgg_genCode(Code code,
InstrFactory inf)
- Generates assembly code from a
harpoon.IR.Tree.Code
.
modifies: this
effects:
Scans tree
to find a tiling of
Instruction Patterns, calling auxillary methods
and data structures as defined in the .spec file.
Generates an associated Derivation
object as the second element of the returned
List
.
- Specified by:
cgg_genCode
in class CodeGen
- Parameters:
tree
- Set of abstract Tree
instructions
that form the body of the procedure being compiled.
- Returns:
- The head of a list of
Instr
s
cgg_genData
public final Instr cgg_genData(Data code,
InstrFactory inf)
- Generates assembly code from a
harpoon.IR.Tree.Data
.
modifies: this
effects:
Scans tree
to define a layout of
Instructions, calling auxillary methods
and data structures as defined in the .Spec file
- Specified by:
cgg_genData
in class CodeGen
- Parameters:
tree
- Set of abstract Tree
instructions
that form the body of the data structure being compiled.