Operator ROM

Operator Library: Memory

ROM operator 是一个动态内容的查找表(LUT)。 输入 link 的值定义了 LUT 的地址。 输出 link 提供存储在该地址处的值。 输入 Bit Width 定义了 LUT 中的地址数量。 输出 Bit Width 定义了每个 LUT 元素的取值范围。 两者都可以设置为任意值。 LUT 内容可以在构建之前更改,也可以在运行时动态更改。

有关 operator 延迟的信息,请参见 Table 46, 'Individual Latencies of the Operators in Library Memory'。

[提示] 与 operator LUT 相同

ROM operator 与 operator LUT 相同。

I/O Property

Property 值
Operator Type O
Input Link I, image data input
Output Link O,数据输入

Supported Link Format

Link Parameter Input Link I Output Link O
Bit Width [1, 16] [1, 63 无符号 / 64 有符号]
Arithmetic {unsigned, signed} as I
Parallelism any as I
Kernel Columns any as I
Kernel Rows any as I
Img Protocol {VALT_IMAGE2D, VALT_LINE1D, VALT_PIXEL0D} as I
Color Format VAF_GRAY as I
Color Flavor FL_NONE as I
Max. Img Width any as I
Max. Img Height any as I

参数

ROMcontent
键入 动态/静态读/写参数
默认 恒等函数
范围 [0, 2^OutputBitWidth-1]

此字段参数定义了 LUT 内容。 字段值的数量由 operator 的输入 Bit Width 定义。

了解如何配置字段参数,请参见 'Parameter Editing'。

[注意] 输入 Bit Width 已更改

如果更改了输入 Bit Width,此参数中的字段元素数量也会随之改变。 如果减小输入 Bit Width,值将被截断并删除。 如果增大输入 Bit Width,新的字段元素将设置为 0。

ImplementationType
键入 静态写参数
默认 AUTO
范围 (AUTO, BRAM, LUTRAM)

参数 ImplementationType 影响 operator 的实现策略,即 使用哪些内存元素来实现该 operator。

您可以选择以下值之一:

AUTO: 根据所连接 link 的参数化, 自动选择最佳实现策略。

BRAM: operator 使用 FPGA 的 Block RAM。

LUTRAM: operator 使用 FPGA 的 LUT RAM。

[注意] 通常使用 AUTO

通常,该参数应设置为 AUTO。 在特殊情况下,即当设计中的某种 FPGA 资源短缺时, 您可以使用值 BRAM 或 LUTRAM 手动干预 FPGA 资源管理。

使用示例

以下示例展示了 ROM operator 的使用: