OpenASIP 2.2
Loading...
Searching...
No Matches
Public Member Functions | Static Public Attributes | Private Attributes | List of all members
HDBToHtml Class Reference

#include <HDBToHtml.hh>

Collaboration diagram for HDBToHtml:
Collaboration graph

Public Member Functions

 HDBToHtml (const HDB::HDBManager &hdb)
 
virtual ~HDBToHtml ()
 
void fuEntryToHtml (RowID id, std::ostream &stream)
 
void rfEntryToHtml (RowID id, std::ostream &stream)
 
void busEntryToHtml (RowID id, std::ostream &stream)
 
void socketEntryToHtml (RowID id, std::ostream &stream)
 
void fuArchToHtml (RowID id, std::ostream &stream)
 
void rfArchToHtml (RowID id, std::ostream &stream)
 
void fuImplToHtml (RowID id, std::ostream &stream)
 
void rfImplToHtml (RowID id, std::ostream &stream)
 
void costFunctionPluginToHtml (RowID id, std::ostream &stream)
 
void OperationImplementationToHtml (RowID id, std::ostream &stream)
 
void OperationImplementationResourceToHtml (RowID id, std::ostream &stream)
 

Static Public Attributes

static const std::string HDB_ROOT
 
static const std::string FU_ENTRIES = "FU Entries"
 
static const std::string RF_ENTRIES = "RF Entries"
 
static const std::string RF_IU_ENTRIES = "RF/IU Entries"
 
static const std::string BUS_ENTRIES = "Bus Entries"
 
static const std::string SOCKET_ENTRIES = "Socket Entries"
 
static const std::string FU_ARCHITECTURES = "Function Units"
 
static const std::string RF_ARCHITECTURES = "Register Files"
 
static const std::string FU_IMPLEMENTATIONS = "FU Implementations"
 
static const std::string RF_IMPLEMENTATIONS = "RF Implementations"
 
static const std::string COST_PLUGINS = "Cost Function Plugins"
 
static const std::string OPERATION_IMPLEMENTATIONS
 
static const std::string OPERATION_IMPLEMENTATION_RESOURCES
 

Private Attributes

const HDB::HDBManagerhdb_
 HDB to create html from.
 

Detailed Description

Collection of functions for generating html pages displaying information of HDB elements.

Definition at line 47 of file HDBToHtml.hh.

Constructor & Destructor Documentation

◆ HDBToHtml()

HDBToHtml::HDBToHtml ( const HDB::HDBManager hdb)

The Cosntructor.

Parameters
hdbHDB

Definition at line 86 of file HDBToHtml.cc.

86 :
87 hdb_(hdb) {
88}
const HDB::HDBManager & hdb_
HDB to create html from.
Definition HDBToHtml.hh:80

◆ ~HDBToHtml()

HDBToHtml::~HDBToHtml ( )
virtual

The Destructor.

Definition at line 93 of file HDBToHtml.cc.

93 {
94}

Member Function Documentation

◆ busEntryToHtml()

void HDBToHtml::busEntryToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a bus entry.

Parameters
idID of the bus entry.
streamStream where the html is written to.

Definition at line 250 of file HDBToHtml.cc.

250 {
251
252 stream << "<html><body><small>" << endl;
253 stream << "<b>Bus entry " << id << "</b><br>" << endl;
254
255 stream << "<tr><td align=right><b>Cost estimation data:</b></td><td>";
256
257 // Cost estimation data
258 const std::set<RowID> costDataIDs = hdb_.busCostEstimationDataIDs(id);
259 if (!costDataIDs.empty()) {
260 stream << "<b>Cost estimation data:</b>" << endl;
261 stream << "<table bgcolor=#bbbbbb>" << endl;
262 stream << "<tr><th>Name</th><th>Value</th>"
263 << "<th>Plugin</th></tr>" << endl;
264 } else {
265 stream << "No cost estimation data.<br>" << endl;
266 }
267 std::set<RowID>::const_iterator iter = costDataIDs.begin();
268 for (; iter != costDataIDs.end(); iter++) {
269 const CostEstimationData data = hdb_.costEstimationData(*iter);
270 stream << "<tr><td>" << data.name() << "</td>"
271 << "<td align=right>";
272 stream << data.value().stringValue();
273 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
274 << "/" << data.pluginID() << "\">"
275 << data.pluginID() << "</a></td></tr>" << endl;
276 }
277 stream << "</table>" << endl;
278 stream << "</small></body></html>" << endl;
279}
DataObject value() const
std::string name() const
virtual std::string stringValue() const
static const std::string COST_PLUGINS
Definition HDBToHtml.hh:74
std::set< RowID > busCostEstimationDataIDs(RowID busID) const
CostEstimationData costEstimationData(RowID id) const

References HDB::HDBManager::busCostEstimationDataIDs(), COST_PLUGINS, HDB::HDBManager::costEstimationData(), hdb_, CostEstimationData::name(), CostEstimationData::pluginID(), DataObject::stringValue(), and CostEstimationData::value().

Referenced by HDBBrowserInfoPanel::displayBusEntry().

Here is the call graph for this function:

◆ costFunctionPluginToHtml()

void HDBToHtml::costFunctionPluginToHtml ( RowID  id,
std::ostream &  stream 
)

Generates html page of a cost function plugin information.

Parameters
idRow id of the cost estimation plugin.
stremStream where the html is written to.

Definition at line 900 of file HDBToHtml.cc.

900 {
901
903
904 stream << "<html><body><small>" << endl;
905 stream << "<table bgcolor=#bbbbbb>"<< endl;
906
907 // Plugin name.
908 stream << "<tr><td align=right>Name:</td><td>" << plugin->name()
909 << "</td></tr>" << endl;
910
911 // Plugin type.
912 stream << "<tr><td align=right>Type:</td><td>";
913 if (plugin->type() == CostFunctionPlugin::COST_FU) {
914 stream << "Function unit cost estimator.";
915 } else if (plugin->type() == CostFunctionPlugin::COST_RF) {
916 stream << "Register file cost estimator.";
917 } else if (plugin->type() == CostFunctionPlugin::COST_DECOMP) {
918 stream << "Decompressor cost estimator.";
919 } else if (plugin->type() == CostFunctionPlugin::COST_ICDEC) {
920 stream << "Interconnection network & decoder cost estimator.";
921 } else {
922 stream << "unknown";
923 }
924 stream << "</td></tr>" << endl;
925
926 // Plugin file path.
927 stream << "<tr><td align=right>File path:</td><td>"
928 << plugin->pluginFilePath() << "</td></tr>" << endl;
929
930 // Plugin description.
931 stream << "<tr><td align=right>Description:</td><td>"
932 << plugin->description() << "</td></tr>" << endl;
933
934 stream << "</table><br><br>"<< endl;
935
936
937 // Cost estiamtion data
938 stream << "<b>Cost estimation data:</b>" << endl;
939 stream << "<table bgcolor=#bbbbbb>"<< endl;
940 stream << "<tr><th>Entry type</th><th>Entry ID</th>"
941 << "<th>Key</th><th>Value</th></tr>" << endl;
942
943 const std::set<RowID> dataIDs = hdb_.costFunctionPluginDataIDs(id);
944 std::set<RowID>::const_iterator iter = dataIDs.begin();
945 for (; iter != dataIDs.end(); iter++) {
947 stream << "<tr>";
948 if (data.hasFUReference()) {
949 // Function unit reference.
950 stream << "<td>FU</td><td><a href=\"/" << FU_ENTRIES << "/"
951 << data.fuReference() << "\">"
952 << data.fuReference() << "</a>";
953 stream << "</td>";
954 } else if (data.hasRFReference()) {
955 // Register file entry reference.
956 stream << "<td>RF</td><td><a href=\"/" << RF_ENTRIES << "/"
957 << data.rfReference() << "\">"
958 << data.rfReference() << "</a>";
959 stream << "</td>";
960 } else if (data.hasBusReference()) {
961 // Bus entry reference.
962 stream << "<td>Bus</td><td>"
963 << data.busReference() << "</a>";
964 stream << "</td>";
965 } else if (data.hasSocketReference()) {
966 // Socket entry reference.
967 stream << "<td>Socket</td><td>"
968 << data.socketReference() << "</a>";
969 stream << "</td>";
970 } else {
971 stream << "<td>-</td><td>-</td>";
972 }
973
974 stream << "<td>" << data.name() << "</td><td>"
975 << data.value().stringValue() << "</td></tr>" << endl;
976
977 }
978 stream << "</table>"<< endl;
979 stream << "</small></body></html>" << endl;
980
981 delete plugin;
982}
bool hasBusReference() const
bool hasFUReference() const
RowID socketReference() const
bool hasSocketReference() const
bool hasRFReference() const
static const std::string FU_ENTRIES
Definition HDBToHtml.hh:65
static const std::string RF_ENTRIES
Definition HDBToHtml.hh:66
@ COST_RF
register file cost estimator
@ COST_ICDEC
interconnection network & decoder cost estimator
@ COST_FU
function unit cost estimator
@ COST_DECOMP
decompressor cost estimator
CostFunctionPluginType type() const
std::string description() const
std::string pluginFilePath() const
CostFunctionPlugin * costFunctionPluginByID(RowID pluginID) const
std::set< RowID > costFunctionPluginDataIDs(RowID pluginID) const

References CostEstimationData::busReference(), HDB::CostFunctionPlugin::COST_DECOMP, HDB::CostFunctionPlugin::COST_FU, HDB::CostFunctionPlugin::COST_ICDEC, HDB::CostFunctionPlugin::COST_RF, HDB::HDBManager::costEstimationData(), HDB::HDBManager::costFunctionPluginByID(), HDB::HDBManager::costFunctionPluginDataIDs(), HDB::CostFunctionPlugin::description(), FU_ENTRIES, CostEstimationData::fuReference(), CostEstimationData::hasBusReference(), CostEstimationData::hasFUReference(), CostEstimationData::hasRFReference(), CostEstimationData::hasSocketReference(), hdb_, CostEstimationData::name(), HDB::CostFunctionPlugin::name(), HDB::CostFunctionPlugin::pluginFilePath(), RF_ENTRIES, CostEstimationData::rfReference(), CostEstimationData::socketReference(), DataObject::stringValue(), HDB::CostFunctionPlugin::type(), and CostEstimationData::value().

Referenced by HDBBrowserInfoPanel::displayCostFunctionPlugin().

Here is the call graph for this function:

◆ fuArchToHtml()

void HDBToHtml::fuArchToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a function unit architecture.

Parameters
idID of the FU architecture.
streamStream where the html is written to.

Definition at line 328 of file HDBToHtml.cc.

328 {
329
330 const FUArchitecture* arch = hdb_.fuArchitectureByID(id);
331 const FunctionUnit& fu = arch->architecture();
332
333 stream << "<html><body><small>" << endl;
334
335 //
336 // PORTS
337 //
338 stream << "<b>Ports:</b><br>" << endl;
339 stream << "<table bgcolor=#bbbbbb>" << endl;
340 stream << "<tr><th>Name</th><th>Width</th>"
341 << "<th>Triggering</th>"
342 << "<th>Opcode</th>"
343 << "<th>Guard</th></tr>"
344 << endl;
345
346 for (int i = 0; i < fu.portCount(); i++) {
347
348 const BaseFUPort& port = *fu.port(i);
349
350 stream << "<tr><td align=left>" << port.name() << "</td>";
351
352 if (arch->hasParameterizedWidth(port.name())) {
353 stream << "<td align=right>param</td>";
354 } else {
355 stream << "<td align=right>" << port.width() << "</td>";
356 }
357
358 if (port.isTriggering()) {
359 stream << "<td align=center><font color=#009900>yes</font></td>";
360 } else {
361 stream << "<td align=center><font color=#ff0000>no</font></td>";
362 }
363
364 if (port.isOpcodeSetting()) {
365 stream << "<td align=center><font color=#009900>yes</font></td>";
366 } else {
367 stream << "<td align=center><font color=#ff0000>no</font></td>";
368 }
369
370 if (arch->hasGuardSupport(port.name())) {
371 stream << "<td align=center><font color=#009900>yes</font></td>";
372 } else {
373 stream << "<td align=center><font color=#ff0000>no</font></td>";
374 }
375 stream << "</tr>" << endl;
376 }
377 stream << "</table><br><br>" << endl;
378
379 //
380 // OPERATIONS
381 //
382 stream << "<b>Operations:</b><br><br>" << endl;
383 for (int i = 0; i < fu.operationCount(); i++) {
384
385 const HWOperation& operation = *fu.operation(i);
386 const ExecutionPipeline& pipeline = *operation.pipeline();
387
388 stream << "<b>" << operation.name() << "</b><br>" << endl;
389 stream << "Latency: " << operation.latency() << endl;
390 stream << "<br>" << endl;
391 stream << "<table><tr><td valing=top>" << endl;
392 stream << "<table bgcolor=#bbbbbb><tr><th>operand</th><th>port</th>";
393 for (int cycle = 0; cycle < operation.latency(); cycle++) {
394 stream << "<th width=20>" << cycle << "</th>";
395 }
396 stream << "</tr>" << endl;
397
398 // Reads operands.
400 ExecutionPipeline::OperandSet::iterator iter = read.begin();
401 for (; iter != read.end(); iter++) {
402 stream << "<tr><td>" << *iter << "</td><td>"
403 << operation.port(*iter)->name() << "</td>";
404 for (int cycle = 0; cycle < operation.latency(); cycle++) {
406 pipeline.readOperands(cycle), *iter)) {
407 stream << "<td align=center><b>R</b></td>";
408 } else {
409 stream << "<td></td>";
410 }
411 }
412 stream << "</tr>" << endl;
413 }
414
415 // Written operands.
417 iter = written.begin();
418 for (; iter != written.end(); iter++) {
419 stream << "<tr><td>" << *iter << "</td><td>"
420 << operation.port(*iter)->name() << "</td>";
421 for (int cycle = 0; cycle < operation.latency(); cycle++) {
423 pipeline.writtenOperands(cycle), *iter)) {
424 stream << "<td align=center><b>W</b></td>";
425 } else {
426 stream << "<td></td>";
427 }
428 }
429 stream << "</tr>" << endl;
430 }
431 stream << "</table></td>" << endl;
432
433 stream << "<td valign=top><table bgcolor=#bbbbbb>"
434 << "<tr><th>resource</th>";
435 for (int cycle = 0; cycle < operation.latency(); cycle++) {
436 stream << "<th width=20>" << cycle << "</th>";
437 }
438 stream << "</tr>" << endl;
439
440 // Resources used.
441 for (int r = 0; r < fu.pipelineElementCount(); r++) {
442 const PipelineElement& res = *fu.pipelineElement(r);
443 stream << "<tr><td>" << res.name() << "</td>";
444 for (int cycle = 0; cycle < operation.latency(); cycle++) {
445 if (pipeline.isResourceUsed(res.name(), cycle)) {
446 stream << "<td align=center><b>X</b></td>";
447 } else {
448 stream << "<td></td>";
449 }
450 }
451 stream << "</tr>" << endl;
452 }
453
454 stream << "</table></td></tr></table><br><br>" << endl;
455 }
456 stream << "</small></body></html>" << endl;
457
458 delete arch;
459}
static bool containsValue(const ContainerType &aContainer, const ElementType &aKey)
bool hasGuardSupport(const std::string &port) const
bool hasParameterizedWidth(const std::string &port) const
TTAMachine::FunctionUnit & architecture() const
virtual FUArchitecture * fuArchitectureByID(RowID id) const
virtual int width() const
virtual bool isOpcodeSetting() const =0
virtual bool isTriggering() const =0
OperandSet writtenOperands(int cycle) const
OperandSet readOperands(int cycle) const
std::set< int > OperandSet
Set for operand indexes.
bool isResourceUsed(const std::string &name, int cycle) const
virtual int pipelineElementCount() const
virtual HWOperation * operation(const std::string &name) const
virtual int operationCount() const
virtual PipelineElement * pipelineElement(int index) const
virtual BaseFUPort * port(const std::string &name) const
ExecutionPipeline * pipeline() const
virtual FUPort * port(int operand) const
const std::string & name() const
const std::string & name() const
virtual std::string name() const
Definition Port.cc:141
virtual int portCount() const
Definition Unit.cc:135

References HDB::FUArchitecture::architecture(), ContainerTools::containsValue(), HDB::HDBManager::fuArchitectureByID(), HDB::FUArchitecture::hasGuardSupport(), HDB::FUArchitecture::hasParameterizedWidth(), hdb_, TTAMachine::BaseFUPort::isOpcodeSetting(), TTAMachine::ExecutionPipeline::isResourceUsed(), TTAMachine::BaseFUPort::isTriggering(), TTAMachine::HWOperation::latency(), TTAMachine::HWOperation::name(), TTAMachine::PipelineElement::name(), TTAMachine::Port::name(), TTAMachine::FunctionUnit::operation(), TTAMachine::FunctionUnit::operationCount(), TTAMachine::HWOperation::pipeline(), TTAMachine::FunctionUnit::pipelineElement(), TTAMachine::FunctionUnit::pipelineElementCount(), TTAMachine::FunctionUnit::port(), TTAMachine::HWOperation::port(), TTAMachine::Unit::portCount(), TTAMachine::ExecutionPipeline::readOperands(), TTAMachine::BaseFUPort::width(), and TTAMachine::ExecutionPipeline::writtenOperands().

Referenced by HDBBrowserInfoPanel::displayFUArchitecture().

Here is the call graph for this function:

◆ fuEntryToHtml()

void HDBToHtml::fuEntryToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a function unit entry->

Parameters
idID of the FU entry in the HDB.
streamStream where the html is written to.

Definition at line 103 of file HDBToHtml.cc.

103 {
104
105 const HDB::FUEntry* entry = hdb_.fuByEntryID(id);
106
107 stream << "<html><body><small>" << endl;
108 stream << "<b>Function unit entry " << entry->id() << "</b><br>" << endl;
109
110 stream << "<table>" << endl;
111 stream << "<tr><td align=right><b>Architecture:</b></td><td>";
112 if (entry->hasArchitecture()) {
113 stream << "<a href=\"/" << FU_ARCHITECTURES << "/"
114 << entry->architecture().id() << "\">"
115 << entry->architecture().id() << "</a>"
116 << "</td></tr>" << endl;
117 } else {
118 stream << "-</td></tr>";
119 }
120
121 stream << "<tr><td align=right><b>Implementation:</b></td><td>";
122 if (entry->hasImplementation()) {
123 stream << "<a href=\"/" << FU_IMPLEMENTATIONS << "/"
124 << entry->implementation().id() << "\">"
125 << entry->implementation().moduleName()
126 << "</a></td></tr>" << endl;
127 } else {
128 stream << "-</td></tr>" << endl;
129 }
130
131 stream << "<tr><td align=right><b>Cost function plugin:</b></td><td>";
132 if (entry->hasCostFunction()) {
133 const CostFunctionPlugin& plugin = entry->costFunction();
134 stream << "<a href=\"/" << COST_PLUGINS << "/"
135 << plugin.id() << "\">"
136 << plugin.name()
137 << "</a></td></tr>" << endl;
138 } else {
139 stream << "-</td></tr>" << endl;
140 }
141
142 stream << "</table>";
143
144 // Cost estimation data
145 const std::set<RowID> costDataIDs = hdb_.fuCostEstimationDataIDs(id);
146 if (!costDataIDs.empty()) {
147 stream << "<b>Cost estimation data:</b>" << endl;
148 stream << "<table bgcolor=#bbbbbb>" << endl;
149 stream << "<tr><th>Name</th><th>Value</th>"
150 << "<th>Plugin</th></tr>" << endl;
151 } else {
152 stream << "No cost estimation data.<br>" << endl;
153 }
154 std::set<RowID>::const_iterator iter = costDataIDs.begin();
155 for (; iter != costDataIDs.end(); iter++) {
156 const CostEstimationData data = hdb_.costEstimationData(*iter);
157 stream << "<tr><td>" << data.name() << "</td>"
158 << "<td align=right>";
159 stream << data.value().stringValue();
160 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
161 << "/" << data.pluginID() << "\">"
162 << data.pluginID() << "</a></td></tr>" << endl;
163 }
164 stream << "</table>" << endl;
165 stream << "</small></body></html>" << endl;
166
167 delete entry;
168}
static const std::string FU_ARCHITECTURES
Definition HDBToHtml.hh:70
static const std::string FU_IMPLEMENTATIONS
Definition HDBToHtml.hh:72
FUImplementation & implementation() const
Definition FUEntry.cc:86
virtual bool hasImplementation() const
Definition FUEntry.cc:74
FUArchitecture & architecture() const
Definition FUEntry.cc:129
virtual bool hasArchitecture() const
Definition FUEntry.cc:117
bool hasCostFunction() const
Definition HDBEntry.cc:99
CostFunctionPlugin & costFunction() const
Definition HDBEntry.cc:111
RowID id() const
Definition HDBEntry.cc:85
FUEntry * fuByEntryID(RowID id) const
std::set< RowID > fuCostEstimationDataIDs(RowID fuImplID) const

References HDB::FUEntry::architecture(), COST_PLUGINS, HDB::HDBManager::costEstimationData(), HDB::HDBEntry::costFunction(), FU_ARCHITECTURES, FU_IMPLEMENTATIONS, HDB::HDBManager::fuByEntryID(), HDB::HDBManager::fuCostEstimationDataIDs(), HDB::FUEntry::hasArchitecture(), HDB::HDBEntry::hasCostFunction(), HDB::FUEntry::hasImplementation(), hdb_, HDB::CostFunctionPlugin::id(), HDB::HDBEntry::id(), HWBlockArchitecture::id(), HDB::HWBlockImplementation::id(), HDB::FUEntry::implementation(), HDB::HWBlockImplementation::moduleName(), CostEstimationData::name(), HDB::CostFunctionPlugin::name(), CostEstimationData::pluginID(), DataObject::stringValue(), and CostEstimationData::value().

Referenced by HDBBrowserInfoPanel::displayFUEntry().

Here is the call graph for this function:

◆ fuImplToHtml()

void HDBToHtml::fuImplToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a function unit implementation.

Parameters
idID of the fu implementation.
streamStream where the html is written to.

Definition at line 539 of file HDBToHtml.cc.

539 {
540
542 const HDB::FUEntry* entry = hdb_.fuByEntryID(entryID);
543 const HDB::FUImplementation& impl = entry->implementation();
544
545 stream << "<html><body>" << endl;
546 stream << "<small><table>" << endl;
547
548 stream << "<tr><td align=right><b>Module name:</b></td><td align=left>"
549 << impl.moduleName() << "</td></tr>" << endl;
550
551 stream << "<tr><td align=right><b>Opcode port:</b></td><td align=left>"
552 << impl.opcodePort() << "</td></tr>" << endl;
553
554 stream << "<tr><td align=right><b>Clock port:</b></td><td align=left>"
555 << impl.clkPort() << "</td></tr>" << endl;
556
557 stream << "<tr><td align=right><b>Reset port:</b></td><td align=left>"
558 << impl.rstPort() << "</td></tr>" << endl;
559
560 stream << "<tr><td align=right><b>Global lock port:</b></td>"
561 << "<td align=left>"
562 << impl.glockPort() << "</td></tr>" << endl;
563
564 stream << "<tr><td align=right><b>Global lock req. port:</b></td>"
565 << "<td align=left>"
566 << impl.glockReqPort() << "</td></tr>" << endl;
567
568 stream << "</table><br><br>" << endl;
569
570 // Architecture ports.
571 if (impl.architecturePortCount() > 0) {
572 stream << "<b>Architecture ports:</b>" << endl;
573 stream << "<table bgcolor=#bbbbbb>" << endl;
574 stream << "<tr><th>Name</th>"
575 << "<th>Architecture port</th>"
576 << "<th>Load port</th>"
577 << "<th>Guard port</th>"
578 << "<th>Width formula</th></tr>" << endl;
579 } else {
580 stream << "No architecture ports.<br>" << endl;
581 }
582 for (int i = 0; i < impl.architecturePortCount(); i++) {
583
584 const HDB::FUPortImplementation& port = impl.architecturePort(i);
585 stream << "<tr><td>" << port.name() << "</td>"
586 << "<td>" << port.architecturePort() << "</td>"
587 << "<td>" << port.loadPort() << "</td>"
588 << "<td>" << port.guardPort() << "</td>"
589 << "</td><td>" << port.widthFormula() << "</td></td>" << endl;
590 }
591 stream << "</table><br><br>" << endl;
592
593
594 // Opcodes
595 if (impl.opcodeCount() > 0) {
596 stream << "<b>Opcodes:</b>" << endl;
597 stream << "<table bgcolor=#bbbbbb>" << endl;
598 stream << "<tr><th>Operation</th><th>Opcode</th></tr>" << endl;
599 } else {
600 stream << "No opcodes.<br>" << endl;
601 }
602 for (int i = 0; i < impl.opcodeCount(); i++) {
603 stream << "<tr><td>" << impl.opcodeOperation(i) << "</td>"
604 << "<td align=center>" << impl.opcode(impl.opcodeOperation(i))
605 << "</td></tr>" << endl;
606 }
607 stream << "</table><br><br>" << endl;
608
609 // External ports
610 if (impl.externalPortCount() > 0) {
611 stream << "<b>External ports:</b>" << endl;
612 stream << "<table bgcolor=#bbbbbb>" << endl;
613 stream << "<tr><th>Name</th><th>Direction</th><th>Width formula</th>"
614 << "<th>Parameter dependencies</th>"
615 << "<th>Description</th></tr>" << endl;
616 } else {
617 stream << "No external ports.<br>" << endl;
618 }
619 for (int i = 0; i < impl.externalPortCount(); i++) {
620
621 const HDB::FUExternalPort& port = impl.externalPort(i);
622 stream << "<tr><td>" << port.name() << "</td><td align=center>";
623 if (port.direction() == HDB::IN) {
624 stream << "in";
625 } else if (port.direction() == HDB::OUT) {
626 stream << "out";
627 } else if (port.direction() == HDB::BIDIR) {
628 stream << "bidir";
629 }
630 stream << "</td><td>" << port.widthFormula() << "</td>";
631 stream << "<td>";
632 for (int dep = 0; dep < port.parameterDependencyCount(); dep++) {
633 if (dep > 0) {
634 stream << ", ";
635 }
636 stream << port.parameterDependency(dep);
637 }
638 stream << "</td><td>" << port.description() << "</td></tr>" << endl;
639 }
640 stream << "</table><br><br>" << endl;
641
642
643
644 // Parameters
645 if (impl.parameterCount() > 0) {
646 stream << "<b>Parameters:</b>" << endl;
647 stream << "<table bgcolor=#bbbbbb>" << endl;
648 stream << "<tr><th>Name</th><th>Type</th><th>Value</th></tr>" << endl;
649 } else {
650 stream << "No parameters.<br>" << endl;
651 }
652 for (int i = 0; i < impl.parameterCount(); i++) {
653
654 const HDB::FUImplementation::Parameter& parameter = impl.parameter(i);
655 stream << "<tr><td>" << parameter.name << "</td>"
656 << "<td align=center>" << parameter.type << "</td>"
657 << "<td>" << parameter.value << "</td></tr>" << endl;
658 }
659 stream << "</table><br><br>" << endl;
660
661
662 // Implementation files
663 if (impl.implementationFileCount() > 0) {
664 stream << "<b>Implementation files:</b>" << endl;
665 stream << "<table bgcolor=#bbbbbb>" << endl;
666 stream << "<tr><th>Path</th><th>Format</th></tr>" << endl;
667 } else {
668 stream << "No implementation files.<br>" << endl;
669 }
670 for (int i = 0; i < impl.implementationFileCount(); i++) {
671 const HDB::BlockImplementationFile& file = impl.file(i);
672 stream << "<tr><td>" << file.pathToFile() << "</td>"
673 << "<td align=center>";
675 stream << "VHDL";
676 }else
678 stream << "Verilog";
679 }
680
681 stream << "</td></tr>" << endl;
682 }
683 stream << "</table><br><br>" << endl;
684
685
686 // Cost estimation data
687 const std::set<RowID> costDataIDs = hdb_.fuCostEstimationDataIDs(entryID);
688 if (!costDataIDs.empty()) {
689 stream << "<b>Cost estimation data:</b>" << endl;
690 stream << "<table bgcolor=#bbbbbb>" << endl;
691 stream << "<tr><th>Name</th><th>Value</th>"
692 << "<th>Plugin</th></tr>" << endl;
693 } else {
694 stream << "No cost estimation data.<br>" << endl;
695 }
696 std::set<RowID>::const_iterator iter = costDataIDs.begin();
697 for (; iter != costDataIDs.end(); iter++) {
698 const CostEstimationData data = hdb_.costEstimationData(*iter);
699 stream << "<tr><td>" << data.name() << "</td>"
700 << "<td align=right>";
701 stream << data.value().stringValue();
702 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
703 << "/" << data.pluginID() << "\">"
704 << data.pluginID() << "</a></td></tr>" << endl;
705 }
706 stream << "</table>" << endl;
707 stream << "</small></body></html>" << endl;
708
709
710 delete entry;
711}
int RowID
Type definition of row ID in relational databases.
Definition DBTypes.hh:37
std::string widthFormula() const
std::string parameterDependency(int index) const
int parameterDependencyCount() const
std::string name() const
std::string description() const
Direction direction() const
FUPortImplementation & architecturePort(int index) const
Parameter parameter(int index) const
std::string glockReqPort() const
std::string opcodeOperation(int index) const
FUExternalPort & externalPort(int index) const
std::string opcodePort() const
int opcode(const std::string &operation) const
std::string architecturePort() const
RowID fuEntryIDOfImplementation(RowID implID) const
BlockImplementationFile & file(int index) const
std::string loadPort() const
@ OUT
Output port.
Definition HDBTypes.hh:42
@ BIDIR
Bidirectional port.
Definition HDBTypes.hh:43
@ IN
Input port.
Definition HDBTypes.hh:41
std::string value
Value of the parameter.
Definition HDBTypes.hh:49
std::string type
Type of the parameter.
Definition HDBTypes.hh:48
std::string name
Name of the parameter.
Definition HDBTypes.hh:47

References HDB::FUPortImplementation::architecturePort(), HDB::FUImplementation::architecturePort(), HDB::FUImplementation::architecturePortCount(), HDB::BIDIR, HDB::HWBlockImplementation::clkPort(), COST_PLUGINS, HDB::HDBManager::costEstimationData(), HDB::ExternalPort::description(), HDB::ExternalPort::direction(), HDB::FUImplementation::externalPort(), HDB::FUImplementation::externalPortCount(), HDB::HWBlockImplementation::file(), HDB::BlockImplementationFile::format(), HDB::HDBManager::fuByEntryID(), HDB::HDBManager::fuCostEstimationDataIDs(), HDB::HDBManager::fuEntryIDOfImplementation(), HDB::HWBlockImplementation::glockPort(), HDB::FUImplementation::glockReqPort(), HDB::FUPortImplementation::guardPort(), hdb_, HDB::FUEntry::implementation(), HDB::HWBlockImplementation::implementationFileCount(), HDB::IN, HDB::PortImplementation::loadPort(), HDB::HWBlockImplementation::moduleName(), CostEstimationData::name(), HDB::ExternalPort::name(), HDB::Parameter::name, HDB::PortImplementation::name(), HDB::FUImplementation::opcode(), HDB::FUImplementation::opcodeCount(), HDB::FUImplementation::opcodeOperation(), HDB::FUImplementation::opcodePort(), HDB::OUT, HDB::FUImplementation::parameter(), HDB::FUImplementation::parameterCount(), HDB::ExternalPort::parameterDependency(), HDB::ExternalPort::parameterDependencyCount(), HDB::BlockImplementationFile::pathToFile(), CostEstimationData::pluginID(), HDB::HWBlockImplementation::rstPort(), DataObject::stringValue(), HDB::Parameter::type, CostEstimationData::value(), HDB::Parameter::value, HDB::BlockImplementationFile::Verilog, HDB::BlockImplementationFile::VHDL, HDB::ExternalPort::widthFormula(), and HDB::FUPortImplementation::widthFormula().

Referenced by HDBBrowserInfoPanel::displayFUImplementation().

Here is the call graph for this function:

◆ OperationImplementationResourceToHtml()

void HDBToHtml::OperationImplementationResourceToHtml ( RowID  id,
std::ostream &  stream 
)

Definition at line 1003 of file HDBToHtml.cc.

1003 {
1006
1007 stream << "<html><body>";
1008 stream << "<b>Operation Implementation Resource</b><br/>";
1009 stream << "name : " << res.name << "<br/>";
1010 for (const auto& sim : res.simFiles) {
1011 stream << "simulation file : " << sim << "<br/>";
1012 }
1013 for (const auto& syn : res.synFiles) {
1014 stream << "synthesis file : " << syn << "<br/>";
1015 }
1016 stream << "</body></html>";
1017}
OperationImplementationResource OperationImplementationResourceByID(RowID id) const

References hdb_, HDB::OperationImplementationResource::name, HDB::HDBManager::OperationImplementationResourceByID(), HDB::OperationImplementationResource::simFiles, and HDB::OperationImplementationResource::synFiles.

Referenced by HDBBrowserInfoPanel::displayOperationImplementationResource().

Here is the call graph for this function:

◆ OperationImplementationToHtml()

void HDBToHtml::OperationImplementationToHtml ( RowID  id,
std::ostream &  stream 
)

Definition at line 986 of file HDBToHtml.cc.

986 {
988
989 stream << "<html><body>";
990 stream << "<b>Operation Implementation</b><br/>";
991 stream << "operation : " << op.name << "<br/>";
992 stream << "implementation (VHDL) : " << op.implFileVhdl << "<br/>";
993 stream << "implementation (Verilog) : " << op.implFileVerilog << "<br/>";
994 for(const auto& r : op.resources) {
995 stream << "resource : " << r.name
996 << " * " << r.count
997 << "<br/>";
998 }
999 stream << "</body></html>\n";
1000}
OperationImplementation OperationImplementationByID(RowID id) const

References hdb_, HDB::OperationImplementation::implFileVerilog, HDB::OperationImplementation::implFileVhdl, HDB::OperationImplementation::name, HDB::HDBManager::OperationImplementationByID(), and HDB::OperationImplementation::resources.

Referenced by HDBBrowserInfoPanel::displayOperationImplementation().

Here is the call graph for this function:

◆ rfArchToHtml()

void HDBToHtml::rfArchToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a register file architecture.

Parameters
idID of the register file architecture.
streamStream where the html is written to.

Definition at line 469 of file HDBToHtml.cc.

469 {
470
472
473 stream << "<html><body><small>" << endl;
474 stream << "<table>" << endl;
475
476 // Width
477 stream << "<tr><td align=right><b>Width:</b></td>";
478 if (arch->hasParameterizedWidth()) {
479 stream << "<td>param</td>";
480 } else {
481 stream << "<td align=center>" << arch->width() << "</td>";
482 }
483 stream << "</tr>" << endl;
484
485 // Size
486 stream << "<tr><td align=right><b>Size:</b></td>";
487 if (arch->hasParameterizedSize()) {
488 stream << "<td align=center>param</td>";
489 } else {
490 stream << "<td align=center>" << arch->size() << "</td>";
491 }
492 stream << "</tr>" << endl;
493
494 stream << "<tr><td align=right><b>Read ports:</b></td><td align=center>"
495 << arch->readPortCount() << "</td></tr>" << endl;
496
497 stream << "<tr><td align=right><b>Write ports:</b></td><td align=center>"
498 << arch->writePortCount() << "</td></tr>" << endl;
499
500 stream << "<tr><td align=right><b>Bidirectional ports:</b></td>"
501 << "<td align=center>" << arch->bidirPortCount() << "</td></tr>"
502 << endl;
503
504 stream << "<tr><td align=right><b>Max reads:</b></td><td align=center>"
505 << arch->maxReads() << "</td></tr>" << endl;
506
507 stream << "<tr><td align=right><b>Max Writes:</b></td><td align=center>"
508 << arch->maxWrites() << "</td></tr>" << endl;
509
510 stream << "<tr><td align=right><b>Latency:</b></td><td align=center>"
511 << arch->latency() << "</td></tr>" << endl;
512
513 stream << "<tr><td align=right><b>Guard support:</b></td>";
514 if (arch->hasGuardSupport()) {
515 stream << "<td align=center>yes</td></tr>";
516 stream << "<tr><td align=right><b>Guard Latency:</b></td>"
517 << "<td align=center>" << arch->guardLatency()
518 << "</td></tr>" << endl;
519 } else {
520 stream << "<td align=center>no</td></tr>";
521 }
522 stream << "<tr><td align=right><b>Zero Register:</b></td><td" <<
523 " align=center>" << arch->zeroRegister() << "</td></tr>" << endl;
524
525 stream << "</table></small><br>" << endl;
526 stream << "</body></html>" << endl;
527
528 delete arch;
529}
virtual RFArchitecture * rfArchitectureByID(RowID id) const
bool hasGuardSupport() const
bool hasParameterizedWidth() const
bool zeroRegister() const
bool hasParameterizedSize() const

References HDB::RFArchitecture::bidirPortCount(), HDB::RFArchitecture::guardLatency(), HDB::RFArchitecture::hasGuardSupport(), HDB::RFArchitecture::hasParameterizedSize(), HDB::RFArchitecture::hasParameterizedWidth(), hdb_, HDB::RFArchitecture::latency(), HDB::RFArchitecture::maxReads(), HDB::RFArchitecture::maxWrites(), HDB::RFArchitecture::readPortCount(), HDB::HDBManager::rfArchitectureByID(), HDB::RFArchitecture::size(), HDB::RFArchitecture::width(), HDB::RFArchitecture::writePortCount(), and HDB::RFArchitecture::zeroRegister().

Referenced by HDBBrowserInfoPanel::displayRFArchitecture().

Here is the call graph for this function:

◆ rfEntryToHtml()

void HDBToHtml::rfEntryToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a register file entry.

Parameters
idID of the register file entry.
streamStream where the html is written to.

Definition at line 177 of file HDBToHtml.cc.

177 {
178
179 const HDB::RFEntry* entry = hdb_.rfByEntryID(id);
180
181 stream << "<html><body><small>" << endl;
182 stream << "<b>Register file entry " << entry->id() << "</b><br>" << endl;
183
184 stream << "<table>" << endl;
185 stream << "<tr><td>Architecture:</td><td>";
186 if (entry->hasArchitecture()) {
187 stream << "<a href=\"/" << RF_ARCHITECTURES << "/"
188 << entry->architecture().id() << "\">"
189 << entry->architecture().id() << "</a>"
190 << "</td></tr>" << endl;
191 } else {
192 stream << "-</td></tr>";
193 }
194
195 stream << "<tr><td><b>Implementation:</b></td><td>";
196 if (entry->hasImplementation()) {
197 stream << "<td><a href=\"/" << RF_IMPLEMENTATIONS << "/"
198 << entry->implementation().id() << "\">"
199 << entry->implementation().moduleName() << "</a>"
200 << "</td></tr>" << endl;
201 } else {
202 stream << "-</td></tr>" << endl;
203 }
204
205 stream << "<tr><td align=right><b>Cost function plugin:</b></td><td>";
206 if (entry->hasCostFunction()) {
207 const CostFunctionPlugin& plugin = entry->costFunction();
208 stream << "<a href=\"/" << COST_PLUGINS << "/"
209 << plugin.id() << "\">"
210 << plugin.name()
211 << "</a></td></tr>" << endl;
212 } else {
213 stream << "-</td></tr>" << endl;
214 }
215 stream << "</table>";
216
217 // Cost estimation data
218 const std::set<RowID> costDataIDs = hdb_.rfCostEstimationDataIDs(id);
219 if (!costDataIDs.empty()) {
220 stream << "<b>Cost estimation data:</b>" << endl;
221 stream << "<table bgcolor=#bbbbbb>" << endl;
222 stream << "<tr><th>Name</th><th>Value</th>"
223 << "<th>Plugin</th></tr>" << endl;
224 } else {
225 stream << "No cost estimation data.<br>" << endl;
226 }
227 std::set<RowID>::const_iterator iter = costDataIDs.begin();
228 for (; iter != costDataIDs.end(); iter++) {
229 const CostEstimationData data = hdb_.costEstimationData(*iter);
230 stream << "<tr><td>" << data.name() << "</td>"
231 << "<td align=right>";
232 stream << data.value().stringValue();
233 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
234 << "/" << data.pluginID() << "\">"
235 << data.pluginID() << "</a></td></tr>" << endl;
236 }
237 stream << "</table>" << endl;
238 stream << "</small></body></html>" << endl;
239 delete entry;
240}
static const std::string RF_IMPLEMENTATIONS
Definition HDBToHtml.hh:73
static const std::string RF_ARCHITECTURES
Definition HDBToHtml.hh:71
std::set< RowID > rfCostEstimationDataIDs(RowID rfImplID) const
RFEntry * rfByEntryID(RowID id) const
virtual bool hasImplementation() const
Definition RFEntry.cc:74
RFArchitecture & architecture() const
Definition RFEntry.cc:145
virtual bool hasArchitecture() const
Definition RFEntry.cc:117
RFImplementation & implementation() const
Definition RFEntry.cc:102

References HDB::RFEntry::architecture(), COST_PLUGINS, HDB::HDBManager::costEstimationData(), HDB::HDBEntry::costFunction(), HDB::RFEntry::hasArchitecture(), HDB::HDBEntry::hasCostFunction(), HDB::RFEntry::hasImplementation(), hdb_, HDB::CostFunctionPlugin::id(), HDB::HDBEntry::id(), HWBlockArchitecture::id(), HDB::HWBlockImplementation::id(), HDB::RFEntry::implementation(), HDB::HWBlockImplementation::moduleName(), CostEstimationData::name(), HDB::CostFunctionPlugin::name(), CostEstimationData::pluginID(), RF_ARCHITECTURES, RF_IMPLEMENTATIONS, HDB::HDBManager::rfByEntryID(), HDB::HDBManager::rfCostEstimationDataIDs(), DataObject::stringValue(), and CostEstimationData::value().

Referenced by HDBBrowserInfoPanel::displayRFEntry().

Here is the call graph for this function:

◆ rfImplToHtml()

void HDBToHtml::rfImplToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a register file implementation.

Parameters
idID of the RF implementation.
streamStream where the html is written to.

Definition at line 720 of file HDBToHtml.cc.

720 {
721
723 const RFEntry* entry = hdb_.rfByEntryID(entryID);
724 const RFImplementation& impl = entry->implementation();
725
726 stream << "<html><body>" << endl;
727 stream << "<small><table>" << endl;
728
729 stream << "<tr><td align=right><b>Module name:</b></td><td align=center>"
730 << impl.moduleName() << "</td></tr>" << endl;
731
732 stream << "<tr><td align=right><b>Clock port:</b></td><td align=center>"
733 << impl.clkPort() << "</td></tr>" << endl;
734
735 stream << "<tr><td align=right><b>Reset port:</b></td><td align=center>"
736 << impl.rstPort() << "</td></tr>" << endl;
737
738 stream << "<tr><td align=right><b>Global lock port:</b></td>"
739 << "<td align=center>"
740 << impl.glockPort() << "</td></tr>" << endl;
741
742 stream << "<tr><td align=right><b>Guard port:</b></td>"
743 << "<td align=center>"
744 << impl.guardPort() << "</td></tr>" << endl;
745
746 stream << "<tr><td align=right><b>Size parameter:</b></td>"
747 << "<td align=center>" << impl.sizeParameter() << "</td></tr>"
748 << endl;
749
750 stream << "<tr><td align=right><b>Width parameter:</b></td>"
751 << "<td align=center>" << impl.widthParameter() << "</td></tr>"
752 << endl;
753
754 std::string sac_flag(impl.separateAddressCycleParameter() ?
755 "true" : "false");
756 stream << "<tr><td align=right><b>Separate address cycle:</b></td>"
757 << "<td align=center>"
758 << sac_flag << "</td></tr>" << endl;
759
760 stream << "</table><br><br>" << endl;
761
762
763 // Ports
764 if (impl.portCount() > 0) {
765 stream << "<b>Ports:</b>" << endl;
766 stream << "<table bgcolor=#bbbbbb>" << endl;
767 stream << "<tr><th>Name</th>"
768 << "<th>Direction</th>"
769 << "<th>Load port</th>"
770 << "<th>Opcode port</th>"
771 << "<th>Opcode port width formula</th></tr>" << endl;
772 } else {
773 stream << "No ports.<br>" << endl;
774 }
775 for (int i = 0; i < impl.portCount(); i++) {
776
777 const HDB::RFPortImplementation& port = impl.port(i);
778 stream << "<tr><td>" << port.name() << "</td><td align=center>";
779 if (port.direction() == HDB::IN) {
780 stream << "in";
781 } else if (port.direction() == HDB::OUT) {
782 stream << "out";
783 } else if (port.direction() == HDB::BIDIR) {
784 stream << "bidir";
785 }
786 stream << "</td><td>" << port.loadPort() << "</td>"
787 << "<td>" << port.opcodePort() << "</td>"
788 << "</td><td>" << port.opcodePortWidthFormula()
789 << "</td></td>" << endl;
790 }
791 stream << "</table><br><br>" << endl;
792
793 // External ports
794 if (impl.externalPortCount() > 0) {
795 stream << "<b>External ports:</b>" << endl;
796 stream << "<table bgcolor=#bbbbbb>" << endl;
797 stream << "<tr><th>Name</th><th>Direction</th><th>Width formula</th>"
798 << "<th>Parameter dependencies</th>"
799 << "<th>Description</th></tr>" << endl;
800 } else {
801 stream << "No external ports.<br>" << endl;
802 }
803 for (int i = 0; i < impl.externalPortCount(); i++) {
804
805 const HDB::RFExternalPort& port = impl.externalPort(i);
806 stream << "<tr><td>" << port.name() << "</td><td align=center>";
807 if (port.direction() == HDB::IN) {
808 stream << "in";
809 } else if (port.direction() == HDB::OUT) {
810 stream << "out";
811 } else if (port.direction() == HDB::BIDIR) {
812 stream << "bidir";
813 }
814 stream << "</td><td>" << port.widthFormula() << "</td>";
815 stream << "<td>";
816 for (int dep = 0; dep < port.parameterDependencyCount(); dep++) {
817 if (dep > 0) {
818 stream << ", ";
819 }
820 stream << port.parameterDependency(dep);
821 }
822 stream << "</td><td>" << port.description() << "</td></tr>" << endl;
823 }
824 stream << "</table><br><br>" << endl;
825
826 // Parameters
827 if (impl.parameterCount() > 0) {
828 stream << "<b>Parameters:</b>" << endl;
829 stream << "<table bgcolor=#bbbbbb>" << endl;
830 stream << "<tr><th>Name</th><th>Type</th><th>Value</th></tr>" << endl;
831 } else {
832 stream << "No parameters.<br>" << endl;
833 }
834 for (int i = 0; i < impl.parameterCount(); i++) {
835
836 const HDB::RFImplementation::Parameter& parameter = impl.parameter(i);
837 stream << "<tr><td>" << parameter.name << "</td>"
838 << "<td align=center>" << parameter.type << "</td>"
839 << "<td>" << parameter.value << "</td></tr>" << endl;
840 }
841 stream << "</table><br><br>" << endl;
842
843 // Implementation files
844 if (impl.implementationFileCount() > 0) {
845 stream << "<b>Implementation files:</b>" << endl;
846 stream << "<table bgcolor=#bbbbbb>" << endl;
847 stream << "<tr><th>Path</th><th>Format</th></tr>" << endl;
848 } else {
849 stream << "No implementation files.<br>" << endl;
850 }
851
852 for (int i = 0; i < impl.implementationFileCount(); i++) {
853 const HDB::BlockImplementationFile& file = impl.file(i);
854 stream << "<tr><td>" << file.pathToFile() << "</td>"
855 << "<td align=center>";
857 stream << "VHDL";
858 }else
860 stream << "Verilog";
861 }
862
863 stream << "</td></tr>" << endl;
864 }
865 stream << "</table><br><br>" << endl;
866
867 // Cost estimation data
868 const std::set<RowID> costDataIDs = hdb_.rfCostEstimationDataIDs(entryID);
869 if (!costDataIDs.empty()) {
870 stream << "<b>Cost estimation data:</b>" << endl;
871 stream << "<table bgcolor=#bbbbbb>" << endl;
872 stream << "<tr><th>Name</th><th>Value</th>"
873 << "<th>Plugin</th></tr>" << endl;
874 } else {
875 stream << "No cost estimation data.<br>" << endl;
876 }
877 std::set<RowID>::const_iterator iter = costDataIDs.begin();
878 for (; iter != costDataIDs.end(); iter++) {
879 const CostEstimationData data = hdb_.costEstimationData(*iter);
880 stream << "<tr><td>" << data.name() << "</td>"
881 << "<td align=right>";
882 stream << data.value().stringValue();
883 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
884 << "/" << data.pluginID() << "\">"
885 << data.pluginID() << "</a></td></tr>" << endl;
886 }
887 stream << "</table>" << endl;
888 stream << "</small></body></html>" << endl;
889
890 delete entry;
891}
RowID rfEntryIDOfImplementation(RowID implID) const
RFExternalPort & externalPort(int index) const
RFPortImplementation & port(int index) const
bool separateAddressCycleParameter() const
std::string sizeParameter() const
std::string widthParameter() const
std::string guardPort() const
Parameter parameter(int index) const
std::string opcodePortWidthFormula() const

References HDB::BIDIR, HDB::HWBlockImplementation::clkPort(), COST_PLUGINS, HDB::HDBManager::costEstimationData(), HDB::ExternalPort::description(), HDB::ExternalPort::direction(), HDB::RFPortImplementation::direction(), HDB::RFImplementation::externalPort(), HDB::RFImplementation::externalPortCount(), HDB::HWBlockImplementation::file(), HDB::BlockImplementationFile::format(), HDB::HWBlockImplementation::glockPort(), HDB::RFImplementation::guardPort(), hdb_, HDB::RFEntry::implementation(), HDB::HWBlockImplementation::implementationFileCount(), HDB::IN, HDB::PortImplementation::loadPort(), HDB::HWBlockImplementation::moduleName(), CostEstimationData::name(), HDB::ExternalPort::name(), HDB::Parameter::name, HDB::PortImplementation::name(), HDB::RFPortImplementation::opcodePort(), HDB::RFPortImplementation::opcodePortWidthFormula(), HDB::OUT, HDB::RFImplementation::parameter(), HDB::RFImplementation::parameterCount(), HDB::ExternalPort::parameterDependency(), HDB::ExternalPort::parameterDependencyCount(), HDB::BlockImplementationFile::pathToFile(), CostEstimationData::pluginID(), HDB::RFImplementation::port(), HDB::RFImplementation::portCount(), HDB::HDBManager::rfByEntryID(), HDB::HDBManager::rfCostEstimationDataIDs(), HDB::HDBManager::rfEntryIDOfImplementation(), HDB::HWBlockImplementation::rstPort(), HDB::RFImplementation::separateAddressCycleParameter(), HDB::RFImplementation::sizeParameter(), DataObject::stringValue(), HDB::Parameter::type, CostEstimationData::value(), HDB::Parameter::value, HDB::BlockImplementationFile::Verilog, HDB::BlockImplementationFile::VHDL, HDB::ExternalPort::widthFormula(), and HDB::RFImplementation::widthParameter().

Referenced by HDBBrowserInfoPanel::displayRFImplementation().

Here is the call graph for this function:

◆ socketEntryToHtml()

void HDBToHtml::socketEntryToHtml ( RowID  id,
std::ostream &  stream 
)

Generates a html page of a socket entry.

Parameters
idID of the sovket entry.
streamStream where the html is written to.

Definition at line 289 of file HDBToHtml.cc.

289 {
290
291 stream << "<html><body><small>" << endl;
292 stream << "<b>Socket entry " << id << "</b><br>" << endl;
293
294 stream << "<tr><td align=right><b>Cost estimation data:</b></td><td>";
295
296 // Cost estimation data
297 const std::set<RowID> costDataIDs = hdb_.socketCostEstimationDataIDs(id);
298 if (!costDataIDs.empty()) {
299 stream << "<b>Cost estimation data:</b>" << endl;
300 stream << "<table bgcolor=#bbbbbb>" << endl;
301 stream << "<tr><th>Name</th><th>Value</th>"
302 << "<th>Plugin</th></tr>" << endl;
303 } else {
304 stream << "No cost estimation data.<br>" << endl;
305 }
306 std::set<RowID>::const_iterator iter = costDataIDs.begin();
307 for (; iter != costDataIDs.end(); iter++) {
308 const CostEstimationData data = hdb_.costEstimationData(*iter);
309 stream << "<tr><td>" << data.name() << "</td>"
310 << "<td align=right>";
311 stream << data.value().stringValue();
312 stream << "</td><td align=center><a href=\"/" << COST_PLUGINS
313 << "/" << data.pluginID() << "\">"
314 << data.pluginID() << "</a></td></tr>" << endl;
315 }
316 stream << "</table>" << endl;
317 stream << "</small></body></html>" << endl;
318}
std::set< RowID > socketCostEstimationDataIDs(RowID socketID) const

References COST_PLUGINS, HDB::HDBManager::costEstimationData(), hdb_, CostEstimationData::name(), CostEstimationData::pluginID(), HDB::HDBManager::socketCostEstimationDataIDs(), DataObject::stringValue(), and CostEstimationData::value().

Referenced by HDBBrowserInfoPanel::displaySocketEntry().

Here is the call graph for this function:

Member Data Documentation

◆ BUS_ENTRIES

const std::string HDBToHtml::BUS_ENTRIES = "Bus Entries"
static

Definition at line 68 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::openLink(), and HDBBrowserWindow::update().

◆ COST_PLUGINS

const std::string HDBToHtml::COST_PLUGINS = "Cost Function Plugins"
static

◆ FU_ARCHITECTURES

const std::string HDBToHtml::FU_ARCHITECTURES = "Function Units"
static

◆ FU_ENTRIES

const std::string HDBToHtml::FU_ENTRIES = "FU Entries"
static

◆ FU_IMPLEMENTATIONS

const std::string HDBToHtml::FU_IMPLEMENTATIONS = "FU Implementations"
static

Definition at line 72 of file HDBToHtml.hh.

Referenced by fuEntryToHtml(), and HDBBrowserWindow::openLink().

◆ hdb_

const HDB::HDBManager& HDBToHtml::hdb_
private

◆ HDB_ROOT

const std::string HDBToHtml::HDB_ROOT
static

Definition at line 64 of file HDBToHtml.hh.

◆ OPERATION_IMPLEMENTATION_RESOURCES

const std::string HDBToHtml::OPERATION_IMPLEMENTATION_RESOURCES
static
Initial value:
=
"Operation Implementation Resources"

Definition at line 76 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::onItemSelected(), and HDBBrowserWindow::update().

◆ OPERATION_IMPLEMENTATIONS

const std::string HDBToHtml::OPERATION_IMPLEMENTATIONS
static
Initial value:
=
"Operation Implementations"

Definition at line 75 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::onItemSelected(), and HDBBrowserWindow::update().

◆ RF_ARCHITECTURES

const std::string HDBToHtml::RF_ARCHITECTURES = "Register Files"
static

◆ RF_ENTRIES

const std::string HDBToHtml::RF_ENTRIES = "RF Entries"
static

Definition at line 66 of file HDBToHtml.hh.

Referenced by costFunctionPluginToHtml(), and HDBBrowserWindow::openLink().

◆ RF_IMPLEMENTATIONS

const std::string HDBToHtml::RF_IMPLEMENTATIONS = "RF Implementations"
static

Definition at line 73 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::openLink(), and rfEntryToHtml().

◆ RF_IU_ENTRIES

const std::string HDBToHtml::RF_IU_ENTRIES = "RF/IU Entries"
static

Definition at line 67 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::update().

◆ SOCKET_ENTRIES

const std::string HDBToHtml::SOCKET_ENTRIES = "Socket Entries"
static

Definition at line 69 of file HDBToHtml.hh.

Referenced by HDBBrowserWindow::openLink(), and HDBBrowserWindow::update().


The documentation for this class was generated from the following files: