Skip to content

WIP: Merges for documentation and to support LIFCL 33/33U#49

Open
jdavidberger wants to merge 19 commits intogatecat:masterfrom
jdavidberger:master
Open

WIP: Merges for documentation and to support LIFCL 33/33U#49
jdavidberger wants to merge 19 commits intogatecat:masterfrom
jdavidberger:master

Conversation

@jdavidberger
Copy link

The changes here are related to:

  • Updated documentation
  • Support for adding new platform types in general
  • Support for platforms LIFCL 33/33U
  • Somewhat faster fuzzing -- mostly by cacheing more things

@jdavidberger jdavidberger changed the title Merges for documentation and to support LIFCL 33/33U WIP: Merges for documentation and to support LIFCL 33/33U Jan 28, 2026

A given bel might span over multiple logical tiles. It's anchor tile is the one with the appropriate tiletype but for routing information on where the related tile is there is rel_x and rel_y; which encode the relative tile offset for the related tile. This data can be varied based on the family, device and actual tile in question.

For bels with these offsets, the offset information is used in fuzzing the routing to map the interconnect. The offset themselves can be devined from the output of the dev_get_nodes command and report for nearby CIB tiles. For instance, related tiles to LRAM will have LRAM_CORE wires in their tile.
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick: derived

The bitstreams are stored compressed and libprjoxide can read them compressed. Instead of copying the files around, the
cache fetch generates symbolic links.

This folder should be cleared very rarely.
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

most notably it needs to be cleared if you want to switch radiant version

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not realize this. I think it makes sense to make the radiant version as part of the hash path. I'll probably make it check both old and new too so my current cache isn't burnt

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That sounds like a good plan

This serves as a master listing of each device and metadata associated with that device:

- packages: Comes from various lattice documentation, can also be seen by looking at the radiant device selection dialog.
- frame metadata: There are various necessary peices of data here. All are available in the "sysCONFIG Guide for Nexus Platform" document from the lattice website.
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be nice to expand this a bit more?

@@ -0,0 +1,9 @@

(* \db:architecture ="LFCPNX", \db:device ="LFCPNX-40", \db:package ="LFG672", \db:speed ="7_High-Performance_1.0V", \db:timestamp =1576073342, \db:view ="physical" *)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

huh, is there an LFCPNX-40 device?


cfg = FuzzConfig(job="PLCROUTE", device="LIFCL-40", sv="../shared/route_40.v", tiles=["R16C22:PLC"])
def run_cfg(device):
tile = list(tiles.get_tiles_by_tiletype(device, "PLC").keys())[0]
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there was a degree of caution not to pick a tile too close to the edge of the device because that could falsely cause some extra edge routing to be included, have you checked this?

"PIOA.SEIO18.BASE_TYPE" => vec![Bel::make_seio18(0)],
"PIOB.SEIO18.BASE_TYPE" => vec![Bel::make_seio18(1)],
"PIOA.DIFFIO18.BASE_TYPE" => vec![Bel::make_diffio18()],
"PIOB.DIFFIO18.BASE_TYPE" => vec![Bel::make_diffio18()],
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think PIOB.DIFFIO18 should ever happen?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so either, will remove

if in_metadata && self.check_preamble(&COMMENT_END) {
if curr_meta.len() > 0 {
self.metadata.push(curr_meta.to_string());
if curr_meta.is_ascii() {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like spaces and tabs got mixed here?

if dev == "LFCPNX-100":
return tap_frame_to_col_100
elif dev == "LIFCL-40" or dev == "LFDN2X-40":
elif dev == "LIFCL-40" or dev == "LFDN2X-40" or dev == "LFD2NX-40":
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like LFD2NX-40 got duplicated here

self.name = name
self.desc = desc
self.depth = depth
self.enable_value = enable_value
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might be worth documenting what "enable_value" actually means/does?

PinSetting(name="ENCLKOS4", dir="in", desc="Enable E output (CLKOS4). Active high. PLL CIB input.", bits=None),
PinSetting(name="ENCLKOS5", dir="in", desc="Enable F output (CLKOS5). Active high. PLL CIB input.", bits=None),
PinSetting(name="FBKCK", dir="in", desc="", bits=None),
PinSetting(name="LEGACY", dir="in", desc="PLL legacy mode signal. Active high to enter the mode. Enabled by lmmi_legacy fuse. PLL CIB input.", bits=None),
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we shouldn't scrape descriptions from the lattice html unfortunately. It creates a theoretical copyright issue (as this is text rather than just a raw fact about an FPGA) particularly when they often reference weird lattice internal things, even if they're public facing docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants