summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--treemap/Makefile17
-rwxr-xr-xtreemap/convert.xsl58
2 files changed, 68 insertions, 7 deletions
diff --git a/treemap/Makefile b/treemap/Makefile
index c4076c4..ae0ee43 100644
--- a/treemap/Makefile
+++ b/treemap/Makefile
@@ -1,8 +1,10 @@
-TOP = top
-DIR = ../s3estarter/syn/xst
+TOP = top
+DIR = ../s3estarter/syn/xst
+SCREENSHOT = s3estarter_ressources
-#TOP = spartan6_top
-#DIR = ../beam_position_monitor/hardware/board_sp601/synthese/xst
+#TOP = spartan6_top
+#DIR = ../beam_position_monitor/hardware/board_sp601/synthese/xst
+#SCREENSHOT = bpm_ressources
# derived Variables
@@ -18,6 +20,7 @@ help:
@echo "run - run Treeviz"
@echo "convert - convert data"
@echo "util - grep for utilization"
+ @echo "combine - two screenshots for better overview"
@echo "clean - tidy up"
run: ressources.xml
@@ -38,7 +41,7 @@ util_hier: $(MAPREPORT)
-ressources.xml: $(MAPREPORTXML)
+ressources.xml: $(MAPREPORTXML) convert.xsl
saxon-xslt $(MAPREPORTXML) convert.xsl > tmp.xml
# prune empty lines with sed
sed -e '/^[ ]*$$/d' tmp.xml > ressources.xml
@@ -46,6 +49,10 @@ ressources.xml: $(MAPREPORTXML)
rm -f tmp.xml
+combine: $(SCREENSHOT)_fein.png $(SCREENSHOT)_grob.png
+ combine -blend 33 $(SCREENSHOT)_fein.png $(SCREENSHOT)_grob.png $(SCREENSHOT)_mixed.png
+
+
clean:
rm -f ressources.xml
diff --git a/treemap/convert.xsl b/treemap/convert.xsl
index b0dd494..080bd00 100755
--- a/treemap/convert.xsl
+++ b/treemap/convert.xsl
@@ -24,17 +24,34 @@
<xsl:call-template name="slices" />
</xsl:variable>
+ <xsl:variable name="nodeslice_reg">
+ <xsl:call-template name="slice_reg" />
+ </xsl:variable>
+
+ <xsl:variable name="nodeluts">
+ <xsl:call-template name="luts" />
+ </xsl:variable>
+
+ <xsl:variable name="nodelutram">
+ <xsl:call-template name="lutram" />
+ </xsl:variable>
+
<xsl:variable name="nodebrams">
<xsl:call-template name="brams" />
</xsl:variable>
+ <xsl:variable name="nodemul_dsp">
+ <xsl:call-template name="mul_dsp" />
+ </xsl:variable>
+
<!--<node name="{$nodename}" size="{$nodeslices}" created="{substring(concat('0000',$nodebrams),1+string-length($nodebrams),4)}-01-01 00:00:00">-->
- <node name="{$nodename}" slices="{$nodeslices}" brams="{$nodebrams}">
+ <node name="{$nodename}" slices="{$nodeslices}" slice_reg="{$nodeslice_reg}" luts="{$nodeluts}" lutram="{$nodelutram}" brams="{$nodebrams}" mul_dsp="{$nodemul_dsp}">
<xsl:apply-templates />
</node>
</xsl:template>
+
<xsl:template name="slices">
<xsl:for-each select="item">
<xsl:if test="@stringID='MAP_SLICES'">
@@ -44,13 +61,50 @@
</xsl:for-each>
</xsl:template>
+
+<xsl:template name="slice_reg">
+ <xsl:for-each select="item">
+ <xsl:if test="@stringID='MAP_SLICE_REG'">
+ <xsl:value-of select="@value" />
+ </xsl:if>
+ </xsl:for-each>
+</xsl:template>
+
+
+<xsl:template name="luts">
+ <xsl:for-each select="item">
+ <xsl:if test="@label='LUTs'">
+ <xsl:value-of select="@value" />
+ </xsl:if>
+ </xsl:for-each>
+</xsl:template>
+
+
+<xsl:template name="lutram">
+ <xsl:for-each select="item">
+ <xsl:if test="@label='LUTRAM'">
+ <xsl:value-of select="@value" />
+ </xsl:if>
+ </xsl:for-each>
+</xsl:template>
+
+
<xsl:template name="brams">
<xsl:for-each select="item">
<xsl:if test="@stringID='MAP_BRAM' or @stringID='MAP_BRAM_FIFO'">
<xsl:value-of select="@value" />
-<!-- <xsl:value-of select="@ACCUMULATED" />-->
</xsl:if>
</xsl:for-each>
</xsl:template>
+
+<xsl:template name="mul_dsp">
+ <xsl:for-each select="item">
+ <xsl:if test="@stringID='MAP_MULT18X18' or @label='DSP48A1'">
+ <xsl:value-of select="@value" />
+ </xsl:if>
+ </xsl:for-each>
+</xsl:template>
+
+
</xsl:stylesheet>
OpenPOWER on IntegriCloud