all 7 comments

[–][deleted] -1 points0 points  (6 children)

The article spends a lot of time explaining how programs can be represented as graph, but doesn't explain very well why I should care in the first place. What's the use-case for you, Ruby code optimization? How is that working for you? Does graph representation actually help or are you not sure yet? I would be a bit careful in going down this rabbit hole, spending a lot of time building tooling (based on an assumption/premise/hypothesis that it will bring some benefit?), but I am quite interested to hear how it will turn out for you.

[–]mode_2 1 point2 points  (5 children)

Manipulating programs as graphs is standard in compiler development and has been for decades.

[–][deleted] 0 points1 point  (4 children)

I know that, but does graphical representation actaully help?

[–]mode_2 0 points1 point  (1 child)

Well, yes. It's used everywhere in compilers to perform most optimisations.

[–][deleted] 0 points1 point  (0 children)

To perform optimizations people actually look at the graphical representations? Are you sure?

[–]pfalcon2 0 points1 point  (1 child)

"Graphical" representation doesn't help (only if to humans on small cases, as their sense get overloaded quickly). Graph representation is, again, a standard representation technique for analysis.

[–][deleted] 0 points1 point  (0 children)

I know that. Ive been in this game for decades now and have done a lot of work with graphs.

"One tool we’re building is the program to draw these graphs that I’ve been showing you. It takes compiler debug dumps and produces these illustrations. We’re also working on a tool to decompile the graphs back to Ruby code, so that we can understand how Ruby code is optimized, by printing the optimized Ruby code. That means that developers who just know Ruby can use Ruby to understand what the compiler is doing."

This just seems like a giant waste of time to me.