Bill Currie
0b49bd343c
Collect information on statements that set or use vars.
...
First, it turns out using daglabels wasn't such a workable plan (due to
labels being flushed every sblock). Instead, flowvars are used. Each actual
variable (whether normal or temp) has a pointer to the flowvar attached to
that variable.
For each variable, the statements that use or define the variable are
recorded in the appropriate set attached to each (flow)variable.
2012-11-15 13:44:08 +09:00
Bill Currie
739ebc522c
Begin working on flow analysis.
...
For now, variable and flow graph node maps are built.
2012-11-15 13:44:06 +09:00
Bill Currie
dc9d2a982e
Make the returned dag a linked list of root-nodes.
...
A dag can have mulitple "root" nodes (ie, nodes with no parents).
2012-11-15 13:44:06 +09:00
Bill Currie
0ccf4093e4
Handle attached identifier labels correctly.
...
I'd forgotten I had the prev field. Makes for much cleaner code.
2012-11-15 13:44:06 +09:00
Bill Currie
dbf1aa8f72
Attach dags to statement blocks.
...
Now, if a dag is attached to a statement block, it will be included in the
flowgraph with that statement block.
2012-11-15 13:44:06 +09:00
Bill Currie
d9354255a3
Avoid double-printing dag nodes.
2012-11-15 13:44:05 +09:00
Bill Currie
8015e1b1e9
Put the dags stuff into a qfcc sub-section.
...
Not much point writting docs if they can't be found.
2012-11-15 13:44:05 +09:00
Bill Currie
aa2943709e
Start work on building dags from basic blocks.
...
Doesn't compile and the design is in flux anyway, but I want to get back to
iqm.
2012-11-15 13:44:05 +09:00
Bill Currie
60108c688c
Change dags from binary to trinary.
...
I'd forgotten some instructions take three inputs that can benefit from
CSE.
2012-11-15 13:44:05 +09:00
Bill Currie
0fefeb73fe
Initial support for basic block dags.
...
Currently, only dumping to dot, but that seems to be a very sensible place
to start: debug support.
2012-11-15 13:44:05 +09:00