Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
d9b027d
rc1 jar
clavin-xlnx Jun 12, 2024
1ea6acb
Merge branch 'master' into 2024.1.1
clavin-xlnx Jun 21, 2024
9fe8131
rc2
clavin-xlnx Jun 21, 2024
532b001
Remove flawed loop intended to for encrypted cell removal (#1023)
clavin-xlnx Jul 3, 2024
0aea28f
Adding legacy support for u280 (#1021)
clavin-xlnx Jul 3, 2024
2a87520
Adds UNKWN state for LSFJobs (#1027)
clavin-xlnx Jul 10, 2024
4d45419
Merge branch 'master' into 2024.1.1
clavin-xlnx Jul 10, 2024
7b3fd0a
rc3
clavin-xlnx Jul 10, 2024
475f3f5
[RWRoute] Do not assume Y = 0 has Laguna tiles, since it could be HBM…
eddieh-xlnx Jul 10, 2024
a7b940f
[RWRoute] Do not NPE on encrypted netlists (#1025)
eddieh-xlnx Jul 10, 2024
1979e17
Test for site routing from raw placed design (#1000)
clavin-xlnx Jul 11, 2024
d06c22c
Adding HDIOB types
clavin-xlnx Jul 12, 2024
64d14f2
Merge branch 'vp1902_interchange_support_routing' into large_intercha…
clavin-xlnx Jul 12, 2024
a55fac3
Adding HDIOB types (#1028)
clavin-xlnx Jul 12, 2024
8131a23
[EDIFTools] writeTclLoadScriptForPartialEncryptedDesigns abspath (#1029)
eddieh-xlnx Jul 12, 2024
f541555
Add TestSite.testGetIntTile() (#1022)
eddieh-xlnx Jul 12, 2024
baa5e1e
Adds multi-message support for logical/physical netlists
clavin-xlnx Jul 13, 2024
0b30fed
Disable/update tests for multi-message, other fixes
clavin-xlnx Jul 13, 2024
ded6be5
Add missing import
clavin-xlnx Jul 13, 2024
dfe44f3
Merge remote-tracking branch 'upstream/master' into large_interchange…
eddieh-xlnx Jul 13, 2024
0f6748b
Test that PIP.isReversed() is correct (#1024)
eddieh-xlnx Jul 15, 2024
e024bff
[VivadoTools] Source *_load.tcl from same dir as DCP (#1032)
eddieh-xlnx Jul 16, 2024
541ae33
Merge remote-tracking branch 'upstream/master' into 2024.1.1
eddieh-xlnx Jul 16, 2024
24fd96f
rc4
clavin-xlnx Jul 17, 2024
b3b2f81
2024.1.1 release notes and jar
clavin-xlnx Jul 17, 2024
c9f8c66
Merge pull request #1012 from Xilinx/2024.1.1
clavin-xlnx Jul 17, 2024
8546f5e
Bump Python pkg version to 2024.1.1
clavin-xlnx Jul 23, 2024
14c3b4d
Fixes to support Versal designs
clavin-xlnx Jul 31, 2024
f5066dc
Merge branch 'interchange_versal' into large_interchange_designs
clavin-xlnx Jul 31, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .classpath
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
<classpathentry kind="lib" path="jars/kryo-5.2.1.jar"/>
<classpathentry kind="lib" path="jars/minlog-1.3.1.jar"/>
<classpathentry kind="lib" path="jars/jython-standalone-2.7.2.jar"/>
<classpathentry kind="lib" path="jars/rapidwright-api-lib-2024.1.0.jar">
<classpathentry kind="lib" path="jars/rapidwright-api-lib-2024.1.1.jar">
<attributes>
<attribute name="javadoc_location" value="jar:platform:/resource/RapidWright/jars/rapidwright-api-lib-2024.1.0-javadoc.jar!/"/>
<attribute name="javadoc_location" value="jar:platform:/resource/RapidWright/jars/rapidwright-api-lib-2024.1.1-javadoc.jar!/"/>
</attributes>
</classpathentry>
<classpathentry kind="lib" path="jars/jgrapht-core-1.3.0.jar"/>
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
pull_request:

env:
RAPIDWRIGHT_VERSION: v2024.1.0-beta
RAPIDWRIGHT_VERSION: v2024.1.1-beta

jobs:
build:
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/check-git-submodules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: Submodule refs on origin

on:
pull_request:
branches:
- master

jobs:
check:
Expand Down
34 changes: 34 additions & 0 deletions RELEASE_NOTES.TXT
Original file line number Diff line number Diff line change
@@ -1,3 +1,37 @@
============= RapidWright 2024.1.1-beta released on 2024-07-17 ================
Notes:
- [VivadoTools] Source *_load.tcl from same dir as DCP (#1032)
- Test that PIP.isReversed() is correct (#1024)
- Add TestSite.testGetIntTile() (#1022)
- [EDIFTools] writeTclLoadScriptForPartialEncryptedDesigns abspath (#1029)
- Adding HDIOB types (#1028)
- Test for site routing from raw placed design (#1000)
- [RWRoute] Do not NPE on encrypted netlists (#1025)
- [RWRoute] Do not assume Y = 0 has Laguna tiles, since it could be HBM device (#1026)
- Adds UNKWN state for LSFJobs (#1027)
- Adding legacy support for u280 (#1021)
- Remove flawed loop intended to for encrypted cell removal (#1023)
- [DesignTools.makeBlackBox()] Fixes an issue of removing CARRY blocks fed by routethrus (#1009)
- Fix null netlist pointer on expanded macro children (#1008)
- [Interchange] Device Resources Verifier Fixes (#1014)
- Fix ConcurrentModificationError (#1015)
- [EDIFTools] Adding method to create a flat netlist from a hierarchical one (#1006)
- Adding HBM ComponentTypes (#1007)
- Test for wire/node mismatch reported in #983 (#1005)
- 3.6% memory reduction usage for large placed designs (de-duplication of cell pin strings)
- Add missing pin entry for BUFG_GT when tracking INT tile connections
- Fixes rare DCP write issue with stubbed bi-directional PIPs (more common on DFX designs)
- Fix for reversed flag on PIPs
- Addresses issue with Net.getBufferDelay() by checking for null wire names
- Fixes two site routing issues


API Additions:
- (None)

API Removals:
- (None)

============= RapidWright 2024.1.0-beta released on 2024-06-11 ================
Notes:
- Support for Vivado 2024.1 DCPs and devices
Expand Down
2 changes: 1 addition & 1 deletion python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

setup(
name='rapidwright',
version='2024.1.0',
version='2024.1.1',
license='Apache 2.0 and Others',
description='Xilinx RapidWright Framework Wrapped for Python.',
long_description='',
Expand Down
2 changes: 1 addition & 1 deletion python/src/rapidwright/rapidwright.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
from typing import List, Optional
import os, urllib.request, platform

version='2024.1.0'
version='2024.1.1'

def start_jvm():
os_str = 'lin64'
Expand Down
15 changes: 5 additions & 10 deletions src/com/xilinx/rapidwright/design/DesignTools.java
Original file line number Diff line number Diff line change
Expand Up @@ -1751,15 +1751,6 @@ public static void makeBlackBox(Design d, EDIFHierCellInst hierarchicalCell) {
}
cells.add(c);
}
// Find encrypted cells that need to be removed
if (d.getNetlist().getEncryptedCells().size() > 0) {
String name = hierarchicalCell.getFullHierarchicalInstName();
for (Cell c : d.getCells()) {
if (c.getName().startsWith(name)) {
cells.add(c);
}
}
}

// Remove all placement and routing information related to the cell to be
// blackboxed
Expand Down Expand Up @@ -2606,7 +2597,11 @@ private static EDIFHierPortInst getPortInstFromBELPin(SiteInst siteInst, BELPin
}
String logPinName = targetCell.getLogicalPinMapping(belPin.getName());
if (logPinName == null) return null;
EDIFPortInst portInst = targetCell.getEDIFCellInst().getPortInst(logPinName);
EDIFCellInst eci = targetCell.getEDIFCellInst();
if (eci == null) {
return null;
}
EDIFPortInst portInst = eci.getPortInst(logPinName);
final EDIFNetlist netlist = targetCell.getSiteInst().getDesign().getNetlist();
EDIFHierPortInst hierPortInst =
new EDIFHierPortInst(netlist.getHierCellInstFromName(targetCell.getParentHierarchicalInstName()), portInst);
Expand Down
11 changes: 7 additions & 4 deletions src/com/xilinx/rapidwright/edif/EDIFHierPortInst.java
Original file line number Diff line number Diff line change
Expand Up @@ -88,10 +88,13 @@ public String getFullHierarchicalInstName() {
return hierarchicalInst.getFullHierarchicalInstName();
}

EDIFCellInst topCellInst = portInst.getCellInst().getCellType().getLibrary().getNetlist().getTopCellInst();
if (portInst.getCellInst() == topCellInst) {
//Outward side of top
return "";
EDIFLibrary library = portInst.getCellInst().getCellType().getLibrary();
if (!library.isHDIPrimitivesLibrary()) {
EDIFCellInst topCellInst = library.getNetlist().getTopCellInst();
if (portInst.getCellInst() == topCellInst) {
// Outward side of top
return "";
}
}

StringBuilder sb = new StringBuilder();
Expand Down
2 changes: 1 addition & 1 deletion src/com/xilinx/rapidwright/edif/EDIFTools.java
Original file line number Diff line number Diff line change
Expand Up @@ -1019,7 +1019,7 @@ public static void writeTclLoadScriptForPartialEncryptedDesigns(EDIFNetlist edif
lines.add("read_checkpoint {" + pathDCPFileName + "}");
lines.add("set_property top "+edif.getName()+" [current_fileset]");
lines.add("link_design -part " + partName);
Path tclFileName = FileTools.replaceExtension(pathDCPFileName.getFileName(), LOAD_TCL_SUFFIX);
Path tclFileName = FileTools.replaceExtension(pathDCPFileName, LOAD_TCL_SUFFIX);
try {
Files.write(tclFileName, lines);
} catch (IOException e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ public static boolean verifyDeviceResources(String devResFileName, String device
put(LogNetlistWriter.DEVICE_PRIMITIVES_LIB, EDIFTools.EDIF_LIBRARY_HDI_PRIMITIVES_NAME);
}}
);
EDIFNetlist primsAndMacros = netlistReader.readLogNetlist(primLibs,
EDIFNetlist primsAndMacros = netlistReader.readLogNetlistSingleMessage(primLibs,
/* skipTopStuff= */true, /* expandMacros= */false, CodePerfTracker.SILENT);

Set<String> libsFound = new HashSet<String>();
Expand Down
28 changes: 28 additions & 0 deletions src/com/xilinx/rapidwright/interchange/Interchange.java
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,34 @@ private static double printFileSize(String title, String fileName) {
return fileSize;
}

/**
* Takes an array of file names and concatenates them into a single GZIP'ed file
* in the order presented in the array. This is used for assembling a list of
* separate Interchange messages into a single compressed file of those
* messages. This also deletes the input files after they have been
* concatenated.
*
* @param msgFileNames Ordered list of input files to be concatenated and then
* deleted
* @param gzipFileName The desired output GZIP file.
*/
public static void concatMessagesToSingleGZIPFile(String[] msgFileNames, String gzipFileName) {
try (GZIPOutputStream gos = new GZIPOutputStream(new FileOutputStream(gzipFileName))) {
byte[] buffer = new byte[1024];
int len = 0;
for (String messageFile : msgFileNames) {
try (FileInputStream fis = new FileInputStream(messageFile)) {
while ((len = fis.read(buffer)) > 0) {
gos.write(buffer, 0, len);
}
}
FileTools.deleteFile(messageFile);
}
} catch (IOException e) {
throw new UncheckedIOException(e);
}
}

public static void main(String[] args) throws IOException {
if (args.length < 1 || args.length > 2) {
System.out.println("USAGE: <input DCP> [input EDIF]");
Expand Down
112 changes: 80 additions & 32 deletions src/com/xilinx/rapidwright/interchange/LogNetlistReader.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@
import org.capnproto.TextList;

import java.io.IOException;
import java.io.UncheckedIOException;
import java.nio.channels.ReadableByteChannel;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
Expand All @@ -62,7 +64,7 @@
import java.util.function.Supplier;

public class LogNetlistReader {
public static boolean CHECK_UNISIM_DEFINITIONS = true;
public static boolean CHECK_UNISIM_DEFINITIONS = false;

private String[] allStrings;
private EDIFPort[] allPorts;
Expand Down Expand Up @@ -328,15 +330,8 @@ public static EDIFNetlist readLogNetlist(String fileName) throws IOException {
*/
public static EDIFNetlist readLogNetlist(String fileName, boolean expandMacros) throws IOException {
CodePerfTracker t = new CodePerfTracker("Read LogNetlist");

t.start("Read File");
ReaderOptions readerOptions = new ReaderOptions(32L * 1024L * 1024L * 1024L, 64);
MessageReader readMsg = Interchange.readInterchangeFile(fileName, readerOptions);
Netlist.Reader netlist = readMsg.getRoot(Netlist.factory);
t.stop();

LogNetlistReader reader = new LogNetlistReader();
return reader.readLogNetlist(netlist, false, expandMacros, t);
return reader.readLogNetlistMultiMessage(fileName, false, expandMacros, t);
}

private EDIFPort readEDIFPort(Port.Reader portReader) {
Expand Down Expand Up @@ -404,28 +399,6 @@ private EDIFLibrary getLibrary(Integer libraryIdx) {
});
}

/**
* Reads an Interchange netlist from Cap'n Proto reader. Will expand macros by default.
* @param netlist The Cap'n Proto netlist reader
* @param skipTopStuff If true, skips netlist design object
* @return The logical netlist.
*/
public EDIFNetlist readLogNetlist(Netlist.Reader netlist, boolean skipTopStuff) {
return readLogNetlist(netlist, skipTopStuff, true);
}

/**
* Reads an Interchange netlist from Cap'n Proto reader.
* @param netlist The Cap'n Proto netlist reader
* @param skipTopStuff If true, skips netlist design object
* @param expandMacros If true, expands the macros in the netlist before returning it to the caller.
* @return The logical netlist.
*/
public EDIFNetlist readLogNetlist(Netlist.Reader netlist, boolean skipTopStuff, boolean expandMacros) {
CodePerfTracker t = new CodePerfTracker("readLogNetlist");
return readLogNetlist(netlist, skipTopStuff, expandMacros, t);
}

/**
* Reads an Interchange netlist from Cap'n Proto reader.
* @param netlist The Cap'n Proto netlist reader
Expand All @@ -434,7 +407,7 @@ public EDIFNetlist readLogNetlist(Netlist.Reader netlist, boolean skipTopStuff,
* @param t CodePerfTracker object.
* @return The logical netlist.
*/
public EDIFNetlist readLogNetlist(Netlist.Reader netlist, boolean skipTopStuff, boolean expandMacros, CodePerfTracker t) {
public EDIFNetlist readLogNetlistSingleMessage(Netlist.Reader netlist, boolean skipTopStuff, boolean expandMacros, CodePerfTracker t) {
n = new EDIFNetlist(netlist.getName().toString());

t.start("Read Strings");
Expand Down Expand Up @@ -487,4 +460,79 @@ public EDIFNetlist readLogNetlist(Netlist.Reader netlist, boolean skipTopStuff,

return n;
}

/**
* Reads an Interchange netlist from Cap'n Proto reader.
* @param netlist The Cap'n Proto netlist reader
* @param skipTopStuff If true, skips netlist design object
* @param expandMacros If true, expands the macros in the netlist before returning it to the caller.
* @param t CodePerfTracker object.
* @return The logical netlist.
*/
public EDIFNetlist readLogNetlistMultiMessage(String fileName, boolean skipTopStuff, boolean expandMacros, CodePerfTracker t) {
try (ReadableByteChannel channel = Interchange.getReadableByteChannel(fileName)) {
ReaderOptions options = new ReaderOptions(32L * 1024L * 1024L * 1024L, 64);
Netlist.Reader netlist = null;

t.start("Read Strings");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
readAllStrings(netlist.getStrList());
n = new EDIFNetlist(netlist.getName().toString());

t.stop().start("Read Ports");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
readAllPorts(netlist.getPortList());

t.stop().start("Read CellDecls");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
readAllCellDecls(netlist.getCellDecls());

t.stop().start("Read Insts");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
readAllInsts(netlist.getInstList());

t.stop().start("Read Cells");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
readAllCells(netlist.getCellList());

t.stop().start("Read Top");
netlist = Interchange.readMessageFromChannel(channel, options).getRoot(Netlist.factory);
if (!skipTopStuff) {
EDIFDesign design = new EDIFDesign(allCells[netlist.getTopInst().getCell()].getName());
design.setTopCell(allCells[netlist.getTopInst().getCell()]);
n.setDesign(design);
if (netlist.hasPropMap()) {
extractPropertyMap(netlist.getPropMap(), design);
}
}

t.stop().start("Order Libraries");

// Put libraries in proper export order
List<EDIFLibrary> libs = n.getLibrariesInExportOrder();
n.getLibrariesMap().clear();
for (EDIFLibrary lib : libs) {
n.addLibrary(lib);
}

if (expandMacros) {
t.stop().start("Expand Macros");
String partName = EDIFTools.getPartName(n);
if (partName != null) {
n.expandMacroUnisims(PartNameTools.getPart(partName).getSeries());
} else {
System.err.println("WARNING: Could not determine target device from netlist. Macro "
+ "unisims are not expanded. Please add a top netlist property to indicate the "
+ "target part such as [part=xcvu095-ffva2104-2-e]. Macro expansion can also be"
+ " run manually with EDIFNetlist.expandMacroUnisims(Series)");
}
}
t.stop().printSummary();
} catch (IOException e) {
throw new UncheckedIOException(e);
}

return n;
}

}
Loading