JML

org.multijava.util.backend
Class StackSchleduler

java.lang.Object
  extended byorg.multijava.util.backend.TreeWalker
      extended byorg.multijava.util.backend.StackSchleduler

public class StackSchleduler
extends TreeWalker

This class tries to find the best schleduling to minimize local vars


Field Summary
private  Stack stack
           
 
Fields inherited from class org.multijava.util.backend.TreeWalker
 
Constructor Summary
StackSchleduler(BasicBlock[] bblocks, BasicBlock[] eblocks)
          Creates a new instruction handle.
 
Method Summary
private  QQuadruple getNode(int pos)
           
private  QTemporary getTemp(int pos)
           
private static boolean isInList(QTemporary temp, QTemporary[] list)
           
protected  void kill()
          Called when a branch is reached
protected  void processNode(QNode node)
          Processes the node
 void run()
          Runs the deadcode algorithm
 
Methods inherited from class org.multijava.util.backend.TreeWalker
getBasicBlock, removeNode, traverse
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

stack

private Stack stack
Constructor Detail

StackSchleduler

public StackSchleduler(BasicBlock[] bblocks,
                       BasicBlock[] eblocks)
Creates a new instruction handle.

Method Detail

run

public void run()
Runs the deadcode algorithm


processNode

protected void processNode(QNode node)
Processes the node

Parameters:
node - the node to be processed

kill

protected void kill()
Called when a branch is reached

Overrides:
kill in class TreeWalker

getTemp

private QTemporary getTemp(int pos)

getNode

private QQuadruple getNode(int pos)

isInList

private static boolean isInList(QTemporary temp,
                                QTemporary[] list)

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.