I also think so, and there was a small discussion on #lisp, where we agreed to dump the flow graph as a data structure which can be a valid input to READ. At this time I think about the format like this:

(component
 (id 278371239)
 (head :refid 6376138123) ;references the separate graph element
 (kind initial)
  ...)

(cblock
 (id 6376138123)
 (component :refid 278371239)
 (loop nil)
  ...)

...

So, it is the very straightforward dump of the code flow graph elements. Two problems arise here:

1) How to assign the unique ID to all graph elements without tweaking node.lisp. This is needed to avoid the infinite loops during the dumping process, and to establish connections between data structures, as shown in the example.
2) How to avoid too tight coupling with the structures definitions (in other words, how to write the universal dumper, which can accept any structure instance and iterate over all slots automatically. Maybe it is easy, but I haven't tried to dig into it yet).

Any ideas about the format or dumper improvements/implementation are very welcome :)

Regards,
Roman

2010/6/13 Levente Mészáros <levente.meszaros@gmail.com>
On Sat, Jun 12, 2010 at 1:02 PM, Roman Marynchak
<roman.marynchak@gmail.com> wrote:
>> What do you think about this idea? Are there better alternatives?
It would be nice to have a layer where you can just get the flow graph
back as a structure. This would allow integrating with a dynamic code
browser or SLIME for example.

levy

--
There's no perfectoin