Hi, > https://github.com/aliguori/qidl/ > > In your example: > > struct SomeDev { > DeviceState _immutable dev; > Chardev _immutable *chr; > uint32_t reg1; > uint32_t reg2; > [ ... ] > }; > >> >> ... instead of the vmstate structs we create manually today. Likewise >> for properties. And probably we can even generate different visitors >> for different "views" at the same struct. > > qc generates a json description of the struct. You can then use a > generate to take that json and generate code for VMState, QAPI, etc. > > The readme has quite a lot of detail about the syntax. The parser is > pretty complete already. > > https://github.com/aliguori/qidl/blob/master/qc.md
Ah, nice. Any plans to support lists there, so it is possible to save the state of (multiple) in-flight transactions? > But I want to get us moving on QOM first before I go any further with > this. We can always go back and remove the manually written visit > functions. Sure, one step at a time. It helps when reviewing to have a rough idea of the big pixture though ... cheers, Gerd