FABulous.fabric_definition.Fabric
FPGA fabric definition module.
This module contains the Fabric class which represents the complete FPGA fabric
including tile layout, configuration parameters, and connectivity information. The
fabric is the top-level container for all tiles, BELs, and routing resources.
Classes
-
class Fabric[source]
Store the configuration of a fabric.
All the information is parsed from the CSV file.
-
tile[source]
The tile map of the fabric
- Type:
list[list[Tile]]
-
name[source]
The name of the fabric
- Type:
str
-
numberOfRows[source]
The number of rows of the fabric
- Type:
int
-
numberOfColumns[source]
The number of columns of the fabric
- Type:
int
-
configBitMode[source]
The configuration bit mode of the fabric.
Currently supports frame based or ff chain
- Type:
ConfigBitMode
-
frameBitsPerRow[source]
The number of frame bits per row of the fabric
- Type:
int
-
maxFramesPerCol[source]
The maximum number of frames per column of the fabric
- Type:
int
-
package[source]
The extra package used by the fabric. Only useful for VHDL output.
- Type:
str
-
generateDelayInSwitchMatrix[source]
The amount of delay in a switch matrix.
- Type:
int
-
multiplexerStyle[source]
The style of the multiplexer used in the fabric.
Currently supports custom or generic
- Type:
MultiplexerStyle
-
frameSelectWidth[source]
The width of the frame select signal.
- Type:
int
-
rowSelectWidth[source]
The width of the row select signal.
- Type:
int
-
desync_flag[source]
The flag indicating desynchronization status,
used to manage timing issues within the fabric.
- Type:
int
-
numberOfBRAMs[source]
The number of BRAMs in the fabric.
- Type:
int
-
superTileEnable[source]
Whether the fabric has super tile.
- Type:
bool
-
tileDic[source]
A dictionary of tiles used in the fabric. The key is the name of the tile and
the value is the tile.
- Type:
dict[str, Tile]
-
superTileDic[source]
A dictionary of super tiles used in the fabric. The key is the name of the
supertile and the value is the supertile.
- Type:
dict[str, SuperTile]
-
unusedTileDic[source]
A dictionary of tiles that are not used in the fabric,
but defined in the fabric.csv.
The key is the name of the tile and the value is the tile.
- Type:
dict[str, Tile]
-
unusedSuperTileDic[source]
A dictionary of super tiles that are not used in the fabric,
but defined in the fabric.csv.
The key is the name of the tile and the value is the tile.
- Type:
dict[str, SuperTile]
-
commonWirePair[source]
A list of common wire pairs in the fabric.
- Type:
list[tuple[str, str]]
Methods:
-
getAllUniqueBels()[source]
Get all unique BELs from all tiles in the fabric.
- Returns:
A list of all unique BELs across all tiles.
- Return type:
list[Bel]
-
getBelsByTileXY(x, y)[source]
Get all the Bels of a tile.
- Parameters:
-
- Returns:
A list of Bels in the tile.
- Return type:
list[Bel]
- Raises:
ValueError – Tile coordinates are out of range.
-
getSuperTileByName(name)[source]
Get a supertile by its name from the fabric.
Searches for the supertile first in the used supertiles dictionary, then in the
unused supertiles dictionary if not found.
- Parameters:
name (str) – The name of the supertile to retrieve.
- Returns:
The super tile object if found.
- Return type:
SuperTile | None
- Raises:
KeyError – If the super tile name is not found in either used or unused super tiles.
-
getTileByName(name)[source]
Get a tile by its name from the fabric.
Search for the tile first in the used tiles dictionary, then in the unused tiles
dictionary if not found.
- Parameters:
name (str) – The name of the tile to retrieve.
- Returns:
The tile object if found.
- Return type:
Tile | None
- Raises:
KeyError – If the tile name is not found in either used or unused tiles.