Quoting Joonas Lahtinen (2018-03-23 12:29:54) > Quoting Jani Nikula (2018-03-21 14:16:37) > > On Wed, 21 Mar 2018, Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> wrote: > > > Quoting Jani Nikula (2018-03-21 11:47:06) > > >> > > >> > Quoting Chris Wilson (2018-03-21 10:41:37) > > >> >> > > >> >> Just idly testing the waters... > > >> >> > > >> >> In yaml, this would be > > >> >> "<indent>- slice%d: { subslices: %u, mask: 0x%04x }\n" > > >> > > > >> > Or if we keep the node name the same for easier parsing: > > >> > > > >> > "<indent>- slice: { id:%u, subslices:%u, mask:0x%04x }\n" > > >> > > >> I'm not against doing this, especially for gpu dumps. > > >> > > >> Wouldn't json be easier to generate and parse? Or do you prefer the > > >> slightly better human readability of yaml? > > > > > > I think for any of the debug output preferring to keep it as readable as > > > possible is essential. libyaml isn't that hard to use, even for a > > > beginner like myself. > > > > Fair enough; I'm only familiar with json, and that's my natural reason > > to lean towards it. > > JSON gets irritating to look at by plain eye. So I would agree that YAML > would serve better when developers are likely to scroll through the file > contents manually, too. > > Then some more random thoughts: > > This discussion will of course bring closer the can of forms that when > we've formalized the debugfs format, does somebody expect it to stay > more stable than not? The starting point is that we do want to transition to an easier-to-extend file format for sysfs (the idea of it being single-valued is long gone :) There having a stable interface is without question, so getting the transition right is the challenge and then maintaining the hierarchy such that it is backwards and forward compatible with new content. > Having a counterpart in IGT and making that always match kernel, would > be the obvious way to keep things sane. Imo, if we aren't parsing debugfs in igt, then they can be dead code eliminated. So I expect yamlification to snow ball once we've got the first few done and a good feel for how to design kernel/igt API to suite us. Then it's just a matter of throwing each debugfs through a yamllint :) -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx