Chao Liu <lc00...@tecorigin.com> writes: > From: Chao Liu <chao....@yeah.net> > > Hi, all: > > After several rounds of discussion, I think that adding a -t option to the > `info mtree` command, which enables the display of tree-like node characters > (e.g., +--, |--), is a better approach. > > As BALATON Zoltan pointed out, retaining space-based indentation for > displaying > memory region (mr) nodes helps ensure that the output remains easily parseable > by other programs. This also provides better compatibility with existing tools > and scripts.
If people really feed the output of HMP info mtree to parsers, we should probably provide the information via QMP. > Users can choose between: > > - Without '-t': The default format using spaces for indentation, suitable for > scripting and parsing; > - With '-t': The tree-style format using visual characters, ideal for > human-readable output. > > This way, both usability and compatibility are preserved. Maintaining compatibility is a choice in HMP, not a requirement. I'm not judging, mind.