Altera Floating-Point User Manual

Page 126

Advertising
background image

Port Name

Type

Required

Description

WIDTH_DATA

Integer

Yes

Specifies the input data width.
If the operation is

INT2FLOAT

, the

WIDTH_DATA

is also

WIDTH_INT

.

If the operation is

FIXED2FLOAT

, the data width value is

WIDTH_INT

+ fractional width.

If the operation is

FLOAT2FIXED

,

FLOAT2INT

or

FLOAT2FLOAT

, the data width value is

WIDTH_EXP_INPUT

+

WIDTH_MAN_INPUT

+

1

.

The available settings are

32

bits,

64

bits or n bits. For n

bits settings, the range is from

4

bits to

64

bits.

WIDTH_EXP_

OUTPUT

Integer

Yes

Specifies the precision of the exponent. If this parameter

is not specified, the default is

8

. The bias of the exponent

is always set to

2

(WIDTH_EXP - 1) -

1

, that is,

127

for

the single-precision format and

1023

for the double-

precision format. The value of

WIDTH_EXP_OUTPUT

must

be

8

for the single-precision format,

11

for the double-

precision format, and a minimum of

11

for the single-

extended precision format. The value of

WIDTH_EXP_

OUTPUT

must be less than the value of

WIDTH_MAN_

OUTPUT

, and the sum of

WIDTH_EXP_OUTPUT

and

WIDTH_

MAN_OUTPUT

must be less than

64

. These settings apply

only to the

FLOAT2FIXED

,

FLOAT2INT

, and

FLOAT2FLOAT

operation modes.

WIDTH_MAN_

OUTPUT

Integer

Yes

Specifies the precision of the mantissa. If this parameter

is not specified, the default is

23

. When

WIDTH_EXP_

OUTPUT

is

8

and the floating point format is single-

precision, the

WIDTH_MAN_OUTPUT

value must be

23

.

Otherwise, the value of

WIDTH_MAN_OUTPUT

must be a

minimum of

31

. The value of

WIDTH_MAN_OUTPUT

must

be greater than the value of

WIDTH_EXP_OUTPUT

, and the

sum of

WIDTH_EXP_OUTPUT

and

WIDTH_MAN_OUTPUT

must

be less than

64

. These settings apply only to the

FLOAT2FIXED

,

FLOAT2INT

, and

FLOAT2FLOAT

operation

modes.

WIDTH_RESULT

Integer

Yes

Specifies the width of the output result. In an

INT2FLOAT

,

FLOAT2FLOAT

, or

FIXED2FLOAT

operation, the result

width is

WIDTH_EXP_OUTPUT

+

WIDTH_MAN_OUTPUT

+

1

.

In a

FLOAT2INT

operation, the result width is the value of

the

WIDTH_INT

parameter.

In a

FLOAT2FIXED

operation, this parameter is the result

width.
The available settings are

32

bits,

64

bits or n bits. For n

bits settings, the range is from

4

bits to

64

bits.

ROUNDING

Integer

Yes

Specifies the rounding mode. The default value is

TO_

NEAREST

. Other modes are not supported.

UG-01058

2014.12.19

ALTFP_CONVERT Parameters

17-11

ALTFP_CONVERT IP Core

Altera Corporation

Send Feedback

Advertising