|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--scale.common.Machine
This is the base class for all machine specific information.
$Id: Machine.java,v 1.7 2002/01/03 21:44:38 burrill Exp $
Copyright 2002 by the Scale Compiler Group,
Department of Computer Science
University of Massachusetts,
Amherst MA. 01003, USA
All Rights Reserved.
| Field Summary | |
protected int |
aligned
|
static int |
ALIGNED
Items in memory should be aligned on the proper boundary. |
protected int |
blockSize
|
protected int |
cacheSize
|
static Machine |
currentMachine
The current machine specification. |
static int |
UNALIGNED
Items in memory do not need to be aligned on the proper boundary. |
| Constructor Summary | |
Machine(int aligned)
Create a Machine instance. |
|
| Method Summary | |
abstract void |
addEDGCFlags(Vector v)
Add the flags necessary for the EDG C front end. |
abstract int |
addressableMemoryUnits(int bitSize)
Return the number of addressable units required |
abstract int |
alignData(int dataSize)
Return the integer value alignmentthat satisfies |
static int |
alignTo(int value,
int to)
Round up a value so that it is evenly divisible by the second value. |
abstract int |
generalAlignment()
Return the most general purpose alignment in memory units. |
int |
getAligned()
Return the alignment specified for the machine. |
int |
getCacheDistance(int typeSize)
|
abstract boolean |
littleEndian()
Return true if the machine is little-endian. |
abstract boolean |
simpleFloat(double value)
Return true if it is faster to generate the floating point value than to load it. |
abstract boolean |
simpleInteger(long value)
Return true if it is faster to generate the integer value than to load it. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static Machine currentMachine
public static final int ALIGNED
public static final int UNALIGNED
protected int aligned
protected int cacheSize
protected int blockSize
| Constructor Detail |
public Machine(int aligned)
aligned - == UNALIGNED if data alignment not required| Method Detail |
public int getAligned()
public abstract int alignData(int dataSize)
0 == address % alignmentfor the data size specified.
dataSize - is the size of the data in addressable units.public abstract int addressableMemoryUnits(int bitSize)
bitSize - is the number of bits required for the datapublic abstract boolean simpleInteger(long value)
public abstract boolean simpleFloat(double value)
public static int alignTo(int value,
int to)
value - - returned rounded upto - - specifies the divisorpublic abstract void addEDGCFlags(Vector v)
public abstract int generalAlignment()
public abstract boolean littleEndian()
public int getCacheDistance(int typeSize)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||