From: <by...@nc...> - 2013-07-24 19:58:00
|
[All of the adds are in SVN. Nothing is "written in stone" yet.] I added struct and union scope types to the FST writer/reader. As far as I can tell, you don't really need arrays as the variable name conveys enough information. If I'm wrong, this is an easy add. Note that even though it's not a part of the VCD "standard", I've also added generate, struct, and union as scope types to the VCD parsers in gtkwave and vcd2fst. fst2vcd will write out such scope types if it encounters them. As a side note: void fstWriterSetScope(void *ctx, enum fstScopeType scopetype, const char *scopename, const char *scopecomp); ...I don't see FSDB supporting it as an element in their "tree types", but for the union/struct, if the simulator fills in the appropriate struct/union type for scopecomp, this will be viewable in gtkwave as well. That is if you have struct t_color and it is called "a", you'll see "a (t_color)" in the SST. I added struct and union as scope rather than tree types (as FSDB does) as they do generate a level of hierarchy when one descends into the instantiation. It doesn't make a whole lot of sense to me having to define a new tree type when it's more-or-less similar in function to how a scope functions. I'll add more SV types to FST and gtkwave as I experiment more. I don't use SV on my day job so I'm mostly looking at SV documentation and am massaging the example .sv files I was provided yesterday to see what comes out of VCS+FSDB. I'll likely hold off on the tarball release of gtkwave for a while longer than usual to add more of these SV features, but it looks like a good excuse finally to bump up the version number up to the 3.4 series. -Tony enum fstScopeType { FST_ST_VCD_MIN = 0, FST_ST_VCD_MODULE = 0, FST_ST_VCD_TASK = 1, FST_ST_VCD_FUNCTION = 2, FST_ST_VCD_BEGIN = 3, FST_ST_VCD_FORK = 4, FST_ST_VCD_GENERATE = 5, FST_ST_VCD_STRUCT = 6, FST_ST_VCD_UNION = 7, FST_ST_VCD_MAX = 7, FST_ST_MAX = 7, FST_ST_VCD_SCOPE = 254, FST_ST_VCD_UPSCOPE = 255 }; |