mirror of
https://github.com/YosysHQ/yosys.git
synced 2026-08-29 01:24:25 +02:00
sim: Improvements and fixes for yw cosim
* Fixed $cover handling * Improved sparse memory handling when writing traces * JSON summary output
This commit is contained in:
+1
-1
@@ -161,7 +161,7 @@ ReadWitness::ReadWitness(const std::string &filename) :
|
||||
signal.offset = signal_json["offset"].int_value();
|
||||
if (signal.offset < 0)
|
||||
log_error("Failed to parse `%s`: Invalid offset for signal `%s`\n", filename.c_str(), signal_json.dump().c_str());
|
||||
signal.init_only = json["init_only"].bool_value();
|
||||
signal.init_only = signal_json["init_only"].bool_value();
|
||||
signals.push_back(signal);
|
||||
}
|
||||
|
||||
|
||||
+12
@@ -52,6 +52,18 @@ struct WitnessHierarchyItem {
|
||||
template<typename D, typename T>
|
||||
void witness_hierarchy(RTLIL::Module *module, D data, T callback);
|
||||
|
||||
template<class T> static std::vector<std::string> witness_path(T *obj) {
|
||||
std::vector<std::string> path;
|
||||
if (obj->name.isPublic()) {
|
||||
auto hdlname = obj->get_string_attribute(ID::hdlname);
|
||||
for (auto token : split_tokens(hdlname))
|
||||
path.push_back("\\" + token);
|
||||
}
|
||||
if (path.empty())
|
||||
path.push_back(obj->name.str());
|
||||
return path;
|
||||
}
|
||||
|
||||
struct ReadWitness
|
||||
{
|
||||
struct Clock {
|
||||
|
||||
Reference in New Issue
Block a user