coins.backend.gen
クラス CodeGenerator

java.lang.Object
  |
  +--coins.backend.gen.CodeGenerator
直系の既知のサブクラス:
CodeGenerator_alpha, CodeGenerator_arm, CodeGenerator_mb, CodeGenerator_mips, CodeGenerator_ppc, CodeGenerator_sample, CodeGenerator_sh4, CodeGenerator_sparc, CodeGenerator_thumb, CodeGenerator_x86, CodeGenerator_x86_64, CodeGenerator_x86simd

public abstract class CodeGenerator
extends java.lang.Object

Abstract code generator. Generators for specific machines are defined as subclasses of this class.


入れ子クラスの概要
(パッケージプライベート) static class CodeGenerator.FunctionAttr
          Keeps track of function's attributes.
(パッケージプライベート)  class CodeGenerator.LexpToString
          Convert address expression to external form.
(パッケージプライベート)  class CodeGenerator.Match
          Node of matching tree (or DAG)
 
フィールドの概要
(パッケージプライベート)  int addrType
          Address type
(パッケージプライベート)  java.io.PrintWriter asmWriter
          Output Writer
(パッケージプライベート)  java.lang.String convention
          OS convention
(パッケージプライベート)  java.io.PrintWriter debOut
          Debugging message
(パッケージプライベート)  NumberSet disableRewrite
          Flags for disabling rescanning.
(パッケージプライベート) static int F128
           
(パッケージプライベート) static int F32
           
(パッケージプライベート) static int F64
           
(パッケージプライベート)  Function func
          Current function
(パッケージプライベート)  java.util.Map funcAttrTbl
          Function attribute tables.
(パッケージプライベート) static int I16
           
(パッケージプライベート) static int I32
           
(パッケージプライベート) static int I64
          Commonly used type constants.
(パッケージプライベート) static int I8
           
(パッケージプライベート) static int INLINECOPYUNIT
           
(パッケージプライベート)  CodeGenerator.LexpToString lexpConv
           
(パッケージプライベート)  LirFactory lir
          LIR factory
(パッケージプライベート)  LocalTransformer localEarlyRewritingTrig
          Early time pre-rewriting of LIR, function by function.
(パッケージプライベート)  LocalTransformer localLateRewritingTrig
          Late time pre-rewriting of LIR, function by function.
(パッケージプライベート)  java.lang.String machineName
          CPU name
(パッケージプライベート)  MachineParams machineParams
          Feature of Machine
(パッケージプライベート)  Module module
          L-Module
(パッケージプライベート)  boolean optSpeed
          Flag speed/space tradeoff.
(パッケージプライベート)  LocalTransformer ProcessFramesTrig
           
(パッケージプライベート)  Root root
          Global variables
(パッケージプライベート)  int typeParamWord
          Type of parameter words on stack
 
コンストラクタの概要
CodeGenerator()
          Creator
 
メソッドの概要
 int alignForType(int type)
          Return alignment for type.
(パッケージプライベート)  BiList buildCode(Function f)
          Convert FUNCTION to S-expression assembly code.
(パッケージプライベート)  ImList clcvnClobbers()
          Return clobber list
(パッケージプライベート)  LirNode clcvnParamMem(int type, int location, boolean caller)
          Return parameter memory
(パッケージプライベート)  int clcvnParamOffset(int location)
          Return offset of parameter
(パッケージプライベート)  LirNode clcvnParamReg(int type, int location, boolean caller)
          Return parameter register
(パッケージプライベート)  LirNode clcvnParamWord(int type, int location, boolean caller)
          Return parameter word - either register or memory.
(パッケージプライベート)  LirNode clcvnPartialWord(LirNode exp, int part)
          Return partial word of object
(パッケージプライベート)  void clcvnPassFloatRegMem(int location, LirNode arg, BiLink memp, BiLink regp, BiList alist)
          Pass floating point number to register/ register and memory.
(パッケージプライベート)  int clcvnRegLimit()
          Return number of registers multiply word-size.
(パッケージプライベート)  LirNode clcvnReturnValue(int type)
          Return return register
(パッケージプライベート)  LirNode clcvnSetPartialWord(LirNode lhs, int part, LirNode rhs)
          Set partial word of object
(パッケージプライベート)  boolean clcvnStructReturnAsFirst()
          Return true if struct return address
(パッケージプライベート)  LirNode clcvnStructReturnPtr(boolean caller)
          Create code that sets address of struct to hidden parameter.
 void close()
          Close output stream.
 ImList codeInfo(LirNode ins)
          Return cost and misc. information about instruction tree.
 LocalTransformer convToAsm()
           
(パッケージプライベート) abstract  java.lang.String defaultRegsetForType(int type)
          Return default register set for type.
(パッケージプライベート)  LirNode dropRegToFrame(LirNode node)
          Convert (REG t ...) node to (MEM t (FRAME I32 ...)).
 Transformer[] earlyRewritingSequence()
          Return early time pre-rewriting sequence.
(パッケージプライベート)  void emitAlign(java.io.PrintWriter out, int align)
          Emit align (Bytesize)
(パッケージプライベート)  java.lang.String emitAsmCode(java.lang.String format, ImList args)
          Emit asm instruction.
(パッケージプライベート)  void emitBeginningOfModule(Module mod, java.io.PrintWriter out)
          Emit beginning of module
(パッケージプライベート)  void emitBeginningOfSegment(java.io.PrintWriter out, java.lang.String segment)
          Emit beginning of segment
(パッケージプライベート)  void emitCode(BiList asmList, java.io.PrintWriter file)
          Emit S-expression assembly code to file.
(パッケージプライベート)  void emitCodeLabel(java.io.PrintWriter out, java.lang.String label)
          Emit label for code
(パッケージプライベート)  void emitComment(java.io.PrintWriter out, java.lang.String comment)
          print comment in assembly language.
(パッケージプライベート)  void emitCommon(java.io.PrintWriter out, SymStatic symbol, int bytes)
          Emit data common
(パッケージプライベート)  void emitData(java.io.PrintWriter out, int type, LirNode node)
          Emit data for big endian machine.
(パッケージプライベート)  void emitDataLabel(java.io.PrintWriter out, java.lang.String label)
          Emit label for data
(パッケージプライベート)  void emitEndOfModule(Module mod, java.io.PrintWriter out)
          Emit ending of module
(パッケージプライベート)  void emitEndOfSegment(java.io.PrintWriter out, java.lang.String segment)
          Emit end of segment
(パッケージプライベート)  void emitIdent(java.io.PrintWriter out, java.lang.String ident)
          Print .ident in assembly language.
(パッケージプライベート)  void emitLinkage(java.io.PrintWriter out, SymStatic symbol)
          Emit linkage information of symbol
(パッケージプライベート) abstract  java.lang.String emitLir(LirNode node)
          Expand emit-macro for LirNode.
(パッケージプライベート)  java.lang.String emitLirDefault(LirNode node)
          Default expansion action for LirNode.
(パッケージプライベート) abstract  java.lang.String emitList(ImList form, boolean topLevel)
          Expand emit-macro for list form.
(パッケージプライベート)  java.lang.String emitListDefault(ImList form, boolean topLevel)
          Default expansion action for S-expression.
 void emitNamedConst(java.lang.String name, LirNode value)
          Emit named constant.
(パッケージプライベート)  java.lang.String emitObject(java.lang.Object x)
          Convert S-expression assembly code to string.
(パッケージプライベート)  java.lang.String emitObjectX(java.lang.Object x, boolean top)
          Convert S-expression assembly code to string.
(パッケージプライベート)  void emitSegment(java.io.PrintWriter file, java.lang.String segment)
          Change default segment to segment.
(パッケージプライベート)  java.lang.String emitTop(java.lang.Object x)
          Convert toplevel S-expression assembly code to string.
(パッケージプライベート)  void emitZeros(java.io.PrintWriter out, int bytes)
          Emit data zeros
(パッケージプライベート)  boolean equalArg(LirNode x, LirNode y)
          Return true if variable x and y are same.
(パッケージプライベート) abstract  java.lang.Object expandBuildMacro(ImList form)
          Expand building macro for list form.
(パッケージプライベート)  boolean frameIsEmpty(Function f)
           
(パッケージプライベート)  int frameSize(Function f)
          Return frame size (in positive) of function.
 void genHeader(Module mod)
          Generate header on assembly file.
 void genTrailer(Module mod)
          Generate trailer on assembly file.
(パッケージプライベート) abstract  int getCost1(LirNode t, int goal)
          Return the cost for LIR node t and goal nonterminal goal.
(パッケージプライベート) abstract  int getCost2(LirNode t, int goal)
           
(パッケージプライベート)  CodeGenerator.FunctionAttr getFunctionAttr(Function func)
          Return function attributes.
 MachineParams getMachineParams()
          Return machineParams
(パッケージプライベート) abstract  Rule getRule(LirNode t, int goal)
          Return the chosen rule for LIR node t and goal nonterminal goal.
 void initialize(Root root, Module module, TargetMachine target, java.lang.String machine, java.lang.String convention)
          Set root pointer etc.
(パッケージプライベート)  void initializeMachineDep()
          Do Machine-dependent initialization (subclass may override this).
(パッケージプライベート) abstract  void initLabeling(LirFactory lir)
          Initialize for labeling.
(パッケージプライベート) abstract  void initRewriteLabeling()
          Initialization for rewriting.
(パッケージプライベート)  java.io.OutputStream insertPostProcessor(java.io.OutputStream stream)
          Insert post-processor filter pass.
 void instructionSelection(Function f)
          Rewrite a function so that each LIR tree corresponds to single machine instruction.
(パッケージプライベート)  boolean isComplex(LirNode node)
          Return true if node is a complex one.
(パッケージプライベート)  boolean isSimple(LirNode node)
          Return true if node is a simple variable.
(パッケージプライベート) abstract  void labelTree(LirNode t)
          Label LIR tree t.
 Transformer[] lateRewritingSequence()
          Return late time pre-rewriting sequence.
(パッケージプライベート)  java.lang.String makeAsmSymbol(java.lang.String symbol)
          Make symbol in assembly language form.
(パッケージプライベート)  java.lang.String makeLabelDef(java.lang.String label)
          Return label definition
(パッケージプライベート)  Symbol mapRegToFrame(Symbol reg)
          Return FRAME variable symbol entry which corresponds to REG variable.
(パッケージプライベート)  int nActualOperands(LirNode node)
          Return the number of operands excluding CLOBBER and USE.
(パッケージプライベート)  CodeGenerator.FunctionAttr newFunctionAttr(Function f)
          Prepare new function attribute information.
(パッケージプライベート)  LirNode noRescan(LirNode node)
          Disable rewriting of LIR node.
(パッケージプライベート)  void notifyEndToPostProcessor()
          Notify end of assembly to post-processor.
(パッケージプライベート)  int paramOffset(LirNode arg)
          Return offset of the formal parameter (used by va_start).
(パッケージプライベート)  int paramToBeSaved()
          Return the location of parameter which should be reside on memory.
(パッケージプライベート)  void peepHoleOpt(BiList list)
          Peep-hole optimizer.
(パッケージプライベート)  LirNode phyReg(java.lang.String name)
          Return physical register node.
 void prepareCodeInfo(Function f)
           
 void prerewrite(Function f, java.lang.String phase)
          Pre-rewrite of L-Function.
(パッケージプライベート)  void printLabel(LirNode t, java.lang.String indent)
          Print label of tree t.
(パッケージプライベート) abstract  java.lang.Object quiltLir(LirNode node)
          Expand building macro for LirNode.
(パッケージプライベート)  java.lang.Object quiltLirDefault(LirNode node)
          Expand LirNode
(パッケージプライベート)  CodeGenerator.Match reduce(LirNode t, int goal)
          Reduce labeled tree t with goal nonterminal goal.
(パッケージプライベート)  SymAuto reserveFrame(java.lang.String name, int type)
          Reserve frame variable.
(パッケージプライベート)  LirNode rewriteAggregateCopy(LirNode node, BiList pre)
          Rewrite aggregate copy.
(パッケージプライベート)  LirNode rewriteAsm(LirNode node, BiList pre, BiList post)
          Rewrite ASM
(パッケージプライベート)  LirNode rewriteCall(LirNode node, BiList pre, BiList post)
          Rewrite CALL.
(パッケージプライベート)  LirNode rewriteCONVFU(LirNode node, BiList pre)
          Rewrite CONVFU(x) to: if (x < 2147483648) CONVFS(x) else CONVFS(x - 2147483648) + 214748648
(パッケージプライベート)  LirNode rewriteCONVUF(LirNode node, BiList pre)
          Rewrite CONVUF
(パッケージプライベート)  LirNode rewriteEpilogue(LirNode node, BiList pre)
          Rewrite EPILOGUE
(パッケージプライベート)  LirNode rewriteFrame(LirNode node)
          Rewrite FRAME node to target machine form.
(パッケージプライベート)  LirNode rewriteJumpn(LirNode node, BiList pre)
          Rewrite JUMPN.
(パッケージプライベート)  LirNode rewritePrologue(LirNode node, BiList post)
          Rewrite PROLOGUE
(パッケージプライベート) abstract  LirNode rewriteTree(LirNode tree, java.lang.String phase, BiList pre, BiList post)
          Rewrite L-expression.
(パッケージプライベート)  java.lang.String segmentForConst()
          Return segment for read-only constant.
 void setAsmStream(java.io.OutputStream stream)
          Set assembler output stream.
(パッケージプライベート) abstract  java.lang.String showLabel(LirNode t)
          Return label state
(パッケージプライベート) abstract  int startNT()
          Return start nonterminal symbol.
 
クラス java.lang.Object から継承したメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

I64

static final int I64
Commonly used type constants.


I32

static final int I32

I16

static final int I16

I8

static final int I8

F128

static final int F128

F64

static final int F64

F32

static final int F32

root

Root root
Global variables


module

Module module
L-Module


debOut

java.io.PrintWriter debOut
Debugging message


machineParams

MachineParams machineParams
Feature of Machine


addrType

int addrType
Address type


typeParamWord

int typeParamWord
Type of parameter words on stack


machineName

java.lang.String machineName
CPU name


convention

java.lang.String convention
OS convention


funcAttrTbl

java.util.Map funcAttrTbl
Function attribute tables.


optSpeed

boolean optSpeed
Flag speed/space tradeoff.


func

Function func
Current function


lir

LirFactory lir
LIR factory


asmWriter

java.io.PrintWriter asmWriter
Output Writer


disableRewrite

NumberSet disableRewrite
Flags for disabling rescanning.


localEarlyRewritingTrig

final LocalTransformer localEarlyRewritingTrig
Early time pre-rewriting of LIR, function by function.


localLateRewritingTrig

final LocalTransformer localLateRewritingTrig
Late time pre-rewriting of LIR, function by function.


ProcessFramesTrig

final LocalTransformer ProcessFramesTrig

INLINECOPYUNIT

static final int INLINECOPYUNIT
関連項目:
定数フィールド値

lexpConv

CodeGenerator.LexpToString lexpConv
コンストラクタの詳細

CodeGenerator

public CodeGenerator()
Creator

メソッドの詳細

initialize

public void initialize(Root root,
                       Module module,
                       TargetMachine target,
                       java.lang.String machine,
                       java.lang.String convention)
Set root pointer etc. This class is created by newInstance() so constructor can't take arguments.


setAsmStream

public void setAsmStream(java.io.OutputStream stream)
Set assembler output stream.


insertPostProcessor

java.io.OutputStream insertPostProcessor(java.io.OutputStream stream)
Insert post-processor filter pass. Subclasses may override it.


notifyEndToPostProcessor

void notifyEndToPostProcessor()
Notify end of assembly to post-processor. Subclasses may override it.


initializeMachineDep

void initializeMachineDep()
Do Machine-dependent initialization (subclass may override this).


getFunctionAttr

CodeGenerator.FunctionAttr getFunctionAttr(Function func)
Return function attributes.


noRescan

LirNode noRescan(LirNode node)
Disable rewriting of LIR node.


prerewrite

public void prerewrite(Function f,
                       java.lang.String phase)
Pre-rewrite of L-Function.


initRewriteLabeling

abstract void initRewriteLabeling()
Initialization for rewriting.


rewriteTree

abstract LirNode rewriteTree(LirNode tree,
                             java.lang.String phase,
                             BiList pre,
                             BiList post)
Rewrite L-expression.


earlyRewritingSequence

public Transformer[] earlyRewritingSequence()
Return early time pre-rewriting sequence.


lateRewritingSequence

public Transformer[] lateRewritingSequence()
Return late time pre-rewriting sequence.


frameSize

int frameSize(Function f)
Return frame size (in positive) of function.


frameIsEmpty

boolean frameIsEmpty(Function f)

dropRegToFrame

LirNode dropRegToFrame(LirNode node)
Convert (REG t ...) node to (MEM t (FRAME I32 ...)).


mapRegToFrame

Symbol mapRegToFrame(Symbol reg)
Return FRAME variable symbol entry which corresponds to REG variable.


reserveFrame

SymAuto reserveFrame(java.lang.String name,
                     int type)
Reserve frame variable.


rewriteAggregateCopy

LirNode rewriteAggregateCopy(LirNode node,
                             BiList pre)
Rewrite aggregate copy. Subclasses may override this.


paramToBeSaved

int paramToBeSaved()
Return the location of parameter which should be reside on memory.


paramOffset

int paramOffset(LirNode arg)
Return offset of the formal parameter (used by va_start).


equalArg

boolean equalArg(LirNode x,
                 LirNode y)
Return true if variable x and y are same.


rewritePrologue

LirNode rewritePrologue(LirNode node,
                        BiList post)
Rewrite PROLOGUE


rewriteEpilogue

LirNode rewriteEpilogue(LirNode node,
                        BiList pre)
Rewrite EPILOGUE


isComplex

boolean isComplex(LirNode node)
Return true if node is a complex one.


phyReg

LirNode phyReg(java.lang.String name)
Return physical register node.


rewriteCall

LirNode rewriteCall(LirNode node,
                    BiList pre,
                    BiList post)
Rewrite CALL. Subclasses may override this.


clcvnRegLimit

int clcvnRegLimit()
Return number of registers multiply word-size.


clcvnParamWord

LirNode clcvnParamWord(int type,
                       int location,
                       boolean caller)
Return parameter word - either register or memory.


clcvnParamReg

LirNode clcvnParamReg(int type,
                      int location,
                      boolean caller)
Return parameter register


clcvnParamMem

LirNode clcvnParamMem(int type,
                      int location,
                      boolean caller)
Return parameter memory


clcvnPassFloatRegMem

void clcvnPassFloatRegMem(int location,
                          LirNode arg,
                          BiLink memp,
                          BiLink regp,
                          BiList alist)
Pass floating point number to register/ register and memory.


clcvnParamOffset

int clcvnParamOffset(int location)
Return offset of parameter


clcvnReturnValue

LirNode clcvnReturnValue(int type)
Return return register


clcvnSetPartialWord

LirNode clcvnSetPartialWord(LirNode lhs,
                            int part,
                            LirNode rhs)
Set partial word of object


clcvnPartialWord

LirNode clcvnPartialWord(LirNode exp,
                         int part)
Return partial word of object


clcvnClobbers

ImList clcvnClobbers()
Return clobber list


clcvnStructReturnAsFirst

boolean clcvnStructReturnAsFirst()
Return true if struct return address


clcvnStructReturnPtr

LirNode clcvnStructReturnPtr(boolean caller)
Create code that sets address of struct to hidden parameter. Subclasses may override this.


rewriteJumpn

LirNode rewriteJumpn(LirNode node,
                     BiList pre)
Rewrite JUMPN. Subclasses may override this.


rewriteAsm

LirNode rewriteAsm(LirNode node,
                   BiList pre,
                   BiList post)
Rewrite ASM


nActualOperands

int nActualOperands(LirNode node)
Return the number of operands excluding CLOBBER and USE.


instructionSelection

public void instructionSelection(Function f)
Rewrite a function so that each LIR tree corresponds to single machine instruction.


genHeader

public void genHeader(Module mod)
Generate header on assembly file.


convToAsm

public LocalTransformer convToAsm()

emitNamedConst

public void emitNamedConst(java.lang.String name,
                           LirNode value)
Emit named constant.


buildCode

BiList buildCode(Function f)
Convert FUNCTION to S-expression assembly code.


prepareCodeInfo

public void prepareCodeInfo(Function f)

codeInfo

public ImList codeInfo(LirNode ins)
Return cost and misc. information about instruction tree.

パラメータ:
ins - instruction L-expression tree which are alpready reduced.
戻り値:
ImList of (hasDelaySlot, cost)

quiltLirDefault

java.lang.Object quiltLirDefault(LirNode node)
Expand LirNode


peepHoleOpt

void peepHoleOpt(BiList list)
Peep-hole optimizer. This method is dummy; Subclasses may override this.


emitCode

void emitCode(BiList asmList,
              java.io.PrintWriter file)
Emit S-expression assembly code to file.


emitTop

java.lang.String emitTop(java.lang.Object x)
Convert toplevel S-expression assembly code to string.


emitObject

java.lang.String emitObject(java.lang.Object x)
Convert S-expression assembly code to string.


emitObjectX

java.lang.String emitObjectX(java.lang.Object x,
                             boolean top)
Convert S-expression assembly code to string.

パラメータ:
top - true if this is a top-level.

emitListDefault

java.lang.String emitListDefault(ImList form,
                                 boolean topLevel)
Default expansion action for S-expression.


emitLirDefault

java.lang.String emitLirDefault(LirNode node)
Default expansion action for LirNode. (obsoleted)


genTrailer

public void genTrailer(Module mod)
Generate trailer on assembly file.


close

public void close()
Close output stream.


emitSegment

void emitSegment(java.io.PrintWriter file,
                 java.lang.String segment)
Change default segment to segment.


printLabel

void printLabel(LirNode t,
                java.lang.String indent)
Print label of tree t.


reduce

CodeGenerator.Match reduce(LirNode t,
                           int goal)
                     throws NoMatchException
Reduce labeled tree t with goal nonterminal goal.

NoMatchException

isSimple

boolean isSimple(LirNode node)
Return true if node is a simple variable.


rewriteCONVUF

LirNode rewriteCONVUF(LirNode node,
                      BiList pre)
Rewrite CONVUF


rewriteCONVFU

LirNode rewriteCONVFU(LirNode node,
                      BiList pre)
Rewrite CONVFU(x) to: if (x < 2147483648) CONVFS(x) else CONVFS(x - 2147483648) + 214748648


initLabeling

abstract void initLabeling(LirFactory lir)
Initialize for labeling.


showLabel

abstract java.lang.String showLabel(LirNode t)
Return label state


labelTree

abstract void labelTree(LirNode t)
Label LIR tree t.


getRule

abstract Rule getRule(LirNode t,
                      int goal)
Return the chosen rule for LIR node t and goal nonterminal goal.


getCost1

abstract int getCost1(LirNode t,
                      int goal)
Return the cost for LIR node t and goal nonterminal goal.


getCost2

abstract int getCost2(LirNode t,
                      int goal)

startNT

abstract int startNT()
Return start nonterminal symbol.


defaultRegsetForType

abstract java.lang.String defaultRegsetForType(int type)
Return default register set for type.


emitList

abstract java.lang.String emitList(ImList form,
                                   boolean topLevel)
Expand emit-macro for list form.


emitLir

abstract java.lang.String emitLir(LirNode node)
Expand emit-macro for LirNode.


expandBuildMacro

abstract java.lang.Object expandBuildMacro(ImList form)
Expand building macro for list form.


quiltLir

abstract java.lang.Object quiltLir(LirNode node)
Expand building macro for LirNode.


rewriteFrame

LirNode rewriteFrame(LirNode node)
Rewrite FRAME node to target machine form.


emitIdent

void emitIdent(java.io.PrintWriter out,
               java.lang.String ident)
Print .ident in assembly language.


emitComment

void emitComment(java.io.PrintWriter out,
                 java.lang.String comment)
print comment in assembly language.


emitBeginningOfModule

void emitBeginningOfModule(Module mod,
                           java.io.PrintWriter out)
Emit beginning of module


emitEndOfModule

void emitEndOfModule(Module mod,
                     java.io.PrintWriter out)
Emit ending of module


emitBeginningOfSegment

void emitBeginningOfSegment(java.io.PrintWriter out,
                            java.lang.String segment)
Emit beginning of segment


emitEndOfSegment

void emitEndOfSegment(java.io.PrintWriter out,
                      java.lang.String segment)
Emit end of segment


emitLinkage

void emitLinkage(java.io.PrintWriter out,
                 SymStatic symbol)
Emit linkage information of symbol


emitDataLabel

void emitDataLabel(java.io.PrintWriter out,
                   java.lang.String label)
Emit label for data


emitCodeLabel

void emitCodeLabel(java.io.PrintWriter out,
                   java.lang.String label)
Emit label for code


emitAlign

void emitAlign(java.io.PrintWriter out,
               int align)
Emit align (Bytesize)


emitCommon

void emitCommon(java.io.PrintWriter out,
                SymStatic symbol,
                int bytes)
Emit data common


emitZeros

void emitZeros(java.io.PrintWriter out,
               int bytes)
Emit data zeros


emitAsmCode

java.lang.String emitAsmCode(java.lang.String format,
                             ImList args)
Emit asm instruction.


emitData

void emitData(java.io.PrintWriter out,
              int type,
              LirNode node)
Emit data for big endian machine. Redefine this method if your machine is little endian.


newFunctionAttr

CodeGenerator.FunctionAttr newFunctionAttr(Function f)
Prepare new function attribute information.


alignForType

public int alignForType(int type)
Return alignment for type.


segmentForConst

java.lang.String segmentForConst()
Return segment for read-only constant.


makeAsmSymbol

java.lang.String makeAsmSymbol(java.lang.String symbol)
Make symbol in assembly language form. Prepend '_' in case of old a.out binary.


makeLabelDef

java.lang.String makeLabelDef(java.lang.String label)
Return label definition


getMachineParams

public MachineParams getMachineParams()
Return machineParams