All Packages Class Hierarchy This Package Previous Next Index
java.lang.Object
|
+----byucc.jhdl.base.Nameable
|
+----byucc.jhdl.base.Node
|
+----byucc.jhdl.base.Cell
|
+----byucc.jhdl.base.Structural
|
+----byucc.jhdl.Logic.Logic
|
+----byucc.jhdl.modgen.fp.floatMult
Floating Point Multiplier with generic sized exponent and mantissa

FloatMult takes in two inputs of the same size, multiplies the two together using floating point arithmetic, and then outputs the result. The output must be the same size as the inputs, otherwise an exception is thrown.
In addition, the floating point multiplier can take into consideration special numbers. For example, an input of all zeros represents the numeric value 0. If the exponent is all ones and the mantissa is all zeros, this can represent +/- infinity. If the exponent is all ones, but the mantissa is not all zeros, this represents NaN, or Not a Number. This floating point multiplier doesn't support denormalized numbers, or numbers with zeros as the exponent and something nonzero as the mantissa.
The floating point multiplier checks for overflow and underflow as it does the multiply. This condition occurs when the exponent field isn't large enough to hold the new calculated exponent.
CLB count:
public static CellInterface cell_interface[]
public static final String cellname
public floatMult(Node parent,
Wire in1,
Wire in2,
Wire clk_en,
Wire out,
Wire flowError,
int expSize,
int pipeDepth)
parent - Parent of the class (this)
in1 - input 1
in2 - input 2
clk_en - clock enable
out - the output of the floating point multiplier
flowError - 1 = overflow or underflow occurred
expSize - the size of the exponent
pipeDepth - determines the number of pipestages
public String getCellName()
public int getMantSize()
public int getDelayDepth()
public void reset()
public void clock()
public void propagate()
protected boolean defaultSimulationModelIsBehavioral()
public long[] compute(long in1,
long in2,
int width,
int expSize,
int mantSize)
in1 - input 1
in2 - input 2
width - the input and output width
expSize - the size of the exponent
mantSize - the size of the mantissa
All Packages Class Hierarchy This Package Previous Next Index