Structure and Class Documentation
#4
(12-24-2021, 01:18 PM)Seeky Wrote: I didn't know about katai at the time I was working on this, and it was mainly just meant to be a reference to get the information out there, rather than something that could be directly used in code; almost everything was written in asm at the time, and I didn't really want to spend time making sure the syntax of everything was valid

Edit: looking at katai again, it also seems like it's not ideal for this purpose at all. Compiling it to C++ creates a huge amount of overhead compared to a simple struct/class definition, and since it's mainly meant for file formats, you have to add a load of useless steps to each struct definition just to tell it it's one block of information

The only amount of overhead is the generation of the parser, which shouldn't be comparable to the parsing itself, given the size of the data. Still, the parser generation is a one-off thing and would not at any case run real-time, but the parser itself would be as fast as a human would write it. I don't see it ever being human-noticeable slow anyway.

Can you maybe clarify a little bit what you mean by "mainly used for file formats" and "useless steps"? Kaitai has been used for executables, core dumps, filesystems and many things https://formats.kaitai.io/. I don't see any limitations for MEM1 dumps. I don't see any useless steps to definitions, you just need to be completely precise so parsers can be generated. That's the point of the tool. You can write the kaitai file as a draft if you want and not make sure it compiles into a proper parser and this would be equivalent to the current project. The only difference is that it would be scalable to an at least partially actual working one, if eventually someone finds the time.

In the end, this can be a tradeoff of documentation time and utility. A basic kaitai file could be used to create very powerful tools, such as a custom real time dashboard of all variables of interest in MKW memory, wiimm like tools (for static files, not RAM memory) and so on. I think it would be timelessly useful tool that can be scaled into arbitrarily interesting stuff.
Reply


Messages In This Thread
Structure and Class Documentation - by Seeky - 05-07-2020, 07:17 PM
RE: Structure and Class Documentation - by Seeky - 12-24-2021, 01:18 PM
RE: Structure and Class Documentation - by em_eight - 12-24-2021, 02:43 PM
RE: Structure and Class Documentation - by Seeky - 12-24-2021, 05:14 PM
RE: Structure and Class Documentation - by Seeky - 12-24-2021, 06:44 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)