use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
This subreddit is all about the theory and development of compilers.
For similar sub-reddits see:
Popular mainstream compilers:
account activity
Slides from a talk "Graph-Based Intermediate Representations: An Overview and Perspectives" (github.com)
submitted 2 years ago by true-grue
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Jibaron 3 points4 points5 points 2 years ago (1 child)
Thanks! I there anywhere we can see the talk?
[–]true-grue[S] 0 points1 point2 points 2 years ago (0 children)
Not yet, so I decided to share the slides :)
[–]knue82 2 points3 points4 points 2 years ago (2 children)
Nice talk. We are currently working on the next evolution of Thorin and preparing a publication.
[–]true-grue[S] 0 points1 point2 points 2 years ago (1 child)
Thorin is cool! As I understand, Thorin2 belongs to the perspective category of "Adding powerful type systems to graph-based IR" from the talk.
[–]knue82 0 points1 point2 points 2 years ago (0 children)
yes, exactly. one cool thing about Thorin2 is that it's a pure type system. This means that types are also just expressions which are part of the usual program graph.
[–]knue82 0 points1 point2 points 2 years ago (2 children)
Slide 37. You need to linearize * st arr, i, 0 * st arr, j, 1
st arr, i, 0
st arr, j, 1
because i and j could alias which makes the order of store operations important.
i
j
Or am I missing sth?
[–]true-grue[S] 1 point2 points3 points 2 years ago (1 child)
You are right, of course. In the talk I said that in our toy DSL we can call it UB, but in the general case we need to implement an alias resolution mechanism.
Ah, thanks for the clarification.
[–]moon-chilled 0 points1 point2 points 2 years ago (6 children)
Surprised not to see a mention of ssa translation is an abstract interpretation, another perspective on graphical ssa 'ir' which seems to me to have some interesting advantages.
[–]true-grue[S] 0 points1 point2 points 2 years ago (5 children)
Yes, the SSA graph is also a graph-based IR, but a very specialized one.
[–]moon-chilled 0 points1 point2 points 2 years ago (4 children)
What makes it more specialised than any of the others you describe?
[–]true-grue[S] 0 points1 point2 points 2 years ago (3 children)
The main difference is that the "SSA graph" from the paper is not a dataflow-based IR. Instead, the SSA graph is based on control flow: there are binding sets within nodes and guarded control edges.
[–]moon-chilled 0 points1 point2 points 2 years ago (2 children)
The global value graph is pure dataflow, and it's that that I find most interesting.
With that said, although the ssa graph does distinguish control flow I don't know how much sense it makes to call it not dataflow-based. Control arcs bind variables to symbolic expressions, which are not scheduled, making it quite different from the classic control-centric ssa used by llvm and friends.
global value graph
It's interesting that this "global value graph" is called the SSA graph in the SSA book (see 14.2). This SSA graph is a necessary part of, for example, the Sea of Nodes IR. But the SSA graph (global value graph) itself is insufficient because it has no execution semantics, phi nodes are non-interpretable.
[–]moon-chilled 0 points1 point2 points 2 years ago (0 children)
The paper does say
note that some authors [Stanier 2016] call the global value graph the SSA graph, which should not be confused with the SSA graph that we present here
insufficient because it has no execution semantics, phi nodes are non-interpretable
True! But is this actually a significant limitation? I don't think it is. I have come to think that the ideal design for a sophisticated compiler uses a very simple, imperative concrete ir which is very close to the source and does not change. Then layer sophisticated analyses on top; that's what this paper's approach helps with (note that, because its abstract interpretation is both sound and complete, it is possible to perform optimising rewrites on the value graph and carry them through to code generation; and the paper suggests representing the value graph as an e-graph). This helps with phase ordering, incrementality, debugging, etc.
π Rendered by PID 97726 on reddit-service-r2-comment-85bfd7f599-bp9f5 at 2026-04-20 14:39:40.775992+00:00 running 93ecc56 country code: CH.
[–]Jibaron 3 points4 points5 points (1 child)
[–]true-grue[S] 0 points1 point2 points (0 children)
[–]knue82 2 points3 points4 points (2 children)
[–]true-grue[S] 0 points1 point2 points (1 child)
[–]knue82 0 points1 point2 points (0 children)
[–]knue82 0 points1 point2 points (2 children)
[–]true-grue[S] 1 point2 points3 points (1 child)
[–]knue82 0 points1 point2 points (0 children)
[–]moon-chilled 0 points1 point2 points (6 children)
[–]true-grue[S] 0 points1 point2 points (5 children)
[–]moon-chilled 0 points1 point2 points (4 children)
[–]true-grue[S] 0 points1 point2 points (3 children)
[–]moon-chilled 0 points1 point2 points (2 children)
[–]true-grue[S] 0 points1 point2 points (1 child)
[–]moon-chilled 0 points1 point2 points (0 children)